Re: sign/verify kicking my ass

2008-11-22 Thread Dr. Stephen Henson
On Sat, Nov 22, 2008, Shaun R. wrote: > Can anybody help me out, not sure whats going wrong. My test case right > now is the following > > gcc sign.c -o sign -lcrypto > gcc verify.c -o verify -lcrypto > ./sign > blah.sig > ./verify > > RSA_sign() and RSA_verify() don't sign arbitrary data they

Re: sign/verify kicking my ass

2008-11-22 Thread Victor Duchovni
On Sat, Nov 22, 2008 at 10:38:18AM -0800, Shaun R. wrote: > Can anybody help me out, not sure whats going wrong. My test case right > now is the following > >signature = (unsigned char*) malloc(RSA_size(private_key)); >if(RSA_sign(NID_sha1, (unsigned char*) message, strlen(messa

Re: problems with VIA Eden sha1 HW acceleration in ssl

2008-11-22 Thread Jan Klod
On Wednesday 19 November 2008 21:23:30 Geoff Thorpe wrote: > On Wednesday 19 November 2008 15:14:21 Jan Klod wrote: > > On Wednesday 19 November 2008 21:02:06 Geoff Thorpe wrote: > > > If neither Michael (Ludvig) nor Andy (Polyakov) respond in the next > > > day or so, I'll try to take a look at (a

Re: FIXED - CRYPTO_set_dynlock_* mystery ... (was: Engine Issue: nShield 500)

2008-11-22 Thread Massimiliano Pala
Hi Geoff, that would be amazing.. I agree with you.. if there were more hours in the day... hehehe... The patch from Sanders looks ok to me... :D It can actually help in understanding better the option... Later, Max Geoff Thorpe wrote: As I stated in another post, I'm looking to overhaul the

FIXED - CRYPTO_set_dynlock_* mystery ... (was: Engine Issue: nShield 500)

2008-11-22 Thread Massimiliano Pala
Hi Sander, I debugged the init process and it seems that you were right. The disable_mutex_callbacks is set to 1 at e_chil.c:578. Definitely it is due to initialization, at this point... ... looked into that, and... et voilas! Found the problem! The PRE commands were wrong. Indeed the following:

Re: CRYPTO_set_dynlock_* mystery ... (was: Engine Issue: nShield 500)

2008-11-22 Thread Massimiliano Pala
Sander Temme wrote: /opt/nfast/toolkits/openssl/openssl098e-patch.txt I found a 'openssl098-patch.txt' is that ok ? Should apply cleanly to newer versions of OpenSSL, with patch -p1. It creates a static lock for CHIL to use so it doesn't need the dynamic ones available. It did. I persona

Re: CRYPTO_set_dynlock_* mystery ... (was: Engine Issue: nShield 500)

2008-11-22 Thread Ger Hobbelt
Quick scan of code leads to this: e_chil.c: if (disable_mutex_callbacks == 0) { if (CRYPTO_get_dynlock_create_callback() != NULL && CRYPTO_get_dynlock_lock_callback() != NULL && CRYPTO_get_dynlock_destroy_callb

Re: CRYPTO_set_dynlock_* mystery ... (was: Engine Issue: nShield 500)

2008-11-22 Thread Sander Temme
On Nov 21, 2008, at 12:01 AM, Massimiliano Pala wrote: Actually, it seems that the dynamic functions are never called... :( I can assure you from my work on Apache 2.2.10 that the CHIL engine calls the dynamic locking upcalls many times. It seems to be the only thing in the OpenSSL distr

Re: CRYPTO_set_dynlock_* mystery ... (was: Engine Issue: nShield 500)

2008-11-22 Thread Massimiliano Pala
Hi Sander, I definitely did - now I do initialize all the static locks in OpenSSL *and* the dynamic functions. But they are never called by the chil - the assert fails and the SIGABRT is sent to my daemon forcing it to exit. For some reason it seems the dynamic locking functions do not function

sign/verify kicking my ass

2008-11-22 Thread Shaun R.
Can anybody help me out, not sure whats going wrong. My test case right now is the following gcc sign.c -o sign -lcrypto gcc verify.c -o verify -lcrypto ./sign > blah.sig ./verify [EMAIL PROTECTED] openssl]# cat sign.c #include #include #include #include #include #include #include #i