Email Address Internationalization                           K. Fujiwara
(EAI)                                                               JPRS
Internet-Draft                                         February 15, 2008
Intended status: Experimental
Expires: August 18, 2008


 Displaying Downgraded Messages for Email Address Internationalization
              draft-fujiwara-eai-downgraded-display-00.txt

Status of this Memo

   By submitting this Internet-Draft, each author represents that any
   applicable patent or other IPR claims of which he or she is aware
   have been or will be disclosed, and any of which he or she becomes
   aware will be disclosed, in accordance with Section 6 of BCP 79.

   Internet-Drafts are working documents of the Internet Engineering
   Task Force (IETF), its areas, and its working groups.  Note that
   other groups may also distribute working documents as Internet-
   Drafts.

   Internet-Drafts are draft documents valid for a maximum of six months
   and may be updated, replaced, or obsoleted by other documents at any
   time.  It is inappropriate to use Internet-Drafts as reference
   material or to cite them other than as "work in progress."

   The list of current Internet-Drafts can be accessed at
   http://www.ietf.org/ietf/1id-abstracts.txt.

   The list of Internet-Draft Shadow Directories can be accessed at
   http://www.ietf.org/shadow.html.

   This Internet-Draft will expire on August 18, 2008.

Copyright Notice

   Copyright (C) The IETF Trust (2008).

Abstract

   This document describes how to display downgraded messages which
   originally contain internationalized E-mail addresses or
   internationalized header fields.







Fujiwara                 Expires August 18, 2008                [Page 1]


Internet-Draft       Displaying Downgraded Messages        February 2008


Table of Contents

   1.  Introduction . . . . . . . . . . . . . . . . . . . . . . . . .  3
   2.  Terminology  . . . . . . . . . . . . . . . . . . . . . . . . .  3
   3.  Displaying downgraded message  . . . . . . . . . . . . . . . .  4
     3.1.  Displaying technique 1 . . . . . . . . . . . . . . . . . .  4
     3.2.  Displaying technique 2 . . . . . . . . . . . . . . . . . .  4
   4.  Security considerations  . . . . . . . . . . . . . . . . . . .  5
   5.  IANA Considerations  . . . . . . . . . . . . . . . . . . . . .  6
   6.  Acknowledgements . . . . . . . . . . . . . . . . . . . . . . .  6
   7.  Change History . . . . . . . . . . . . . . . . . . . . . . . .  6
     7.1.  draft-fujiwara-eai-downgraded-display: Version 00  . . . .  6
   8.  Normative References . . . . . . . . . . . . . . . . . . . . .  6
   Appendix A.  Examples  . . . . . . . . . . . . . . . . . . . . . .  7
     A.1.  Displaying technique 1 example . . . . . . . . . . . . . . 10
     A.2.  Displaying technique 2 example . . . . . . . . . . . . . . 10
   Author's Address . . . . . . . . . . . . . . . . . . . . . . . . . 13
   Intellectual Property and Copyright Statements . . . . . . . . . . 14

































Fujiwara                 Expires August 18, 2008                [Page 2]


Internet-Draft       Displaying Downgraded Messages        February 2008


1.  Introduction

   The Email Address Internationalization (UTF8SMTP) extension document
   set [RFC4952] [I-D.ietf-eai-smtpext] [I-D.ietf-eai-utf8headers]
   [I-D.ietf-eai-dsn] expands Email address structure, syntax and Email
   header format.  To avoid bouncing internationalized Email messages,
   the downgrading mechanism [I-D.ietf-eai-downgrade] converts an
   internationalized message to a traditional Email message when a
   server in the delivery path does not support the UTF8SMTP extension.
   The downgraded message is a traditional Email message, except the
   message has "Downgraded-" header fields.

   A perfect reverse-function of the downgrading does not exist because
   the encoding defined in [RFC2047] is not exactly reversible and
   Received header field downgrading may remove FOR clause information.
   The restoration of the downgrading should be done once at the final
   destination of the downgraded message such as MUAs or IMAP servers.
   This document describes the restoration methods as displaying
   techniques in MUAs.

   This is an informational document and it does not supersede the
   referenced documents.


