<?xml version="1.0" encoding="US-ASCII"?>
<!DOCTYPE rfc SYSTEM "rfc2629.dtd" [
<!ENTITY RFC1035 SYSTEM "bibxml/reference.RFC.1035.xml">
<!ENTITY RFC2119 SYSTEM "bibxml/reference.RFC.2119.xml">
<!ENTITY RFC2782 SYSTEM "bibxml/reference.RFC.2782.xml">
<!ENTITY RFC5321 SYSTEM "bibxml/reference.RFC.5321.xml">
<!ENTITY RFC5598 SYSTEM "bibxml/reference.RFC.5598.xml">
<!ENTITY RFC7208 SYSTEM "bibxml/reference.RFC.7208.xml">
]>
<?xml-stylesheet type='text/xsl' href='rfc2629.xslt' ?>
<?rfc compact="yes" ?>
<?rfc subcompact="no" ?>
<?rfc toc="yes" ?>
<?rfc tocindent="yes" ?>
<?rfc tocdepth="2" ?>
<?rfc symrefs="yes" ?>
<?rfc sortrefs="yes"?>
<?rfc iprnotified="no" ?>

<rfc category="std" docName="draft-ietf-appsawg-nullmx-09" ipr="trust200902">
  <front>
    <title abbrev="Null MX">A "Null MX" No Service Resource Record for Domains that Accept No Mail</title>

    <author fullname="John Levine" initials="J." surname="Levine">
      <organization>Taughannock Networks</organization>

      <address>
        <postal>
          <street>PO Box 727</street>
          <city>Trumansburg</city>
          <code>14886</code>
          <region>NY</region>
        </postal>
        <phone>+1 831 480 2300</phone>
        <email>standards@taugh.com</email>
        <uri>http://jl.ly</uri>
      </address>
    </author>

    <author fullname="Mark Delany" initials="M." surname="Delany">
      <organization>Apple Inc.</organization>

      <address>
        <postal>
          <street>1 Infinite Loop</street>
          <city>Cupertino</city>
          <code>95014</code>
          <region>CA</region>
        </postal>
        <email>mx0dot@yahoo.com</email>
      </address>
    </author>

    <date month="September" year="2014" />

    <area>Applications</area>

    <keyword>DNS</keyword>
    <keyword>e-mail</keyword>

    <abstract>
       <t>
     Internet mail determines the address of a receiving server through the DNS, first by looking for
an MX record and then by looking for an A/AAAA record as a fallback.
Unfortunately this means that the A/AAAA record is taken to be mail server address even when that
address does not accept mail.
  The no service MX RR, informally called null MX,
  formalizes the existing mechanism by which a domain
  announces that it accepts no mail, without having to provide a mail server,
  which permits
