Documentation ¶
Index ¶
- func AuthFromAuthorizationHeader(keyFunc jwt.Keyfunc, claimsFunc ClaimsFunc, signingMethod jwt.SigningMethod, ...) nhttp.Handler
- func AuthFromQueryParam(keyFunc jwt.Keyfunc, claimsFunc ClaimsFunc, signingMethod jwt.SigningMethod, ...) nhttp.Handler
- func Logging(logger log.Logger, next nhttp.Handler) nhttp.Handler
- type ClaimsFunc
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AuthFromAuthorizationHeader ¶
func AuthFromAuthorizationHeader(keyFunc jwt.Keyfunc, claimsFunc ClaimsFunc, signingMethod jwt.SigningMethod, next nhttp.Handler) nhttp.Handler
AuthFromAuthorizationHeader is a middleware that extracts the token from the authorization header and verifies it
func AuthFromQueryParam ¶
func AuthFromQueryParam(keyFunc jwt.Keyfunc, claimsFunc ClaimsFunc, signingMethod jwt.SigningMethod, next nhttp.Handler) nhttp.Handler
AuthFromQueryParam is a middleware that extracts the token from the query parameter and verifies it
Types ¶
type ClaimsFunc ¶
type ClaimsFunc func() jwt.Claims
ClaimsFunc is a function that returns a jwt.Claims with the custom claims and correct type
Click to show internal directories.
Click to hide internal directories.