Hi, I have implemented a simple TCP client and server processes such that..server generates the RSA keys and send the public modulus and public exponent to the client. The client process uses these values to encrypt a user entered string and sends it back to server. The server then decrypts the string and outputs the decrypted string. I have used the crypto API in openSSL for generating the key, encryption and decryption.
But, when the encrypted string is sent to the server, not always the decryption is successful. Some times I get an error "11768:error:04065072:rsa routines:RSA_EAY_PRIVATE_DECRYPT:padding check failed:rsa_eay.c:481:". On some further research I found out that I get the error only when the encrypted string length is less than 128 bytes. When the length of the encypted string is 128, all is fine. I haven't seen a encrypted string greater than 128 till now ______________________________________________________________________ OpenSSL Project http://www.openssl.org User Support Mailing List [EMAIL PROTECTED] Automated List Manager [EMAIL PROTECTED]