2.  Terminology

   The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
   "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this
   document are to be interpreted as described in RFC 2119 [RFC2119].

   Specialized terms used in this specification are defined in the EAI
   overview [RFC4952] or in [RFC2821][RFC2822], MIME documents [RFC2045]
   [RFC2047] [RFC2183] [RFC2231].

   This document depends on [I-D.ietf-eai-utf8headers] and
   [I-D.ietf-eai-downgrade].  Key words used in these document are used
   in this document, too.

   The term "non-ASCII" is an UTF-8 string which contains at least one
   non-ASCII character.

   The term "address header field" is used for a header field which
   contains <mailbox> elements which is defined in [RFC2822].  "Address
   header fields" contain "From", "Sender", "Reply-To", "To", "Cc",
   "Bcc", "Resent-From", "Resent-Sender", "Resent-To", "Resent-Cc",
   "Return-Path" header fields.

   An "UTF8SMTP message" is an Email messages expanded by



Fujiwara                 Expires August 18, 2008                [Page 3]


Internet-Draft       Displaying Downgraded Messages        February 2008


   [I-D.ietf-eai-utf8headers].


3.  Displaying downgraded message

   Displaying downgraded message is mostly performed by MIME decoding
   according to [RFC2047] and [RFC2231].  Result of MIME decoding, the
   header of the message still contains Downgraded-*: header fields, but
   the header field bodies are MIME decoded.  These decoded
   "Downgraded-" header fields contain the original header field name
   and the original header field values.  The recipient can read them.
   But the recipient's MUA cannot use the original header fields
   automatically.

   Additionally, MUAs can process "Downgraded-" header fields.  It is
   described in Section 3.1 and Section 3.2.

3.1.  Displaying technique 1

   MUAs may remove "Downgraded-" from decoded "Downgraded-" header
   fields' name.

   First, decode MIME encoded header fields and MIME body part header
   fields according to [RFC2047] and [RFC2231].

   Then, for each "Downgraded-" header field, generate new header field
   which field name is the original header field name and the field
   value is the decoded header field value, and replace the
   "Downgraded-" header field by the generated header field.

   Don't change "Downgraded-Mail-From" and "Downgraded-Rcpt-To" header
   fields because they do not have their original header fields.

   With this technique, the "address header fields" may be displayed
   twice, one is from downgraded header field and the other is from
   decoded "Downgraded-" header.

3.2.  Displaying technique 2

   MUAs may decode and re-generate the original header of the message.
   This technique may reconstruct the original message from the
   downgraded message.  But it is not guaranteed.

   This technique is implemented by the following steps.







Fujiwara                 Expires August 18, 2008                [Page 4]


Internet-Draft       Displaying Downgraded Messages        February 2008


   Step 1:   Select "Downgraded-" header fields whose original header
      field is an "address header field".  Target header fields are
      "Downgraded-From", "Downgraded-Sender", "Downgraded-Reply-To",
      "Downgraded-To", "Downgraded-Cc", "Downgraded-Bcc", "Downgraded-
      Resent-From", "Downgraded-Resent-Sender", "Downgraded-Resent-To",
      "Downgraded-Resent-Cc", and "Downgraded-Return-Path" header
      fields.

   Step 2:   Generate new header field which field name is the original
      header field name and the field value is the decoded header field
      value from the output of Step 1.

   Step 3:   Apply Email header fields downgrading defined in section 5
      of [I-D.ietf-eai-downgrade] to the output of Step 2 without re-
      generating "Downgraded-" header fields.

   Step 4:   Compare the output of Step 3 and the original header
      fields.  If the same header fields exist for both the output and
      the original header fields, remove the same header fields from the
      original header fields.  This step outputs the original header
      fields which is modified by this step.  Before this comparison, a
      canonicalization described below is useful.

      1.  Unfold all header field continuation lines as described in
          [RFC2822].
      2.  Insert a space character before and after <mailbox-list>
          separator "," if there is no space character.
      3.  Insert a space character before and after <comment> if there
          is no space character.
      4.  Decode <encoded-word> whose charset is 'UTF-8'.
      5.  Convert all sequences of one or more WSP characters to a
          single space character.  WSP characters here include those
          before and after a line folding boundary.
      6.  Delete all WSP characters at the end of each unfolded header
          field value.
      7.  Delete any WSP characters remaining before and after the colon
          separating the header field name from the header field value.
          The colon separator MUST be retained.

   Step 5:   Finally, do 'Displaying technique 1' described in
      Section 3.1 to the output of Step 4.


