Documentation
¶
Index ¶
- Variables
- func WithAudience(audience string) func(*Token) error
- func WithExpirationTime(expirationTime *time.Time) func(*Token) error
- func WithId(id string) func(*Token) error
- func WithIssuedAt(issuedAt *time.Time) func(*Token) error
- func WithIssuer(issuer string) func(*Token) error
- func WithNotBefore(notBefore *time.Time) func(*Token) error
- func WithPrivateClaim(key string, value any) func(*Token) error
- func WithSignature(algorithm jwa.Signer, key *jwk.Key, options ...func(*jws.Signature)) func(*Token) error
- func WithSubject(subject string) func(*Token) error
- type Token
- func (token *Token) Audience() string
- func (token *Token) ExpirationTime() *time.Time
- func (token *Token) Id() string
- func (token *Token) IssuedAt() *time.Time
- func (token *Token) Issuer() string
- func (token *Token) MarshalJSON() ([]byte, error)
- func (token *Token) NotBefore() *time.Time
- func (token *Token) PrivateClaim(key string) any
- func (token *Token) String() string
- func (token *Token) Subject() string
- func (token *Token) UnmarshalJSON(data []byte) error
- func (token *Token) Verify(keySet *jwk.KeySet, config verificationConfig) error
Constants ¶
This section is empty.
Variables ¶
View Source
var DefaultVerificationConfig = verificationConfig{ // contains filtered or unexported fields }
Functions ¶
func WithAudience ¶
func WithIssuer ¶
func WithSignature ¶
func WithSubject ¶
Types ¶
type Token ¶
type Token struct {
// contains filtered or unexported fields
}
func (*Token) ExpirationTime ¶
func (*Token) MarshalJSON ¶
func (*Token) PrivateClaim ¶
func (*Token) UnmarshalJSON ¶
Click to show internal directories.
Click to hide internal directories.