Forum Discussion

philcms1's avatar
philcms1
Occasional Contributor
11 years ago

How to keep return carriages in a global variable?

Hi,

I am parsing a SOAP response to extract a SAML assertion with the following configuration of a property transfer, which is then assigned to a global variable:

declare namespace ns2='http://docs.oasis-open.org/ws-sx/ws-trust/200512';

declare namespace saml2='urn:oasis:names:tc:SAML:2.0:assertion';

//ns2:RequestSecurityTokenResponse/ns2:RequestedSecurityToken/saml2:Assertion


It is working fine, except that the assertion contains return carriages in the X509 certificate, which are then replaced by a single space in the global variable. Is there a way to keep those special characters (pretty-printing is already disabled) so the hash doesn't fail?

Response:


Global variable:
<ds:X509Certificate>MIIDEzCCAtGgAwIBAgIET/WquDALBgcqhkjOOAQDBQAwbTELMAkGA1UEBhMCVVMxCzAJBgNVBAgT Ak9IMQ4wDAYDVQQHEwVNYXNvbjEQMA4GA1UEChMHTWVkUGx1czESMBAGA1UECxMJQ2hhcnRNYXh4 MRswGQYDVQQDExJDaGFydE1heHggQ0VTUCBTVFMwHhcNMTIwN


Thanks!
No RepliesBe the first to reply