title: How to use wsdl2java to generate code from WSDL which is secured using x.509 certificate?
body: <p>I try to generate Java classes using wsdl2java. </p>
  
  <p>Wsdl is located in remote server which is secured using X509 certificate, in such a way, that when I try to access it in the browser without having certificate in trust store, it is returning an error (of course when I have certificate imported into <code>certmgr.msc</code>, wsdl is showing just fine).</p>
  
  <p>Unfortunatelly, when I try to run wsdl2java, I get: </p>
  
  <pre><code>&gt; org.apache.cxf.wsdl11.WSDLRuntimeException: Fail to create wsdl definition file:/resources/wsdl/my.xml: WSDLException (at /wsdl:definitions/wsdl:types/xsd:schema): faultCode=PARSER_ERROR: Problem parsing 'https://SERVER_HOST/my?xsd=../xsd/XX.xsd'.: javax.net.ssl.SSLHandshakeException: Received fatal alert: handshake_failure
  </code></pre>
  
  <p>I have my certificate imported in JKS store. </p>
  
  <p>How can I advise wsdl2java to use that certificate from JKS in order to connect to the serwer?</p>