title: CXF wsdl2java not resolving catalog
body: <p>I'm using the wsdl2java tool with the cxf-codegen-plugin for maven in an <strong>offline</strong> scenario.
  I have a jar <em>Types.jar</em> including common XML Schemata which are translated to java classes using the jaxb2-maven-plugin. I'm using an OASIS xml catalog to refer to local copies of common schemata like e.g. xmldsig-core-schema.xsd. This works so far.</p>
  
  <p>I also have a <em>WebService.jar</em> which consists of a wsdl and an accompaning xsd, which imports Schemata from <em>Types.jar</em>.</p>
  
  <p>When running the maven build, I get the following error:</p>
  
  <pre><code>    Loading FrontEnd jaxws ...
  Loading DataBinding jaxb ...
  wsdl2java -encoding UTF-8 -d C:\path\to\my\project\src\generated\java -b classpath:/xsd/Types.xjb -b classpath:/xsd/simpleBinding.schemalet -xjc-verbose -xjc-encoding -xjcUTF-8 -xjc-
  catalog -xjcC:/path/to/my/catalog.cat -catalog C:/path/to/my/catalog.cat -p http://ws.myws.com/Test=com.myws.ws.test -verbose -wsdlLocation wsdl/MYWSDL.wsdl file:/C:/path/to/my/MYWSDL.wsdl
  wsdl2java - Apache CXF 2.7.11
  
  [DEBUG]
  org.apache.cxf.tools.common.ToolException: org.apache.cxf.wsdl11.WSDLRuntimeException: Fail to create wsdl definition file:/C:/path/to/my/MYWSDL.wsdl
  _SOAP.wsdl: WSDLException (at /wsdl:definitions/wsdl:types/schema/xs:schema/xs:schema/schema): faultCode=PARSER_ERROR: Problem parsing 'jar:file:/C:/Users/me/.m2/repository/path/to/my/types.jar!/xsd/xmldsig-core-schema.xsd'.: java.net.UnknownHostException: www.w3.org
      at org.apache.cxf.tools.wsdlto.WSDLToJavaContainer.execute(WSDLToJavaContainer.java:420)
      at org.apache.cxf.tools.common.toolspec.ToolRunner.runTool(ToolRunner.java:103)
      at org.apache.cxf.tools.wsdlto.WSDLToJava.run(WSDLToJava.java:113)
      at org.apache.cxf.tools.wsdlto.WSDLToJava.run(WSDLToJava.java:86)
      at org.apache.cxf.maven_plugin.wsdl2java.WSDL2JavaMojo.generate(WSDL2JavaMojo.java:427)
      at org.apache.cxf.maven_plugin.AbstractCodegenMoho.execute(AbstractCodegenMoho.java:311)
      at org.apache.cxf.maven_plugin.wsdl2java.WSDL2JavaMojo.execute(WSDL2JavaMojo.java:524)
      at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:101)
      at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:209)
      at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
      at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
      at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:84)
      at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:59)
      at org.apache.maven.lifecycle.internal.LifecycleStarter.singleThreadedBuild(LifecycleStarter.java:183)
      at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:161)
      at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:319)
      at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:156)
      at org.apache.maven.cli.MavenCli.execute(MavenCli.java:537)
      at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:196)
      at org.apache.maven.cli.MavenCli.main(MavenCli.java:141)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      at java.lang.reflect.Method.invoke(Method.java:606)
      at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:290)
      at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:230)
      at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:409)
      at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:352)
  Caused by: org.apache.cxf.wsdl11.WSDLRuntimeException: Fail to create wsdl definition file:/C:/path/to/my/MYWSDL.wsdl_SOAP.wsdl: WSDLException (at /w
  sdl:definitions/wsdl:types/schema/xs:schema/xs:schema/schema): faultCode=PARSER_ERROR: Problem parsing 'jar:file:/C:/Users/me/.m2/repository/path/to/my/types.jar!/xsd/xmldsig-core-schema.xsd'.: java.net.UnknownHostException: www.w3.org
      at org.apache.cxf.wsdl11.WSDLDefinitionBuilder.parseWSDL(WSDLDefinitionBuilder.java:97)
      at org.apache.cxf.wsdl11.WSDLDefinitionBuilder.build(WSDLDefinitionBuilder.java:69)
      at org.apache.cxf.tools.wsdlto.frontend.jaxws.wsdl11.JAXWSDefinitionBuilder.build(JAXWSDefinitionBuilder.java:82)
      at org.apache.cxf.tools.wsdlto.frontend.jaxws.wsdl11.JAXWSDefinitionBuilder.build(JAXWSDefinitionBuilder.java:59)
      at org.apache.cxf.tools.wsdlto.WSDLToJavaContainer.processWsdl(WSDLToJavaContainer.java:198)
      at org.apache.cxf.tools.wsdlto.WSDLToJavaContainer.execute(WSDLToJavaContainer.java:164)
      at org.apache.cxf.tools.wsdlto.WSDLToJavaContainer.execute(WSDLToJavaContainer.java:412)
      ... 27 more
  Caused by: javax.wsdl.WSDLException: WSDLException (at /wsdl:definitions/wsdl:types/schema/xs:schema/xs:schema/schema): faultCode=PARSER_ERROR: Problem parsing 'jar:file:/C:/Users/me/.m2/repository/path/to/my/types.jar!/xsd/xmldsig-core-schema.xsd'.: java.net.UnknownHostException: www.w3.org
      at com.ibm.wsdl.xml.WSDLReaderImpl.getDocument(WSDLReaderImpl.java:2198)
      at com.ibm.wsdl.xml.WSDLReaderImpl.parseSchema(WSDLReaderImpl.java:830)
      at com.ibm.wsdl.xml.WSDLReaderImpl.parseSchema(WSDLReaderImpl.java:864)
      at com.ibm.wsdl.xml.WSDLReaderImpl.parseSchema(WSDLReaderImpl.java:864)
      at com.ibm.wsdl.xml.WSDLReaderImpl.parseSchema(WSDLReaderImpl.java:864)
      at com.ibm.wsdl.xml.WSDLReaderImpl.parseSchema(WSDLReaderImpl.java:654)
      at com.ibm.wsdl.xml.WSDLReaderImpl.parseTypes(WSDLReaderImpl.java:610)
      at com.ibm.wsdl.xml.WSDLReaderImpl.parseDefinitions(WSDLReaderImpl.java:320)
      at com.ibm.wsdl.xml.WSDLReaderImpl.readWSDL(WSDLReaderImpl.java:2352)
      at com.ibm.wsdl.xml.WSDLReaderImpl.readWSDL(WSDLReaderImpl.java:2338)
      at org.apache.cxf.wsdl11.WSDLManagerImpl.loadDefinition(WSDLManagerImpl.java:261)
      at org.apache.cxf.wsdl11.WSDLManagerImpl.getDefinition(WSDLManagerImpl.java:206)
      at org.apache.cxf.wsdl11.WSDLDefinitionBuilder.parseWSDL(WSDLDefinitionBuilder.java:78)
      ... 33 more
  Caused by: java.net.UnknownHostException: www.w3.org
      at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:178)
      at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:172)
      at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)
      at java.net.Socket.connect(Socket.java:579)
      at java.net.Socket.connect(Socket.java:528)
      at sun.net.NetworkClient.doConnect(NetworkClient.java:180)
      at sun.net.www.http.HttpClient.openServer(HttpClient.java:432)
      at sun.net.www.http.HttpClient.openServer(HttpClient.java:527)
      at sun.net.www.http.HttpClient.&lt;init&gt;(HttpClient.java:211)
      at sun.net.www.http.HttpClient.New(HttpClient.java:308)
      at sun.net.www.http.HttpClient.New(HttpClient.java:326)
      at sun.net.www.protocol.http.HttpURLConnection.getNewHttpClient(HttpURLConnection.java:996)
      at sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConnection.java:932)
      at sun.net.www.protocol.http.HttpURLConnection.connect(HttpURLConnection.java:850)
      at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1300)
      at org.apache.xerces.impl.XMLEntityManager.setupCurrentEntity(Unknown Source)
      at org.apache.xerces.impl.XMLEntityManager.startEntity(Unknown Source)
      at org.apache.xerces.impl.XMLEntityManager.startDTDEntity(Unknown Source)
      at org.apache.xerces.impl.XMLDTDScannerImpl.setInputSource(Unknown Source)
      at org.apache.xerces.impl.XMLDocumentScannerImpl$DTDDispatcher.dispatch(Unknown Source)
      at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
      at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
      at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
      at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
      at org.apache.xerces.parsers.DOMParser.parse(Unknown Source)
      at org.apache.xerces.jaxp.DocumentBuilderImpl.parse(Unknown Source)
      at com.ibm.wsdl.xml.WSDLReaderImpl.getDocument(WSDLReaderImpl.java:2188)
      ... 45 more
  </code></pre>
  
  <p>My catalog.cat looks like this:</p>
  
  <pre><code>SYSTEM "http://www.w3.org/2001/xml.xsd" "classpath:/xsd/xml.xsd"
  PUBLIC "http://www.w3.org/2001/XMLSchema" "classpath:/xsd/xml.xsd"
  PUBLIC "-//W3C//DTD XMLSchema 200102//EN" "classpath:/xsd/XMLSchema.dtd"
  SYSTEM "http://www.w3.org/2001/XMLSchema.dtd" "classpath:/xsd/XMLSchema.dtd"
  </code></pre>
  
  <p>I tried cxf 2.7.6 and 2.7.11, I tried the XML catalog format, I even copied all the referenced Schemata to the <em>WebService.jar</em> without the <em>classpath:</em> expressions in the catalog, all with the same result and error message.</p>
  
  <p>It seems the catalog Information is lost somewhere.</p>
  
  <p>Any ideas?</p>