Hi,

Stub.getOptions should help you.

// Sample code

HttpTransportProperties.Authenticator auth = new
HttpTransportProperties.Authenticator();

auth.setPreemptiveAuthentication(true);
auth.setAuthSchemes(authSchemes);

auth.setUsername("username"); 
auth.setPassword("password");

Options options = ((YourStub)._getServiceClient().getOptions(); 

options.setProperty(HTTPConstants.AUTHENTICATE, auth);

YourStub._getServiceClient().setOptions(options);


Haneef

________________________________

From: Nencho Lupanov [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, July 11, 2007 6:26 AM
To: [EMAIL PROTECTED]; [email protected]
Subject: HttpBasicAuthentification scenarion


Hi all,
 i am trying to use the axis2 ServiceClient against 
web service endpoint that has http basic authentification enabled.
 
I wonder - is there a way to get hold of the http-commons HttpClient
that is used underneath in order to set the Credentials?
 
Thanks,
Nencho

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

Reply via email to