RE: signature length mismatch ERROR in RSA_Verify.

2008-11-19 Thread David Schwartz
> RSA_verify(NID_md5, datatosign, (strlen(datatosign)), signature, > strlen(signature), key); The 'strlen' function is only useable on a C-style string. The signature cannot be a C-style string because it is arbitrary binary data. > Best regards, > Am. Sivaramakrishnan DS __

Re: signature length mismatch ERROR in RSA_Verify.

2008-11-19 Thread Sivaramakrishnan Ananthakrishnan
Hi, As explained in the initial email we were able to resolve the "RSA_verify:wrong signature length" by generating the signature in two steps as explained below (which generates 128 byte signature): openssl dgst -md5 -binary -out signmd.bin input.txt openssl rsautl -encrypt -inkey rsap