Versions in this module Expand all Collapse all v1 v1.5.1 May 14, 2026 v1.5.0 May 13, 2026 Changes in this version + const DefaultJWKSTimeout + var ErrEmptyKeySet = errors.New("JWKS key set is empty") + var ErrInvalidAudience = errors.New("token audience does not match issuer configuration") + var ErrInvalidConfiguration = errors.New("no claim mapping configured for requested organization") + var ErrInvalidJWK = errors.New("invalid JWK") + var ErrInvalidRole = errors.New("role is not in allowed roles set") + var ErrInvalidScope = errors.New("token scopes do not match required scopes for issuer") + var ErrJWKSFetch = errors.New("failed to fetch JWKS") + var ErrJWKSNotInitialized = errors.New("JWKS not initialized - call UpdateAllJWKS first") + var ErrJWKSURLEmpty = errors.New("JWKS URL is empty") + var ErrJWKSUpdateInProgress = errors.New("JWKS update already in progress") + var ErrKeyNotFound = errors.New("key not found") + var ErrNoClaimRoles = errors.New("no roles found in token claims for organization") + var ErrNoValidKeys = errors.New("JWKS contains no valid keys") + var ErrReservedOrgName = errors.New("token claims a reserved organization name") + var ScopeClaims = []string + func ComputeIssuerPrefix(issuerURL string) string + func GetClaimAttribute(claims jwt.MapClaims, attribute string) any + func GetClaimAttributeAsString(claims jwt.MapClaims, attributes ...string) string + func GetScopes(claims jwt.MapClaims) []string + func InterfaceToStringSlice(v any) ([]string, error) + type JWKS struct + Set *jose.JSONWebKeySet + func NewJWKSFromURL(url string, timeout time.Duration) (*JWKS, error) + func (jwks JWKS) GetKeyByID(keyID string) (*jose.JSONWebKey, error) + func (jwks JWKS) GetKeysForAlgorithm(algorithm string) []jose.JSONWebKey