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

OpenSSL.EVP.Seal

Description

Asymmetric cipher decryption using encrypted symmetric key. This is an opposite of OpenSSL.EVP.Open.

Synopsis

Documentation

seal Source #

Arguments

:: Cipher

symmetric cipher algorithm to use

-> [SomePublicKey]

A list of public keys to encrypt a symmetric key. At least one public key must be supplied. If two or more keys are given, the symmetric key are encrypted by each public keys so that any of the corresponding private keys can decrypt the message.

-> String

input string to encrypt

-> IO (String, [String], String)

(encrypted string, list of encrypted asymmetric keys, IV)

Deprecated: Use sealBS or sealLBS instead.

seal lazilly encrypts a stream of data. The input string doesn't necessarily have to be finite.

sealBS Source #

Arguments

:: Cipher

symmetric cipher algorithm to use

-> [SomePublicKey]

list of public keys to encrypt a symmetric key

-> ByteString

input string to encrypt

-> IO (ByteString, [ByteString], ByteString)

(encrypted string, list of encrypted asymmetric keys, IV)

sealBS strictly encrypts a chunk of data.

sealLBS Source #

Arguments

:: Cipher

symmetric cipher algorithm to use

-> [SomePublicKey]

list of public keys to encrypt a symmetric key

-> ByteString

input string to encrypt

-> IO (ByteString, [ByteString], ByteString)

(encrypted string, list of encrypted asymmetric keys, IV)

sealLBS lazilly encrypts a stream of data. The input string doesn't necessarily have to be finite.