“Secure” site generally means one behind SSL. The ‘AuthenticationRequired’ event represents basic authentication which is just a HTTP header. You could create that header yourself and add it to the request before you send it off. This way you can determine if it’s the server, the client, or the client event that is failing you.
Hopefully this is for an internal network or behind SSL as basic authentication leaks. passwords very easily.[/quote]
Phillip, no this is an external state government site which I access at work through a proxy, but can also access it at home. I’ve only tried it from home at this stage. I’ll deal with the proxy issues if any later.
Sorry to resurrect an old thread, but I’ve just run into this myself. It seems like Xojo.Net.HTTPSocket on Windows will fire the AuthenticationRequired event, and then PageReceived with both the authorized and unauthorized content concatenated together. Works correctly on Mac.
Update: Yeah, this is infuriating. Tried putting the username and password into the url. That works on the Mac, and has the benefit of reducing the number of requests required. It does not work on Windows, the header is not included in the request. And since the new framework does not have Base64, there’s no way to compute the header manually.
Yes, setting the header manually works. I had to write an EncodeBase64 method, along with ShiftLeft and ShiftRight for the new framework to do it though, to keep the code cross-platform. Sometimes I really love the new framework…
Edit: ShiftLeft and ShiftRight are single-line methods, so its not really a big deal. But I find it absurd that these don’t exist in the new framework.
That’s my point. I can expect that new platforms will allow me to use the new framework. There is currently one platform that requires I use it. I can safely assume that any new platforms will not require the classic framework. So if I want to write future-proof code, I need to use the new framework. It’s the only framework I can safely assume will work with all projects current and future.