#include <ElGamal.h>
Inheritance diagram for CODEX_Ciphers::ElGamalPrivateKey:


Public Methods | |
| ElGamalPrivateKey () | |
| Default constructor, for creating an object to be unmarshalled. | |
| ElGamalPrivateKey (BIGNUM *x) | |
| Create an ElGamalPrivateKey from a BIGNUM. | |
| ElGamalPrivateKey (const CODEX_ASN1::BigNumber &x) | |
| Create an ElGamalPrivateKey from a BigNumber. | |
| ElGamalPrivateKey (const ElGamalPrivateKey &aKey) | |
| Copy constructor. | |
| virtual | ~ElGamalPrivateKey () |
| Destructor. | |
| const CODEX_ASN1::SecureBigNumber & | x () const |
| |
| BIGNUM * | decrypt (const ElGamalCipherText &cipherText, const ElGamalPublicKey &publicKey) const |
| Decrypt a message. | |
| ElGamalSignature * | sign (const BIGNUM *message, const ElGamalPublicKey &publicKey) const |
| Sign a message. | |
| void | toFile (const char *fname) const |
| Writes the private key to a file. | |
| void * | fromFile (const char *fname) |
| Reads the private key from a file. | |
This is just an extension of a SecureBigNumber.
Definition at line 367 of file ElGamal.h.
|
||||||||||||
|
Decrypt a message.
Definition at line 49 of file ElGamalPrivateKey.cc. References CODEX_Ciphers::ElGamalCipherText::c1(), CODEX_Ciphers::ElGamalCipherText::c2(), CODEX_ASN1::BigNumber::m_value, CODEX_Ciphers::ElGamalPublicKey::p(), CODEX_Ciphers::ElGamalPublicKey::q(), and CODEX_ASN1::BigNumber::value(). |
|
|
Reads the private key from a file.
Definition at line 266 of file ElGamalPrivateKey.cc. References CODEX_ASN1::BigNumber::unmarshal(). |
|
||||||||||||
|
Sign a message.
Definition at line 120 of file ElGamalPrivateKey.cc. References CODEX_Ciphers::ElGamalPublicKey::g(), CODEX_ASN1::BigNumber::m_value, CODEX_Ciphers::ElGamalPublicKey::p(), CODEX_Ciphers::ElGamalPublicKey::q(), and CODEX_ASN1::BigNumber::value(). |
|
|
Writes the private key to a file.
Definition at line 244 of file ElGamalPrivateKey.cc. References CODEX_ASN1::BigNumber::marshal(). |
1.2.18