I have a handler on client side that gets the SOAP message and
attaches the SOAP header element to it. Before I attach the header
element the name of the body element contains: namespace and local
part only, _no prefixes_. :
<RequestElement xmlns="http://example.com">
But after I attach the SOAP header the name of the body element is
changing and contains a prefix "ns1".
<ns1:RequestElement xmlns:ns1="http://example.com">
Is there a way to preserve the original format. I'm signing the SOAP
Body and verification of the signature fails for me now, when I modify
SOAP header ?
Thanks in advance.
---------- Before I attach SOAP Header ----------------
<?xml version="1.0" encoding="UTF-8"?>
<soapenv:Envelope
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<soapenv:Body>
<RequestElement xmlns="http://example.com">
.....
</RequestElement>
</soapenv:Body>
</soapenv:Envelope>
---------- After I attach SOAP Header ----------------
<?xml version="1.0" encoding="UTF-8"?>
<soapenv:Envelope
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<soapenv:Header>
<HeaderElement
soapenv:actor="http://www.mapinfo.com/envinsa/ws/async"
soapenv:mustUnderstand="0" xmlns="http://www.example.com/ws"/>
</soapenv:Header>
<soapenv:Body>
<ns1:RequestElement xmlns:ns1="http://example.com">
</ns1:RequestElement>
</soapenv:Body>
</soapenv:Envelope>