Documentation ¶ Index ¶ type SignFunc type Token func New(alg common.AlgorithmType, claims common.ClaimSet, key []byte) (*Token, error) func (t *Token) Decode(parts []string) error func (t *Token) Encode() ([]byte, error) func (t *Token) Validate() (bool, error) type ValidateFunc Constants ¶ This section is empty. Variables ¶ This section is empty. Functions ¶ This section is empty. Types ¶ type SignFunc ¶ type SignFunc func(t *Token, signingInput []byte) ([]byte, error) type Token ¶ type Token struct { Header common.Header Payload common.Payload Signature common.Signature SignFunc ValidateFunc Key []byte Raw []byte } func New ¶ func New(alg common.AlgorithmType, claims common.ClaimSet, key []byte) (*Token, error) func (*Token) Decode ¶ func (t *Token) Decode(parts []string) error func (*Token) Encode ¶ func (t *Token) Encode() ([]byte, error) func (*Token) Validate ¶ func (t *Token) Validate() (bool, error) type ValidateFunc ¶ type ValidateFunc func(t *Token) (bool, error) Source Files ¶ View all Source files jws.go sign.go validate.go Click to show internal directories. Click to hide internal directories.