When I send a request to WS-Trust endpoint, my request includes WS-Trust namespace http://docs.oasis-open.org/ws-sx/ws-trust/200512
, but the WS-Trust Endpoint throws an error as
<soap:Fault>
<soap:Code>
<soap:Value>soap:Sender</soap:Value>
</soap:Code>
<soap:Reason>
<soap:Text xml:lang="en">Unexpected element {http://docs.oasis-open.org/ws-sx/ws-trust/200512}RequestSecurityToken found. Expected {http://docs.oasis-open.org/ws-sx/ws-trust/200512/}RequestSecurityToken.</soap:Text>
</soap:Reason>
</soap:Fault>
It works fine if I use the namespace http://docs.oasis-open.org/ws-sx/ws-trust/200512/
, but how do I change on my WS-Trust endpoint so it accepts the request with http://docs.oasis-open.org/ws-sx/ws-trust/200512
. I have checked my wsdl
and it has namespace as http://docs.oasis-open.org/ws-sx/ws-trust/200512
.
I fixed this issue by changing the targetNamespace
in my generated java resources from WSDL.