Alex Hunsley wrote:
My main question is: if I don't call setAuthenticationPreemptive(true), and if HttpClient tries to use a proxy and receives an HTTP 403 (proxy auth required) message back, will it transparently then give the proxy auth that I have set, or will it just give me the 403 code it received?

On a 403 response from the proxy, HttpClient will try to authenticate with the proxy by repeating the request, if (and only if) you have set credentials that are applicable to the host and realm. If all auth attempts fail, you will get the 403 response back as a last resort.


Please make sure you set the correct hostname and realm for your credentials.

p.s. I have had no luck at all finding a simple proxy that is runnable under cygwin or windows that will let me enable basic proxy authorization so I can test this.

Check out Squid, which is available for Cygwin (Web category) and native Window (which is kinda not well-supported). Its config file is huge (squid can do a lot) but quite straight forward.


HTH

Ortwin Glück

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to