Return-Path: Delivered-To: apmail-ws-axis-dev-archive@www.apache.org Received: (qmail 59154 invoked from network); 2 Dec 2004 14:05:36 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur-2.apache.org with SMTP; 2 Dec 2004 14:05:35 -0000 Received: (qmail 33050 invoked by uid 500); 2 Dec 2004 14:02:43 -0000 Delivered-To: apmail-ws-axis-dev-archive@ws.apache.org Received: (qmail 32991 invoked by uid 500); 2 Dec 2004 14:02:43 -0000 Mailing-List: contact axis-dev-help@ws.apache.org; run by ezmlm Precedence: bulk Reply-To: axis-dev@ws.apache.org list-help: list-unsubscribe: list-post: Delivered-To: mailing list axis-dev@ws.apache.org Received: (qmail 32960 invoked by uid 99); 2 Dec 2004 14:02:42 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received: from exchange.sun.com (HELO exchange.sun.com) (192.18.33.10) by apache.org (qpsmtpd/0.28) with SMTP; Thu, 02 Dec 2004 06:02:31 -0800 Received: (qmail 13966 invoked from network); 2 Dec 2004 14:02:22 -0000 Received: from localhost (HELO nagoya) (127.0.0.1) by nagoya.betaversion.org with SMTP; 2 Dec 2004 14:02:22 -0000 Message-ID: <867004709.1101996142480.JavaMail.apache@nagoya> Date: Thu, 2 Dec 2004 06:02:22 -0800 (PST) From: "Per Thomas Jahr (JIRA)" To: axis-dev@ws.apache.org Subject: [jira] Commented: (AXIS-1689) Broken NTLM support in CommonsHTTPSender In-Reply-To: <1017524947.1101825568623.JavaMail.apache@nagoya> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N [ http://nagoya.apache.org/jira/browse/AXIS-1689?page=comments#action_56103 ] Per Thomas Jahr commented on AXIS-1689: --------------------------------------- Seems fine to me and it runs correctly. Thanks! -- Per Thomas > Broken NTLM support in CommonsHTTPSender > ---------------------------------------- > > Key: AXIS-1689 > URL: http://nagoya.apache.org/jira/browse/AXIS-1689 > Project: Axis > Type: Bug > Components: Basic Architecture > Versions: current (nightly) > Reporter: Per Thomas Jahr > > The current implementation of CommonsHTTPSender will not work with proxies using NTLM authentication (ISA Server 2004). According to the documentation for HttpClient one needs to use NTCredentials instead of UsernamePasswordCredentials when setting up credentials. > The following code will fix the problem (starting at line 287 inside the method getHostConfiguration in org.apache.axis.transport.http.CommonsHTTPSender): > if (tcp.getProxyUser().length() != 0) { > // begin fix for NTLM > Credentials proxyCred = new UsernamePasswordCredentials(tcp.getProxyUser(), > tcp.getProxyPassword()); > // if the username is in the form "user\domain" use NTCredentials instead. > if (tcp.getProxyUser().indexOf("\\") > 0) { > int domainIndex = tcp.getProxyUser().indexOf("\\"); > String domain = tcp.getProxyUser().substring(0, domainIndex); > if (tcp.getProxyUser().length() > domainIndex + 1) { > String user = tcp.getProxyUser().substring(domainIndex + 1); > proxyCred = new NTCredentials(user, tcp.getProxyPassword(), tcp.getProxyHost(), domain); > } > } > // end fix for NTLM > client.getState().setProxyCredentials(null, null, proxyCred); > } > There should certainly be another way of deciding if one should use NTCredentials or UsernamePasswordCredentials than parsing the username for a "\". But this works for me. > If anyone is interested in testing Axis against ISA Server 2004 I can do that from now and until February 2005. -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://nagoya.apache.org/jira/secure/Administrators.jspa - If you want more information on JIRA, or have a bug to report see: http://www.atlassian.com/software/jira