views:

2091

answers:

2

I know this question has been asked a number of times. I seem to have a bit of a different problem. In my situation after the exception is thrown initially it works fine (and no; I did not turn off exceptions). So what I have done is on the exception I simply repost:

IdHTTP1.Post(.......

I have put the libeay32.dll and ssleay32.dll both in the Apache bin directory and the directory where my ISAPI dll resides.

Anyone have any suggestions?

A: 

That error means that the TIdSSLIOHandlerSocketOpenSSL.PassThrough property is being set to False (which would happen when posting to an HTTPS URL) before TIdSSLIOHandlerSocketOpenSSL.Init() has been called to intialize the SSL context first. Sounds like a bug. Next time you get the error, can you grab the stack trace?

Remy Lebeau - TeamB
Here it is. Sorry, I can't seem to insert carriage returns.:7761b08e kernel32.RaiseException + 0x58:0113bb57 Call_HookedRaise + $B3:011f7bed TIdSSLContext.Create + $61:011f7481 TIdSSLIOHandlerSocketOpenSSL.Init + $1D:011f7270 TIdSSLIOHandlerSocketOpenSSL.ConnectClient + $20:012076e2 TIdCustomHTTP.CheckAndConnect + $7E:01207b2a TIdCustomHTTP.ConnectToHost + $3BE:01209426 TIdCustomHTTP.DoRequest + $152:012064d7 TIdCustomHTTP.Post + $9F:01206899 TIdCustomHTTP.Post + $D1:012069ec TIdCustomHTTP.Post + $6CMyMain.SubmitIt
M Schenkel
Given that stack trace, there are a couple of possibilities: 1) the OpenSSL DLLs can't be loaded at all (you can use WhichFailedToLoad() to check that); 2) OpenSSL is loaded but the mi_SSLeay_add_ssl_algorithms() function is failing.
Remy Lebeau - TeamB
+2  A: 

For Indy you need a special build of OpenSSL libraries. The default OpenSSL libraries are not suitable for using with Indy.

See also. May be you need to try different versions, until you'll find a suitable one.

Alexander
That only applies to older versions of Indy. Modern version use the default OpenSSL DLLs as-is now.
Remy Lebeau - TeamB