MARF Working Group                                          S. Kitterman
Internet-Draft                                    Authentication Metrics
Intended status: Standards Track                           June 27, 2011
Expires: December 29, 2011


   SPF Authentication Failure Reporting using the Abuse Report Format
                    draft-ietf-marf-spf-reporting-00

Abstract

   This memo presents extensions to the Abuse Reporting Format (ARF),
   and Sender Policy Framework (SPF) specifications to allow for
   detailed reporting of message authentication failures in an on-demand
   fashion.

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 December 29, 2011.

Copyright Notice

   Copyright (c) 2011 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
   (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.




Kitterman               Expires December 29, 2011               [Page 1]


Internet-Draft         SPF Auth Failure Reporting              June 2011


Table of Contents

   1.  Introduction . . . . . . . . . . . . . . . . . . . . . . . . .  3
   2.  Definitions  . . . . . . . . . . . . . . . . . . . . . . . . .  4
     2.1.  Keywords . . . . . . . . . . . . . . . . . . . . . . . . .  4
     2.2.  Imported Definitions . . . . . . . . . . . . . . . . . . .  4
   3.  Optional Reporting Address for SPF . . . . . . . . . . . . . .  5
   4.  Requested Reports  . . . . . . . . . . . . . . . . . . . . . .  7
     4.1.  Requested Reports for SPF Failures . . . . . . . . . . . .  7
   5.  IANA Considerations  . . . . . . . . . . . . . . . . . . . . .  8
     5.1.  SPF Modifier Registration  . . . . . . . . . . . . . . . .  8
   6.  Security Considerations  . . . . . . . . . . . . . . . . . . .  9
     6.1.  Inherited Considerations . . . . . . . . . . . . . . . . .  9
     6.2.  Reports From Unrelated Domains . . . . . . . . . . . . . .  9
     6.3.  Forgeries  . . . . . . . . . . . . . . . . . . . . . . . .  9
     6.4.  Automatic Generation . . . . . . . . . . . . . . . . . . . 10
     6.5.  Envelope Sender Selection  . . . . . . . . . . . . . . . . 10
     6.6.  Reporting Multiple Incidents . . . . . . . . . . . . . . . 10
   7.  References . . . . . . . . . . . . . . . . . . . . . . . . . . 12
     7.1.  Normative References . . . . . . . . . . . . . . . . . . . 12
     7.2.  Informative References . . . . . . . . . . . . . . . . . . 12
   Appendix A.  Acknowledgements  . . . . . . . . . . . . . . . . . . 14
   Appendix B.  Examples  . . . . . . . . . . . . . . . . . . . . . . 15
     B.1.  Minimal SPF DNS record change to add a reporting
           address  . . . . . . . . . . . . . . . . . . . . . . . . . 15
     B.2.  SPF DNS record with reporting address, report
           interval, and requested report type  . . . . . . . . . . . 15
   Author's Address . . . . . . . . . . . . . . . . . . . . . . . . . 16























Kitterman               Expires December 29, 2011               [Page 2]


Internet-Draft         SPF Auth Failure Reporting              June 2011


1.  Introduction

   [ARF] defines a message format for sending reports of abuse in the
   messaging infrastructure, with an eye toward automating both the
   generating and consumption of those reports.

   [SPF] is one mechanism for message sender authentication; it is
   "path-based" meaning it authenticates the route that a message took
   from origin to destination.  As with other email authentication
   methods, like [DKIM], the output is a verified domain name that can
   then be subjected to some sort of evaluation process (e.g.,
   comparison to a known-good list, submission to a reputation service,
   etc.).

   Deployers of message sender authentication technologies are
   increasingly seeking visibility into DKIM verification failures,
   unauthorized path traversals (SPF failures), and conformance failures
   involving the published signing practices (e.g., [ADSP]) of an
   Administrative Mail Domain (ADMD; see [EMAIL-ARCH]).

   This document extends [SPF] to add an optional reporting address and
   an optional means of specifying a desired report format and other
   parameters.  Extension of [ARF] to add features required for the
   reporting of these incidents is covered in [I-D.MARF-DKIM-REPORTING].

   This document additionally creates a an IANA registry of [SPF] record
   modifiers to avoid modidier namespace collisions.
























Kitterman               Expires December 29, 2011               [Page 3]


Internet-Draft         SPF Auth Failure Reporting              June 2011


2.  Definitions

2.1.  Keywords

   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 [KEYWORDS].

2.2.  Imported Definitions

   The ABNF token "qp-section" is imported from [MIME].

   "local-part" is defined in [MAIL].

   "addr-spec" is defined in [MAIL].




































Kitterman               Expires December 29, 2011               [Page 4]


Internet-Draft         SPF Auth Failure Reporting              June 2011


3.  Optional Reporting Address for SPF

   There exist cases in which a domain name owner employing [SPF] for
   announcing sending practises may want to know when messages are
   received via unauthorized routing.  Currently there is no such
   mechanism defined.

   This document adds the following optional "modifier" (as defined in
   Section 4.6.1 of [SPF]) to SPF records, using the form defined in
   that specification:

   r= Reporting Address (plain-text; OPTIONAL; no default).  MUST be a
      local-part or addr-spec (see Section 3.4.1 of [MAIL])\ containing
      an e-mail address to which a report SHOULD be sent when mail
      claiming to be from this domain (see Section 2.4 of [SPF] for a
      description of how domains are identified for SPF checks) has
      failed the evaluation algorithm described in [SPF], in particular
      because a message arrived via an unauthorized route .  The format
      of this reply MUST be in the format specified by the "rf=" tag
      defined below.  If only a local-part is provided, then to generate
      a complete address to which the report is sent, the verifier
      simply appends to this value an "@" followed by the domain whose
      policy was queried in order to evaluate the sender's SPF record.
      r= modifiers in a record that was reached by following an include:
      mechanism MUST be ignored.

      ABNF:

      spf-report-tag = %x72 *WSP "=" qp-section

   rf=  Reporting Format (plain-text; OPTIONAL; default is "arf").  The
      value MUST be a colon-separated list of tokens representing
      desired reporting formats in decreasing order of preference.  Each
      element of the list MUST be a token that is taken from the
      registered list of report formats.  See Section 5 for a
      description of the registry and [I-D.MARF-DKIM-REPORTING] for a
      description of recognized formats.  The verifier generating
      reports MUST generate a report using the first token in the list
      that represents a report format it is capable of generating.  If
      no supported formats are requested, then no report is sent.

      ABNF:

      spf-rf-tag = %x72 %x66 *WSP "=" *WSP rep-format *WSP 0*( ":" *WSP
      rep-format )






Kitterman               Expires December 29, 2011               [Page 5]


Internet-Draft         SPF Auth Failure Reporting              June 2011


   ri=  Requested Report Interval (plain-text; OPTIONAL; default is
      "0").  The value is an unsigned 32-bit integer that specifies an
      interval, i.e. a number of reports, during which the report
      generator SHOULD NOT issue more than one report about a given type
      of incident should be generated.  A value of "0" requests a report
      for every incident.  Where the requested interval is not zero, the
      agent generating a report SHOULD include an "Incidents:" field in
      the generated report so the receiving agent has some indication of
      how many reports were suppressed.

      ABNF:

      spf-ri-tag = %x72 %x69 *WSP "=" *WSP 1*DIGIT

   ro=  Requested Reports (plain-text; OPTIONAL; default is "all").  The
      value MUST be a colon-separated list of tokens representing those
      conditions under which a report is desired.  See Section 4.1 for a
      list of valid tags.

      ABNF:

      spf-ro-type = ( "all" / "e" / "f" / "s" )

      spf-ro-tag = %x72 %x6f *WSP "=" *WSP spf-ro-type *WSP 0* ( ":"
      *WSP spf-ro-type )

   rs=  Requested SMTP Error String (plain-text; OPTIONAL; no default).
      The value is a string the sending domain requests be included in
      [SMTP] error strings when messages are rejected.

      ABNF:

      spf-rs-tag = %x72 %x73 *WSP "=" qp-section


















Kitterman               Expires December 29, 2011               [Page 6]


Internet-Draft         SPF Auth Failure Reporting              June 2011


4.  Requested Reports

   This memo also includes, as the "ro" tags defined above, the means by
   which the sender can request reports for specific circumstances of
   interest.  Verifiers MUST NOT generate reports for incidents that do
   not match a requested report, and MUST ignore requests for reports
   not included in this these lists.

4.1.  Requested Reports for SPF Failures

   The following report requests are defined for SPF keys:

   all  All reports are requested.

   e  Reports are requested for messages that produced an SPF result of
      "TempError" or "PermError.

   f  Reports are requested for messages that produced an SPF result of
      "Fail".

   s  Reports are requested for messages that produced an SPF result of
      "SoftFail".





























Kitterman               Expires December 29, 2011               [Page 7]


Internet-Draft         SPF Auth Failure Reporting              June 2011


5.  IANA Considerations

   As required by [IANA-CONSIDERATIONS], this section contains registry
   information for the new [SPF] tags.

5.1.  SPF Modifier Registration

   IANA is requested to create the Sender Policy Framework Modifier
   Registry, to include a list of all registered SPF modifier names and
   their defining documents.

   New registrations or updates MUST be published in accordance with the
   "Specification Required" guidelines as described in
   [IANA-CONSIDERATIONS].  New registrations and updates MUST contain
   the following information:

   1.  Name of the modifier being registered or updated

   2.  The document in which the specification of the modifier is
       published

   3.  New or updated status, which MUST be one of:

       current:  The field is in current use

       deprecated:  The field is in current use but its use is
          discouraged

       historic:  The field is no longer in current use

   An update may make a notation on an existing registration indicating
   that a registered field is historic or deprecated if appropriate.

                 +------------+-----------------+---------+
                 | MODIFIER   | REFERENCE       | STATUS  |
                 +------------+-----------------+---------+
                 | exp        | RFC4408         | current |
                 | redirect   | RFC4408         | current |
                 | r          | (this document) | current |
                 | rf         | (this document) | current |
                 | ri         | (this document) | current |
                 | ro         | (this document) | current |
                 | rs         | (this document) | current |
                 +------------+-----------------+---------+







Kitterman               Expires December 29, 2011               [Page 8]


Internet-Draft         SPF Auth Failure Reporting              June 2011


6.  Security Considerations

   Security issues with respect to these reports are similar to those
   found in [DSN].

6.1.  Inherited Considerations

   Implementors are advised to consider the Security Considerations
   sections of [SPF] and [ARF].

6.2.  Reports From Unrelated Domains

   SPF records can be used by other domains via include mechanisms and
   redirect modifiers.  If reporting addresses included in these records
   are specified with a full addr-spec then reports for other,
   potentially unrelated, domains may be reported to this address.  In
   theory, malicious senders might use this as a path for generating
   large numbers of feedback reports.  To mitigate this issue, specify
   reporting addresses with a local-part so that reports will be
   directed to the original domain from which the message causing the
   feedback report was sent.

6.3.  Forgeries

   These reports may be forged as easily as ordinary Internet electronic
   mail.  User agents and automatic mail handling facilities (such as
   mail distribution list exploders) that wish to make automatic use of
   DSNs of any kind should take appropriate precautions to minimize the
   potential damage from denial-of-service attacks.

   Security threats related to forged DSNs include the sending of:

   a.  A falsified authentication failure notification when the message
       was in fact delivered to the indicated recipient;

   b.  Falsified authentication information, such as result, domain,
       etc.

   Perhaps the simplest means of mitigating this threat is to assert
   that these reports should themselves be signed with something like
   DKIM or sent from sources authorized by SPF.  On the other hand, if
   there's a problem with the DKIM infrastructure at the verifier,
   signing DKIM failure reports may produce reports that aren't trusted
   or even accepted by their intended recipients.







Kitterman               Expires December 29, 2011               [Page 9]


Internet-Draft         SPF Auth Failure Reporting              June 2011


6.4.  Automatic Generation

   Automatic generation of these reports by verifying agents can cause a
   denial-of-service attack when a large volume of e-mail is sent that
   causes sender authentication failures for whatever reason.

   Limiting the rate of generation of these messages may be appropriate
   but threatens to inhibit the distribution of important and possibly
   time-sensitive information.

   In general ARF feedback loop terms, it is suggested that report
   generators only create these (or any) ARF reports after an out-of-
   band arrangement has been made between two parties.  This mechanism
   then becomes a way to adjust parameters of an authorized abuse report
   feedback loop that is configured and activated by private agreement
   rather than starting to send them automatically based solely on
   discovered data in the DNS.

6.5.  Envelope Sender Selection

   In the case of transmitted reports in the form of a new message, it
   is necessary to construct the message so as to avoid amplification
   attacks, deliberate or otherwise.  Thus, per Section 2 of [DSN], the
   envelope sender address of the report SHOULD be chosen to ensure that
   no delivery status reports will be issued in response to the report
   itself, and MUST be chosen so that these reports will not generate
   mail loops.  Whenever an [SMTP] transaction is used to send a report,
   the MAIL FROM command MUST use a NULL return address, i.e.  "MAIL
   FROM:<>".  The HELO/EHLO command SHOULD pass [SPF] HELO checks.

6.6.  Reporting Multiple Incidents

   If it is known that a particular host generates abuse reports upon
   certain incidents, an attacker could forge a high volume of messages
   that will trigger such a report.  The recipient of the report could
   then be innundated with reports.  This could easily be extended to a
   distributed denial-of-service attack by finding a number of report-
   generating servers.

   The incident count referenced in [ARF] provides a limited form of
   mitigation.  The host generating reports may elect to send reports
   only periodically, with each report representing a number of
   identical or near-identical incidents.  One might even do something
   inverse-exponentially, sending reports for each of the first ten
   incidents, then every tenth incident up to 100, then every 100th
   incident up to 1000, etc. until some period of relative quiet after
   which the limitation resets.




Kitterman               Expires December 29, 2011              [Page 10]


Internet-Draft         SPF Auth Failure Reporting              June 2011


   The use of this for "near-identical" incidents in particular causes a
   degradation in reporting quality, however.  If for example a large
   number of pieces of spam arrive from one attacker, a reporting agent
   may decide only to send a report about a fraction of those messages.
   While this averts a flood of reports to a system administrator, the
   precise details of each incident are similarly not sent.













































Kitterman               Expires December 29, 2011              [Page 11]


Internet-Draft         SPF Auth Failure Reporting              June 2011


7.  References

7.1.  Normative References

   [ARF]      Shafranovich, Y., Levine, J., and M. Kucherawy, "An
              Extensible Format for Email Feedback Reports", RFC 5965,
              August 2010.

   [DKIM]     Allman, E., Callas, J., Delany, M., Libbey, M., Fenton,
              J., and M. Thomas, "DomainKeys Identified Mail (DKIM)
              Signatures", RFC 4871, May 2007.

   [EMAIL-ARCH]
              Crocker, D., "Internet Mail Architecture", RFC 5598,
              October 2008.

   [I-D.MARF-DKIM-REPORTING]
              Kucherawy, M., "Extensions to DKIM for Failure Reporting",
              May 2011.

   [IANA-CONSIDERATIONS]
              Alvestrand, H. and T. Narten, "Guidelines for Writing an
              IANA Considerations Section in RFCs", RFC 5226, May 2008.

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

   [MAIL]     Resnick, P., "Internet Message Format", RFC 5322,
              October 2008.

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

   [SMTP]     Klensin, J., "Simple Mail Transfer Protocol", RFC 5321,
              October 2008.

   [SPF]      Wong, M. and W. Schlitt, "Sender Policy Framework (SPF)
              for Authorizing Use of Domains in E-Mail, Version 1",
              RFC 4408, April 2006.

7.2.  Informative References

   [ADSP]     Allman, E., Delany, M., Fenton, J., and J. Levine, "DKIM
              Sender Signing Practises", RFC 5617, August 2009.

   [DSN]      Moore, K. and G. Vaudreuil, "An Extensible Message Format



Kitterman               Expires December 29, 2011              [Page 12]


Internet-Draft         SPF Auth Failure Reporting              June 2011


              for Delivery Status Notifications", RFC 3464,
              January 2003.

















































Kitterman               Expires December 29, 2011              [Page 13]


Internet-Draft         SPF Auth Failure Reporting              June 2011


Appendix A.  Acknowledgements

   The author wishes to acknowledge the following for their review and
   constructive criticism of this proposal: Murray Kucherawy and Tim
   Draegen.














































Kitterman               Expires December 29, 2011              [Page 14]


Internet-Draft         SPF Auth Failure Reporting              June 2011


Appendix B.  Examples

B.1.  Minimal SPF DNS record change to add a reporting address

   v=spf1 mx:example.org r=postmaster -all

B.2.  SPF DNS record with reporting address, report interval, and
      requested report type

   v=spf1 mx:example.org r=postmaster@example.net rf=arf ri=10 ro=e -all









































Kitterman               Expires December 29, 2011              [Page 15]


Internet-Draft         SPF Auth Failure Reporting              June 2011


Author's Address

   Scott Kitterman
   Authentication Metrics
   3611 Scheel Dr
   Ellicott City, MD  21042
   US

   Phone: +1 301 325 5475
   Email: skitterman@authmetrics.com









































Kitterman               Expires December 29, 2011              [Page 16]