I've RTFM, Ive spent quite literally days looking at websites, Ive
looked at source, I even bought the o-reilly openssl book.

I don't understand the ins and outs of encryption, Im just a regular
coder, not a cryptographer, but from what I can see, the code should
work. There IS a fairly good chance of a gap in my knowledge or I just
misunderstood something in one of the FM's I read {:-)

The specific rsa.c doesnt contain anything like what Im trying to do,
genrsa.c comes closer but still doesnt extract a keyPAIR just the
private key.


Kyle Hamilton wrote:
> Before I look at what you've got, have you compared this to the rsa.c
> file in the apps/ directory of the source distribution?
> -Kyle H
> On Fri, Oct 31, 2008 at 1:13 AM, Michael Simms wrote:
>> I am having a bit of a problem generating a set of new keys.
>> I have code that works just fine when using a pair of imported keys
>> from a file generated from the openssl commandline.
>> However when I try and use RSA_generate_key, I can obtain the public
>> and private keypair, they validate using SSL_CTX_check_private_key,
>> yet, they cause SSL_connect on the client to complain
>> error:0D07209B:asn1 encoding routines:ASN1_get_object:too long
>> I have the code for generating the keys up for scrutiny at
>> http://pastebin.com/m2dc98526
>> Any suggestions gratefully appreciated.
>> Michael

__________________________________________________ ____________________
OpenSSL Project http://www.openssl.org
User Support Mailing List openssl-users@openssl.org
Automated List Manager majordomo@openssl.org