4.  Security considerations

   Displaying downgraded message may break the header of the message.
   MUAs should have a function to read the original received message.




Fujiwara                 Expires August 18, 2008                [Page 5]


Internet-Draft       Displaying Downgraded Messages        February 2008


   See "Security considerations" section in [RFC4952] for more
   discussion.


5.  IANA Considerations


6.  Acknowledgements


7.  Change History

   This section is used for tracking the update of this document.  Will
   be removed after finalize.

7.1.  draft-fujiwara-eai-downgraded-display: Version 00

   o  Initial version
   o  It is separated from Appendix A of draft-ietf-eai-downgrade-05.txt


8.  Normative References

   [I-D.ietf-eai-downgrade]
              Yoneya, Y. and K. Fujiwara, "Downgrading mechanism for
              Email Address Internationalization",
              draft-ietf-eai-downgrade-06 (work in progress),
              February 2008.

   [I-D.ietf-eai-dsn]
              Newman, C. and A. Melnikov, "Internationalized Delivery
              Status and Disposition Notifications",
              draft-ietf-eai-dsn-06 (work in progress), January 2008.

   [I-D.ietf-eai-smtpext]
              Yao, J. and W. MAO, "SMTP extension for internationalized
              email address", draft-ietf-eai-smtpext-11 (work in
              progress), January 2008.

   [I-D.ietf-eai-utf8headers]
              Yeh, J., "Internationalized Email Headers",
              draft-ietf-eai-utf8headers-09 (work in progress),
              February 2008.

   [RFC2045]  Freed, N. and N. Borenstein, "Multipurpose Internet Mail
              Extensions (MIME) Part One: Format of Internet Message
              Bodies", RFC 2045, November 1996.




Fujiwara                 Expires August 18, 2008                [Page 6]


Internet-Draft       Displaying Downgraded Messages        February 2008


   [RFC2047]  Moore, K., "MIME (Multipurpose Internet Mail Extensions)
              Part Three: Message Header Extensions for Non-ASCII Text",
              RFC 2047, November 1996.

   [RFC2119]  Bradner, S., "Key words for use in RFCs to Indicate
              Requirement Levels", BCP 14, RFC 2119, March 1997.

   [RFC2183]  Troost, R., Dorner, S., and K. Moore, "Communicating
              Presentation Information in Internet Messages: The
              Content-Disposition Header Field", RFC 2183, August 1997.

   [RFC2231]  Freed, N. and K. Moore, "MIME Parameter Value and Encoded
              Word Extensions:
              Character Sets, Languages, and Continuations", RFC 2231,
              November 1997.

   [RFC2821]  Klensin, J., "Simple Mail Transfer Protocol", RFC 2821,
              April 2001.

   [RFC2822]  Resnick, P., "Internet Message Format", RFC 2822,
              April 2001.

   [RFC4952]  Klensin, J. and Y. Ko, "Overview and Framework for
              Internationalized Email", RFC 4952, July 2007.


Appendix A.  Examples

   This section shows a example of displaying downgraded message.
   First, an example of the original UTF8SMTP message and its downgraded
   message are shown.  They are the same as "Example 1" of
   [I-D.ietf-eai-downgrade].  The example UTF8SMTP message is shown in
   Figure 1.


















Fujiwara                 Expires August 18, 2008                [Page 7]


