How to get a SOAP error message for WS-I compliance

I have this message

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"> <soapenv:Body> <soapenv:Fault> <faultcode>soapenv:Server</faultcode> <faultstring>LOGIN-ERR:Incorrect password - user could not be logged in.</faultstring> </soapenv:Fault> </soapenv:Body> </soapenv:Envelope> 

The tested schema is excellent, but the SOAP interface tool, when you click Check WS-I Compliance, it gives an unsuccessful status with a BP1305 approval. I can not find what 1305 is and this is a detailed message

 Result failed Failure Detail Message HTTP/1.1 200 OK Transfer-Encoding: chunked Date: Thu, 22 Jul 2010 20:41:43 GMT Set-Cookie: JSESSIONID=C9D19FE6AAD89DFCB6BA9FE196E08D40; Path=/ Content-Type: text/xml;charset=utf-8 Server: Apache-Coyote/1.1 
  Element Location: lineNumber=26 
+4
source share
2 answers

It seems that the problem is that you are returning a SOAP error message, but with an HTTP status code of 200, SOAP Faults must be sent with an HTTP status code of 500.

+3
source

You are missing a part item in a fault message. This is a necessary element if a wsdl error is generated as a result of the contents of the body element in the request

The message should be like this (the part element should contain information specific to the application, but it must be empty. It must not be absent):

  <soapenv:Fault> <faultcode>soapenv:Server</faultcode> <faultstring>LOGIN-ERR:Incorrect password - user could not be logged in.</faultstring> <detail></detail> </soapenv:Fault> 
0
source

Source: https://habr.com/ru/post/1316596/


All Articles