Brian,

This feature is available in HttpClient 3.0 only:

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=10794

Please note, though, that HttpClient 3.0 is still in an early alpha state

Oleg

-----Original Message-----
From: Russell, Brian [mailto:[EMAIL PROTECTED]
Sent: Tuesday, May 18, 2004 12:29
To: [EMAIL PROTECTED]
Subject: Supplying Credentials only when needed.


I am using http client 2.0

I have managed to use the NTCredentials to successfully authenticate
with an NTLM proxy, by providing the credentials to the HttpState

 Credentials proxyCred = new
NTCredentials(loggedInUserName,userPassword,"",domainName);
 client.getState().setProxyCredentials(null,proxyCred);

This is all very well where I know for sure that there is an NTLM proxy
in place, and I can prompt the user for their Windows logon details, and
provide an instance of a Credentials object which is an NTCredentials.
My application, however, needs to cater for various environments, where
there may be no proxies, proxies authenticating by IP address, proxies
using Basic authentication etc etc.
Is it possible for httpclient to inform its caller when it encounters a
challenge, and to indicate what type of challenge it is. The caller can
then decide which type of Credentials object to supply to the state?

I don't know if what I am asking for exists, or if it is a new feature.
Hopefully the former.

Any comments would be appreciated.


Thanks,


Brian.

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


***************************************************************************************************
The information in this email is confidential and may be legally privileged.  Access 
to this email by anyone other than the intended addressee is unauthorized.  If you are 
not the intended recipient of this message, any review, disclosure, copying, 
distribution, retention, or any action taken or omitted to be taken in reliance on it 
is prohibited and may be unlawful.  If you are not the intended recipient, please 
reply to or forward a copy of this message to the sender and delete the message, any 
attachments, and any copies thereof from your system.
***************************************************************************************************

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

Reply via email to