Advice for Safe Handling of Malformed Messages

The information below is for an old version of the document
Document Type Active Internet-Draft (appsawg WG)
Last updated 2013-09-20 (latest revision 2013-09-17)
Replaces draft-kucherawy-mta-malformed
Stream IETF
Intended RFC status Informational
Formats plain text pdf html bibtex
Additional URLs
- Mailing list discussion
Stream WG state Submitted to IESG for Publication (wg milestone: Sep 2013 - Publication requeste... )
Document shepherd Moonesamy S
Shepherd write-up Show (last changed 2013-09-20)
IESG IESG state AD Evaluation::Revised I-D Needed
Consensus Boilerplate No
Telechat date
Responsible AD Barry Leiba
Send notices to,,
APPSAWG                                                     M. Kucherawy
Internet-Draft                                                G. Shapiro
Intended status: Informational                                  N. Freed
Expires: March 21, 2014                               September 17, 2013

             Advice for Safe Handling of Malformed Messages


   Although Internet mail formats have been precisely defined since the
   1970s, authoring and handling software often show only mild
   conformance to the specifications.  The distributed and non-
   interactive nature of email has often prompted adjustments to
   receiving software, to handle these variations, rather than trying to
   gain better conformance by senders, since the receiving operator is
   primarily driven by complaining recipient users and has no authority
   over the sending side of the system.  Processing with such
   flexibility comes at some cost, since mail software is faced with
   decisions about whether or not to permit non-conforming messages to
   continue toward their destinations unaltered, adjust them to conform
   (possibly at the cost of losing some of the original message), or
   outright rejecting them.

   A core requirement for interoperability is that both sides of an
   exchange work from the same details and semantics.  By having
   receivers be flexible, beyond the specifications, there can be -- and
   often has been -- a good chance that a message will not be fully
   interoperable.  Worse, a well-established pattern of tolerance for
   variations can sometimes be used as an attack vector.

   This document includes a collection of the best advice available
   regarding a variety of common malformed mail situations, to be used
   as implementation guidance.  These malformations are typically based
   around loose interpretations or implementations of specifications
   such as Internet Message Format [MAIL] and Multipurpose Internet Mail
   Extensions [MIME].

   It must be emphasized, however, that the intent of this document is
   not to standardize malformations or otherwise encourage their
   proliferation.  The messages are manifestly malformed, and the code
   and culture that generates them needs to be fixed.  Therefore, these
   messages should be rejected outright if at all possible.
   Nevertheless, many malformed messages from otherwise legitimate
   senders are in circulation and will be for some time, and,
   unfortunately, commercial reality shows that we cannot always simply
   reject or discard them.  Accordingly, this document presents

Kucherawy, et al.        Expires March 21, 2014                 [Page 1]
Internet-Draft             Safe Mail Handling             September 2013

   alternatives for dealing with them in ways that seem to do the least
   additional harm until the infrastructure is tightened up to match the

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

   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 March 21, 2014.

Copyright Notice

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

   This document is subject to BCP 78 and the IETF Trust's Legal
   Provisions Relating to IETF Documents
   ( 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.

Kucherawy, et al.        Expires March 21, 2014                 [Page 2]
Internet-Draft             Safe Mail Handling             September 2013

Table of Contents

   1.  Introduction . . . . . . . . . . . . . . . . . . . . . . . . .  4
     1.1.  The Purpose Of This Work . . . . . . . . . . . . . . . . .  4
     1.2.  Not The Purpose Of This Work . . . . . . . . . . . . . . .  4
     1.3.  General Considerations . . . . . . . . . . . . . . . . . .  5
   2.  Document Conventions . . . . . . . . . . . . . . . . . . . . .  5
     2.1.  Examples . . . . . . . . . . . . . . . . . . . . . . . . .  5
Show full document text