auth

package
v1.9.14 Latest Latest
Warning

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

Go to latest
Published: Sep 13, 2024 License: MPL-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ThisIssuer   = "vgss"
	ThisAudience = "https://api.vpngen.com"
)

Variables

View Source
var (
	SwaggerErrTokenInvalid = swagerrs.New(http.StatusUnauthorized, "invalid token")
	SwaggerErrTokenExpired = swagerrs.New(http.StatusUnauthorized, "token expired")
)

Functions

func JWTValidator

func JWTValidator(logger *slog.Logger, a jwtauth.Authorizer, bearerToken string, scope []string, testing bool) (*models.Principal, error)

func NewOptions

func NewOptions(m jwt.SigningMethod) jwtauth.Options

Types

This section is empty.

Jump to

Keyboard shortcuts

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