<?xml version="1.0" encoding="US-ASCII"?>
<!DOCTYPE rfc SYSTEM "rfc2629.dtd" [
<!ENTITY RFC1035 SYSTEM "reference.RFC.1035.xml">
<!ENTITY RFC2119 SYSTEM "reference.RFC.2119.xml">
<!ENTITY RFC2782 SYSTEM "reference.RFC.2782.xml">
<!ENTITY RFC5321 SYSTEM "reference.RFC.5321.xml">
<!ENTITY RFC5598 SYSTEM "reference.RFC.5598.xml">
<!ENTITY RFC7208 SYSTEM "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 rfcedstyle="yes"?>

<rfc number="7505" category="std" 
     ipr="trust200902" submissionType="IETF" consensus="yes">
  <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>
<country>United States</country>
        </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>
<country>United States</country>
        </postal>
        <email>mx0dot@yahoo.com</email>
      </address>
    </author>

    <date month="June" year="2015" />

    <area>Applications</area>

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

<!-- [rfced] The IESG included the following "RFC Editor Note"
in the Protocol Action message for version 08 of this document.

   There is some challenge in writing the document, in that community
   discussion about email tends to use words like 'sender' and 'server'
   generically.  Hence they can be ambiguous.  (Yes, an SMTP client is
   often referred to as a server.)  The current draft could perhaps benefit
   from some more careful attention to vocabulary usage; this might be
   worthy of RFC Editor staff consideration.  It is difficult for
   experienced email folk to read such text as if they were naive readers.

During editing, we have not made any changes to the usage of these
terms. However, in light of the note, please review the following
snippets. Are instances of 'sender[s]' or 'server' ambiguous?

Section 2
   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.

Section 4.2
   If a server nonetheless
   does so, it risks having its mail rejected.

NOTE: we made changes between -08 and -10 to address these concerns,
    and I fixed server->system in 4.2. Good catch.

-->
    <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/&wj;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;
  this permits
significant operational efficiencies.
       </t>
    </abstract>
  </front>
  <middle>
     <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; 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.


<!-- [rfced] May this sentence be updated for clarity (i.e., to avoid 
the construction "overloads ... onto")?

Original:
   Hence this overloads an email service semantic onto a DNS record
   with a different primary mission.

Perhaps:
   Hence, this overloads a DNS record (that has a different primary mission) 
   with an email service semantic.

YES, ACCEPTED
	   -->
   Hence, this overloads a DNS record (that has a different primary mission) 
   with an email service semantic.
	</t><t>

<!-- [rfced] Should "addresses" be changed to singular, as it is the
subsequent sentence? (If so, should it be singular "host"?)
May the sentence be rephrased as follows?

Original:
   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, ...

Perhaps:
   If a domain has no MX records, senders will attempt to deliver mail
   to the host at the address of the domain's A or AAAA record.  If there
   is no SMTP listener at the A/AAAA address, ...

PLURAL IS RIGHT, REWROTE A LITTLE TO UNSCRAMBLE IT.

	   -->
	   If a domain has no MX records, senders will attempt to deliver mail to
	   the hosts at the addresses in the domain's A or AAAA records.
	   If there are no SMTP listeners at the A/AAAA addresses, message delivery will be
	   attempted repeatedly for a long period, typically a week,
	   before the sending Mail Transfer Agent (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="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="MX Resource Records Specifying Null MX">
	<t>
	   To indicate that a domain does not accept email, it advertises a
	   single MX RR (see Section 3.3.9 of <xref target="RFC1035" />)
	   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 cannot be confused with an ordinary MX record.
	   The use of "." as a pseudo-hostname 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, 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>

<!-- [rfced]  We have updated "5.1.TBD" to "X.1.10" and "5.7.TBD" to "X.7.27"
in the sentences below. Please review and confirm that these updates are
correct.

Original
...a 5.1.TBD enhanced status code (Permanent failure:
   Recipient address has null MX).
...
   a 5.7.TBD enhanced status code (Permanent failure: 
   Sender address has null MX).

Updated
...an X.1.10 enhanced status code (Permanent failure:
   Recipient address has null MX).       
...
   an X.7.27 enhanced status code (Permanent failure: 
   Sender address has null MX).                   


FIXED to 5.1.10 and 5.7.27 because in this context we know the X is 5.
	-->

<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="RFC7504"/>
	   (Requested action not taken: domain does not accept mail) and a
	   5.1.10 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.27 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 system nonetheless does so, it risks having its mail rejected.
	</t><t>
	   Operators of domains that do not send mail can publish Sender
	   Policy Framework (SPF) "-all"
	   policies <xref target="RFC7208" /> 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 Section 4.5.5 of RFC 5321 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 has added the following entries to the
	   "Enumerated Status Codes" subregistry of the "Simple Mail Transfer Protocol (SMTP) 
	  Enhanced Status Codes Registry".</t>
	  <figure>
	     <artwork>
Code:              X.1.10
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.27
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>
  </middle>

  <back>
    <references title="Normative References">
       &RFC1035;
       &RFC2119;
       &RFC5321;

<!-- draft-klensin-smtp-521code : RFC 7504 -->
<reference anchor='RFC7504' target='http://www.rfc-editor.org/info/rfc7504'>
<front>
<title>SMTP 521 and 556 Reply Codes</title>

<author initials='J' surname='Klensin' fullname='John Klensin'>
    <organization />
</author>

<date month='June' year='2015' />

</front>
<seriesInfo name="RFC" value="7504"/>
<seriesInfo name="DOI" value="10.17487/RFC7504"/>

</reference>

    </references>
    <references title="Informative References">
       &RFC2782;
       &RFC5598;
       &RFC7208;
    </references>

     <section title="Acknowledgements" numbered="no">
	<t>
	   We thank Dave Crocker for his diligent and lengthy shepherding of this document,
	   and members of the APPSAWG working group for their constructive suggestions.
	</t>
     </section>


  </back>
</rfc>
