[prev in list] [next in list] [prev in thread] [next in thread] 

List:       httpclient-users
Subject:    Re: quesiton for socks proxy and secure proxy support
From:       Roland Weber <ROLWEBER () de ! ibm ! com>
Date:       2007-03-15 7:50:41
Message-ID: OF72D467C5.4FFCE1B8-ONC125729F.002A7AF4-C125729F.002B1798 () de ! ibm ! com
[Download RAW message or body]


Hello Michelle,

> 3. socks proxy
> nothing if according to what Roland mentioned below"SOCKS 
> connections are transparent
> to HttpClient", then how do you know it is using socks proxy or a 
> direct connect?

We don't. SOCKS is transparent to HTTP, so there is no reason
why HttpClient should know about it. Sockets are created using
the standard JDK functionality, and that's where it is decided
whether the connection is direct or through SOCKS. HttpClient
just uses the socket connection it gets from the JDK.

> The wield thing is if I do 
> client.getState().setProxyCredentials(new AuthScope(hostName,port), new
> UsernamePasswordCredentials(NTUser, NTpassword));
> or
> client.getState().setProxyCredentials(new AuthScope(hostName,port), new
> NTCredentials(user, password,hostName, domain));
> they both work fine. why?

If your proxy doesn't require NTLM authentication but supports
BASIC authentication, then BASIC authentication can be performed
with both kinds of credentials. Test against a proxy that requires
NTLM authentication and you should see the first version fail.

hope that helps,
  Roland


["smime.p7s" (application/x-pkcs7-signature)]

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic