Regular Expressions for Internet Mail
draft-seantek-mail-regexen-02

Document Type Active Internet-Draft (individual in art area)
Last updated 2017-03-13
Stream IETF
Intended RFC status Informational
Formats plain text pdf html bibtex
Stream WG state (None)
Document shepherd No shepherd assigned
IESG IESG state I-D Exists (IESG: Dead)
Consensus Boilerplate Unknown
Telechat date
Responsible AD Alexey Melnikov
Send notices to (None)
Network Working Group                                         S. Leonard
Internet-Draft                                             Penango, Inc.
Intended status: Informational                             J. Hildebrand
Expires: September 14, 2017                                Cisco Systems
                                                               T. Hansen
                                                       AT&T Laboratories
                                                          March 13, 2017

                 Regular Expressions for Internet Mail
                     draft-seantek-mail-regexen-02

Abstract

   Internet Mail identifiers are used ubiquitously throughout computing
   systems as building blocks of online identity.  Unfortunately,
   incomplete understandings of the syntaxes of these identifiers has
   led to interoperability problems and poor user experiences.  Many
   users use specific characters in their addresses that are not
   properly accepted on various systems.  This document prescribes
   normative regular expression (regex) patterns for all Internet-
   connected systems to use when validating or parsing Internet Mail
   identifiers, with special attention to regular expressions that work
   with popular languages and platforms.

Status of This Memo

   This Internet-Draft is submitted in full conformance with the
   provisions of BCP 78 and BCP 79.

   Internet-Drafts are working documents of the Internet Engineering
   Task Force (IETF).  Note that other groups may also distribute
   working documents as Internet-Drafts.  The list of current Internet-
   Drafts is at http://datatracker.ietf.org/drafts/current/.

   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."

   This Internet-Draft will expire on September 14, 2017.

Copyright Notice

   Copyright (c) 2017 IETF Trust and the persons identified as the
   document authors.  All rights reserved.

Leonard, et al.        Expires September 14, 2017               [Page 1]
Internet-Draft                mail-regexen                    March 2017

   This document is subject to BCP 78 and the IETF Trust's Legal
   Provisions Relating to IETF Documents
   (http://trustee.ietf.org/license-info) in effect on the date of
   publication of this document.  Please review these documents
   carefully, as they describe your rights and restrictions with respect
   to this document.  Code Components extracted from this document must
   include Simplified BSD License text as described in Section 4.e of
   the Trust Legal Provisions and are provided without warranty as
   described in the Simplified BSD License.

Table of Contents

   1.  Introduction  . . . . . . . . . . . . . . . . . . . . . . . .   3
     1.1.  Normative Effects . . . . . . . . . . . . . . . . . . . .   4
     1.2.  Definitions . . . . . . . . . . . . . . . . . . . . . . .   4
   2.  History and Formal Models for Internet Mail Identifiers . . .   6
     2.1.  The Core History  . . . . . . . . . . . . . . . . . . . .   6
     2.2.  Multipurpose Internet Mail Extensions and Uniform
           Resource Identifiers  . . . . . . . . . . . . . . . . . .   9
     2.3.  Email Address Internationalization  . . . . . . . . . . .   9
     2.4.  The Data Model  . . . . . . . . . . . . . . . . . . . . .  10
       2.4.1.  Email Address . . . . . . . . . . . . . . . . . . . .  10
       2.4.2.  Message-ID  . . . . . . . . . . . . . . . . . . . . .  11
     2.5.  Equivalence and Comparison  . . . . . . . . . . . . . . .  11
       2.5.1.  Email Address . . . . . . . . . . . . . . . . . . . .  11
       2.5.2.  Message-ID  . . . . . . . . . . . . . . . . . . . . .  13
   3.  Regular Expressions for Email Addresses . . . . . . . . . . .  13
     3.1.  Deliverable Email Address . . . . . . . . . . . . . . . .  14
       3.1.1.  ASCII Building Blocks . . . . . . . . . . . . . . . .  14
       3.1.2.  Deliverable Email Address . . . . . . . . . . . . . .  14
       3.1.3.  (Leftover from draft-00) Basic Rules of Derivation
               (Unicode) . . . . . . . . . . . . . . . . . . . . . .  16
       3.1.4.  Complete Expression for Deliverable Email Address . .  17
       3.1.5.  Using Character Classes . . . . . . . . . . . . . . .  18
       3.1.6.  "Flotsam" and "Jetsam" Beyond ASCII . . . . . . . . .  18
       3.1.7.  Certain Expressions for Restrictions  . . . . . . . .  18
       3.1.8.  Unquoting Local-Part  . . . . . . . . . . . . . . . .  20
       3.1.9.  Quoting Local-Part  . . . . . . . . . . . . . . . . .  20
     3.2.  Modern Email Address  . . . . . . . . . . . . . . . . . .  20
Show full document text