HsOpenSSL-0.11.4.18: Partial OpenSSL binding for Haskell
Safe HaskellNone
LanguageHaskell2010

OpenSSL.EVP.PKey

Description

An interface to asymmetric cipher keypair.

Synopsis

Documentation

class (Eq k, Typeable k, PKey k) => PublicKey k where #

Instances of this class has at least public portion of a keypair. They might or might not have the private key.

Minimal complete definition

Nothing

Methods

fromPublicKey :: k -> SomePublicKey #

Wrap an arbitrary public key into polymorphic type SomePublicKey.

toPublicKey :: SomePublicKey -> Maybe k #

Cast from the polymorphic type SomePublicKey to the concrete type. Return Nothing if failed.

class PublicKey a => KeyPair a where #

Instances of this class has both of public and private portions of a keypair.

Minimal complete definition

Nothing

Methods

fromKeyPair :: a -> SomeKeyPair #

Wrap an arbitrary keypair into polymorphic type SomeKeyPair.

toKeyPair :: SomeKeyPair -> Maybe a #

Cast from the polymorphic type SomeKeyPair to the concrete type. Return Nothing if failed.

Instances

Instances details
KeyPair RSAKeyPair # 
Instance details

Defined in OpenSSL.EVP.PKey

KeyPair DSAKeyPair # 
Instance details

Defined in OpenSSL.EVP.PKey

KeyPair SomeKeyPair # 
Instance details

Defined in OpenSSL.EVP.PKey

data SomePublicKey #

This is an opaque type to hold an arbitrary public key in it. The actual key type can be safelly type-casted using toPublicKey.

Instances

Instances details
Eq SomePublicKey # 
Instance details

Defined in OpenSSL.EVP.PKey

PKey SomePublicKey # 
Instance details

Defined in OpenSSL.EVP.PKey

PublicKey SomePublicKey # 
Instance details

Defined in OpenSSL.EVP.PKey

data SomeKeyPair #

This is an opaque type to hold an arbitrary keypair in it. The actual key type can be safelly type-casted using toKeyPair.

Instances

Instances details
Eq SomeKeyPair # 
Instance details

Defined in OpenSSL.EVP.PKey

Methods

(==) :: SomeKeyPair -> SomeKeyPair -> Bool

(/=) :: SomeKeyPair -> SomeKeyPair -> Bool

PKey SomeKeyPair # 
Instance details

Defined in OpenSSL.EVP.PKey

KeyPair SomeKeyPair # 
Instance details

Defined in OpenSSL.EVP.PKey

PublicKey SomeKeyPair # 
Instance details

Defined in OpenSSL.EVP.PKey

Orphan instances

PKey RSAKeyPair # 
Instance details

PKey RSAPubKey # 
Instance details

PKey DSAKeyPair # 
Instance details

PKey DSAPubKey # 
Instance details