Alternative to URLConnection with proxy handling?

Hi,

our application uses the URLConnection class from Xojo to connect to foreign webservices. This works well. Now we try to install the application in another environment, which handles HTTP/HTTPS traffic through a proxy.

These are the facts:

  • Our app runs in a docker container on Ubuntu 20.04.
  • On Ubuntu you set the proxy settings with environment variables. We’ve done that, and now curl and ping are working fine.
  • But not our application.
  • The proxy only uses an address, no user, no password, the env variable looks like this:
export HTTP_PROXY="http://proxy10.domain.loc:8080"
export HTTPS_PROXY="http://proxy10.domain.loc:8080"
export NO_PROXY="repo.domain.de,.domain.loc,[...]"

My Question is:
is there another Class, Plugin or package, which brings the functionality of URLConnection auch as synchronous calls and such?

We’re in a hurry, so any recommendation is welcome (also things about the root problem).

Much love to u all

If you can get away with HTTP 1.0 they haven’t yet removed HTTPSecureSocket.

1 Like

Check the CURLSMBS class in MBS CURL Plugin.

1 Like

Or the cURLClient class in my RB-libcURL binding.

Dim curl As New cURLClient
curl.Proxy.Address = "proxy10.domain.loc"
curl.Proxy.Port = 8080
curl.Proxy.Type = libcURL.ProxyType.HTTP 
If Not curl.Get("https://www.example.com/") Then
    MsgBox("Error")
End If
2 Likes

Turns out this is not possible :smiley:

I’ll try the other classes. Thanks for the help!

Allright thank you guys.

We used the cURLClient class . It worked directly and guess what: it is also much faster, than URLConnection. Also much more complex though.