I want to decrypt a ciphertext which has been encrypted using the
ElGamal-algorithm. I know the parameters a, b which represent the
ciphertext, the paramter x (private key), the parameter g (Group Generator)
and the modulus p.
I found the functions Decrypt() (from a base class) and the function
SymmetricDecrypt() but they both do not take the ciphertext splitted in a
and b. Does anybody know how to decrypt the message using crypptopp? The
elgamal example in validate2.cpp is not helpful in this case.
Thanks in advance,
Thorsten
If you must use ElGamal encryption for some reason, it takes ciphertext
that is twice as long as the prime modulus. The first half of the
ciphertext is a, the second is b.
unfortunately I have to use ElGamal and I still do not know how to use it. I
have tried the follwing:
ElGamalKeys::PrivateKey pk;
RandomPool randPool;
pk.Initialize( clP, clG, clX);
ElGamal::Decryptor clDecrypter(pk);
clDecrypter.Decrypt(randPool, ciphertext, cipherTextLength, plaintext);
Every time I try to decrypt a message I run into an exception called
DL_BadElement. What am I doing wrong?
When do I have to use the method "SymmetricDecrypt()"?
Thanks in advance,
Thorsten
-----Ursprüngliche Nachricht-----
Von: Wei Dai [mailto:wei...@weidai.com]
Gesendet: Mittwoch, 30. Juli 2003 01:54
An: crypto...@eskimo.com
Betreff: Re: ElGamal Decryption
73,
Shawn
Thanks,
Thorsten
-----Ursprüngliche Nachricht-----
Von: Shawn Masters [mailto:s...@nfr.com]
Gesendet: Mittwoch, 30. Juli 2003 14:16
An: crypto...@eskimo.com
Betreff: Re: AW: ElGamal Decryption