hc-httpclient-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ramit Bhardwaj" <ram...@cybage.com>
Subject RE: working behind a proxy
Date Mon, 10 Oct 2005 12:40:51 GMT
Hi
i think the following code should help
ProxyClient proxyclient = new ProxyClient();
proxyclient.getState().setProxyCredentials(
            new AuthScope("ipaddress", portNo, realm),new UsernamePasswordCredentials("usernamefor
proxy", "password for proxy"));


-----Original Message-----
From: Michael Becke [mailto:mbecke@gmail.com]
Sent: Monday, October 10, 2005 12:47 AM
To: HttpClient User Discussion
Subject: Re: working behind a proxy


Hi Sam,

HostConfiguration.setProxy() is where you want to start.  You can set
it per HttpClient instance via HttpClient.getHostConfiguration() or
per request by using HttpClient.executeMethod(hostConfig, method,
state).

Mike

On 10/9/05, Sam Hwang <samhng@gmail.com> wrote:
> Hi,
> I am working behind a proxy, when I use HttpClient it always timeout at the
> end. How can I configure it to adapt the proxy? Thx!
>
>

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


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


Mime
View raw message