jwks

package
v0.0.0-...-e204074 Latest Latest
Warning

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

Go to latest
Published: Nov 23, 2024 License: AGPL-3.0 Imports: 8 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrNoKidInJWT = jwksError{errors.New("no header kid in JWT header")}
View Source
var ErrNoSuchKid = jwksError{errors.New("no such kid")}

Functions

This section is empty.

Types

type Option

type Option func(v *Verifier)

func WithHttpClient

func WithHttpClient(httpClient *http.Client) Option

type Verifier

type Verifier struct {
	// contains filtered or unexported fields
}

func NewVerifier

func NewVerifier(jwksUri string, opts ...Option) *Verifier

func (*Verifier) JWTKeyFunc

func (v *Verifier) JWTKeyFunc(token *jwt.Token) (any, error)

func (*Verifier) JWTKeyFuncWithContext

func (v *Verifier) JWTKeyFuncWithContext(ctx context.Context) jwt.Keyfunc

func (*Verifier) Key

func (v *Verifier) Key(ctx context.Context, kid string) (jose.JSONWebKey, error)

Jump to

Keyboard shortcuts

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