server

package
v0.0.0-...-b7f3801 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 18, 2024 License: MIT Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrNotEnoughPerm = errors.New("You aren't authorized to perform this action.")
)
View Source
var (
	PsshNotFound = errors.New("pssh field can not be emtpy")
)

Functions

This section is empty.

Types

type FiberServer

type FiberServer struct {
	*fiber.App

	DB database.Service
}

func New

func New() *FiberServer

func (*FiberServer) AddSudoerHandler

func (s *FiberServer) AddSudoerHandler(c *fiber.Ctx) error

func (*FiberServer) ArsenalKeyHandler

func (s *FiberServer) ArsenalKeyHandler(c *fiber.Ctx) error

func (*FiberServer) AuthHandler

func (s *FiberServer) AuthHandler(c *fiber.Ctx) error

AuthHandler just returns ok if user is authenticated or not

func (*FiberServer) ChallengeHandler

func (s *FiberServer) ChallengeHandler(c *fiber.Ctx) error

func (*FiberServer) KeyHandler

func (s *FiberServer) KeyHandler(c *fiber.Ctx) error

func (*FiberServer) RegisterFiberRoutes

func (s *FiberServer) RegisterFiberRoutes()

func (*FiberServer) RevokeSudoerHandler

func (s *FiberServer) RevokeSudoerHandler(c *fiber.Ctx) error

func (*FiberServer) SUChecker

func (s *FiberServer) SUChecker(c *fiber.Ctx, key string) (bool, error)

func (*FiberServer) ValidateAPIKey

func (s *FiberServer) ValidateAPIKey(c *fiber.Ctx, key string) (bool, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL