hc-httpclient-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "John Watson" <JWat...@sis.tv>
Subject Help with basic authentication
Date Mon, 30 Mar 2009 10:48:18 GMT
I'm a new user of Http Client 4.0 (beta 2) and I'm struggling with BASIC
authentication.  I'm attempting to follow the authentication sample
using (simply):

 

        httpclient.getCredentialsProvider().setCredentials(

                new AuthScope(realm, port),

                new UsernamePasswordCredentials(userName, password));

 

Firstly, I can't seem to set pre-emptive authentication using as a guide
the sample from http://hc.apache.org/httpclient-3.x/authentication.html
- I can't seem to find the method
client.getParams().setAuthenticationPreemptive(...);
 
Secondly, from inspecting the logs issued by the client, it appears that
the authorization request header that I'd expect to see is not there.
 
I'm obviously missing something obvious, but for the life of me, can't
find what it is.  Any help gratefully accepted.
 
John Watson
 
 

 


**********************************************************************
Satellite Information Services Limited. Registered Office: 17 Corsham Street, London, N1 6DR.
Company No. 4243307
The information in this email (which includes any files transmitted with it) is confidential
and is intended for the addressee only. Unauthorized recipients are required to maintain confidentiality.
If you have received this email in error please notify the sender immediately, destroy any
copies and delete it from your computer system.
**********************************************************************


Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message