Skip to main content

developerWorks >  WebSphere  >  Forums  >  WebSphere Portal  >  developerWorks

Valid SOAP message header?    Point your RSS reader here for a feed of the latest messages in this thread


Tags for this thread: 

     

 
 

My developerWorks
 Welcome, Guest
Sign in or register
This question is not answered.

Permlink Replies: 1 - Pages: 1 - Last Post: Nov 6, 2009 8:44 AM Last Post By: Dave.C
Dave.C

Posts: 20
Registered: Dec 07, 2007 01:29:30 PM
Valid SOAP message header?
Posted: Nov 05, 2009 01:19:53 PM
 
Click to report abuse...   Click to reply to this thread Reply
Hi there,

We provide some web services from WebSphere Portal 6.1.0.23 on RHEL 5.2 and one of the users has raised an issue to do with CR+LF characters in the SOAP headers. When there are attachments with long file names the resulting message seems to sometimes have the CR+LF characters within the file name. Here's an example:

Content-Type: application/octet-stream
Content-Transfer-Encoding: 8bit
Content-ID: 3610543@aaaaaaaaaa.aaa
Content-Disposition: attachment;
filename="This is a very long filename_this is still a very long
file.pdf"
Content-Length: 445688

Shorter filenames looks like:

Content-Type: application/octet-stream
Content-Transfer-Encoding: 8bit
Content-ID: 3610544@aaaaaaaaaa.aaa
Content-Disposition: attachment; filename="shortFileName.pdf"
Content-Length: 301175

As you can see, the version with a long file name has "x0d x0a x09" after "attachment; ", and has "x0d x0a" within the filename. Our own Test Web Service client seems to handle these characters without a problem, however one of our users' clients seems to have a issue with them. I've used WireShark to confirm that the characters really do exist in the message and are not an artifact created by the local webservice client.

I've been trying to find out if this is actually valid as a SOAP message or not, as if it is valid then the user needs to fix their client. If not we need to fix our webservice. I suspect they are using the line feed as a delimiter when retrieving the filename from the message.

Does anyone know if the above message fragment is valid with CR+LF in the filename line? I can't seem to find any resources that address the issue, so if anyone can help or point me in the right direction it would be much appreciated.

Thanks in advance,
Dave.C

Dave.C

Posts: 20
Registered: Dec 07, 2007 01:29:30 PM
Re: Valid SOAP message header?
Posted: Nov 06, 2009 08:44:21 AM   in response to: Dave.C in response to: Dave.C's post
 
Click to report abuse...   Click to reply to this thread Reply
I have done some more reading and I think the message is valid. RFC 2045 covers the MIME standards, and on page 3 it references RFC822 for the format of the header fields. RFC822 is superseded by RFC2822, and section 2.2.3 of 2822 states:
The general rule is that wherever this standard allows for folding white space 
(not simply WSP characters), a CRLF may be inserted before any WSP.  
For example, the header field:
 
        Subject: This is a test
 
can be represented as:
 
        Subject: This
         is a test


As such I think our application is generating standards compliant messages.
 Tags
Help

Use the search field to find all types of content in My developerWorks with that tag.

Use the slider bar to see more or fewer tags.

Popular tags shows the top tags for this particular type of content or application that you're viewing.

My tags shows your tags for this particular type of content or application that you're viewing.

 

MoreLess 


Point your RSS reader here for a feed of the latest messages in all forums