No, you have to setup the keystore to contain the self-signed certificate. If you perform a google search you will see examples of how this can be done.
There may be an alternative to using System.setProperty so that you do not need to modify the WSDL2Java code. Someone on this list may be able to tell you how, or Google is your friend. Regardless, I don't see how this would fix your Instantiation exception reported in the other email. From: james a. cubeta [mailto:[EMAIL PROTECTED] Sent: Thursday, September 18, 2008 6:28 PM To: [email protected] Subject: Re: Newbie wsdl2java question... Thanks Ryan - some stupid follow-up question: First, setup a java keystore. A simple google search should get you going. Just set up an empty keystore? Next, put this code in the WSDL2Java main function: // set the keystore stuff System.setProperty("javax.net.ssl.trustStore", "keystore_filename"); System.setProperty("javax.net.ssl.keyStorePassword", "keystore_password"); How am I to modify the WSDL2Java utility? I only have a bunch of Axis-related JARs. Thanks, James -Ryan From: james a. cubeta [mailto:[EMAIL PROTECTED]<mailto:[EMAIL PROTECTED]>] Sent: Thursday, September 18, 2008 3:10 PM To: [email protected]<mailto:[email protected]> Subject: Newbie wsdl2java question... Hello everyone, I am both new to Axis and new to this mailing list, so I apologize in advance if my questions are simple or have been covered... I am trying to use Axis 1.4 to develop a simple application that will test a web service that is deployed on a private network. As a first step, I am trying to generate stub code using the WSDL2Java tool. Because the server is https & uses an IP only, my command line resembles this: java org.apache.axis.wsdl.WSDL2Java --username user --password pass https://192.168.1.150:8443/example-ws/services/SimpleExample?wsdl When I run this, I get the following exception: javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target <exception stack truncated> Questions: 1. I assume that the reason this is happening is because the server is using a self-signed certificate, and the JVM cannot validate it. Is this assumption correct? 2. How can I get around this problem? (Note that I do not have administrative access to the server, so making changes on that end is probably not possible). Thanks in advance for any help or references, James -- james a. cubeta -- james a. cubeta
