Re: [Beepcore-java-users] RFC 822 Header Parsing broken; Patch
Status: Beta
Brought to you by:
huston
From: Huston <hu...@us...> - 2003-11-24 15:29:25
|
Thanks for reporting this! I'll look into it. --Huston ----- Original Message ----- From: "Henner Zeller" <HZ...@gm...> To: <bee...@li...> Sent: Sunday, November 23, 2003 4:06 PM Subject: [Beepcore-java-users] RFC 822 Header Parsing broken; Patch [Note, I resend this message, since the first message I sent was from a sender address different from my subscription address] Hi, In an attempt to implement Beep as a protocol for JAXM and SAAJ using the SOAP Profile specification, I noticed, that the implementation of the RFC822 Header parser has not been complete. The problems arises when sending attachments with SUNs default implementation of JAXM. When sending an Attachment with Soap, the payload actually contains a full mime multipart document, so one mime header of a beep message contains the boundary which happens to be on a new line with the SUN implementation; something like: Content-Type:multipart/related; type="text/xml"; boundary="----=_Part_0_19610963.1069622873839" This is correct according to RFC822 (Paragraph 3.2, field-body production), but is not implemented in the Beep header parser which does not understand multiline headers. So in this case the boundary is lost and SOAP-Attachments won't work :-( I fixed this for the current CVS by implementing a RFC822 parser (an improved version found on w3c) The patch can be found at: http://jwsbuch.net/~hzeller/beep-rfc822-headerpatch.tar.gz It will create a new java file and a patch file: rfc822-header-parse.patch src/org/beepcore/beep/util/Rfc822HeaderParser.java The files can then be patched with patch -p0 < rfc822-header-parse.patch With this patch, sending JAXM Attachments works without problems. ciao, -hen PS: My JAXM-Implementation is just proof of concept and far from ready, but anyone who wants to have a look: http://jwsbuch.net/~hzeller/jaxmbeep-0.0.1.tar.gz The implementation was quite simple. Look in example/SimpleBeepServer.java how easy it will become to implement a JAXM ReqRespListener. It actually is that simple! -- Henner Zeller Freie Software durch Bücherkauf fördern | http://bookzilla.de/ ------------------------------------------------------- This SF.net email is sponsored by: SF.net Giveback Program. Does SourceForge.net help you be more productive? Does it help you create better code? SHARE THE LOVE, and help us help YOU! Click Here: http://sourceforge.net/donate/ _______________________________________________ Beepcore-java-users mailing list Bee...@li... https://lists.sourceforge.net/lists/listinfo/beepcore-java-users |