cxf-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ricky Hazelwood (JIRA)" <j...@apache.org>
Subject [jira] Commented: (CXF-2623) AttachmentDeserializer doesn't work when no boundary message in content type
Date Tue, 19 Jan 2010 21:33:54 GMT

    [ https://issues.apache.org/jira/browse/CXF-2623?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12802481#action_12802481
] 

Ricky Hazelwood commented on CXF-2623:
--------------------------------------

That is true, sadly one of our clients uses IBM product to send soap messages into our web
service and it put carriage return before the first boundary.

> AttachmentDeserializer doesn't work when no boundary message in content type
> ----------------------------------------------------------------------------
>
>                 Key: CXF-2623
>                 URL: https://issues.apache.org/jira/browse/CXF-2623
>             Project: CXF
>          Issue Type: Bug
>          Components: Core
>    Affects Versions: 2.2.1, 2.2.2, 2.2.3, 2.2.4, 2.2.5
>            Reporter: Ricky Hazelwood
>            Assignee: Daniel Kulp
>            Priority: Blocker
>             Fix For: 2.1.9, 2.2.6
>
>
> Changes done to AttachmentDeserializer.INPUT_STREAM_BOUNDARY_PATTERN (in http://svn.apache.org/viewvc?view=revision&revision=766101)
has caused the message without boundary descriptor in content type to fail. The regex is missing
the MULTILINE flag.
> Here is a quick test :
> {code:java}
>         String message = "Address: /inbox\n" +
>                          "Encoding: ISO-8859-1\n" +
>                          "Content-Type: multipart/related\n" +
>                          "Headers: {content-type=[multipart/related], connection=[Keep-Alive],
Authorization=[Basic dmVyb0FkbWluOmNoYW5nZW1l], " +
>                          "host=[203.0.194.58:443], Content-Length=[16569], SOAPAction=[http://www.ACORD.org/Standards/AcordMsgSvc/Inbox#PostRq],
" +
>                          "keep-alive=[timeout=5, max=10000], Content-Type=[multipart/related]}\n"
+
>                          "Payload:\n" +
>                          "------=_Part_34950_1098328613.1263781527359\n" +
>                          "Content-Type: text/xml; charset=UTF-8\n" +
>                          "Content-Transfer-Encoding: binary\n" +
>                          "Content-Id: <318731183421.1263781527359.IBM.WEBSERVICES@auhpap02>\n"
+
>                          "\n" +
>                          "<envelope/>\n" +
>                          "------=_Part_34950_1098328613.1263781527359\n" +
>                          "Content-Type: text/xml\n" +
>                          "Content-Transfer-Encoding: binary\n" +
>                          "Content-Id: <b86a5f2d-e7af-4e5e-b71a-9f6f2307cab0>\n"
+
>                          "Content-Length: 13129\n" +
>                          "\n" +
>                          "<message>\n" +
>                          "------=_Part_34950_1098328613.1263781527359--";
>         Matcher m = Pattern.compile("^--(\\S*)").matcher(message);
>         Assert.assertFalse(m.find());
>         m = Pattern.compile("^--(\\S*)", Pattern.MULTILINE).matcher(message);
>         Assert.assertTrue(m.find());
> {code}

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message