Internet-Draft       Displaying Downgraded Messages        February 2008


   Message-Id: MESSAGE_ID
   Mime-Version: 1.0
   Content-Type: text/plain; charset="UTF-8"
   Content-Transfer-Encoding: 8bit
   Subject: NON-ASCII-SUBJECT
   From: DISPLAY-local <NON-ASCII-local@example.com
    <ASCII-local@example.com>>
   To: DISPLAY-remote1 <NON-ASCII-remote1@example.net
    <ASCII-remote1@example.net>>
   Cc: DISPLAY-remote2 <NON-ASCII-remote2@example.org>
   Date: DATE

   MAIL_BODY


                        Figure 1: Original message

   Delivered downgraded message is shown in Figure 2.  Return-Path
   header will be added by the final destination MTA.


Return-Path: <ASCII-local@example.com>
Downgraded-Mail-From: =?UTF-8?Q?<NON-ASCII-local@example.com>_?=
 =?UTF-8?Q?<ASCII-local@example.com>?=
Downgraded-Rcpt-To: =?UTF-8?Q?<NON-ASCII-remote1@example.net>_?=
 =?UTF-8?Q?<ASCII-remote1@example.net>?=
Message-Id: MESSAGE_ID
Mime-Version: 1.0
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: 8bit
Subject: =?UTF-8?Q?NON-ASCII-SUBJECT?=
From: =?UTF-8?Q?DISPLAY-local?= <ASCII-local@example.com>
Downgraded-From: =?UTF-8?Q?DISPLAY-local_<NON-ASCII-local@example.com_?=
 =?UTF-8?Q?<ASCII-local@example.com>>?=
To: =?UTF-8?Q?DISPLAY-remote1?= <ASCII-remote1@example.net>
Downgraded-To: =?UTF-8?Q?DISPLAY-remote1_?=
 =?UTF-8?Q?<NON-ASCII-remote1@example.net_<ASCII-remote1@example.net>>?=
Cc: =?UTF-8?Q?DISPLAY-remote2?= Internationalized address
 =?UTF-8?Q?NON-ASCII-remote2@example.org?= removed:;
Downgraded-Cc: =?UTF-8?Q?DISPLAY-remote2_?=
 =?UTF-8?Q?<NON-ASCII-remote2@example.org>?=
Date: DATE

MAIL_BODY


                       Figure 2: Downgraded message




Fujiwara                 Expires August 18, 2008                [Page 8]


Internet-Draft       Displaying Downgraded Messages        February 2008


   Figure 3 shows MIME decoded message of Figure 2.  The recipient can
   read the original From, To, Cc header fields as Downgraded-From,
   Downgraded-To, Downgraded-Cc header fields.


   Return-Path: <ASCII-local@example.com>
   Downgraded-Mail-From: <NON-ASCII-local@example.com>
    <ASCII-local@example.com>
   Downgraded-Rcpt-To: <NON-ASCII-remote1@example.net>
    <ASCII-remote1@example.net>
   Message-Id: MESSAGE_ID
   Mime-Version: 1.0
   Content-Type: text/plain; charset="UTF-8"
   Content-Transfer-Encoding: 8bit
   Subject: NON-ASCII-SUBJECT
   From: DISPLAY-local <ASCII-local@example.com>
   Downgraded-From: DISPLAY-local <NON-ASCII-local@example.com
    <ASCII-local@example.com>>
   To: DISPLAY-remote1 <ASCII-remote1@example.net>
   Downgraded-To: DISPLAY-remote1 <NON-ASCII-remote1@example.net
    <ASCII-remote1@example.net>>
   Cc: DISPLAY-remote2 Internationalized address
    NON-ASCII-remote2@example.org removed:;
   Downgraded-Cc: DISPLAY-remote2 <NON-ASCII-remote2@example.org>
   Date: DATE

   MAIL_BODY


                      Figure 3: MIME decoded message





















Fujiwara                 Expires August 18, 2008                [Page 9]


Internet-Draft       Displaying Downgraded Messages        February 2008


