go_jwt

package module
v0.6.3 Latest Latest
Warning

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

Go to latest
Published: Oct 15, 2025 License: GPL-3.0 Imports: 1 Imported by: 5

Documentation

Index

Constants

View Source
const (
	// BearerPrefix is the prefix for the bearer token
	BearerPrefix = "Bearer"
)

Variables

View Source
var (
	// CtxRefreshTokenClaimsKey is the key for the refresh token context claims
	CtxRefreshTokenClaimsKey = "refresh_token_claims"

	// CtxAccessTokenClaimsKey is the key for the access token context claims
	CtxAccessTokenClaimsKey = "access_token_claims"

	// CtxRefreshTokenKey is the key for the refresh token context token
	CtxRefreshTokenKey = "refresh_token"

	// CtxAccessTokenKey is the key for the access token context token
	CtxAccessTokenKey = "access_token"

	// IDClaim is the claim for the JWT ID
	IDClaim = "jti"

	// IsRefreshTokenClaim is the claim for refresh token
	IsRefreshTokenClaim = "irt"

	// SubjectClaim is the claim for the subject
	SubjectClaim = "sub"
)
View Source
var (
	ErrUnableToParsePrivateKey            = errors.New("unable to parse private key")
	ErrUnableToParsePublicKey             = errors.New("unable to parse public key")
	ErrInvalidKeyType                     = errors.New("invalid key type")
	ErrMissingTokenInContext              = errors.New("missing token in context")
	ErrMissingTokenClaimsInContext        = errors.New("missing token claims in context")
	ErrUnexpectedTokenTypeInContext       = errors.New("unexpected token type in context")
	ErrUnexpectedTokenClaimsTypeInContext = errors.New("unexpected token claims type in context")
	ErrEmptyToken                         = errors.New("empty token")
)

Functions

This section is empty.

Types

This section is empty.

Jump to

Keyboard shortcuts

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