OK, I searched around and find out I need a 'Handler' component, which I did
not need before (code has gone unchanged since 2004)
I try out TIdServerIOHandlerSSLOpenSSL (no changes to the component) and
when I attempt again, I receive the error/exception 'Socket Error # 11004'
I went as far as downloading the OpenSSL dlls and placing them in the
application's directory, same error.
A bit frustrating to say the least.
Is there a workaround? What's the trick in using the TidHttp component
against https sites? Has Indy feature-creeped itself into obscurity and
it's time to use something else?
Thanks for any info,
krf
Dang, it shouldn't be this hard.
function TdmUSPSCustomsFormCP72.GetResponse(const URL, XML: String): String;
var
WebURL: string; {for debugging}
URI :TIdURI;
begin
Result := '';
URI := TIdURI.Create();
try
WebURL := URL + '&XML=' + URI.ParamsEncode(XML);
{debugging code snipped}
try
Result := IdUSPSCustomsServer.Get(WebURL);
{debugging code snipped}
except
on E: Exception do
begin
Result := E.Message;
end;
end;
finally { wrap up }
URI.Free();
end; { try/finally }
end;
"Kevin Frevert" <kevin@workdrinkingicewater> wrote in message
news:475570a4$1...@newsgroups.borland.com...
> I received the error/exception 'IOHandler value is not valid'.
That error only occurs if you do not have a
TIdSSLIOHandlerSocketBase-derived component, such as TIdSSLIOHandlerOpenSSL,
assigned to the TIdHTTP's IOHandler property.
> OK, I searched around and find out I need a 'Handler' component,
> which I did not need before (code has gone unchanged since 2004)
Yes, you did. TIdHTTP has never implemented SSL directly. It has always
required a separate SSL component be attached to it.
> I try out TIdServerIOHandlerSSLOpenSSL
That is a server-side IOHandler, not a client-side IOHandler. TIdHTTP is a
client-side component. You can't use TIdServerIOHandlerSSLOpenSSL with it.
Gambit
A little background, I am interfacing with the USPS international customs
form generation "web service". I just found out from the floor supervisor
that they have never used the generated forms. They ignore the 'Print'
pop-up and handle the paperwork manually (why is a long answer). I'm so
glad he left out that little detail from the escalated 'emergency' helpdesk
ticket and I wasted almost two days.
Apparently this has never worked since USPS went to https. The issue came
to light because of a missing property exception at run-time(D6->2007
issue).
Now the component has been updated, the application is 'working' normally.
>> I try out TIdServerIOHandlerSSLOpenSSL
>
> That is a server-side IOHandler, not a client-side IOHandler. TIdHTTP is
> a client-side component. You can't use TIdServerIOHandlerSSLOpenSSL with
> it.
That was stupid, yes it was the other ssl one. I wrote this message on my
laptop and the project is on my desktop and I copy/pasted from the first
thing I saw that had ssl from the help.
Thanks,
krf