A.1.  Displaying technique 1 example

   After removing "Downgraded-" from decoded "Downgraded-" header fields
   from Figure 3, 'Displaying technique 1' example is shown in Figure 4.



   Return-Path: <ASCII-local@example.com>
   Mail-From: <NON-ASCII-local@example.com>
    <ASCII-local@example.com>
   Rcpt-To: <NON-ASCII-remote1@example.net>
    <ASCII-remote1@example.net>
   Message-Id: MESSAGE_ID
   Mime-Version: 1.0
   Content-Type: text/plain; charset="UTF-8"
   Content-Transfer-Encoding: 8bit
   Subject: NON-ASCII-SUBJECT
   From: DISPLAY-local <ASCII-local@example.com>
   From: DISPLAY-local <NON-ASCII-local@example.com
    <ASCII-local@example.com>>
   To: DISPLAY-remote1 <ASCII-remote1@example.net>
   To: DISPLAY-remote1 <NON-ASCII-remote1@example.net
    <ASCII-remote1@example.net>>
   Cc: DISPLAY-remote2 Internationalized address
    NON-ASCII-remote2@example.org removed:;
   Cc: DISPLAY-remote2 <NON-ASCII-remote2@example.org>
   Date: DATE

   MAIL_BODY


                     Figure 4: Displaying technique 1

A.2.  Displaying technique 2 example

   This example shows displaying process of 'Displaying technique 2' for
   Figure 2.

   First, perform Step 1.



Downgraded-From: =?UTF-8?Q?DISPLAY-local_<NON-ASCII-local@example.com_?=
 =?UTF-8?Q?<ASCII-local@example.com>>?=
Downgraded-To: =?UTF-8?Q?DISPLAY-remote1_?=
 =?UTF-8?Q?<NON-ASCII-remote1@example.net_<ASCII-remote1@example.net>>?=
Downgraded-Cc: =?UTF-8?Q?DISPLAY-remote2_?=
 =?UTF-8?Q?<NON-ASCII-remote2@example.org>?=



Fujiwara                 Expires August 18, 2008               [Page 10]


Internet-Draft       Displaying Downgraded Messages        February 2008


            Figure 5: Displaying technique 2: Output of Step 1

   Then, perform Step 2.



   From: DISPLAY-local <NON-ASCII-local@example.com
    <ASCII-local@example.com>>
   To: DISPLAY-remote1 <NON-ASCII-remote1@example.net
    <ASCII-remote1@example.net>>
   Cc: DISPLAY-remote2 <NON-ASCII-remote2@example.org>


            Figure 6: Displaying technique 2: Output of Step 2

   Perform Step 3.



   From: =?UTF-8?Q?DISPLAY-local?= <ASCII-local@example.com>
   To: =?UTF-8?Q?DISPLAY-remote1?= <ASCII-remote1@example.net>
   Cc: =?UTF-8?Q?DISPLAY-remote2?= Internationalized address
    =?UTF-8?Q?NON-ASCII-remote2@example.org?= removed:;


            Figure 7: Displaying technique 2: Output of Step 3

   Perform Step 4.  "From", "To", "Cc" header fields are removed in
   Figure 8.






















Fujiwara                 Expires August 18, 2008               [Page 11]


Internet-Draft       Displaying Downgraded Messages        February 2008


Return-Path: <ASCII-local@example.com>
Downgraded-Mail-From: =?UTF-8?Q?<NON-ASCII-local@example.com>?=
 =?UTF-8?Q?<ASCII-local@example.com>?=
Downgraded-Rcpt-To: =?UTF-8?Q?<NON-ASCII-remote1@example.net>_?=
 =?UTF-8?Q?<ASCII-remote1@example.net>?=
Message-Id: MESSAGE_ID
Mime-Version: 1.0
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: 8bit
Subject: =?UTF-8?Q?NON-ASCII-SUBJECT?=
Downgraded-From: =?UTF-8?Q?DISPLAY-local_<NON-ASCII-local@example.com_?=
 =?UTF-8?Q?<ASCII-local@example.com>>?=
