https using a proxy?

One of my beta testers thought it would be helpful if my app could use a proxy server since their school has YouTube blocked. It will need to use https to access the YouTube api. I don’t even have a clue how to even set this up. I’m guessing I’d have a window where the user would input their proxy server info and somehow this gets used when my app accesses YouTube. I haven’t found any examples on setting this up yet and the language reference does not seem detailed enough to get me started. I found ProxyAuthenticationRequired, HTTPProxyAddress, and HTTPProxyPort, but no clue how to implement it. Any examples would sure be helpful.

This depends greatly on whether you are using Xojo.Net.HTTPSocket or HTTPSecureSocket. If it’s the former, the socket uses the system settings from the user’s internet preferences. If the latter then yes, you’ll need to provide a way for the user to put in a server and a port and also a username and password.

The server and port need to be set before you attempt the connection, but you set the username and password in the ProxyAuthenticationRequired event and return True.

okay thanks. right now i’m not using, just httpSecureSocket. While I can set up a window that asks for username and pw, i have no idea how to implement it to actually make the proxy call to the server.

I’m assuming will be used with the Windows version when I port it to that platform?

You should be able to simply set the proxy settings, implement the Authentication event if necessary and then just send your request as normal.

[quote=371180:@Patrick Besong]
I’m assuming will be used with the Windows version when I port it to that platform?[/quote]