Thank you Marek,

I tried the PEM_read_RSAPrivateKey and PEM_read_RSAPublicKey pair. 
PEM_read_RSAPrivateKey seems work fine. PEM_read_RSAPublicKey failed. By 
tracing, it failed in BIO_gets(), returning 0. Any idea?

Thanks.

Sonia

-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] Behalf Of Marek Marcola
Sent: Friday, June 30, 2006 10:01 AM
To: openssl-users@openssl.org
Subject: RE: Private Key Type and PEM Length


Hello,
> I am working on something similar. if I generated a private key with no 
> password, 
> can I pass NULL to PEM_read_bio_privateKey(bio,&pkey,NULL,NULL)?
Yes,

> Is there lib function that reads DER format?
Try d2i_RSAPrivateKey_bio();

Best regards,
-- 
Marek Marcola <[EMAIL PROTECTED]>

______________________________________________________________________
OpenSSL Project                                 http://www.openssl.org
User Support Mailing List                    openssl-users@openssl.org
Automated List Manager                           [EMAIL PROTECTED]
______________________________________________________________________
OpenSSL Project                                 http://www.openssl.org
User Support Mailing List                    openssl-users@openssl.org
Automated List Manager                           [EMAIL PROTECTED]

Reply via email to