Here's some code that worked fine before 0.9.7. The BN_CTX_init()
isn't "right" per se, but then again it shouldn't cause a crash in
BN_copy, since that context isn't actually used in the copy!
The code works fine if you comment out the BN_CTX_init call, or if you
initialize a BN_CTX properly. Beyond that, I haven't looked into the
matter.
John
#include <openssl/bn.h>
int main() {
unsigned char brep[1] = {0x65};
BIGNUM x, y;
BN_CTX c;
BN_init(&x);
BN_init(&y);
BN_CTX_init(&c);
BN_bin2bn(brep, 8, &x);
BN_add_word(&x, 12);
BN_copy(&y, &x);
return 0;
}
______________________________________________________________________
OpenSSL Project http://www.openssl.org
Development Mailing List [EMAIL PROTECTED]
Automated List Manager [EMAIL PROTECTED]