I'm trying to make a simple application which uses a 4096-bit RSA public key (encoded in DER format, statically compiled into the program itself. I generated this key with OpenSSL itself and I am able to do operations with it from the command-line. And I know I encoded it in the program correctly, because if I ask it to write TESTING_PUBLIC_KEY to disk, OpenSSL continues to accept it.

However, when I try to use d2i_PublicKey to load it, it returns NULL. Anyone have any hints that might help me?

My code is at http://pastebin.ca/1501265 and I'm compiling with VC++ (in C mode), for what it's worth.

--
Jeremy R.
NovaWave Solutions
______________________________________________________________________
OpenSSL Project                                 http://www.openssl.org
User Support Mailing List                    openssl-users@openssl.org
Automated List Manager                           majord...@openssl.org

Reply via email to