xxxyyyz commented on code in PR #17967: URL: https://github.com/apache/camel/pull/17967#discussion_r2073142673
########## components/camel-as2/camel-as2-api/src/main/java/org/apache/camel/component/as2/api/entity/TextPlainEntity.java: ########## @@ -54,7 +54,7 @@ public void writeTo(OutputStream outstream) throws IOException { } // Write out content - canonicalOutstream.write(content.getBytes(StandardCharsets.US_ASCII), 0, content.length()); + outstream.write(content.getBytes(StandardCharsets.US_ASCII), 0, content.length()); Review Comment: From my understanding, the request body should never be filtered. It leads to the unwanted behavior that LF characters in request body get substituted by CRLF. Using the original outstream in write() prevents filtering, thus leaving the request body unchanged. I found it the least intrusive way to introduce a patch. Furthermore, I suggest to extend other tests like, e.g. EntityParserTest to use LF in request body. This test will consequently also fail with the current implementation. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: commits-unsubscr...@camel.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org