Documentation ¶
Overview ¶
Package ecdsa provides ECDSA signing methods for JWT.
Index ¶
- Variables
- func SignES256(token string, secret interface{}) (string, error)
- func SignES384(token string, secret interface{}) (string, error)
- func SignES512(token string, secret interface{}) (string, error)
- func VerifyES256(token, signature string, secret interface{}) error
- func VerifyES384(token, signature string, secret interface{}) error
- func VerifyES512(token, signature string, secret interface{}) error
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // ErrVerifyFailed is returned when signature verification fails. ErrVerifyFailed = errors.New("jwt/ecdsa: verification failed") // ErrInvalidKey is returned when the given key is not a valid ECDSA key. ErrInvalidKey = errors.New("jwt/ecdsa: invalid key") // ErrInvalidSignature is returned when the signature provided cannot be decoded. ErrInvalidSignature = errors.New("jwt/ecdsa: invalid signature") // ErrUnsupportedKeyType is returned when the secret is not a supported type. ErrUnsupportedKeyType = errors.New("jwt/ecdsa: unsupported key type") )
Functions ¶
func VerifyES256 ¶
VerifyES256 verifies the given signature using the given secret.
func VerifyES384 ¶
VerifyES384 verifies the given signature using the given secret.
func VerifyES512 ¶
VerifyES512 verifies the given signature using the given secret.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.