package
0.0.6
Repository: https://github.com/coderi421/gframework.git
Documentation: pkg.go.dev

# Functions

KeyExpired checks if a key has expired, if the value of user.SessionState.Expires is 0, it will be ignored.
NewAutoStrategy create auto strategy with basic strategy and jwt strategy.
NewBasicStrategy create basic strategy with compare function.
NewCacheStrategy create cache strategy with function which can list and cache secrets.
NewJWTStrategy create jwt bearer strategy with GinJWTMiddleware.

# Constants

AuthzAudience defines the value of jwt audience field.

# Variables

Defined errors.
Defined errors.

# Structs

AutoStrategy defines authentication strategy which can automatically choose between Basic and Bearer according `Authorization` header.
BasicStrategy defines Basic authentication strategy.
CacheStrategy defines jwt bearer authentication strategy which called `cache strategy`.
JWTStrategy defines jwt bearer authentication strategy.
Secret contains the basic information of the secret key.