> I attempt to decrypt a 256 bytes of data with an RSA public key. The > openssl error I'm getting is > error:0406706C:lib(4):func(103):reason(108), which from what I read on > the internet means "data greater than mod len". The openssl API I'm > using to decrypt the data is RSA_public_decrypt(). From what a read on > the internet this API is really for decrypting signatures. So is there > another API for decrypting data that is larger than 128 bytes using a > RSA public key? Any help would be greatly appreciated. > > Bill
No, it is not possible to use RSA to encrypt data that is larger than the modulus. Some algorithm other than RSA was used to encrypt the data (possibly one that uses RSA internally to encrypt some data smaller than the modulus), and you should use that algorithm to decrypt it. As a general rule, when decrypting data, you should use the same algorithm that was used to encrypt it. You don't get a choice. Only the exact same algorithm will work. DS ______________________________________________________________________ OpenSSL Project http://www.openssl.org User Support Mailing List openssl-users@openssl.org Automated List Manager [EMAIL PROTECTED]