significant operational efficiencies.
       </t>
    </abstract>
  </front>
  <middle>
     <section title="Conventions Used in This Document">

	<t>
	   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 <xref target="RFC2119"/>.
	</t>
	<t>
	   The terms RFC5321.MailFrom and RFC5322.From are used as defined
	   in <xref target="RFC5598"/>.
	</t>

     </section>
     <section title="Introduction">
	<t>
	   This document defines the No Service MX, informally called null MX,
	   as a simple mechanism by
	   which a domain can indicate that it does not accept email.
	</t><t>
	   SMTP clients have a prescribed sequence for identifying a server that
	   accepts email for a domain. Section 5 of <xref target="RFC5321" /> covers this in
	   detail, but in essence the SMTP client first looks up a DNS MX RR and
	   if that is not found it falls back to looking up a DNS A or AAAA RR.
	   Hence this overloads an email service semantic onto a DNS record with a different primary mission.
	</t><t>
	   If a domain has no MX records, senders will attempt to deliver mail to
	   the hosts at the domain's A or AAAA record's addresses.
	   If there is no SMTP listener at the A/AAAA address, message delivery will be
	   attempted repeatedly for a long period, typically a week,
	   before the sending MTA gives up.
	   This will delay notification to the sender in the case of
	   misdirected mail, and will consume resources at the sender.
	</t><t>
	   This document defines a null MX that will
	   cause all mail delivery attempts to a domain to fail immediately,
	   without requiring domains to create SMTP
	   listeners dedicated to preventing delivery attempts.
	</t>
     </section>

     <section title="MX Resource Records Specifying Null MX">
	<t>
	   To indicate that a domain does not accept email, it advertises a
	   single MX RR (see <xref target="RFC1035" />, section 3.3.9)
	   with an RDATA section consisting of
	   preference number 0, and a zero length label, written in master files as ".",
	   as the exchange domain, to denote that there exists no mail exchanger for a
	   domain.
	   Since "." is not a valid host name, a null MX
	   record can not be confused with an ordinary MX record.
	   The use of "." as a pseudo-host name meaning no service available is
	   modeled on <xref target="RFC2782">the SRV RR</xref> where
	   it has a similar meaning.
	</t><t>
	   A domain that advertises a null MX MUST NOT advertise any other MX RR.
	</t>
     </section>
     <section title="Effects of Null MX">
	<t>The null MX record has a variety of efficiency and usability benefits.
	</t>

     <section title="SMTP Server Benefits">
	<t>
	   Mail often has an incorrect address due to user error, where the
	   address was mistranscribed or misunderstood, for example, to
	   alice@www.example.com or alice@example.org or alice@examp1e.com
	   rather than alice@example.com.
	   Null MX allows a mail system to report the delivery failure when 
	   the user sends the message, rather than hours or days later.
	</t><t>
	   Senders of abusive mail often use forged undeliverable return addresses.
	   Null MX allows  Delivery Status Notifications (DSNs)
	   and other attempted responses to such mail
	   to be disposed of efficiently.
	</t><t>
	   The ability to detect domains that do not accept email offers 
	   resource savings to an SMTP client.
	   It will discover on the first sending attempt that an address
	   is not deliverable, avoiding queuing and retries.
	</t><t>
	   When a submission or SMTP relay server rejects an envelope recipient due to a domain's
	   null MX record, it SHOULD use a 556 reply code<xref target="rfc1846bis"/>
	   (Requested action not taken: domain does not accept mail) and a
	   5.1.TBD enhanced status code
	   (Permanent failure: Recipient address has null MX).
	</t><t>
	   A receiving SMTP server that
	   chooses to reject email during the SMTP conversation that
	   presents an undeliverable RFC5321.MailFrom or RFC5322.From domain
	   can be more confident that for other messages a subsequent attempt
	   to send a DSN or other response will
	   reach a recipient SMTP server.
	</t><t>
	   SMTP servers that reject mail because a RFC5321.MailFrom or RFC5322.From domain
	   has a null MX record SHOULD use a 550 reply code
	   (Requested action not taken: mailbox unavailable) and a
	   5.7.TBD enhanced status code
	   (Permanent failure: Sender address has null MX).
	</t>
     </section>
     
     <section title="Sending Mail from Domains that Publish Null MX">
	<t>
	   Null MX is primarily intended for domains that do not send or receive
	   any mail, but have mail sent to them anyway due to mistakes or malice.
	   Many receiving systems reject mail that has an invalid return address.
	   Return addresses are needed to allow the sender to handle message delivery errors.
           An invalid return address often signals that the message is spam.
	   Hence mail systems SHOULD NOT publish a null MX record for domains
	   that they use in RFC5321.MailFrom or RFC5322.From addresses.
	   If a server nonetheless does so, it risks having its mail rejected.
	</t><t>
	   Operators of domains that do not send mail can publish SPF -all
	   <xref target="RFC7208" /> policies to make an explicit declaration that the
	   domains send no mail.
	</t><t>
	   Null MX is not intended to be a replacement
	   for the null reverse path described in RFC 5321 section 4.5.5 and does
	   not change the meaning or use of a null reverse path.
	</t>
     </section>
     </section>

     <section title="Security Considerations">
	<t>
	   Within the DNS, a null MX RR is an ordinary MX record and presents no
	   new security issues.
	   If desired, it can be secured in the same manner as any other DNS record
	   using DNSSEC.
	</t>
     </section>
     <section title="IANA Considerations">
	<t>IANA is requested to add the following entries to the
	   "Enumerated Status Codes" sub-registry of the Simple Mail Transfer Protocol (SMTP) 
	  Enhanced Status Codes Registry.</t>
	  <figure>
	     <artwork>
