Mar 18th, 2013, 08:29 PM
Password in policy.xml contains the "&" character
We are using spring-ws to generate a web service client which is secure and requires an username and password.
The password contains the "&" character. In order to get permit the parsing of the policy.xml, we had to convert the "&" to "&", but when the password in placed into the SOAP ws security tag, it is not translated back.
How could the situation be handled?
Mar 18th, 2013, 11:51 PM
SOAP WS-Security Header element is XML just like policy.xml and there "&" means "&" like in every XML document. When it will be read on the other side it will be read as "&".
Mar 19th, 2013, 08:04 AM
Thanks for the reply, but that does not appear to be true for the password tag within the UserToken element of SOAP WS-Security Header.
Mar 19th, 2013, 08:26 AM
So how does your ws-security header look like?
Mar 19th, 2013, 08:48 AM
I just confirmed that what my code is generating is the same string for the password as was generated by SOAPUI, with the "&" in place for the "&". I will now have to work with the developers of the web service to determine what the problem is.
Thanks for your quick replies.