Boundary calculation and other byte/String processing should honor the char encoding of the message ---------------------------------------------------------------------------------------------------
Key: WSCOMMONS-169 URL: https://issues.apache.org/jira/browse/WSCOMMONS-169 Project: WS-Commons Issue Type: Bug Components: AXIOM Reporter: Rich Scheuerle Priority: Minor The boundary byte calulation should honor the character encoding of the message. Here are two examples: In MIMEOutputUtils: public static void writeMimeBoundary(OutputStream outStream, String boundary) throws IOException { outStream.write(new byte[]{45, 45}); outStream.write(boundary.getBytes("UTF-8")); <---- Should use character encoding of the message } In Attachments: // Boundary always have the prefix "--". this.boundary = ("--" + contentType.getParameter("boundary")) .getBytes("UTF-8"); <---- Should use character encoding of the message Changing the calculations to use the encoding of the message may cause breakage in the lower level ByteDelimittedInputStream code and related classes due to (A) hard-coded character usage and (B) assumptions that characters are represented as single bytes. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]