Code:              X.1.TBD
Sample Text:       Recipient address has null MX
Associated basic status code:  556
Description:       This status code is returned when the associated
                   address is marked as invalid using a null MX.
Reference:         [this document]
Submitter:         [authors of this document]
Change controller: IESG

Code:              X.7.TBD
Sample Text:       Sender address has null MX
Associated basic status code:  550
Description:       This status code is returned when the associated
                   sender address has a null MX, and the SMTP
		   receiver is configured to reject mail from such
		   sender (e.g. because it could not return a DSN).
Reference:         [this document]
Submitter:         [authors of this document]
Change controller: IESG</artwork>
	  </figure>

     </section>
     <section title="Acknowledgements">
	<t>
	   We thank Dave Crocker for his diligent and lengthy shepherding of this document.
	</t>
     </section>
  </middle>

  <back>
    <references title="Normative References">
       &RFC1035;
       &RFC2119;
      &RFC5321;
      <reference anchor="rfc1846bis">
        <front>
          <title>SMTP 521 and 556 Reply Codes</title>
          <author fullname="John Klensin" initials="J." surname="Klensin">
            <organization/>
          </author>
          <date />
        </front>
        <annotation>Work In Progress</annotation>
      </reference>

    </references>
    <references title="Informative References">
       &RFC2782;
       &RFC5598;
       &RFC7208;
    </references>
    <section title="Change Log">
       <t><spanx style="strong">NOTE TO RFC EDITOR: This section may be removed
	   upon publication of this document as an RFC.</spanx></t>
	
	<section title="Change to appsawg-nullmx-09">
	   <t>Change 521 to 556, change reference.</t>
	</section>
	<section title="Change to appsawg-nullmx-08">
	   <t>Fix name of IANA registry.</t>
	   <t>Yea, even yet more editorial cleanup.</t>
	</section>
	<section title="Change to appsawg-nullmx-07">
	   <t>Add new enhanced status codes and ref for 521 return code.</t>
	   <t>Even yet more editorial cleanup.</t>
	</section>
	<section title="Change to appsawg-nullmx-06">
	   <t>Even more editorial cleanup.</t>
	   <t>Mention SRV</t>
	   <t>you SHOULD NOT put a null MX on domains that send mail</t>
	</section>
	<section title="Change to appsawg-nullmx-05">
	   <t>Fix ID nits, add NULL IANA section. More editorial cleanup.</t>
	</section>
	<section title="Change to appsawg-nullmx-04">
	   <t>Reorganize.</t>
	</section>
	<section title="Change to appsawg-nullmx-03">
	   <t>Editorial nits per Murray.</t>
	</section>
	<section title="Change to appsawg-nullmx-02">
	   <t>Should not publish NULL MX with other MX.</t>
	   <t>Never say never.</t>
	   <t>Add 5.1.2 enhanced status code.</t>
	   <t>Minor editorial changes.</t>
	</section>
	<section title="Change to appsawg-nullmx-1">
	   <t>Editorial improvements per D. Crocker's review.</t>
	</section>
	<section title="Change to appsawg-nullmx-0">
	   <t>Fix typos.</t>
	</section>
     </section>

  </back>
</rfc>
