Documentation
¶
Index ¶
- func AddKeyToPayload(payload map[string]interface{}, pubKey jwk.Key) error
- func DecryptWithSecretKey(payload []byte, skJWK jwk.Key) ([]byte, error)
- func EncryptWithPublicKey(payload []byte, pkJWK jwk.Key) ([]byte, error)
- func GenerateUUID() string
- func Hash(data []byte) []byte
- func KeyJWKToJson(key jwk.Key) ([]byte, error)
- func KeyJsonToJWK(jwkJSON []byte) (jwk.Key, error)
- func PublicBytesToECDSA(data []byte) (*ecdsa.PublicKey, error)
- func PublicECDSAToBytes(pub *ecdsa.PublicKey) []byte
- func ValidatePublicKey(curve elliptic.Curve, xBig, yBig *big.Int) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DecryptWithSecretKey ¶ added in v0.1.13
func EncryptWithPublicKey ¶
func PublicBytesToECDSA ¶
PublicBytesToECDSA elliptic.Marshal and elliptic.Unmarshal are deprecated in favor of the crypto/ecdh package, but that's specifically for ECDH operations. For ECDSA, these functions are still the standard way to handle point marshaling/unmarshaling, so we're good to use them.
func PublicECDSAToBytes ¶
PublicECDSAToBytes elliptic.Marshal and elliptic.Unmarshal are deprecated in favor of the crypto/ecdh package, but that's specifically for ECDH operations. For ECDSA, these functions are still the standard way to handle point marshaling/unmarshaling, so we're good to use them.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.