From issues-return-67070-archive-asf-public=cust-asf.ponee.io@commons.apache.org Thu Mar 22 19:43:05 2018 Return-Path: X-Original-To: archive-asf-public@cust-asf.ponee.io Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by mx-eu-01.ponee.io (Postfix) with SMTP id E3A18180676 for ; Thu, 22 Mar 2018 19:43:04 +0100 (CET) Received: (qmail 55543 invoked by uid 500); 22 Mar 2018 18:43:03 -0000 Mailing-List: contact issues-help@commons.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: issues@commons.apache.org Delivered-To: mailing list issues@commons.apache.org Received: (qmail 55532 invoked by uid 99); 22 Mar 2018 18:43:03 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd2-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 22 Mar 2018 18:43:03 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd2-us-west.apache.org (ASF Mail Server at spamd2-us-west.apache.org) with ESMTP id 79BCB1A04AB for ; Thu, 22 Mar 2018 18:43:03 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd2-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -101.511 X-Spam-Level: X-Spam-Status: No, score=-101.511 tagged_above=-999 required=6.31 tests=[KAM_ASCII_DIVIDERS=0.8, RCVD_IN_DNSWL_MED=-2.3, SPF_PASS=-0.001, T_RP_MATCHES_RCVD=-0.01, USER_IN_WHITELIST=-100] autolearn=disabled Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd2-us-west.apache.org [10.40.0.9]) (amavisd-new, port 10024) with ESMTP id wq369iXhVmbl for ; Thu, 22 Mar 2018 18:43:02 +0000 (UTC) Received: from mailrelay1-us-west.apache.org (mailrelay1-us-west.apache.org [209.188.14.139]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with ESMTP id 28CDA5F2F2 for ; Thu, 22 Mar 2018 18:43:02 +0000 (UTC) Received: from jira-lw-us.apache.org (unknown [207.244.88.139]) by mailrelay1-us-west.apache.org (ASF Mail Server at mailrelay1-us-west.apache.org) with ESMTP id E41AFE0D83 for ; Thu, 22 Mar 2018 18:43:00 +0000 (UTC) Received: from jira-lw-us.apache.org (localhost [127.0.0.1]) by jira-lw-us.apache.org (ASF Mail Server at jira-lw-us.apache.org) with ESMTP id 38B9D214DC for ; Thu, 22 Mar 2018 18:43:00 +0000 (UTC) Date: Thu, 22 Mar 2018 18:43:00 +0000 (UTC) From: =?utf-8?Q?V=C3=ADt_Rozkovec_=28JIRA=29?= To: issues@commons.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (EMAIL-171) buildMimeMessage() unconditionally encodes and folds header values MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/EMAIL-171?page=3Dcom.atlassian.= jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=3D16410= 100#comment-16410100 ]=20 V=C3=ADt Rozkovec commented on EMAIL-171: ------------------------------------ Is this related to EMAIL-138? > buildMimeMessage() unconditionally encodes and folds header values > ------------------------------------------------------------------ > > Key: EMAIL-171 > URL: https://issues.apache.org/jira/browse/EMAIL-171 > Project: Commons Email > Issue Type: Bug > Reporter: Sebb > Priority: Major > > The buildMimeMessage() method unconditionally calls MimeUtility#fold and = MimeUtility#encodeText for all entries in the headers Map. > However the encodeText method is only suitable for "unstructured" RFC 822= headers, i.e. those which consist of arbitrary text. > If the headers Map contains any keys that have structured values, and the= value contains any non-ASCII characters, the generated header may be corru= pted. > If the user adds a structured header to the Map, they need to ensure that= the value is already ASCII-encoded using the appropriate strategy for the = field. > This needs to be documented. -- This message was sent by Atlassian JIRA (v7.6.3#76005)