You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cxf.apache.org by "ASF GitHub Bot (JIRA)" <ji...@apache.org> on 2018/04/20 08:42:00 UTC

[jira] [Commented] (CXF-7317) Non-URL encoded Content-Id href does not seem be serilaized by CXF's AttachmentSerializer

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

ASF GitHub Bot commented on CXF-7317:
-------------------------------------

rnetuka opened a new pull request #408: [CXF-7317] Non-URL encoded Content-Id href does not seem be serialized by CXF's AttachmentSerializer
URL: https://github.com/apache/cxf/pull/408
 
 
   JIRA: https://issues.apache.org/jira/browse/CXF-7317
   downstream: https://issues.jboss.org/browse/JBWS-4064
   
   According to https://tools.ietf.org/html/rfc2392, Content-ID header shouldn't be decoded
   
   For example, "cid:foo4%25foo1@bar.net" corresponds to Content-ID: foo4%25foo1@bar.net
   See comments in JBWS-4064 for more info

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


> Non-URL encoded Content-Id href does not seem be serilaized by CXF's AttachmentSerializer
> -----------------------------------------------------------------------------------------
>
>                 Key: CXF-7317
>                 URL: https://issues.apache.org/jira/browse/CXF-7317
>             Project: CXF
>          Issue Type: Bug
>          Components: Core
>    Affects Versions: 3.1.10
>            Reporter: Viral Gohel
>            Priority: Major
>         Attachments: mtomExample.war
>
>
> CXF-6484 states that, 
> >> URL-encoded content ID for MTOM attachments causes problems with web service clients.  This is effectively a regression on:
>   https://issues.apache.org/jira/browse/CXF-2669
> For example, If the namespace is "https://cxf.apache.org/" for the service endpoint, then the content id is now:
>  5726d366-df25-4945-9f3b-3003a2ae8a70-3@http%3A%2F%2Fcxf.apache.org%2F
> It was previously:
>  5726d366-df25-4945-9f3b-3003a2ae8a70-3@cxf.apache.org
> Hence, 
> Actual results:
> Content Id contains the full namespace (as URL) which is URL encoded: 5726d366-df25-4945-9f3b-3003a2ae8a70-3@http%3A%2F%2Fcxf.apache.org%2F
> Expected results:
> Content id does not require encoding and only contains hostname:  5726d366-df25-4945-9f3b-3003a2ae8a70-3@cxf.apache.org
> With the attached reproducer, here's what the results looks like, 
> Actual Result - href="cid:0842d204-23ec-4b6f-955b-0e38a4c2f35a-1@urn%3Awsc.td.com%2Fcis%2F2010%2F01%2F19
> Expected Result -
> href="cid:0842d204-23ec-4b6f-955b-0e38a4c2f35a-1@urn:Awsc.td.com/cis/2010/01/19
> The difference here compared to the fix for CXF-6484, is that a non-url encoded href using namespace with 'urn:' for the attachments is used. 
> For example, like the below in the @WebService class, 
> @WebService(targetNamespace = "urn:wsc.td.com/cis/2010/01/19")
> To me, it seems that the fix for CXF-6484 does not work for non-url encoded href. 
> I.e After the fix of CXF-6484, 
> Actual Result - href="cid:0842d204-23ec-4b6f-955b-0e38a4c2f35a-1@urn%3Awsc.td.com%2Fcis%2F2010%2F01%2F19
> Expected Result -
> href="cid:0842d204-23ec-4b6f-955b-0e38a4c2f35a-1@urn:Awsc.td.com/cis/2010/01/19
> It looks like CXF's AttachmentSerializer is not able to serialize the forward slashes(/) or the AttachmentUtil needs to be changed. 
> I am not sure if the proper urn: namespaces should be of format, i.e urn:com.namespace.someResource or it can be also like, urn:com/namespace/someResource.  
> Can we make CXF to interpret and display the href in the Content-Id with non-url namespace as cid:0842d204-23ec-4b6f-955b-0e38a4c2f35a-1@urn:Awsc.td.com/cis/2010/01/19 ?
> instead of 
> href="cid:0842d204-23ec-4b6f-955b-0e38a4c2f35a-1@urn%3Awsc.td.com%2Fcis%2F2010%2F01%2F19



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)