On Thu, Aug 21, 2003 at 03:15:10PM -0400, Bala Pitchandi wrote: > Hello, > > Does the following method of assigning the value of P & g (which are in hex > representation in a string) look okay? > > <code snippet> > > a = DH_new(); > > if (a == NULL) > goto err; > BN_hex2bn (&a->p, (const char *)Prime); > BN_hex2bn (&a->g, (const char *)Generator); > > DH_check(a, &i); > > <\code snippet>
Calling DH_check() without testing return value or "i" looks strange, everything else seems Ok > Also, for a given P and g, would the DH_generate_key() generate the same > public key always? It is expected to never be the same without a good reason. DH public value is generator "g" power secret value (modulus p) and the secret is usually a random. I mean, generated with a good PRNG. Regards, Vadim ______________________________________________________________________ OpenSSL Project http://www.openssl.org Development Mailing List [EMAIL PROTECTED] Automated List Manager [EMAIL PROTECTED]
