(Answer) (Category) Crypto++ Faq-O-Matic :
Why is ElGamal key generation so slow?
Moderator: weidai (inherited from parent)
When you generate an ElGamal key pair, you have the option of specifying a prime modulus. If you do not specify the prime modulus, one will be generated, however because the modulus must be a safe prime (a prime p such that (p-1)/2 is also prime), and those are much rarer than regular primes, it takes a long time.
I suggest that you use an existing well known safe prime instead. For example the following 2048-bit one from http://www.ietf.org/internet-drafts/draft-ietf-ipsec-ike-modp-groups-04.txt :
The g (generator) value for this prime should be 2.
2002-May-14 6:54pm weidai
[Append to This Answer]
2002-May-14 6:54pm
Previous: (Answer) The sample code shows how to work with a file, but my data is in a string (or vice versa).
Next: (Answer) I'm trying to process multiple messages with a Filter, and MaxRetrievable() always returns 0 after the first one.
This document is: http://www.cryptopp.com/cgi-bin/fom.cgi?file=71
[Search] [Appearance] [Show Expert Edit Commands]
This is a Faq-O-Matic 2.721.
This FAQ is administered by Wei Dai.