On 4/13/2011 2:35 AM, pattabi raman wrote:

*1. If I can't use sprintf then how can I copy the enrypted message to a
character buffer. Bcoz so far I am sending the request to middleware in
Char Buffer using TCP /IP socket. How can I able to achieve now.*
**

If you don't know how to copy bytes of data, you don't know how to code in C. You can copy it yourself, using a 'for' loop. You can use 'memcpy'.

*2. Actually I am using 2048 bit public key. So what is the right size I
can use. I tried to use RSA_size(rsa) , which gives core dump error. *
So any idea on the above points will help me a lot. Thanks.

I'd have to see the code to be sure, but likely your core dump comes from misusing the result of this call. For example, there is no guarantee that you can *en*crypt a value just because it is RSA_size or fewer bytes.

DS


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

Reply via email to