Eh, why? CommonsHTTP supports NTLM auth over HTTP. The problem just looks like a bug crept into commonsHTTPsender somewhere along the lines.
Cheers Simon -----Original Message----- From: Martin Gainty [mailto:[EMAIL PROTECTED] Sent: Wednesday, July 19, 2006 1:22 PM To: axis-user@ws.apache.org; [EMAIL PROTECTED] Subject: Re: Axis client and .NET Web Service using NTLM security You are going to have to shoehorn the NTLM security credentials inside the SOAP:header e.g. <wsse:Security xmlns:wsse="http://schemas.xmlsoap.org/ws/2002/12/secext"> <wsse:UsernameToken> <wsse:Username>Bob</wsse:Username> <wsse:Password>YourStr0ngPassWord</wsse:Password> </wsse:UsernameToken> </wsse:Security> in order to authenticate to the NTLM credentialing authority No small task M- ********************************************************************* This email message and any files transmitted with it contain confidential information intended only for the person(s) to whom this email message is addressed. If you have received this email message in error, please notify the sender immediately by telephone or email and destroy the original message without making a copy. Thank you. ----- Original Message ----- From: "Davanum Srinivas" <[EMAIL PROTECTED]> To: <axis-user@ws.apache.org> Sent: Wednesday, July 19, 2006 3:09 PM Subject: Re: Axis client and .NET Web Service using NTLM security > Can you please try Axis1.4 and also download latest commons http client jar? > > -- dims > > On 7/19/06, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: >> >> >> >> Hi, >> I have spent about a week researching this and google just isn't getting me >> a viable working solution. Please advise if possible. >> >> I am using Axis code which I generated using wsdl2java. I need to >> communicate with a .NET web service that uses the ntlm authentication >> scheme. I do not want to go the client-config.wsdd route. I would rather >> specify that I want to use the CommonsHTTPSender class programatically. >> >> In my generated axis stub (and I wish I didn't have to modify a stub..) I >> have added the following lines of code to the createCall() method (it is >> surrounded by comments): >> >> >> <CODE> >> protected org.apache.axis.client.Call createCall() throws >> java.rmi.RemoteException { >> try { >> org.apache.axis.client.Call _call = (org.apache.axis.client.Call) >> super.service.createCall(); >> >> // Use HttpClient for ntlm. - start >> org.apache.axis.transport.http.CommonsHTTPSender >> reqConnectionHandler = new >> org.apache.axis.transport.http.CommonsHTTPSender(); >> >> org.apache.axis.transport.http.CommonsHTTPSender >> respConnectionHandler = new >> org.apache.axis.transport.http.CommonsHTTPSender(); >> >> >> _call.setClientHandlers(reqConnectionHandler,respConnectionHandler); >> >> super.setUsername("QA-DOMAIN\\andyh"); >> super.setPassword("VikesDominatePackers"); >> // Use HttpClient for ntlm. - end >> >> if (super.maintainSessionSet) { >> _call.setMaintainSession(super.maintainSession); >> } >> >> ... >> </CODE> >> >> >> The resulting POST from TCPMON is this: >> >> POST /imgservice.asmx HTTP/1.1 >> Content-Type: text/xml; charset=utf-8 >> SOAPAction: >> "http://wellsfargo.com/provide/image/performView/2005/" >> Authorization: Basic QUQfGN5UXGFJeUdIldhdGVyMTImQPA== >> User-Agent: Jakarta Commons-HttpClient/3.0.1 >> Host: localhost:9001 >> Content-Length: 559 >> >> <soapenv:Envelope >> xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" >> xmlns:xsd="http://www.w3.org/2001/XMLSchema" >> >> >> This is the resulting error from my java console: >> >> - Unable to find required classes (javax.activation.DataHandler and >> javax.mail.internet.MimeMultipart). Attachment support is >> disabled. >> >> - ntlm authentication scheme selected >> - Failure authenticating with NTLM <any realm>@localhost:9001 >> - Error in ezimg service. AxisFault caught. MessageId: null >> AxisFault >> faultCode: {http://xml.apache.org/axis/}HTTP >> faultSubcode: >> faultString: (401)Unauthorized >> faultActor: >> faultNode: >> faultDetail: >> {}:return code: 401 >> >> >> So it appears NTLM is being used because of the second line output above, >> however the TCPMON output states that BASIC authentication is being used. I >> am very confused by this. Thanks for helping!!!! >> >> Andy >> >> >> >> >> Andrew Hahn >> HCFTG - Sales Technology Group >> Technology Information Group >> >> >> This message may contain confidential and/or privileged information. If you >> are not the addressee or authorized to receive this for the addressee, you >> must not use, copy, disclose, or take any action based on this message or >> any information herein. If you have received this message in error, please >> advise the sender immediately by reply e-mail and delete this message. >> Thank you for your cooperation. >> >> > > > -- > Davanum Srinivas : http://www.wso2.net (Oxygen for Web Service Developers) > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]