Downgraded-To: =?UTF-8?Q?DISPLAY-remote1?_?=
 =?UTF-8?Q?<NON-ASCII-remote1@example.net_<ASCII-remote1@example.net>>?=
Downgraded-Cc: =?UTF-8?Q?DISPLAY-remote2_?=
 =?UTF-8?Q?<NON-ASCII-remote2@example.org>?=
Date: DATE

MAIL_BODY


            Figure 8: Displaying technique 2: Output of Step 4

   Perform Step 5.  (Apply 'Displaying technique 1'.)



   Return-Path: <ASCII-local@example.com>
   Downgraded-Mail-From: <NON-ASCII-local@example.com>
    <ASCII-local@example.com>
   Downgraded-Rcpt-To: <NON-ASCII-remote1@example.net>
    <ASCII-remote1@example.net>
   Message-Id: MESSAGE_ID
   Mime-Version: 1.0
   Content-Type: text/plain; charset="UTF-8"
   Content-Transfer-Encoding: 8bit
   Subject: NON-ASCII-SUBJECT
   From: DISPLAY-local <NON-ASCII-local@example.com
    <ASCII-local@example.com>>
   To: DISPLAY-remote1 <NON-ASCII-remote1@example.net
    <ASCII-remote1@example.net>>
   Cc: DISPLAY-remote2 <NON-ASCII-remote2@example.org>
   Date: DATE

   MAIL_BODY


              Figure 9: Display technique 2: Decoded message



Fujiwara                 Expires August 18, 2008               [Page 12]


Internet-Draft       Displaying Downgraded Messages        February 2008


   As a result, in this simple example, all original header fields are
   displayed in the original form.  Differences between Figure 1 and
   Figure 9 are Return-Path, Downgraded-Mail-From, Downgraded-Rcpt-To
   header fields only.


Author's Address

   Kazunori Fujiwara
   JPRS
   Chiyoda First Bldg. East 13F, 3-8-1 Nishi-Kanda
   Chiyoda-ku, Tokyo  101-0065
   Japan

   Phone: +81 3 5215 8451
   Email: fujiwara@jprs.co.jp



































Fujiwara                 Expires August 18, 2008               [Page 13]


Internet-Draft       Displaying Downgraded Messages        February 2008


Full Copyright Statement

   Copyright (C) The IETF Trust (2008).

   This document is subject to the rights, licenses and restrictions
   contained in BCP 78, and except as set forth therein, the authors
   retain all their rights.

   This document and the information contained herein are provided on an
   "AS IS" basis and THE CONTRIBUTOR, THE ORGANIZATION HE/SHE REPRESENTS
   OR IS SPONSORED BY (IF ANY), THE INTERNET SOCIETY, THE IETF TRUST AND
   THE INTERNET ENGINEERING TASK FORCE DISCLAIM ALL WARRANTIES, EXPRESS
   OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTY THAT THE USE OF
   THE INFORMATION HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED
   WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.


Intellectual Property

   The IETF takes no position regarding the validity or scope of any
   Intellectual Property Rights or other rights that might be claimed to
   pertain to the implementation or use of the technology described in
   this document or the extent to which any license under such rights
   might or might not be available; nor does it represent that it has
   made any independent effort to identify any such rights.  Information
   on the procedures with respect to rights in RFC documents can be
   found in BCP 78 and BCP 79.

   Copies of IPR disclosures made to the IETF Secretariat and any
   assurances of licenses to be made available, or the result of an
   attempt made to obtain a general license or permission for the use of
   such proprietary rights by implementers or users of this
   specification can be obtained from the IETF on-line IPR repository at
   http://www.ietf.org/ipr.

   The IETF invites any interested party to bring to its attention any
   copyrights, patents or patent applications, or other proprietary
   rights that may cover technology that may be required to implement
   this standard.  Please address the information to the IETF at
   ietf-ipr@ietf.org.


Acknowledgment

   Funding for the RFC Editor function is provided by the IETF
   Administrative Support Activity (IASA).





Fujiwara                 Expires August 18, 2008               [Page 14]