Documentation ¶
Index ¶
- Variables
- func IsAdmin(next fasthttp.RequestHandler) fasthttp.RequestHandler
- func IsAdminFiber(c *fiber.Ctx) error
- func ValidateAdminPermissions(next fasthttp.RequestHandler, serviceName string) fasthttp.RequestHandler
- func VerifyAdmin(ctx *fasthttp.RequestCtx, host string) (uint64, error)
- func VerifyAdminFiber(c *fiber.Ctx, host string) (uint64, error)
- func VerifyUserFiber(c *fiber.Ctx, host string) (uint64, error)
- type TotalAdminPermission
Constants ¶
This section is empty.
Variables ¶
Functions ¶
func IsAdmin ¶ added in v1.5.15
func IsAdmin(next fasthttp.RequestHandler) fasthttp.RequestHandler
func IsAdminFiber ¶ added in v1.5.15
func IsAdminFiber(c *fiber.Ctx) error
func ValidateAdminPermissions ¶ added in v1.5.15
func ValidateAdminPermissions(next fasthttp.RequestHandler, serviceName string) fasthttp.RequestHandler
func VerifyAdmin ¶
func VerifyAdmin(ctx *fasthttp.RequestCtx, host string) (uint64, error)
func VerifyAdminFiber ¶ added in v1.5.1
func VerifyUserFiber ¶ added in v1.5.13
Types ¶
type TotalAdminPermission ¶ added in v1.5.8
type TotalAdminPermission struct { IsAvailableTools bool `json:"tools,omitempty"` IsAvailableTerminals bool `json:"terminals,omitempty"` IsAvailableUsers bool `json:"users,omitempty"` IsAvailableBackendTesting bool `json:"backendTesting,omitempty"` IsAvailableDocumentation bool `json:"documentation,omitempty"` IsAvailableInsights bool `json:"insights,omitempty"` IsAvailableBalancer bool `json:"balancer,omitempty"` IsAvailableNews bool `json:"news,omitempty"` IsAvailableTwitter bool `json:"twitter,omitempty"` IsAvailableForex bool `json:"forex,omitempty"` IsAvailableLanguages bool `json:"languages,omitempty"` }
func FetchAdminPermissions ¶ added in v1.5.8
func FetchAdminPermissions(ctx *fasthttp.RequestCtx, host string) (perms TotalAdminPermission, err error)
func GetAdminPermissions ¶ added in v1.5.15
func GetAdminPermissions(ctx *fasthttp.RequestCtx) (permissions TotalAdminPermission, err error)
Click to show internal directories.
Click to hide internal directories.