Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func SignPayload ¶
func SignPayload(payload []byte, signingAlg jwa.SignatureAlgorithm, key crypto.Signer, headers jws.Headers) ( []byte, error, )
SignPayload signs a payload with the passed properties and adds the kid to the jwt header
func SignWithType ¶
func SignWithType(payload []byte, typ string, signingAlg jwa.SignatureAlgorithm, key crypto.Signer) ([]byte, error)
SignWithType creates a signed JWT of the passed type for the passed payload using the passed crypto.Signer with the passed jwa.SignatureAlgorithm
Types ¶
type ParsedJWT ¶
ParsedJWT is a type extending jws.Message by holding the original jwt
func (ParsedJWT) MarshalMsgpack ¶
MarshalMsgpack implements the msgpack.Marshaler interface
func (*ParsedJWT) UnmarshalMsgpack ¶
UnmarshalMsgpack implements the msgpack.Unmarshaler interface
func (*ParsedJWT) VerifyType ¶
VerifyType verifies that the header typ has a certain value
Click to show internal directories.
Click to hide internal directories.