Hi group,

I have written a simple program to test my understanding of the OpenSSL APIs. And of course I have a problem with one of them. My problem is that when I use
RSA_public_encrypt to encrypt my Symmetric key is get the following error:

    Testing RSA encryption of Symmertic key
145 Encrypt In bytes: 128, 149 Encript failed:
    Code: 67555438
    error:0406D06E
    rsa routines:RSA_padding_add_PKCS1_type_2
    data too large for key size

The program first generates a Symmetric key, then uses it to encrypt and decrypt some simple text that the user inputs. Next it create an RSA Key and
a public RSA key. then the same with these keys. The last thing tested is the
encryption of the Symmetric Key using the RSA keys which fails.  The error
message does not make any sense to me since the Sym key is only 128 bytes.

I would appreciate any help with my problem. All of the code is here:

   http://64.124.13.3/_OpenSSL_/Keys/

 Thanks for your time.

--
William Estrada
[EMAIL PROTECTED]
Mt-Umunhum-Wireless.net ( http://Mt-Umunhum-Wireless.net )
Ymessenger: MrUmunhum


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

Reply via email to