Documentation ¶
Index ¶
- func FindAndParseEcJwk(signatureKid []byte, jwksData []byte) (*ecdsa.PublicKey, error)
- func ParseEcPrivateKey(privateKeyData []byte) (*ecdsa.PrivateKey, error)
- func ParseEcPublicKey(publicKeyData []byte) (*ecdsa.PublicKey, error)
- func SignES512(key *ecdsa.PrivateKey, payload []byte) ([]byte, error)
- func VerifyES512(key *ecdsa.PublicKey, payload []byte, signature []byte) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func FindAndParseEcJwk ¶
Read JWKs json then find & parse the JWK for the given signatureKid
func ParseEcPrivateKey ¶
func ParseEcPrivateKey(privateKeyData []byte) (*ecdsa.PrivateKey, error)
ParseEcPrivateKey parses the private key data and produces an elliptic curve private key
func ParseEcPublicKey ¶
ParseEcPublicKey parses the public key data and produces an elliptic curve public key
func SignES512 ¶
func SignES512(key *ecdsa.PrivateKey, payload []byte) ([]byte, error)
SignES512 signs a payload using the provided private key and return the signature Check section A.4 of RFC7515 for the details <https://www.rfc-editor.org/rfc/rfc7515.txt>
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.