Using HTTPSecureSocket that targets a CGI app

I’m trying to use HTTPSecureSocket to determine the status of an Xojo Web (200, 500, etc.). First I tried with a test case for Google.com by assigning this to a button action:

Dim s As New HTTPSecureSocket Dim x As String = s.SendRequest("HEAD", "https://www.google.com", 5) MsgBox Str(s.HTTPStatusCode)

That works fine, returning a 200. Then I tried it with a CGI app like this:

Dim s As New HTTPSecureSocket Dim x As String = s.SendRequest("HEAD", "https://www.MyDomain.com/cgi-bin/MyApp/myapp.cgi", 5) MsgBox Str(s.HTTPStatusCode)

That returns 0. Unreachable. Is there something different I have to do if the target is a CGI app?

Is that the exact url that you would type into a browser?

Oh, you probably need to set the Secure property to True and ConnectionType to SSLv23.

That did it! Thanks as usual, Greg.

Dim s As New HTTPSecureSocket s.ConnectionType = SSLSocket.SSLv23 s.Secure = True Dim x As String = s.SendRequest("HEAD", "https://www.MyDomain.com/cgi-bin/MyApp/myapp.cgi", 5) MsgBox Str(s.HTTPStatusCode)

[quote=439612:@Ralph Alvy]That did it! Thanks as usual, Greg.

Dim s As New HTTPSecureSocket s.ConnectionType = SSLSocket.SSLv23 s.Secure = True Dim x As String = s.SendRequest("HEAD", "https://www.MyDomain.com/cgi-bin/MyApp/myapp.cgi", 5) MsgBox Str(s.HTTPStatusCode)[/quote]
Is there a way to do something similar to the above that does not generate a session in the target CGI Web app?

If you cannot get the status of a CGI Web (using a different CGI to do it, like the above) without creating a session, is it possible to configure the target app to kill any session created that way (i.e., when no browser was used in the creation of that session) immediately or quickly? Otherwise you have to wait the usual 3 minutes for that session to die (via the framework).