Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrInvalidKid = errors.New("invalid kid") ErrUnsetKid = errors.New("unset kid") )
Functions ¶
This section is empty.
Types ¶
type Auth ¶
type Auth[CustomClaims any] struct { // contains filtered or unexported fields }
func NewWithClock ¶
func (*Auth[CustomClaims]) GenerateToken ¶
func (*Auth[CustomClaims]) ParseToken ¶
type Key ¶
type Key struct { Kid string // jwt 'kid' header value to identify the correct key for verifying SigningKey any // key used for signing: symmetric methods have the same signing and verifying key VerifyingKey any // key used for verifying: symmetric methods have the same signing and verifying key SigningMethod jwt.SigningMethod // key signing method // contains filtered or unexported fields }
func NewECDSAKey ¶
func NewECDSAKey( kid string, key *ecdsa.PrivateKey, signingMethod *jwt.SigningMethodECDSA, ) *Key
func NewHMACKey ¶
func NewRSAKey ¶
func NewRSAKey( kid string, key *rsa.PrivateKey, signingMethod *jwt.SigningMethodRSA, ) *Key
func (*Key) Deprecated ¶
Mark the key as deprecated. Deprecated keys are used only for verifying and not signing.
Click to show internal directories.
Click to hide internal directories.