\Horde_Pgp_Crypt_Elgamal

Elgamal encryption implementation (w/EME-PKCS1-v1_5 block encoding).

Summary

Methods
Properties
Constants
__construct()
encrypt()
decrypt()
No public properties found
No constants found
No protected methods found
No protected properties found
N/A
No private methods found
$_key
N/A

Properties

$_key

$_key : \OpenPGP_PublicKeyPacket

Public/private key packet.

Type

\OpenPGP_PublicKeyPacket

Methods

__construct()

__construct(\OpenPGP_PublicKeyPacket  $key) 

Constructor.

Parameters

\OpenPGP_PublicKeyPacket $key

Key data.

encrypt()

encrypt(string  $text) : array

Encrypt data.

Parameters

string $text

Plaintext.

Returns

array —

Array of MPI values (c1, c2).

decrypt()

decrypt(string  $text) : string

Decrypt data.

Parameters

string $text

PKCS1-v1_5 encoded text.

Returns

string —

Plaintext.