Валидация Soap-XML против XSD не работает

так как много дней я пытаюсь проверить soap requst xml против моего xsd, но без успеха:

Это мой XML (сгенерированный PHP-Soap-Client):

<?xml version="1.0" encoding="UTF-8"?> <env:Envelope xmlns:env="http://www.w3.org/2003/05/soap-envelope" xmlns:ns1="http://localhost/APItest" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:enc="http://www.w3.org/2003/05/soap-encoding"> <env:Body> <ns1:Hello env:encodingStyle="http://www.w3.org/2003/05/soap-encoding"> <input xsi:type="ns1:HelloRequest"> <name xsi:type="ns1:name">MartinMartinMartinMartin</name> <car xsi:type="ns1:car">Ford</car> </input> </ns1:Hello> </env:Body> </env:Envelope> 

И это мой XSD:

 <?xml version="1.0" encoding="UTF-8" standalone="yes"?> <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" targetNamespace="http://localhost/APItest" xmlns="http://localhost/APItest" elementFormDefault="qualified"> <xsd:element name="HelloRequest"> <xsd:complexType> <xsd:sequence> <xsd:element name="name"> <xsd:simpleType> <xsd:restriction base="xsd:string"> <xsd:minLength value="5"/> <xsd:maxLength value="8"/> </xsd:restriction> </xsd:simpleType> </xsd:element> <xsd:element name="car"> <xsd:simpleType> <xsd:restriction base="xsd:string"> <xsd:enumeration value="Audi"/> <xsd:enumeration value="Golf"/> <xsd:enumeration value="BMW"/> </xsd:restriction> </xsd:simpleType> </xsd:element> </xsd:sequence> </xsd:complexType> </xsd:element> <xsd:element name="HelloResponse"> <xsd:complexType> <xsd:sequence> <xsd:element minOccurs="0" name="result" type="xsd:string"/> <xsd:element minOccurs="0" name="time" type="xsd:dateTime"/> </xsd:sequence> </xsd:complexType> </xsd:element> </xsd:schema> пространство <?xml version="1.0" encoding="UTF-8" standalone="yes"?> <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" targetNamespace="http://localhost/APItest" xmlns="http://localhost/APItest" elementFormDefault="qualified"> <xsd:element name="HelloRequest"> <xsd:complexType> <xsd:sequence> <xsd:element name="name"> <xsd:simpleType> <xsd:restriction base="xsd:string"> <xsd:minLength value="5"/> <xsd:maxLength value="8"/> </xsd:restriction> </xsd:simpleType> </xsd:element> <xsd:element name="car"> <xsd:simpleType> <xsd:restriction base="xsd:string"> <xsd:enumeration value="Audi"/> <xsd:enumeration value="Golf"/> <xsd:enumeration value="BMW"/> </xsd:restriction> </xsd:simpleType> </xsd:element> </xsd:sequence> </xsd:complexType> </xsd:element> <xsd:element name="HelloResponse"> <xsd:complexType> <xsd:sequence> <xsd:element minOccurs="0" name="result" type="xsd:string"/> <xsd:element minOccurs="0" name="time" type="xsd:dateTime"/> </xsd:sequence> </xsd:complexType> </xsd:element> </xsd:schema> 

Я использую инструмент проверки xsd: http://www.utilities-online.info/xsdvalidation Там я получил ошибку:

Недействительно. Ошибка – строка 2, 255: org.xml.sax.SAXParseException; lineNumber: 2; columnNumber: 255; cvc-elt.1: Не удается найти объявление элемента 'env: Envelope'. Ошибка – строка 5, 36: org.xml.sax.SAXParseException; lineNumber: 5; columnNumber: 36; cvc-elt.4.2: Не удается разрешить 'ns1: HelloRequest' для определения типа для элемента input. Ошибка – строка 6, 27: org.xml.sax.SAXParseException; lineNumber: 6; columnNumber: 27; cvc-elt.4.2: Не удается разрешить «ns1: name» для определения типа для «name» элемента. Ошибка – строка 7, 25: org.xml.sax.SAXParseException; lineNumber: 7; columnNumber: 25; cvc-elt.4.2: Не удается разрешить «ns1: car» для определения типа для элемента «автомобиль».

