-
1. Re: Newlines/spaces in SOAPMessage
alfred.rsa Jul 2, 2009 4:30 AM (in response to alfred.rsa)Using WireShark to intercept the transmission, I found that the JBoss SOAPElement.setvalue implementation seems
to add a carriage return linefeed combination to my text which causes the Web Service to crash:0000 37 32 0d 0a 3c 65 6e 76 3a 45 6e 76 65 6c 6f 70 72..<env:Envelop 0010 65 20 78 6d 6c 6e 73 3a 65 6e 76 3d 27 68 74 74 e xmlns:env='htt 0020 70 3a 2f 2f 73 63 68 65 6d 61 73 2e 78 6d 6c 73 p://schemas.xmls 0030 6f 61 70 2e 6f 72 67 2f 73 6f 61 70 2f 65 6e 76 oap.org/soap/env 0040 65 6c 6f 70 65 2f 27 3e 3c 65 6e 76 3a 42 6f 64 elope/'><env:Bod 0050 79 3e 3c 73 65 61 72 63 68 44 6f 63 44 61 74 61 y><searchDocData 0060 52 65 71 75 65 73 74 3e 3c 66 5f 6e 72 3e 74 65 Request><f_nr>te 0070 73 74 5f 66 6e 6f 0d 0a st_fno..
When I use Sun's SAAJ this doesnot happen
Any ideas?
Regards Alfred -
2. Re: Newlines/spaces in SOAPMessage
asoldano Jul 15, 2009 11:16 AM (in response to alfred.rsa)This reminds me of something related to CR/LF when dealing with signatures.
Where do you get the soap elements content from? are you reading them from file? -
3. Re: Newlines/spaces in SOAPMessage
alfred.rsa Jul 16, 2009 1:28 AM (in response to alfred.rsa)Hi Alessio
Thanks for the reply. No I create the SOAP message by getting an instance of the SOAP MessageFactory and then adding elements to the body.
When i use the SoapMessage writeTo method to a file, it contains no CRLF pairs, but when I intercept the message using WireShark, I see the CRLF's.
So it seems as if the SOAPConnection call method or underlying transport is adding the CRLF's
Using the exact same code in GlassFish, the CRLF's are never added and it works fine, but I do not want to use GlassFish
Regards
Alfred