jose-0.2.33.0: Javascript Object Signing and Encryption and JSON Web Token library

Safe HaskellNone
LanguageHaskell98

Crypto.JOSE.Classes

Description

Type classes for use with the JOSE modules.

Synopsis

Documentation

class Key k where Source

A Key that can sign messages and validate signatures according to a given Alg.

Can fail with AlgorithmMismatch

Associated Types

type KeyGenParam k Source

type KeyContent k Source

Methods

gen :: CPRG g => KeyGenParam k -> g -> (k, g) Source

fromKeyContent :: KeyContent k -> k Source

sign :: CPRG g => Alg -> k -> g -> ByteString -> (Either Error ByteString, g) Source

verify :: Alg -> k -> ByteString -> ByteString -> Either Error Bool Source

Instances

Key KeyMaterial 
Key OctKeyParameters 
Key RSAKeyParameters 
Key ECKeyParameters 
Key JWK 
Key JWK'