Я также попробую функцию xml-> schemaValidate в php . Здесь я получил:

Ошибка 1845: Element '{ http://www.w3.org/2003/05/soap-envelope } Envelope': для корня проверки нет соответствующей глобальной декларации.

Прочитав много результатов в google, я обнаружил, что мне нужно импортировать схему конверта:

 <xsd:import namespace="http://schemas.xmlsoap.org/soap/envelope/" schemaLocation="http://schemas.xmlsoap.org/soap/envelope/"/> 

Но чем вернется инструмент проверки:

 <html><head><title>Apache Tomcat/7.0.54 - Error report</title><style><!--H1 {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:22px;} H2 {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:16px;} H3 {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:14px;} BODY {font-family:Tahoma,Arial,sans-serif;color:black;background-color:white;} B {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;} P {font-family:Tahoma,Arial,sans-serif;background:white;color:black;font-size:12px;}A {color : black;}A.name {color : black;}HR {color : #525D76;}--></style> </head><body><h1>HTTP Status 500 - access denied (&quot;java.net.SocketPermission&quot; &quot;schemas.xmlsoap.org:80&quot; &quot;connect,resolve&quot;)</h1><HR size="1" noshade="noshade"><p><b>type</b> Exception report</p><p><b>message</b> <u>access denied (&quot;java.net.SocketPermission&quot; &quot;schemas.xmlsoap.org:80&quot; &quot;connect,resolve&quot;)</u></p><p><b>description</b> <u>The server encountered an internal error that prevented it from fulfilling this request.</u></p><p><b>exception</b> <pre>java.security.AccessControlException: access denied (&quot;java.net.SocketPermission&quot; &quot;schemas.xmlsoap.org:80&quot; &quot;connect,resolve&quot;) java.security.AccessControlContext.checkPermission(AccessControlContext.java:472) java.security.AccessController.checkPermission(AccessController.java:884) java.lang.SecurityManager.checkPermission(SecurityManager.java:549) java.lang.SecurityManager.checkConnect(SecurityManager.java:1051) sun.net.www.http.HttpClient.openServer(HttpClient.java:510) sun.net.www.http.HttpClient.&lt;init&gt;(HttpClient.java:211) sun.net.www.http.HttpClient.New(HttpClient.java:308) sun.net.www.http.HttpClient.New(HttpClient.java:326) sun.net.www.protocol.http.HttpURLConnection.getNewHttpClient(HttpURLConnection.java:1169) sun.net.www.protocol.http.HttpURLConnection.plainConnect0(HttpURLConnection.java:1105) sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConnection.java:999) sun.net.www.protocol.http.HttpURLConnection.connect(HttpURLConnection.java:933) sun.net.www.protocol.http.HttpURLConnection.getInputStream0(HttpURLConnection.java:1513) sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1441) com.sun.org.apache.xerces.internal.impl.XMLEntityManager.setupCurrentEntity(XMLEntityManager.java:647) com.sun.org.apache.xerces.internal.impl.XMLVersionDetector.determineDocVersion(XMLVersionDetector.java:148) com.sun.org.apache.xerces.internal.impl.xs.opti.SchemaParsingConfig.parse(SchemaParsingConfig.java:582) com.sun.org.apache.xerces.internal.impl.xs.opti.SchemaParsingConfig.parse(SchemaParsingConfig.java:685) com.sun.org.apache.xerces.internal.impl.xs.opti.SchemaDOMParser.parse(SchemaDOMParser.java:530) com.sun.org.apache.xerces.internal.impl.xs.traversers.XSDHandler.getSchemaDocument(XSDHandler.java:2179) com.sun.org.apache.xerces.internal.impl.xs.traversers.XSDHandler.resolveSchema(XSDHandler.java:2082) com.sun.org.apache.xerces.internal.impl.xs.traversers.XSDHandler.constructTrees(XSDHandler.java:1012) com.sun.org.apache.xerces.internal.impl.xs.traversers.XSDHandler.parseSchema(XSDHandler.java:623) com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaLoader.loadSchema(XMLSchemaLoader.java:613) com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaLoader.loadGrammar(XMLSchemaLoader.java:572) com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaLoader.loadGrammar(XMLSchemaLoader.java:538) com.sun.org.apache.xerces.internal.jaxp.validation.XMLSchemaFactory.newSchema(XMLSchemaFactory.java:255) javax.xml.validation.SchemaFactory.newSchema(SchemaFactory.java:638) info.utilitiesonline.backend.rest.XSDController.validateXSD(XSDController.java:70) info.utilitiesonline.backend.rest.XSDController.validateXML(XSDController.java:106) sun.reflect.GeneratedMethodAccessor58.invoke(Unknown Source) sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) java.lang.reflect.Method.invoke(Method.java:498) com.sun.jersey.spi.container.JavaMethodInvokerFactory$1.invoke(JavaMethodInvokerFactory.java:60) com.sun.jersey.server.impl.model.method.dispatch.AbstractResourceMethodDispatchProvider$ResponseOutInvoker._dispatch(AbstractResourceMethodDispatchProvider.java:205) com.sun.jersey.server.impl.model.method.dispatch.ResourceJavaMethodDispatcher.dispatch(ResourceJavaMethodDispatcher.java:75) com.sun.jersey.server.impl.uri.rules.HttpMethodRule.accept(HttpMethodRule.java:302) com.sun.jersey.server.impl.uri.rules.RightHandPathRule.accept(RightHandPathRule.java:147) com.sun.jersey.server.impl.uri.rules.ResourceClassRule.accept(ResourceClassRule.java:108) com.sun.jersey.server.impl.uri.rules.RightHandPathRule.accept(RightHandPathRule.java:147) com.sun.jersey.server.impl.uri.rules.RootResourceClassesRule.accept(RootResourceClassesRule.java:84) com.sun.jersey.server.impl.application.WebApplicationImpl._handleRequest(WebApplicationImpl.java:1542) com.sun.jersey.server.impl.application.WebApplicationImpl._handleRequest(WebApplicationImpl.java:1473) com.sun.jersey.server.impl.application.WebApplicationImpl.handleRequest(WebApplicationImpl.java:1419) com.sun.jersey.server.impl.application.WebApplicationImpl.handleRequest(WebApplicationImpl.java:1409) com.sun.jersey.spi.container.servlet.WebComponent.service(WebComponent.java:409) com.sun.jersey.spi.container.servlet.ServletContainer.service(ServletContainer.java:540) com.sun.jersey.spi.container.servlet.ServletContainer.doFilter(ServletContainer.java:909) com.sun.jersey.spi.container.servlet.ServletContainer.doFilter(ServletContainer.java:857) com.sun.jersey.spi.container.servlet.ServletContainer.doFilter(ServletContainer.java:811) com.google.inject.servlet.FilterDefinition.doFilter(FilterDefinition.java:163) com.google.inject.servlet.FilterChainInvocation.doFilter(FilterChainInvocation.java:58) com.google.inject.servlet.ManagedFilterPipeline.dispatch(ManagedFilterPipeline.java:118) com.google.inject.servlet.GuiceFilter.doFilter(GuiceFilter.java:113) sun.reflect.GeneratedMethodAccessor51.invoke(Unknown Source) sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) java.lang.reflect.Method.invoke(Method.java:498) org.apache.catalina.security.SecurityUtil$1.run(SecurityUtil.java:277) org.apache.catalina.security.SecurityUtil$1.run(SecurityUtil.java:274) java.security.AccessController.doPrivileged(Native Method) javax.security.auth.Subject.doAsPrivileged(Subject.java:549) org.apache.catalina.security.SecurityUtil.execute(SecurityUtil.java:309) org.apache.catalina.security.SecurityUtil.doAsPrivilege(SecurityUtil.java:249)</pre></p><p><b>note</b> <u>The full stack trace of the root cause is available in the Apache Tomcat/7.0.54 logs.</u></p><HR size="1" noshade="noshade"><h3>Apache Tomcat/7.0.54</h3></body></html> 

Итак, я понятия не имею, что мне делать, чтобы решить проблему … Я с нетерпением жду ваших намеков.

заранее спасибо