Return-Path: Delivered-To: apmail-axis-java-dev-archive@www.apache.org Received: (qmail 23998 invoked from network); 14 Sep 2010 00:18:16 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 14 Sep 2010 00:18:16 -0000 Received: (qmail 35744 invoked by uid 500); 14 Sep 2010 00:18:15 -0000 Delivered-To: apmail-axis-java-dev-archive@axis.apache.org Received: (qmail 35382 invoked by uid 500); 14 Sep 2010 00:18:14 -0000 Mailing-List: contact java-dev-help@axis.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: java-dev@axis.apache.org Delivered-To: mailing list java-dev@axis.apache.org Received: (qmail 35374 invoked by uid 99); 14 Sep 2010 00:18:14 -0000 Received: from Unknown (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 14 Sep 2010 00:18:14 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED,WEIRD_PORT X-Spam-Check-By: apache.org Received: from [140.211.11.22] (HELO thor.apache.org) (140.211.11.22) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 14 Sep 2010 00:17:56 +0000 Received: from thor (localhost [127.0.0.1]) by thor.apache.org (8.13.8+Sun/8.13.8) with ESMTP id o8E0HYlu007672 for ; Tue, 14 Sep 2010 00:17:35 GMT Message-ID: <29838261.168151284423454925.JavaMail.jira@thor> Date: Mon, 13 Sep 2010 20:17:34 -0400 (EDT) From: "Mark Kinsella (JIRA)" To: java-dev@axis.apache.org Subject: [jira] Updated: (AXIS2-4060) wsdl2java is unable to retrieve a WSDL when basic authentication is required MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/AXIS2-4060?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Mark Kinsella updated AXIS2-4060: --------------------------------- Comment: was deleted (was: I reproduced this error and tested it with a quick-and-dirty PHP page that logs all sent credentials -- indeed, there are no credentials at all being passed from wsdl2java to my page. I'm not sure I'm following the source correctly, but per my initial investigation, this looks like an issue with the associated wsdl4j-1.6.2 library, specifically the getContentAsInputStream(URL url) function in the com.ibm.wsdl.util.StringUtils class. I can't see that there is any credential passing going on here, nor any reading of credentials from the URL via url.getUserInfo() or anything similar. Not sure what might have changed here, as I can't find a copy of wsdl4j prior to a 1.6.2 release, and I'm not sure what libs axis2 was using in the functioning version.) > wsdl2java is unable to retrieve a WSDL when basic authentication is required > ---------------------------------------------------------------------------- > > Key: AXIS2-4060 > URL: https://issues.apache.org/jira/browse/AXIS2-4060 > Project: Axis2 > Issue Type: Bug > Affects Versions: 1.4.1, 1.4 > Reporter: Jorge Medina > Assignee: Dimuthu Leelarathne > > When access to the WSDL requires basic authentication, wsdl2java fails to send the credentials in version 1.4.1 > while version 1.3 works fine. > Using version 1.4.1: > > wsdl2java -uri http://ssmith:password@myapp.example.com:8080/webservices/mywsdl.wsdl -s -uw -u > you will get HTTP error 401 as shown below, while the same command works fine when using version 1.3. > ------ ---- --- --- --- --- --- --- > Retrieving document at 'http://ssmith:password@myapp.example.com:8080/company-webservices/mywsdl.wsdl'. > Exception in thread "main" org.apache.axis2.wsdl.codegen.CodeGenerationException > : Error parsing WSDL > at org.apache.axis2.wsdl.codegen.CodeGenerationEngine.(CodeGenerat > ionEngine.java:156) > at org.apache.axis2.wsdl.WSDL2Code.main(WSDL2Code.java:35) > at org.apache.axis2.wsdl.WSDL2Java.main(WSDL2Java.java:24) > Caused by: javax.wsdl.WSDLException: WSDLException: faultCode=OTHER_ERROR: Unabl > e to resolve imported document at 'http://ssmith:password@myapp.example.com:8 > 080/webservices/mywsdl.wsdl'.: java.io.IOException: Server retu > rned HTTP response code: 401 for URL: http://ssmith:password@sdk.eng.e-dialog.co > m:8080/webservices/mywsdl.wsdl > at com.ibm.wsdl.xml.WSDLReaderImpl.readWSDL(Unknown Source) > at com.ibm.wsdl.xml.WSDLReaderImpl.readWSDL(Unknown Source) > at org.apache.axis2.wsdl.codegen.CodeGenerationEngine.readInTheWSDLFile( > CodeGenerationEngine.java:288) > at org.apache.axis2.wsdl.codegen.CodeGenerationEngine.(CodeGenerat > ionEngine.java:111) > ... 2 more > Caused by: java.io.IOException: Server returned HTTP response code: 401 for URL: > http://ssmith:password@myapp.example.com:8080/webservices/mailingCru > dWsdl.wsdl > at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLCon > nection.java:1241) > at java.net.URL.openStream(URL.java:1009) > at com.ibm.wsdl.util.StringUtils.getContentAsInputStream(Unknown Source) > > ... 6 more -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online. --------------------------------------------------------------------- To unsubscribe, e-mail: java-dev-unsubscribe@axis.apache.org For additional commands, e-mail: java-dev-help@axis.apache.org