You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@hc.apache.org by rohit gupta <ro...@lycos.com> on 2003/12/05 08:43:59 UTC

HTTP/1.1 407 Proxy authentication required

Hello there,

I am exploring HttpClient and its capability and I am a newly join member for this mailing list.

I am trying to get a resource using HttpClient. My network does have a proxy.

My code looks like following.

HttpClient httpclient = new HttpClient();
httpclient.getHostConfiguration().setProxy("172.18.1.1", 80);// my proxy details
httpclient.getState().setProxyCredentials("172.18.1.1",  "172.18.1.1",				new UsernamePasswordCredentials  userName, pwd));// realms and other detail
GetMethod httpget = new GetMethod("http://www.google.com/"); 
httpclient.executeMethod(httpget);
System.out.println(httpget.getStatusLine().toString());

When i am trying to execute this i am getting following error:


Dec 5, 2003 1:01:53 PM org.apache.commons.httpclient.HttpMethodBase processAuthenticationResponse
INFO: Already tried to authenticate with '172.18.1.1' authentication realm at 172.18.1.1, but still receiving: HTTP/1.1 407 Proxy authentication required
HTTP/1.1 407 Proxy authentication required


Somebody please let me know the reason and the probable solution.

Warm Regards,
Rohit




____________________________________________________________
Get advanced SPAM filtering on Webmail or POP Mail ... Get Lycos Mail!
http://login.mail.lycos.com/r/referral?aid=27005

---------------------------------------------------------------------
To unsubscribe, e-mail: commons-httpclient-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-httpclient-dev-help@jakarta.apache.org