Documentation ¶
Index ¶
- func GetBearerTokenFromReq(ctx types.Context, req *http.Request) string
- func ValidateAuthTokenWithCtx(ctx types.Context, config *types.AuthConfig) (*types.AuthToken, error)
- func ValidateAuthTokenWithCtxOrReq(ctx types.Context, config *types.AuthConfig, req *http.Request) (*types.AuthToken, error)
- func ValidateAuthTokenWithJWT(ctx types.Context, config *types.AuthConfig, encJWT string) (*types.AuthToken, error)
- func ValidateAuthTokenWithReq(ctx types.Context, config *types.AuthConfig, req *http.Request) (*types.AuthToken, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetBearerTokenFromReq ¶
GetBearerTokenFromReq retrieves the bearer token from the HTTP request.
func ValidateAuthTokenWithCtx ¶
func ValidateAuthTokenWithCtx( ctx types.Context, config *types.AuthConfig) (*types.AuthToken, error)
ValidateAuthTokenWithCtx validates the auth token from the provided context.
func ValidateAuthTokenWithCtxOrReq ¶
func ValidateAuthTokenWithCtxOrReq( ctx types.Context, config *types.AuthConfig, req *http.Request) (*types.AuthToken, error)
ValidateAuthTokenWithCtxOrReq validates the auth token from the provided context. If not present in the context attempt a validation against the provided HTTP request.
func ValidateAuthTokenWithJWT ¶
func ValidateAuthTokenWithJWT( ctx types.Context, config *types.AuthConfig, encJWT string) (*types.AuthToken, error)
ValidateAuthTokenWithJWT validates the auth token from the provided JWT.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.