idnits 2.17.1 draft-ietf-appsawg-rfc7001bis-02.txt: Checking boilerplate required by RFC 5378 and the IETF Trust (see https://trustee.ietf.org/license-info): ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/1id-guidelines.txt: ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/checklist : ---------------------------------------------------------------------------- -- The draft header indicates that this document obsoletes RFC7001, but the abstract doesn't seem to mention this, which it should. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year -- The document date (February 20, 2015) is 3353 days in the past. Is this intentional? Checking references for intended status: Proposed Standard ---------------------------------------------------------------------------- (See RFCs 3967 and 4897 for information about using normative references to lower-maturity documents in RFCs) == Missing Reference: 'CFWS' is mentioned on line 488, but not defined == Missing Reference: 'RFC7208' is mentioned on line 772, but not defined -- Obsolete informational reference (is this intentional?): RFC 4870 (ref. 'DOMAINKEYS') (Obsoleted by RFC 4871) -- Obsolete informational reference (is this intentional?): RFC 5226 (ref. 'IANA-CONSIDERATIONS') (Obsoleted by RFC 8126) -- Obsolete informational reference (is this intentional?): RFC 3501 (ref. 'IMAP') (Obsoleted by RFC 9051) -- Obsolete informational reference (is this intentional?): RFC 7410 (ref. 'PTYPES-REGISTRY') (Obsoleted by RFC 7601) -- Obsolete informational reference (is this intentional?): RFC 5451 (Obsoleted by RFC 7001) -- Obsolete informational reference (is this intentional?): RFC 7001 (Obsoleted by RFC 7601) Summary: 0 errors (**), 0 flaws (~~), 3 warnings (==), 8 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 Individual submission M. Kucherawy 3 Internet-Draft February 20, 2015 4 Obsoletes: 7001, 7410 5 (if approved) 6 Intended status: Standards Track 7 Expires: August 24, 2015 9 Message Header Field for Indicating Message Authentication Status 10 draft-ietf-appsawg-rfc7001bis-02 12 Abstract 14 This document specifies a message header field called Authentication- 15 Results for use with electronic mail messages to indicate the results 16 of message authentication efforts. Any receiver-side software, such 17 as mail filters or Mail User Agents (MUAs), can use this header field 18 to relay that information in a convenient and meaningful way to users 19 or to make sorting and filtering decisions. 21 Status of This Memo 23 This Internet-Draft is submitted in full conformance with the 24 provisions of BCP 78 and BCP 79. 26 Internet-Drafts are working documents of the Internet Engineering 27 Task Force (IETF). Note that other groups may also distribute 28 working documents as Internet-Drafts. The list of current Internet- 29 Drafts is at http://datatracker.ietf.org/drafts/current/. 31 Internet-Drafts are draft documents valid for a maximum of six months 32 and may be updated, replaced, or obsoleted by other documents at any 33 time. It is inappropriate to use Internet-Drafts as reference 34 material or to cite them other than as "work in progress." 36 This Internet-Draft will expire on August 24, 2015. 38 Copyright Notice 40 Copyright (c) 2015 IETF Trust and the persons identified as the 41 document authors. All rights reserved. 43 This document is subject to BCP 78 and the IETF Trust's Legal 44 Provisions Relating to IETF Documents 45 (http://trustee.ietf.org/license-info) in effect on the date of 46 publication of this document. Please review these documents 47 carefully, as they describe your rights and restrictions with respect 48 to this document. Code Components extracted from this document must 49 include Simplified BSD License text as described in Section 4.e of 50 the Trust Legal Provisions and are provided without warranty as 51 described in the Simplified BSD License. 53 Table of Contents 55 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . . 4 56 1.1. Purpose . . . . . . . . . . . . . . . . . . . . . . . . . 5 57 1.2. Trust Boundary . . . . . . . . . . . . . . . . . . . . . . 5 58 1.3. Processing Scope . . . . . . . . . . . . . . . . . . . . . 6 59 1.4. Requirements . . . . . . . . . . . . . . . . . . . . . . . 6 60 1.5. Definitions . . . . . . . . . . . . . . . . . . . . . . . 6 61 1.5.1. Key Words . . . . . . . . . . . . . . . . . . . . . . 7 62 1.5.2. Security . . . . . . . . . . . . . . . . . . . . . . . 7 63 1.5.3. Email Architecture . . . . . . . . . . . . . . . . . . 7 64 1.5.4. Other Terms . . . . . . . . . . . . . . . . . . . . . 8 65 1.6. Trust Environment . . . . . . . . . . . . . . . . . . . . 9 66 2. Definition and Format of the Header Field . . . . . . . . . . 9 67 2.1. General Description . . . . . . . . . . . . . . . . . . . 9 68 2.2. Formal Definition . . . . . . . . . . . . . . . . . . . . 10 69 2.3. Property Types (ptypes) and Properties . . . . . . . . . . 12 70 2.4. The "policy" ptype . . . . . . . . . . . . . . . . . . . . 13 71 2.5. Authentication Identifier Field . . . . . . . . . . . . . 14 72 2.6. Version Tokens . . . . . . . . . . . . . . . . . . . . . . 15 73 2.7. Defined Methods and Result Values . . . . . . . . . . . . 15 74 2.7.1. DKIM and DomainKeys . . . . . . . . . . . . . . . . . 16 75 2.7.2. SPF and Sender ID . . . . . . . . . . . . . . . . . . 17 76 2.7.3. "iprev" . . . . . . . . . . . . . . . . . . . . . . . 18 77 2.7.4. SMTP AUTH . . . . . . . . . . . . . . . . . . . . . . 18 78 2.7.5. Other Registered Codes . . . . . . . . . . . . . . . . 19 79 2.7.6. Extension Methods . . . . . . . . . . . . . . . . . . 19 80 2.7.7. Extension Result Codes . . . . . . . . . . . . . . . . 20 81 3. The "iprev" Authentication Method . . . . . . . . . . . . . . 20 82 4. Adding the Header Field to a Message . . . . . . . . . . . . . 22 83 4.1. Header Field Position and Interpretation . . . . . . . . . 23 84 4.2. Local Policy Enforcement . . . . . . . . . . . . . . . . . 24 85 5. Removing Existing Header Fields . . . . . . . . . . . . . . . 24 86 6. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 25 87 6.1. The Authentication-Results Header Field . . . . . . . . . 26 88 6.2. "Email Authentication Methods" Registry . . . . . . . . . 26 89 6.3. "Email Authentication Result Names" Registry . . . . . . . 27 90 7. Security Considerations . . . . . . . . . . . . . . . . . . . 27 91 7.1. Forged Header Fields . . . . . . . . . . . . . . . . . . . 27 92 7.2. Misleading Results . . . . . . . . . . . . . . . . . . . . 29 93 7.3. Header Field Position . . . . . . . . . . . . . . . . . . 29 94 7.4. Reverse IP Query Denial-of-Service Attacks . . . . . . . . 29 95 7.5. Mitigation of Backscatter . . . . . . . . . . . . . . . . 30 96 7.6. Internal MTA Lists . . . . . . . . . . . . . . . . . . . . 30 97 7.7. Attacks against Authentication Methods . . . . . . . . . . 30 98 7.8. Intentionally Malformed Header Fields . . . . . . . . . . 30 99 7.9. Compromised Internal Hosts . . . . . . . . . . . . . . . . 30 100 7.10. Encapsulated Instances . . . . . . . . . . . . . . . . . . 31 101 7.11. Reverse Mapping . . . . . . . . . . . . . . . . . . . . . 31 102 8. References . . . . . . . . . . . . . . . . . . . . . . . . . . 31 103 8.1. Normative References . . . . . . . . . . . . . . . . . . . 31 104 8.2. Informative References . . . . . . . . . . . . . . . . . . 32 105 Appendix A. Acknowledgements . . . . . . . . . . . . . . . . . . 33 106 Appendix B. Legacy MUAs . . . . . . . . . . . . . . . . . . . . . 34 107 Appendix C. Authentication-Results Examples . . . . . . . . . . . 34 108 C.1. Trivial Case; Header Field Not Present . . . . . . . . . . 34 109 C.2. Nearly Trivial Case; Service Provided, but No 110 Authentication Done . . . . . . . . . . . . . . . . . . . 35 111 C.3. Service Provided, Authentication Done . . . . . . . . . . 36 112 C.4. Service Provided, Several Authentications Done, Single 113 MTA . . . . . . . . . . . . . . . . . . . . . . . . . . . 37 114 C.5. Service Provided, Several Authentications Done, 115 Different MTAs . . . . . . . . . . . . . . . . . . . . . . 38 116 C.6. Service Provided, Multi-Tiered Authentication Done . . . . 40 117 C.7. Comment-Heavy Example . . . . . . . . . . . . . . . . . . 41 118 Appendix D. Operational Considerations about Message 119 Authentication . . . . . . . . . . . . . . . . . . . 42 120 Appendix E. Change History . . . . . . . . . . . . . . . . . . . 43 121 E.1. RFC7001 to -00 . . . . . . . . . . . . . . . . . . . . . . 43 122 E.2. -00 to -01 . . . . . . . . . . . . . . . . . . . . . . . . 44 123 E.3. -01 to -02 . . . . . . . . . . . . . . . . . . . . . . . . 44 125 1. Introduction 127 This document describes a header field called Authentication-Results 128 for electronic mail messages that presents the results of a message 129 authentication effort in a machine-readable format. The intent of 130 the header field is to create a place to collect such data when 131 message authentication mechanisms are in use so that a Mail User 132 Agent (MUA) and downstream filters can make filtering decisions 133 and/or provide a recommendation to the user as to the validity of the 134 message's origin and possibly the safety and integrity of its 135 content. 137 This document revises the original definition found in [RFC5451] 138 based upon various authentication protocols in current use and 139 incorporates errata logged since the publication of the original 140 specification. 142 End users are not expected to be direct consumers of this header 143 field. This header field is intended for consumption by programs 144 that will then use such data or render it in a human-usable form. 146 This document specifies the format of this header field and discusses 147 the implications of its presence or absence. However, it does not 148 discuss how the data contained in the header field ought to be used, 149 such as what filtering decisions are appropriate or how an MUA might 150 render those results, as these are local policy and/or user interface 151 design questions that are not appropriate for this document. 153 At the time of publication of this document, the following are 154 published, domain-level email authentication methods in common use: 156 o Author Domain Signing Practices ([ADSP]) 158 o SMTP Service Extension for Authentication ([AUTH]) 160 o DomainKeys Identified Mail Signatures ([DKIM]) 162 o Sender Policy Framework ([SPF]) 164 o Vouch By Reference ([VBR]) 166 o reverse IP address name validation ("iprev", defined in Section 3) 168 In addition, the following are non-standard methods recognized by 169 this specification that are no longer common: 171 o DomainKeys ([DOMAINKEYS]) (Historic) 172 o Sender ID ([SENDERID]) (Experimental) 174 This specification is not intended to be restricted to domain-based 175 authentication schemes, but the existing schemes in that family have 176 proven to be a good starting point for implementations. The goal is 177 to give current and future authentication schemes a common framework 178 within which to deliver their results to downstream agents and 179 discourage the creation of unique header fields for each. 181 Although SPF defined a header field called "Received-SPF" and the 182 historic DomainKeys defined one called "DomainKey-Status" for this 183 purpose, those header fields are specific to the conveyance of their 184 respective results only and thus are insufficient to satisfy the 185 requirements enumerated below. In addition, many SPF implementations 186 have adopted the header field specified here at least as an option, 187 and DomainKeys has been obsoleted by DKIM. 189 1.1. Purpose 191 The header field defined in this document is expected to serve 192 several purposes: 194 1. Convey the results of various message authentication checks, 195 which are applied by upstream filters and Mail Transfer Agents 196 (MTAs) and then passed to MUAs and downstream filters within the 197 same "trust domain". Such agents might wish to render those 198 results to end users or to use those data to apply more or less 199 stringent content checks based on authentication results; 201 2. Provide a common location within a message for this data; 203 3. Create an extensible framework for reporting new authentication 204 methods as they emerge. 206 In particular, the mere presence of this header field does not mean 207 its contents are valid. Rather, the header field is reporting 208 assertions made by one or more authentication schemes (supposedly) 209 applied somewhere upstream. For an MUA or downstream filter to treat 210 the assertions as actually valid, there must be an assessment of the 211 trust relationship among such agents, the validating MTA, and the 212 mechanism for conveying the information. 214 1.2. Trust Boundary 216 This document makes several references to the "trust boundary" of an 217 administrative management domain (ADMD). Given the diversity among 218 existing mail environments, a precise definition of this term isn't 219 possible. 221 Simply put, a transfer from the producer of the header field to the 222 consumer must occur within a context that permits the consumer to 223 treat assertions by the producer as being reliable and accurate 224 (trustworthy). How this trust is obtained is outside the scope of 225 this document. It is entirely a local matter. 227 Thus, this document defines a "trust boundary" as the delineation 228 between "external" and "internal" entities. Services that are 229 internal -- within the trust boundary -- are provided by the ADMD's 230 infrastructure for its users. Those that are external are outside of 231 the authority of the ADMD. By this definition, hosts that are within 232 a trust boundary are subject to the ADMD's authority and policies, 233 independent of their physical placement or their physical operation. 234 For example, a host within a trust boundary might actually be 235 operated by a remote service provider and reside physically within 236 its data center. 238 It is possible for a message to be evaluated inside a trust boundary 239 but then depart and re-enter the trust boundary. An example might be 240 a forwarded message such as a message/rfc822 attachment (see 241 Multipurpose Internet Mail Extensions [MIME]) or one that is part of 242 a multipart/digest. The details reported by this field cannot be 243 trusted in that case. Thus, this field found within one of those 244 media types is typically ignored. 246 1.3. Processing Scope 248 The content of this header field is meant to convey to message 249 consumers that authentication work on the message was already done 250 within its trust boundary, and those results are being presented. It 251 is not intended to provide message parameters to consumers so that 252 they can perform authentication protocols on their own. 254 1.4. Requirements 256 This document establishes no new requirements on existing protocols 257 or servers. 259 In particular, this document establishes no requirement on MTAs to 260 reject or filter arriving messages that do not pass authentication 261 checks. The data conveyed by the specified header field's contents 262 are for the information of MUAs and filters and are to be used at 263 their discretion. 265 1.5. Definitions 267 This section defines various terms used throughout this document. 269 1.5.1. Key Words 271 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 272 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this 273 document are to be interpreted as described in [KEYWORDS]. 275 1.5.2. Security 277 "Guidelines for Writing RFC Text on Security Considerations" 278 ([SECURITY]) discusses authentication and authorization and the 279 conflation of the two concepts. The use of those terms within the 280 context of recent message security work has given rise to slightly 281 different definitions, and this document reflects those current 282 usages, as follows: 284 o "Authorization" is the establishment of permission to use a 285 resource or represent an identity. In this context, authorization 286 indicates that a message from a particular ADMD arrived via a 287 route the ADMD has explicitly approved. 289 o "Authentication" is the assertion of validity of a piece of data 290 about a message (such as the sender's identity) or the message in 291 its entirety. 293 As examples: SPF and Sender ID are authorization mechanisms in that 294 they express a result that shows whether or not the ADMD that 295 apparently sent the message has explicitly authorized the connecting 296 Simple Mail Transfer Protocol ([SMTP]) client to relay messages on 297 its behalf, but they do not actually validate any other property of 298 the message itself. By contrast, DKIM is agnostic as to the routing 299 of a message but uses cryptographic signatures to authenticate 300 agents, assign (some) responsibility for the message (which implies 301 authorization), and ensure that the listed portions of the message 302 were not modified in transit. Since the signatures are not tied to 303 SMTP connections, they can be added by either the ADMD of origin, 304 intermediate ADMDs (such as a mailing list server), other handling 305 agents, or any combination. 307 Rather than create a separate header field for each class of 308 solution, this proposal groups them both into a single header field. 310 1.5.3. Email Architecture 312 o A "border MTA" is an MTA that acts as a gateway between the 313 general Internet and the users within an organizational boundary. 314 (See also Section 1.2.) 316 o A "delivery MTA" (or Mail Delivery Agent or MDA) is an MTA that 317 actually enacts delivery of a message to a user's inbox or other 318 final delivery. 320 o An "intermediate MTA" is any MTA that is not a delivery MTA and is 321 also not the first MTA to handle the message. 323 The following diagram illustrates the flow of mail among these 324 defined components. See Internet Mail Architecture [EMAIL-ARCH] for 325 further discussion on general email system architecture, which 326 includes detailed descriptions of these components, and Appendix D of 327 this document for discussion about the common aspects of email 328 authentication in current environments. 330 +-----+ +-----+ +------------+ 331 | MUA |-->| MSA |-->| Border MTA | 332 +-----+ +-----+ +------------+ 333 | 334 | 335 V 336 +----------+ 337 | Internet | 338 +----------+ 339 | 340 | 341 V 342 +-----+ +-----+ +------------------+ +------------+ 343 | MUA |<--| MDA |<--| Intermediate MTA |<--| Border MTA | 344 +-----+ +-----+ +------------------+ +------------+ 346 Generally, it is assumed that the work of applying message 347 authentication schemes takes place at a border MTA or a delivery MTA. 348 This specification is written with that assumption in mind. However, 349 there are some sites at which the entire mail infrastructure consists 350 of a single host. In such cases, such terms as "border MTA" and 351 "delivery MTA" might well apply to the same machine or even the very 352 same agent. It is also possible that some message authentication 353 tests could take place on an intermediate MTA. Although this 354 document doesn't specifically describe such cases, they are not meant 355 to be excluded. 357 1.5.4. Other Terms 359 In this document, the term "producer" refers to any component that 360 adds this header field to messages it is handling, and "consumer" 361 refers to any component that identifies, extracts, and parses the 362 header field to use as part of a handling decision. 364 1.6. Trust Environment 366 This header field permits one or more message validation mechanisms 367 to communicate output to one or more separate assessment mechanisms. 368 These mechanisms operate within a unified trust boundary that defines 369 an Administrative Management Domain (ADMD). An ADMD contains one or 370 more entities that perform validation and generate the header field 371 and one or more that consume it for some type of assessment. The 372 field often contains no integrity or validation mechanism of its own, 373 so its presence must be trusted implicitly. Hence, valid use of the 374 header field requires removing any occurrences of it that are present 375 when the message enters the ADMD. This ensures that later 376 occurrences have been added within the trust boundary of the ADMD. 378 The authserv-id token defined in Section 2.2 can be used to reference 379 an entire ADMD or a specific validation engine within an ADMD. 380 Although the labeling scheme is left as an operational choice, some 381 guidance for selecting a token is provided in later sections of this 382 document. 384 2. Definition and Format of the Header Field 386 This section gives a general overview of the format of the header 387 field being defined and then provides more formal specification. 389 2.1. General Description 391 The header field specified here is called Authentication-Results. It 392 is a Structured Header Field as defined in Internet Message Format 393 ([MAIL]), and thus all of the related definitions in that document 394 apply. 396 This header field is added at the top of the message as it transits 397 MTAs that do authentication checks, so some idea of how far away the 398 checks were done can be inferred. It is therefore considered to be a 399 trace field as defined in [MAIL], and thus all of the related 400 definitions in that document apply. 402 The value of the header field (after removing comments) consists of 403 an authentication identifier, an optional version, and then a series 404 of statements and supporting data. The statements are of the form 405 "method=result" and indicate which authentication method(s) were 406 applied and their respective results. For each such statement, the 407 supporting data can include a "reason" string and one or more 408 "property=value" statements indicating which message properties were 409 evaluated to reach that conclusion. 411 The header field can appear more than once in a single message, more 412 than one result can be represented in a single header field, or a 413 combination of these can be applied. 415 2.2. Formal Definition 417 Formally, the header field is specified as follows using Augmented 418 Backus-Naur Form ([ABNF]): 420 authres-header = "Authentication-Results:" [CFWS] authserv-id 421 [ CFWS authres-version ] 422 ( no-result / 1*resinfo ) [CFWS] CRLF 424 authserv-id = value 425 ; see below for a description of this element 427 authres-version = 1*DIGIT [CFWS] 428 ; indicates which version of this specification is in use; 429 ; this specification is version "1", and the absence of a 430 ; version implies this version of the specification 432 no-result = [CFWS] ";" [CFWS] "none" 433 ; the special case of "none" is used to indicate that no 434 ; message authentication was performed 436 resinfo = [CFWS] ";" methodspec [ CFWS reasonspec ] 437 *( CFWS propspec ) 439 methodspec = [CFWS] method [CFWS] "=" [CFWS] result 440 ; indicates which authentication method was evaluated 441 ; and what its output was 443 reasonspec = "reason" [CFWS] "=" [CFWS] value 444 ; a free-form comment on the reason the given result 445 ; was returned 447 propspec = ptype [CFWS] "." [CFWS] property [CFWS] "=" pvalue 448 ; an indication of which properties of the message 449 ; were evaluated by the authentication scheme being 450 ; applied to yield the reported result 452 method = Keyword [ [CFWS] "/" [CFWS] method-version ] 453 ; a method indicates which method's result is 454 ; represented by "result", and is one of the methods 455 ; explicitly defined as valid in this document 456 ; or is an extension method as defined below 458 method-version = 1*DIGIT [CFWS] 459 ; indicates which version of the method specification is 460 ; in use, corresponding to the matching entry in the IANA 461 ; "Email Authentication Methods" registry; a value of "1" 462 ; is assumed if this version string is absent 464 result = Keyword 465 ; indicates the results of the attempt to authenticate 466 ; the message; see below for details 468 ptype = Keyword 469 ; indicates whether the property being evaluated was 470 ; a parameter to an [SMTP] command, was a value taken 471 ; from a message header field, was some property of 472 ; the message body, or was some other property evaluated by 473 ; the receiving MTA; expected to be one of the "property 474 ; types" explicitly defined as valid, or an extension 475 ; ptype, as defined below 477 property = special-smtp-verb / Keyword 478 ; indicates more specifically than "ptype" what the 479 ; source of the evaluated property is; the exact meaning 480 ; is specific to the method whose result is being reported 481 ; and is defined more clearly below 483 special-smtp-verb = "mailfrom" / "rcptto" 484 ; special cases of [SMTP] commands that are made up 485 ; of multiple words 487 pvalue = [CFWS] ( value / [ [ local-part ] "@" ] domain-name ) 488 [CFWS] 489 ; the value extracted from the message property defined 490 ; by the "ptype.property" construction 492 "local-part" is defined in Section 3.4.1 of [MAIL], and "CFWS" is 493 defined in Section 3.2.2 of [MAIL]. 495 "Keyword" is defined in Section 4.1.2 of [SMTP]. 497 The "value" is as defined in Section 5.1 of [MIME]. 499 The "domain-name" is as defined in Section 3.5 of [DKIM]. 501 The "Keyword" used in "result" above is further constrained by the 502 necessity of being enumerated in Section 2.7. 504 See Section 2.5 for a description of the authserv-id element. 506 If the value portion of a "pvalue" construction identifies something 507 intended to be an e-mail identity, then it MUST use the right hand 508 portion of that ABNF definition. 510 The list of commands eligible for use with the "smtp" ptype can be 511 found in Section 4.1 of [SMTP]. 513 The "propspec" may be omitted if, for example, the method was unable 514 to extract any properties to do its evaluation yet has a result to 515 report. 517 Where an SMTP command name is being reported as a "property", the 518 agent generating the header field represents that command by 519 converting it to lowercase and dropping any spaces (e.g., "MAIL FROM" 520 becomes "mailfrom", "RCPT TO" becomes "rcptto", etc.). 522 A "ptype" value of "policy" indicates a policy decision about the 523 message not specific to a property of the message that could be 524 extracted. See Section 2.4 for details. 526 Examples of complete messages using this header field can be found in 527 Appendix C. 529 2.3. Property Types (ptypes) and Properties 531 The "ptype" in the ABNF above indicates the general type of property 532 being described by the result being reported, upon which the reported 533 result was based. Coupled with the "property", which is more 534 specific, they inidcate from which part of the message the reported 535 data were extracted. 537 Combinations of ptypes and properties are registered and described in 538 the "Email Authentication Methods" registry, coupled with the 539 authentication methods with which they are used. This is further 540 described in Section 6. 542 Legal values of "ptype" are as defined in the IANA "Email 543 Authentication Property Types" registry, created by 544 [PTYPES-REGISTRY]. The initial values and what they typically 545 indicate are as follows, copied from [RFC7001]: 547 body: Information that was extracted from the body of the message. 548 This might be an arbitrary string of bytes, a hash of a string of 549 bytes, a Uniform Resource Identifier, or some other content of 550 interest. The "property" is an indication of where within the 551 message body the extracted content was found, and can indicate an 552 offset, identify a MIME part, or 554 header: Indicates information that was extracted from the header of 555 the message. This might be the value of a header field or some 556 portion of a header field. The "property" gives a more precise 557 indication of the place in the header from which the extraction 558 took place. 560 policy: A local policy mechanism was applied that augments or 561 overrides the result returned by the authentication mechanism. 562 (See Section 2.4.) 564 smtp: Indicates information that was extracted from an SMTP command 565 that was used to relay the message. The "property" indicates 566 which SMTP command included the extracted content as a parameter. 568 When a consumer of this header field encounters a "ptype" that it 569 does not understand, it ignores the result reported with that 570 "ptype". 572 Entries in the "Email Authentication Methods" registry can define 573 properties that deviate from these definitions when appropriate. For 574 example, when reporting the result of a [DKIM] evaluation, it would 575 be redundant to report the name of the header field from which 576 details were extracted. Thus, instead, DKIM results use the "header" 577 property to name the signature tag from which a detail of interest 578 was extracted. 580 2.4. The "policy" ptype 582 A special ptype value of "policy" is also defined. This ptype is 583 provided to indicate that some local policy mechanism was applied 584 that augments or even replaces (i.e., overrides) the result returned 585 by the authentication mechanism. The property and value in this case 586 identify the local policy that was applied and the result it 587 returned. 589 For example, a DKIM signature is not required to include the Subject 590 header field in the set of fields that are signed. An ADMD receiving 591 such a message might decide that such a signature is unacceptable, 592 even if it passes, because the content of the Subject header field 593 could be altered post-signing without invalidating the signature. 594 Such an ADMD could replace the DKIM "pass" result with a "policy" 595 result and then also include the following in the corresponding 596 Authentication-Result field: 598 ... dkim=fail policy.dkim-rules=unsigned-subject ... 600 In this case, the property is "dkim-rules", indicating some local 601 check by that name took place and that check returned a result of 602 "unsigned-subject". These are arbitrary names selected by (and 603 presumably used within) the ADMD making use of them, so they are not 604 normally registered with IANA or otherwise specified apart from 605 setting syntax restrictions that allow for easy parsing within the 606 rest of the header field. 608 This ptype existed in the original specification for this header 609 field, but without a complete description or example of intended use. 610 As a result, it has not seen any practical use to date that matches 611 its intended purpose. These added details are provided to guide 612 implementers toward proper use. 614 2.5. Authentication Identifier Field 616 Every Authentication-Results header field has an authentication 617 service identifier field (authserv-id above). Specifically, this is 618 any string intended to identify the authentication service within the 619 ADMD that conducted authentication checks on the message. This 620 identifier is intended to be machine-readable and not necessarily 621 meaningful to users. 623 Since agents consuming this field will use this identifier to 624 determine whether its contents are of interest (and are safe to use), 625 the uniqueness of the identifier MUST be guaranteed by the ADMD that 626 generates it and MUST pertain to that ADMD. MUAs or downstream 627 filters SHOULD use this identifier to determine whether or not the 628 data contained in an Authentication-Results header field ought to be 629 used or ignored. 631 For simplicity and scalability, the authentication service identifier 632 SHOULD be a common token used throughout the ADMD. Common practice 633 is to use the DNS domain name used by or within that ADMD, sometimes 634 called the "organizational domain", but this is not strictly 635 necessary. 637 For tracing and debugging purposes, the authentication identifier can 638 instead be the specific hostname of the MTA performing the 639 authentication check whose result is being reported. Moreover, some 640 implementations define a substructure to the identifier; these are 641 outside of the scope of this specification. 643 Note, however, that using a local, relative identifier like a flat 644 hostname, rather than a hierarchical and globally unique ADMD 645 identifier like a DNS domain name, makes configuration more difficult 646 for large sites. The hierarchical identifier permits aggregating 647 related, trusted systems together under a single, parent identifier, 648 which in turn permits assessing the trust relationship with a single 649 reference. The alternative is a flat namespace requiring 650 individually listing each trusted system. Since consumers will use 651 the identifier to determine whether to use the contents of the header 652 field: 654 o Changes to the identifier impose a large, centralized 655 administrative burden. 657 o Ongoing administrative changes require constantly updating this 658 centralized table, making it difficult to ensure that an MUA or 659 downstream filter will have access to accurate information for 660 assessing the usability of the header field's content. In 661 particular, consumers of the header field will need to know not 662 only the current identifier(s) in use but previous ones as well to 663 account for delivery latency or later re-assessment of the header 664 field's contents. 666 Examples of valid authentication identifiers are "example.com", 667 "mail.example.org", "ms1.newyork.example.com", and "example-auth". 669 2.6. Version Tokens 671 The grammar above provides for the optional inclusion of versions on 672 both the header field itself (attached to the authserv-id token) and 673 on each of the methods being reported. The method version refers to 674 the method itself, which is specified in the documents describing 675 those methods, while the authserv-id version refers to this document 676 and thus the syntax of this header field. 678 The purpose of including these is to avoid misinterpretation of the 679 results. That is, if a parser finds a version after an authserv-id 680 that it does not explicitly know, it can immediately discontinue 681 trying to parse since what follows might not be in an expected 682 format. For a method version, the parser SHOULD ignore a method 683 result if the version is not supported in case the semantics of the 684 result have a different meaning than what is expected. For example, 685 if a hypothetical DKIM version 2 yielded a "pass" result for 686 different reasons than version 1 does, a consumer of this field might 687 not want to use the altered semantics. Allowing versions in the 688 syntax is a way to indicate this and let the consumer of the header 689 field decide. 691 2.7. Defined Methods and Result Values 693 Each individual authentication method returns one of a set of 694 specific result values. The subsections below provide references to 695 the documents defining the authentication methods specifically 696 supported by this document, and their corresponding result values. 697 Verifiers SHOULD use these values as described below. New methods 698 not specified in this document, but intended to be supported by the 699 header field defined here, MUST include a similar result table either 700 in their defining documents or in supplementary ones. 702 2.7.1. DKIM and DomainKeys 704 DKIM is represented by the "dkim" method and is defined in [DKIM]. 705 DomainKeys is defined in [DOMAINKEYS] and is represented by the 706 "domainkeys" method. 708 A signature is "acceptable to the ADMD" if it passes local policy 709 checks (or there are no specific local policy checks). For example, 710 an ADMD policy might require that the signature(s) on the message be 711 added using the DNS domain present in the From header field of the 712 message, thus making third-party signatures unacceptable even if they 713 verify. 715 Both DKIM and DomainKeys use the same result set, as follows: 717 none: The message was not signed. 719 pass: The message was signed, the signature or signatures were 720 acceptable to the ADMD, and the signature(s) passed verification 721 tests. 723 fail: The message was signed and the signature or signatures were 724 acceptable to the ADMD, but they failed the verification test(s). 726 policy: The message was signed, but some aspect of the signature or 727 signatures was not acceptable to the ADMD. 729 neutral: The message was signed, but the signature or signatures 730 contained syntax errors or were not otherwise able to be 731 processed. This result is also used for other failures not 732 covered elsewhere in this list. 734 temperror: The message could not be verified due to some error that 735 is likely transient in nature, such as a temporary inability to 736 retrieve a public key. A later attempt may produce a final 737 result. 739 permerror: The message could not be verified due to some error that 740 is unrecoverable, such as a required header field being absent. A 741 later attempt is unlikely to produce a final result. 743 [DKIM] advises that if a message fails verification, it is to be 744 treated as an unsigned message. A report of "fail" here permits the 745 receiver of the report to decide how to handle the failure. A report 746 of "neutral" or "none" preempts that choice, ensuring the message 747 will be treated as if it had not been signed. 749 2.7.2. SPF and Sender ID 751 SPF and Sender ID use the "spf" and "sender-id" method names, 752 respectively. The result values for SPF are defined in Section 2.6 753 of [SPF], and those definitions are included here by reference: 755 +-----------+--------------------------------+ 756 | Code | Meaning | 757 +-----------+--------------------------------+ 758 | none | [RFC7208], Section 2.6.1 | 759 +-----------+--------------------------------+ 760 | pass | [RFC7208], Section 2.6.3 | 761 +-----------+--------------------------------+ 762 | fail | [RFC7208], Section 2.6.4 | 763 +-----------+--------------------------------+ 764 | softfail | [RFC7208], Section 2.6.5 | 765 +-----------+--------------------------------+ 766 | policy | [this RFC], Section 2.4 | 767 +-----------+--------------------------------+ 768 | neutral | [RFC7208], Section 2.6.2 | 769 +-----------+--------------------------------+ 770 | temperror | [RFC7208], Section 2.6.6 | 771 +-----------+--------------------------------+ 772 | permerror | [RFC7208], Section 2.6.7 | 773 +-----------+--------------------------------+ 775 These result codes are used in the context of this specification to 776 reflect the result returned by the component conducting SPF 777 evaluation. 779 Similarly, the results for Sender ID are listed and described in 780 Section 4.2 of [SENDERID], which in turn uses the SPF definitions 781 that now appear in [SPF]. 783 Note that both of those documents specify result codes that use mixed 784 case, but they are typically used all lowercase in this context. 786 In both cases, an additional result of "policy" is defined, which 787 means the client was authorized to inject or relay mail on behalf of 788 the sender's DNS domain according to the authentication method's 789 algorithm, but local policy dictates that the result is unacceptable. 790 For example, "policy" might be used if SPF returns a "pass" result, 791 but a local policy check matches the sending DNS domain to one found 792 in an explicit list of unacceptable DNS domains (e.g., spammers). 794 If the retrieved sender policies used to evaluate SPF and Sender ID 795 do not contain explicit provisions for authenticating the local-part 796 (see Section 3.4.1 of [MAIL]) of an address, the "pvalue" reported 797 along with results for these mechanisms SHOULD NOT include the local- 798 part. 800 2.7.3. "iprev" 802 The result values used by the "iprev" method, defined in Section 3, 803 are as follows: 805 pass: The DNS evaluation succeeded, i.e., the "reverse" and 806 "forward" lookup results were returned and were in agreement. 808 fail: The DNS evaluation failed. In particular, the "reverse" and 809 "forward" lookups each produced results, but they were not in 810 agreement, or the "forward" query completed but produced no 811 result, e.g., a DNS RCODE of 3, commonly known as NXDOMAIN, or an 812 RCODE of 0 (NOERROR) in a reply containing no answers, was 813 returned. 815 temperror: The DNS evaluation could not be completed due to some 816 error that is likely transient in nature, such as a temporary DNS 817 error, e.g., a DNS RCODE of 2, commonly known as SERVFAIL, or 818 other error condition resulted. A later attempt may produce a 819 final result. 821 permerror: The DNS evaluation could not be completed because no PTR 822 data are published for the connecting IP address, e.g., a DNS 823 RCODE of 3, commonly known as NXDOMAIN, or an RCODE of 0 (NOERROR) 824 in a reply containing no answers, was returned. This prevented 825 completion of the evaluation. A later attempt is unlikely to 826 produce a final result. 828 There is no "none" for this method since any TCP connection 829 delivering email has an IP address associated with it, so some kind 830 of evaluation will always be possible. 832 For discussion of the format of DNS replies, see "Domain Names - 833 Implementation and Specification" ([DNS]). 835 2.7.4. SMTP AUTH 837 SMTP AUTH (defined in [AUTH]) is represented by the "auth" method, 838 and its result values are as follows: 840 none: SMTP authentication was not attempted. 842 pass: The SMTP client authenticated to the server reporting the 843 result using the protocol described in [AUTH]. 845 fail: The SMTP client attempted to authenticate to the server using 846 the protocol described in [AUTH] but was not successful, yet 847 continued to send the message about which a result is being 848 reported. 850 temperror: The SMTP client attempted to authenticate using the 851 protocol described in [AUTH] but was not able to complete the 852 attempt due to some error that is likely transient in nature, such 853 as a temporary directory service lookup error. A later attempt 854 may produce a final result. 856 permerror: The SMTP client attempted to authenticate using the 857 protocol described in [AUTH] but was not able to complete the 858 attempt due to some error that is likely not transient in nature, 859 such as a permanent directory service lookup error. A later 860 attempt is not likely to produce a final result. 862 An agent making use of the data provided by this header field SHOULD 863 consider "fail" and "temperror" to be synonymous in terms of message 864 authentication, i.e., the client did not authenticate in either case. 866 2.7.5. Other Registered Codes 868 Result codes were also registered in other RFCs for Vouch By 869 Reference (in [AR-VBR], represented by "vbr"), Authorized Third-Party 870 Signatures (in [ATPS], represented by "dkim-atps"), and the DKIM- 871 related Author Domain Signing Practices (in [ADSP], represented by 872 "dkim-adsp"). 874 2.7.6. Extension Methods 876 Additional authentication method identifiers (extension methods) may 877 be defined in the future by later revisions or extensions to this 878 specification. These method identifiers are registered with the 879 Internet Assigned Numbers Authority (IANA) and, preferably, published 880 in an RFC. See Section 6 for further details. 882 Extension methods can be defined for the following reasons: 884 1. To allow additional information from new authentication systems 885 to be communicated to MUAs or downstream filters. The names of 886 such identifiers ought to reflect the name of the method being 887 defined but ought not be needlessly long. 889 2. To allow the creation of "sub-identifiers" that indicate 890 different levels of authentication and differentiate between 891 their relative strengths, e.g., "auth1-weak" and "auth1-strong". 893 Authentication method implementers are encouraged to provide adequate 894 information, via message header field comments if necessary, to allow 895 an MUA developer to understand or relay ancillary details of 896 authentication results. For example, if it might be of interest to 897 relay what data was used to perform an evaluation, such information 898 could be relayed as a comment in the header field, such as: 900 Authentication-Results: example.com; 901 foo=pass bar.baz=blob (2 of 3 tests OK) 903 Experimental method identifiers MUST only be used within ADMDs that 904 have explicitly consented to use them. These method identifiers and 905 the parameters associated with them are not documented in RFCs. 906 Therefore, they are subject to change at any time and not suitable 907 for production use. Any MTA, MUA, or downstream filter intended for 908 production use SHOULD ignore or delete any Authentication-Results 909 header field that includes an experimental (unknown) method 910 identifier. 912 2.7.7. Extension Result Codes 914 Additional result codes (extension results) might be defined in the 915 future by later revisions or extensions to this specification. 916 Result codes MUST be registered with the Internet Assigned Numbers 917 Authority (IANA) and preferably published in an RFC. See Section 6 918 for further details. 920 Experimental results MUST only be used within ADMDs that have 921 explicitly consented to use them. These results and the parameters 922 associated with them are not formally documented. Therefore, they 923 are subject to change at any time and not suitable for production 924 use. Any MTA, MUA, or downstream filter intended for production use 925 SHOULD ignore or delete any Authentication-Results header field that 926 includes an extension result. 928 3. The "iprev" Authentication Method 930 This section defines an additional authentication method called 931 "iprev". 933 "iprev" is an attempt to verify that a client appears to be valid 934 based on some DNS queries, which is to say that the IP address is 935 explicitly associated with a domain name. Upon receiving a session 936 initiation of some kind from a client, the IP address of the client 937 peer is queried for matching names (i.e., a number-to-name 938 translation, also known as a "reverse lookup" or a "PTR" record 939 query). Once that result is acquired, a lookup of each of the names 940 (i.e., a name-to-number translation, or an "A" or "AAAA" record 941 query) thus retrieved is done. The response to this second check 942 will typically result in at least one mapping back to the client's IP 943 address. 945 Expressed as an algorithm: If the client peer's IP address is I, the 946 list of names to which I maps (after a "PTR" query) is the set N, and 947 the union of IP addresses to which each member of N maps (after 948 corresponding "A" and "AAAA" queries) is L, then this test is 949 successful if I is an element of L. 951 The response to a PTR query could contain multiple names. To prevent 952 heavy DNS loads, agents performing these queries MUST be implemented 953 such that the number of names evaluated by generation of 954 corresponding A or AAAA queries is limited so as not to be unduly 955 taxing to the DNS infrastructure, though it MAY be configurable by an 956 administrator. As an example, Section 4.6.4 of [SPF] chose a limit 957 of 10 for its implementation of this algorithm. 959 "DNS Extensions to Support IP Version 6" ([DNS-IP6]) discusses the 960 query formats for the IPv6 case. 962 There is some contention regarding the wisdom and reliability of this 963 test. For example, in some regions, it can be difficult for this 964 test ever to pass because the practice of arranging to match the 965 forward and reverse DNS is infrequently observed. Therefore, the 966 precise implementation details of how a verifier performs an "iprev" 967 test are not specified here. The verifier MAY report a successful or 968 failed "iprev" test at its discretion having done some kind of check 969 of the validity of the connection's identity using DNS. It is 970 incumbent upon an agent making use of the reported "iprev" result to 971 understand what exactly that particular verifier is attempting to 972 report. 974 Extensive discussion of reverse DNS mapping and its implications can 975 be found in "Considerations for the use of DNS Reverse Mapping" 976 ([DNSOP-REVERSE]). In particular, it recommends that applications 977 avoid using this test as a means of authentication or security. Its 978 presence in this document is not an endorsement but is merely 979 acknowledgement that the method remains common and provides the means 980 to relay the results of that test. 982 4. Adding the Header Field to a Message 984 This specification makes no attempt to evaluate the relative 985 strengths of various message authentication methods that may become 986 available. The methods listed are an order-independent set; their 987 sequence does not indicate relative strength or importance of one 988 method over another. Instead, the MUA or downstream filter consuming 989 this header field is to interpret the result of each method based on 990 its own knowledge of what that method evaluates. 992 Each "method" MUST refer to an authentication method declared in the 993 IANA registry or an extension method as described in Section 2.7.6, 994 and each "result" MUST refer to a result code declared in the IANA 995 registry or an extension result code as defined in Section 2.7.7. 996 See Section 6 for further information about the registered methods 997 and result codes. 999 An MTA compliant with this specification adds this header field 1000 (after performing one or more message authentication tests) to 1001 indicate which MTA or ADMD performed the test, which test got 1002 applied, and what the result was. If an MTA applies more than one 1003 such test, it adds this header field either once per test or once 1004 indicating all of the results. An MTA MUST NOT add a result to an 1005 existing header field. 1007 An MTA MAY add this header field containing only the authentication 1008 identifier portion and the "none" token (see Section 2.2) to indicate 1009 explicitly that no message authentication schemes were applied prior 1010 to delivery of this message. 1012 An MTA adding this header field has to take steps to identify it as 1013 legitimate to the MUAs or downstream filters that will ultimately 1014 consume its content. One process to do so is described in Section 5. 1015 Further measures may be necessary in some environments. Some 1016 possible solutions are enumerated in Section 7.1. This document does 1017 not mandate any specific solution to this issue as each environment 1018 has its own facilities and limitations. 1020 Most known message authentication methods focus on a particular 1021 identifier to evaluate. SPF and Sender ID differ in that they can 1022 yield a result based on more than one identifier; specifically, SPF 1023 can evaluate the RFC5321.HELO parameter or the RFC5321.MailFrom 1024 parameter, and Sender ID can evaluate the RFC5321.MailFrom parameter 1025 or the Purported Responsible Address (PRA) identity. When generating 1026 this field to report those results, only the parameter that yielded 1027 the result is included. 1029 For MTAs that add this header field, adding header fields in order 1030 (at the top), per Section 3.6 of [MAIL], is particularly important. 1031 Moreover, this header field SHOULD be inserted above any other trace 1032 header fields such MTAs might prepend. This placement allows easy 1033 detection of header fields that can be trusted. 1035 End users making direct use of this header field might inadvertently 1036 trust information that has not been properly vetted. If, for 1037 example, a basic SPF result were to be relayed that claims an 1038 authenticated addr-spec, the local-part of that addr-spec has 1039 actually not been authenticated. Thus, an MTA adding this header 1040 field SHOULD NOT include any data that has not been authenticated by 1041 the method(s) being applied. Moreover, MUAs SHOULD NOT render to 1042 users such information if it is presented by a method known not to 1043 authenticate it. 1045 4.1. Header Field Position and Interpretation 1047 In order to ensure non-ambiguous results and avoid the impact of 1048 false header fields, MUAs and downstream filters SHOULD NOT interpret 1049 this header field unless specifically configured to do so by the user 1050 or administrator. That is, this interpretation should not be "on by 1051 default". Naturally then, users or administrators ought not activate 1052 such a feature unless they are certain the header field will be 1053 validly added by an agent within the ADMD that accepts the mail that 1054 is ultimately read by the MUA, and instances of the header field 1055 appearing to originate within the ADMD but are actually added by 1056 foreign MTAs will be removed before delivery. 1058 Furthermore, MUAs and downstream filters SHOULD NOT interpret this 1059 header field unless the authentication service identifier it bears 1060 appears to be one used within its own ADMD as configured by the user 1061 or administrator. 1063 MUAs and downstream filters MUST ignore any result reported using a 1064 "result" not specified in the IANA "Result Code" registry or a 1065 "ptype" not listed in the corresponding registry for such values as 1066 defined in Section 6. Moreover, such agents MUST ignore a result 1067 indicated for any "method" they do not specifically support. 1069 An MUA SHOULD NOT reveal these results to end users, absent careful 1070 human factors design considerations and testing, for the presentation 1071 of trust-related materials. For example, an attacker could register 1072 examp1e.com (note the digit "one") and send signed mail to intended 1073 victims; a verifier would detect that the signature was valid and 1074 report a "pass" even though it's clear the DNS domain name was 1075 intended to mislead. See Section 7.2 for further discussion. 1077 As stated in Section 2.1, this header field MUST be treated as though 1078 it were a trace header field as defined in Section 3.6.7 of [MAIL] 1079 and hence MUST NOT be reordered and MUST be prepended to the message, 1080 so that there is generally some indication upon delivery of where in 1081 the chain of handling MTAs the message authentication was done. 1083 Note that there are a few message handlers that are only capable of 1084 appending new header fields to a message. Strictly speaking, these 1085 handlers are not compliant with this specification. They can still 1086 add the header field to carry authentication details, but any signal 1087 about where in the handling chain the work was done may be lost. 1088 Consumers SHOULD be designed such that this can be tolerated, 1089 especially from a producer known to have this limitation. 1091 MUAs SHOULD ignore instances of this header field discovered within 1092 message/rfc822 MIME attachments. 1094 Further discussion of these topics can be found in Section 7 below. 1096 4.2. Local Policy Enforcement 1098 Some sites have a local policy that considers any particular 1099 authentication policy's non-recoverable failure results (typically 1100 "fail" or similar) as justification for rejecting the message. In 1101 such cases, the border MTA SHOULD issue an SMTP rejection response to 1102 the message, rather than adding this header field and allowing the 1103 message to proceed toward delivery. This is more desirable than 1104 allowing the message to reach an internal host's MTA or spam filter, 1105 thus possibly generating a local rejection such as a Delivery Status 1106 Notification (DSN) [DSN] to a forged originator. Such generated 1107 rejections are colloquially known as "backscatter". 1109 The same MAY also be done for local policy decisions overriding the 1110 results of the authentication methods (e.g., the "policy" result 1111 codes described in Section 2.7). 1113 Such rejections at the SMTP protocol level are not possible if local 1114 policy is enforced at the MUA and not the MTA. 1116 5. Removing Existing Header Fields 1118 For security reasons, any MTA conforming to this specification MUST 1119 delete any discovered instance of this header field that claims, by 1120 virtue of its authentication service identifier, to have been added 1121 within its trust boundary but that did not come directly from another 1122 trusted MTA. For example, an MTA for example.com receiving a message 1123 MUST delete or otherwise obscure any instance of this header field 1124 bearing an authentication service identifier indicating that the 1125 header field was added within example.com prior to adding its own 1126 header fields. This could mean each MTA will have to be equipped 1127 with a list of internal MTAs known to be compliant (and hence 1128 trustworthy). 1130 For simplicity and maximum security, a border MTA could remove all 1131 instances of this header field on mail crossing into its trust 1132 boundary. However, this may conflict with the desire to access 1133 authentication results performed by trusted external service 1134 providers. It may also invalidate signed messages whose signatures 1135 cover external instances of this header field. A more robust border 1136 MTA could allow a specific list of authenticating MTAs whose 1137 information is to be admitted, removing the header field originating 1138 from all others. 1140 As stated in Section 1.2, a formal definition of "trust boundary" is 1141 deliberately not made here. It is entirely possible that a border 1142 MTA for example.com will explicitly trust authentication results 1143 asserted by upstream host example.net even though they exist in 1144 completely disjoint administrative boundaries. In that case, the 1145 border MTA MAY elect not to delete those results; moreover, the 1146 upstream host doing some authentication work could apply a signing 1147 technology such as [DKIM] on its own results to assure downstream 1148 hosts of their authenticity. An example of this is provided in 1149 Appendix C. 1151 Similarly, in the case of messages signed using [DKIM] or other 1152 message-signing methods that sign header fields, this removal action 1153 could invalidate one or more signatures on the message if they 1154 covered the header field to be removed. This behavior can be 1155 desirable since there's little value in validating the signature on a 1156 message with forged header fields. However, signing agents MAY 1157 therefore elect to omit these header fields from signing to avoid 1158 this situation. 1160 An MTA SHOULD remove any instance of this header field bearing a 1161 version (express or implied) that it does not support. However, an 1162 MTA MUST remove such a header field if the [SMTP] connection relaying 1163 the message is not from a trusted internal MTA. This means the MTA 1164 needs to be able to understand versions of this header field at least 1165 as late as the ones understood by the MUAs or other consumers within 1166 its ADMD. 1168 6. IANA Considerations 1170 IANA has registered the defined header field and created two tables 1171 as described below. These registry actions were originally defined 1172 by [RFC5451] and are repeated here to provide a single, current 1173 reference. 1175 6.1. The Authentication-Results Header Field 1177 [RFC5451] added the Authentication-Results header field to the IANA 1178 "Permanent Message Header Field Names" registry, per the procedure 1179 found in [IANA-HEADERS]. That entry has been updated to reference 1180 this document. The following is the registration template: 1182 Header field name: Authentication-Results 1183 Applicable protocol: mail ([MAIL]) 1184 Status: Standard 1185 Author/Change controller: IETF 1186 Specification document(s): [this RFC] 1187 Related information: 1188 Requesting review of any proposed changes and additions to 1189 this field is recommended. 1191 6.2. "Email Authentication Methods" Registry 1193 Names of message authentication methods supported by this 1194 specification are to be registered with IANA, with the exception of 1195 experimental names as described in Section 2.7.6. A registry was 1196 created by [RFC5451] for this purpose. [RFC7001] amended ther rules 1197 governing that registry, and also added a "version" field to the 1198 registry. 1200 New entries are assigned only for values that have received Expert 1201 Review, per [IANA-CONSIDERATIONS]. The designated expert shall be 1202 appointed by the IESG. The designated expert has discretion to 1203 request that a publication be referenced if a clear, concise 1204 definition of the authentication method cannot be provided such that 1205 interoperability is assured. Registrations should otherwise be 1206 permitted. The designated expert can also handle requests to mark 1207 any current registration as "deprecated". 1209 Each method must register a name, the specification that defines it, 1210 a version number associated with the method being registered 1211 (preferably starting at "1"), zero or more "ptype" values appropriate 1212 for use with that method, which "property" value(s) should be 1213 reported by that method, and a description of the "value" to be used 1214 with each. 1216 All existing registry entries that reference [RFC7001] are to be 1217 updated to reference this document, except where entries have already 1218 been deprecated. 1220 6.3. "Email Authentication Result Names" Registry 1222 Names of message authentication result codes supported by this 1223 specification must be registered with IANA, with the exception of 1224 experimental codes as described in Section 2.7.7. A registry was 1225 created by [RFC5451] for this purpose. [RFC7001] updated the rules 1226 governing that registry. 1228 New entries are assigned only for values that have received Expert 1229 Review, per [IANA-CONSIDERATIONS]. The designated expert shall be 1230 appointed by the IESG. The designated expert has discretion to 1231 request that a publication be referenced if a clear, concise 1232 definition of the authentication result cannot be provided such that 1233 interoperability is assured. Registrations should otherwise be 1234 permitted. The designated expert can also handle requests to mark 1235 any current registration as "deprecated". 1237 All existing registry entries that reference [RFC7001] are to be 1238 updated to reference this document. 1240 The definitions for the SPF and Sender ID authentication methods are 1241 updated using the references found in Section 2.7.2. 1243 7. Security Considerations 1245 The following security considerations apply when adding or processing 1246 the Authentication-Results header field: 1248 7.1. Forged Header Fields 1250 An MUA or filter that accesses a mailbox whose messages are handled 1251 by a non-conformant MTA, and understands Authentication-Results 1252 header fields, could potentially make false conclusions based on 1253 forged header fields. A malicious user or agent could forge a header 1254 field using the DNS domain of a receiving ADMD as the authserv-id 1255 token in the value of the header field and, with the rest of the 1256 value, claim that the message was properly authenticated. The non- 1257 conformant MTA would fail to strip the forged header field, and the 1258 MUA could inappropriately trust it. 1260 For this reason, it is best not to have processing of the 1261 Authentication-Results header field enabled by default; instead, it 1262 should be ignored, at least for the purposes of enacting filtering 1263 decisions, unless specifically enabled by the user or administrator 1264 after verifying that the border MTA is compliant. It is acceptable 1265 to have an MUA aware of this specification but have an explicit list 1266 of hostnames whose Authentication-Results header fields are 1267 trustworthy; however, this list should initially be empty. 1269 Proposed alternative solutions to this problem were made some time 1270 ago and are listed below. To date, they have not been developed due 1271 to lack of demand but are documented here should the information be 1272 useful at some point in the future: 1274 1. Possibly the simplest is a digital signature protecting the 1275 header field, such as using [DKIM], that can be verified by an 1276 MUA by using a posted public key. Although one of the main 1277 purposes of this document is to relieve the burden of doing 1278 message authentication work at the MUA, this only requires that 1279 the MUA learn a single authentication scheme even if a number of 1280 them are in use at the border MTA. Note that [DKIM] requires 1281 that the From header field be signed, although in this 1282 application, the signing agent (a trusted MTA) likely cannot 1283 authenticate that value, so the fact that it is signed should be 1284 ignored. Where the authserv-id is the ADMD's domain name, the 1285 authserv-id matching this valid internal signature's "d=" DKIM 1286 value is sufficient. 1288 2. Another would be a means to interrogate the MTA that added the 1289 header field to see if it is actually providing any message 1290 authentication services and saw the message in question, but this 1291 isn't especially palatable given the work required to craft and 1292 implement such a scheme. 1294 3. Yet another might be a method to interrogate the internal MTAs 1295 that apparently handled the message (based on Received header 1296 fields) to determine whether any of them conform to Section 5 of 1297 this memo. This, too, has potentially high barriers to entry. 1299 4. Extensions to [IMAP], [SMTP], and [POP3] could be defined to 1300 allow an MUA or filtering agent to acquire the authserv-id in use 1301 within an ADMD, thus allowing it to identify which 1302 Authentication-Results header fields it can trust. 1304 5. On the presumption that internal MTAs are fully compliant with 1305 Section 3.6 of [MAIL] and the compliant internal MTAs are using 1306 their own hostnames or the ADMD's DNS domain name as the 1307 authserv-id token, the header field proposed here should always 1308 appear above a Received header added by a trusted MTA. This can 1309 be used as a test for header field validity. 1311 Support for some of these is being considered for future work. 1313 In any case, a mechanism needs to exist for an MUA or filter to 1314 verify that the host that appears to have added the header field (a) 1315 actually did so and (b) is legitimately adding that header field for 1316 this delivery. Given the variety of messaging environments deployed 1317 today, consensus appears to be that specifying a particular mechanism 1318 for doing so is not appropriate for this document. 1320 Mitigation of the forged header field attack can also be accomplished 1321 by moving the authentication results data into metadata associated 1322 with the message. In particular, an [SMTP] extension could be 1323 established to communicate authentication results from the border MTA 1324 to intermediate and delivery MTAs; the latter of these could arrange 1325 to store the authentication results as metadata retrieved and 1326 rendered along with the message by an [IMAP] client aware of a 1327 similar extension in that protocol. The delivery MTA would be told 1328 to trust data via this extension only from MTAs it trusts, and border 1329 MTAs would not accept data via this extension from any source. There 1330 is no vector in such an arrangement for forgery of authentication 1331 data by an outside agent. 1333 7.2. Misleading Results 1335 Until some form of service for querying the reputation of a sending 1336 agent is widely deployed, the existence of this header field 1337 indicating a "pass" does not render the message trustworthy. It is 1338 possible for an arriving piece of spam or other undesirable mail to 1339 pass checks by several of the methods enumerated above (e.g., a piece 1340 of spam signed using [DKIM] by the originator of the spam, which 1341 might be a spammer or a compromised system). In particular, this 1342 issue is not resolved by forged header field removal discussed above. 1344 Hence, MUAs and downstream filters must take some care with use of 1345 this header even after possibly malicious headers are scrubbed. 1347 7.3. Header Field Position 1349 Despite the requirements of [MAIL], header fields can sometimes be 1350 reordered en route by intermediate MTAs. The goal of requiring 1351 header field addition only at the top of a message is an 1352 acknowledgement that some MTAs do reorder header fields, but most do 1353 not. Thus, in the general case, there will be some indication of 1354 which MTAs (if any) handled the message after the addition of the 1355 header field defined here. 1357 7.4. Reverse IP Query Denial-of-Service Attacks 1359 Section 4.6.4 of [SPF] describes a DNS-based denial-of-service attack 1360 for verifiers that attempt DNS-based identity verification of 1361 arriving client connections. A verifier wishing to do this check and 1362 report this information needs to take care not to go to unbounded 1363 lengths to resolve "A" and "PTR" queries. MUAs or other filters 1364 making use of an "iprev" result specified by this document need to be 1365 aware of the algorithm used by the verifier reporting the result and, 1366 especially, its limitations. 1368 7.5. Mitigation of Backscatter 1370 Failing to follow the instructions of Section 4.2 can result in a 1371 denial-of-service attack caused by the generation of [DSN] messages 1372 (or equivalent) to addresses that did not send the messages being 1373 rejected. 1375 7.6. Internal MTA Lists 1377 Section 5 describes a procedure for scrubbing header fields that may 1378 contain forged authentication results about a message. A compliant 1379 installation will have to include, at each MTA, a list of other MTAs 1380 known to be compliant and trustworthy. Failing to keep this list 1381 current as internal infrastructure changes may expose an ADMD to 1382 attack. 1384 7.7. Attacks against Authentication Methods 1386 If an attack becomes known against an authentication method, clearly 1387 then the agent verifying that method can be fooled into thinking an 1388 inauthentic message is authentic, and thus the value of this header 1389 field can be misleading. It follows that any attack against the 1390 authentication methods supported by this document is also a security 1391 consideration here. 1393 7.8. Intentionally Malformed Header Fields 1395 It is possible for an attacker to add an Authentication-Results 1396 header field that is extraordinarily large or otherwise malformed in 1397 an attempt to discover or exploit weaknesses in header field parsing 1398 code. Implementers must thoroughly verify all such header fields 1399 received from MTAs and be robust against intentionally as well as 1400 unintentionally malformed header fields. 1402 7.9. Compromised Internal Hosts 1404 An internal MUA or MTA that has been compromised could generate mail 1405 with a forged From header field and a forged Authentication-Results 1406 header field that endorses it. Although it is clearly a larger 1407 concern to have compromised internal machines than it is to prove the 1408 value of this header field, this risk can be mitigated by arranging 1409 that internal MTAs will remove this header field if it claims to have 1410 been added by a trusted border MTA (as described above), yet the 1411 [SMTP] connection is not coming from an internal machine known to be 1412 running an authorized MTA. However, in such a configuration, 1413 legitimate MTAs will have to add this header field when legitimate 1414 internal-only messages are generated. This is also covered in 1415 Section 5. 1417 7.10. Encapsulated Instances 1419 MIME messages can contain attachments of type "message/rfc822", which 1420 contain other messages. Such an encapsulated message can also 1421 contain an Authentication-Results header field. Although the 1422 processing of these is outside of the intended scope of this document 1423 (see Section 1.3), some early guidance to MUA developers is 1424 appropriate here. 1426 Since MTAs are unlikely to strip Authentication-Results header fields 1427 after mailbox delivery, MUAs are advised in Section 4.1 to ignore 1428 such instances within MIME attachments. Moreover, when extracting a 1429 message digest to separate mail store messages or other media, such 1430 header fields should be removed so that they will never be 1431 interpreted improperly by MUAs that might later consume them. 1433 7.11. Reverse Mapping 1435 Although Section 3 of this memo includes explicit support for the 1436 "iprev" method, its value as an authentication mechanism is limited. 1437 Implementers of both this proposal and agents that use the data it 1438 relays are encouraged to become familiar with the issues raised by 1439 [DNSOP-REVERSE] when deciding whether or not to include support for 1440 "iprev". 1442 8. References 1444 8.1. Normative References 1446 [ABNF] Crocker, D. and P. Overell, "Augmented BNF for 1447 Syntax Specifications: ABNF", STD 68, 1448 RFC 5234, January 2008. 1450 [IANA-HEADERS] Klyne, G., Nottingham, M., and J. Mogul, 1451 "Registration Procedures for Message Header 1452 Fields", BCP 90, RFC 3864, September 2004. 1454 [KEYWORDS] Bradner, S., "Key words for use in RFCs to 1455 Indicate Requirement Levels", BCP 14, 1456 RFC 2119. 1458 [MAIL] Resnick, P., Ed., "Internet Message Format", 1459 RFC 5322, October 2008. 1461 [MIME] Freed, N. and N. Borenstein, "Multipurpose 1462 Internet Mail Extensions (MIME) Part One: 1463 Format of Internet Message Bodies", RFC 2045, 1464 November 1996. 1466 [SMTP] Klensin, J., "Simple Mail Transfer Protocol", 1467 RFC 5321, October 2008. 1469 8.2. Informative References 1471 [ADSP] Allman, E., Fenton, J., Delany, M., and J. 1472 Levine, "DomainKeys Identified Mail (DKIM) 1473 Author Domain Signing Practices (ADSP)", 1474 RFC 5617, August 2009. 1476 [AR-VBR] Kucherawy, M., "Authentication-Results 1477 Registration for Vouch by Reference Results", 1478 RFC 6212, April 2011. 1480 [ATPS] Kucherawy, M., "DomainKeys Identified Mail 1481 (DKIM) Authorized Third-Party Signatures", 1482 RFC 6541, February 2012. 1484 [AUTH] Siemborski, R. and A. Melnikov, "SMTP Service 1485 Extension for Authentication", RFC 4954, 1486 July 2007. 1488 [DKIM] Crocker, D., Hansen, T., and M. Kucherawy, 1489 "DomainKeys Identified Mail (DKIM) 1490 Signatures", STD 76, RFC 6376, September 2011. 1492 [DNS] Mockapetris, P., "Domain names - 1493 Implementation and Specification", STD 13, 1494 RFC 1035, November 1987. 1496 [DNS-IP6] Thomson, S., Huitema, C., Ksinant, V., and M. 1497 Souissi, "DNS Extensions to Support IP Version 1498 6", RFC 3596, October 2003. 1500 [DNSOP-REVERSE] Senie, D. and A. Sullivan, "Considerations for 1501 the use of DNS Reverse Mapping", Work 1502 in Progress, March 2008. 1504 [DOMAINKEYS] Delany, M., "Domain-Based Email Authentication 1505 Using Public Keys Advertised in the DNS 1506 (DomainKeys)", RFC 4870, May 2007. 1508 [DSN] Moore, K. and G. Vaudreuil, "An Extensible 1509 Message Format for Delivery Status 1510 Notifications", RFC 3464, January 2003. 1512 [EMAIL-ARCH] Crocker, D., "Internet Mail Architecture", 1513 RFC 5598, July 2009. 1515 [IANA-CONSIDERATIONS] Narten, T. and H. Alvestrand, "Guidelines for 1516 Writing an IANA Considerations Section in 1517 RFCs", BCP 26, RFC 5226, May 2008. 1519 [IMAP] Crispin, M., "INTERNET MESSAGE ACCESS PROTOCOL 1520 - VERSION 4rev1", RFC 3501, March 2003. 1522 [POP3] Myers, J. and M. Rose, "Post Office Protocol - 1523 Version 3", STD 53, RFC 1939, May 1996. 1525 [PTYPES-REGISTRY] Kucherawy, M., "A Property Types Registry for 1526 the Authentication-Results Header Field", 1527 RFC 7410, December 2014. 1529 [RFC5451] Kucherawy, M., "Message Header Field for 1530 Indicating Message Authentication Status", 1531 RFC 5451, April 2009. 1533 [RFC7001] Kucherawy, M., "Message Header Field for 1534 Indicating Message Authentication Status", 1535 RFC 7001, September 2013. 1537 [SECURITY] Rescorla, E. and B. Korver, "Guidelines for 1538 Writing RFC Text on Security Considerations", 1539 BCP 72, RFC 3552, July 2003. 1541 [SENDERID] Lyon, J. and M. Wong, "Sender ID: 1542 Authenticating E-Mail", RFC 4406, April 2006. 1544 [SPF] Kitterman, S., "Sender Policy Framework (SPF) 1545 for Authorizing Use of Domains in E-Mail, 1546 Version 1", RFC 7208, April 2014. 1548 [VBR] Hoffman, P., Levine, J., and A. Hathcock, 1549 "Vouch By Reference", RFC 5518, April 2009. 1551 Appendix A. Acknowledgements 1553 The author wishes to acknowledge the following individuals for their 1554 review and constructive criticism of this document: (names) 1556 Appendix B. Legacy MUAs 1558 Implementers of this protocol should be aware that many MUAs are 1559 unlikely to be retrofitted to support the new header field and its 1560 semantics. In the interests of convenience and quicker adoption, a 1561 delivery MTA might want to consider adding things that are processed 1562 by existing MUAs in addition to the Authentication-Results header 1563 field. One suggestion is to include a Priority header field, on 1564 messages that don't already have such a header field, containing a 1565 value that reflects the strength of the authentication that was 1566 accomplished, e.g., "low" for weak or no authentication, "normal" or 1567 "high" for good or strong authentication. 1569 Some modern MUAs can already filter based on the content of this 1570 header field. However, there is keen interest in having MUAs make 1571 some kind of graphical representation of this header field's meaning 1572 to end users. Until this capability is added, other interim means of 1573 conveying authentication results may be necessary while this proposal 1574 and its successors are adopted. 1576 Appendix C. Authentication-Results Examples 1578 This section presents some examples of the use of this header field 1579 to indicate authentication results. 1581 C.1. Trivial Case; Header Field Not Present 1583 The trivial case: 1585 Received: from mail-router.example.com 1586 (mail-router.example.com [192.0.2.1]) 1587 by server.example.org (8.11.6/8.11.6) 1588 with ESMTP id g1G0r1kA003489; 1589 Fri, Feb 15 2002 17:19:07 -0800 1590 From: sender@example.com 1591 Date: Fri, Feb 15 2002 16:54:30 -0800 1592 To: receiver@example.org 1593 Message-Id: <12345.abc@example.com> 1594 Subject: here's a sample 1596 Hello! Goodbye! 1598 Example 1: Trivial Case 1600 The Authentication-Results header field is completely absent. The 1601 MUA may make no conclusion about the validity of the message. This 1602 could be the case because the message authentication services were 1603 not available at the time of delivery, or no service is provided, or 1604 the MTA is not in compliance with this specification. 1606 C.2. Nearly Trivial Case; Service Provided, but No Authentication Done 1608 A message that was delivered by an MTA that conforms to this 1609 specification but provides no actual message authentication service: 1611 Authentication-Results: example.org 1; none 1612 Received: from mail-router.example.com 1613 (mail-router.example.com [192.0.2.1]) 1614 by server.example.org (8.11.6/8.11.6) 1615 with ESMTP id g1G0r1kA003489; 1616 Fri, Feb 15 2002 17:19:07 -0800 1617 From: sender@example.com 1618 Date: Fri, Feb 15 2002 16:54:30 -0800 1619 To: receiver@example.org 1620 Message-Id: <12345.abc@example.com> 1621 Subject: here's a sample 1623 Hello! Goodbye! 1625 Example 2: Header Present but No Authentication Done 1627 The Authentication-Results header field is present, showing that the 1628 delivering MTA conforms to this specification. It used its DNS 1629 domain name as the authserv-id. The presence of "none" (and the 1630 absence of any method and result tokens) indicates that no message 1631 authentication was done. The version number of the specification to 1632 which the field's content conforms is explicitly provided. 1634 C.3. Service Provided, Authentication Done 1636 A message that was delivered by an MTA that conforms to this 1637 specification and applied some message authentication: 1639 Authentication-Results: example.com; 1640 spf=pass smtp.mailfrom=example.net 1641 Received: from dialup-1-2-3-4.example.net 1642 (dialup-1-2-3-4.example.net [192.0.2.200]) 1643 by mail-router.example.com (8.11.6/8.11.6) 1644 with ESMTP id g1G0r1kA003489; 1645 Fri, Feb 15 2002 17:19:07 -0800 1646 From: sender@example.net 1647 Date: Fri, Feb 15 2002 16:54:30 -0800 1648 To: receiver@example.com 1649 Message-Id: <12345.abc@example.net> 1650 Subject: here's a sample 1652 Hello! Goodbye! 1654 Example 3: Header Reporting Results 1656 The Authentication-Results header field is present, indicating that 1657 the border MTA conforms to this specification. The authserv-id is 1658 once again the DNS domain name. Furthermore, the message was 1659 authenticated by that MTA via the method specified in [SPF]. Note 1660 that since that method cannot authenticate the local-part, it has 1661 been omitted from the result's value. The MUA could extract and 1662 relay this extra information if desired. 1664 C.4. Service Provided, Several Authentications Done, Single MTA 1666 A message that was relayed inbound via a single MTA that conforms to 1667 this specification and applied three different message authentication 1668 checks: 1670 Authentication-Results: example.com; 1671 auth=pass (cram-md5) smtp.auth=sender@example.net; 1672 spf=pass smtp.mailfrom=example.net 1673 Authentication-Results: example.com; 1674 sender-id=pass header.from=example.net 1675 Received: from dialup-1-2-3-4.example.net (8.11.6/8.11.6) 1676 (dialup-1-2-3-4.example.net [192.0.2.200]) 1677 by mail-router.example.com (8.11.6/8.11.6) 1678 with ESMTP id g1G0r1kA003489; 1679 Fri, Feb 15 2002 17:19:07 -0800 1680 Date: Fri, Feb 15 2002 16:54:30 -0800 1681 To: receiver@example.com 1682 From: sender@example.net 1683 Message-Id: <12345.abc@example.net> 1684 Subject: here's a sample 1686 Hello! Goodbye! 1688 Example 4: Headers Reporting Results from One MTA 1690 The Authentication-Results header field is present, indicating that 1691 the delivering MTA conforms to this specification. Once again, the 1692 receiving DNS domain name is used as the authserv-id. Furthermore, 1693 the sender authenticated herself/himself to the MTA via a method 1694 specified in [AUTH], and both SPF and Sender ID checks were done and 1695 passed. The MUA could extract and relay this extra information if 1696 desired. 1698 Two Authentication-Results header fields are not required since the 1699 same host did all of the checking. The authenticating agent could 1700 have consolidated all the results into one header field. 1702 This example illustrates a scenario in which a remote user on a 1703 dialup connection (example.net) sends mail to a border MTA 1704 (example.com) using SMTP authentication to prove identity. The 1705 dialup provider has been explicitly authorized to relay mail as 1706 example.com resulting in passes by the SPF and Sender ID checks. 1708 C.5. Service Provided, Several Authentications Done, Different MTAs 1710 A message that was relayed inbound by two different MTAs that conform 1711 to this specification and applied multiple message authentication 1712 checks: 1714 Authentication-Results: example.com; 1715 sender-id=fail header.from=example.com; 1716 dkim=pass (good signature) header.d=example.com 1717 Received: from mail-router.example.com 1718 (mail-router.example.com [192.0.2.1]) 1719 by auth-checker.example.com (8.11.6/8.11.6) 1720 with ESMTP id i7PK0sH7021929; 1721 Fri, Feb 15 2002 17:19:22 -0800 1722 DKIM-Signature: v=1; a=rsa-sha256; s=gatsby; d=example.com; 1723 t=1188964191; c=simple/simple; h=From:Date:To:Subject: 1724 Message-Id:Authentication-Results; 1725 bh=sEuZGD/pSr7ANysbY3jtdaQ3Xv9xPQtS0m70; 1726 b=EToRSuvUfQVP3Bkz ... rTB0t0gYnBVCM= 1727 Authentication-Results: example.com; 1728 auth=pass (cram-md5) smtp.auth=sender@example.com; 1729 spf=fail smtp.mailfrom=example.com 1730 Received: from dialup-1-2-3-4.example.net 1731 (dialup-1-2-3-4.example.net [192.0.2.200]) 1732 by mail-router.example.com (8.11.6/8.11.6) 1733 with ESMTP id g1G0r1kA003489; 1734 Fri, Feb 15 2002 17:19:07 -0800 1735 From: sender@example.com 1736 Date: Fri, Feb 15 2002 16:54:30 -0800 1737 To: receiver@example.com 1738 Message-Id: <12345.abc@example.com> 1739 Subject: here's a sample 1741 Hello! Goodbye! 1743 Example 5: Headers Reporting Results from Multiple MTAs 1745 The Authentication-Results header field is present, indicating 1746 conformance to this specification. Once again, the authserv-id used 1747 is the recipient's DNS domain name. The header field is present 1748 twice because two different MTAs in the chain of delivery did 1749 authentication tests. The first MTA, mail-router.example.com, 1750 reports that SMTP AUTH and SPF were both used and that the former 1751 passed while the latter failed. In the SMTP AUTH case, additional 1752 information is provided in the comment field, which the MUA can 1753 choose to render if desired. 1755 The second MTA, auth-checker.example.com, reports that it did a 1756 Sender ID test (which failed) and a DKIM test (which passed). Again, 1757 additional data about one of the tests is provided as a comment, 1758 which the MUA may choose to render. Also noteworthy here is the fact 1759 that there is a DKIM signature added by example.com that assured the 1760 integrity of the lower Authentication-Results field. 1762 Since different hosts did the two sets of authentication checks, the 1763 header fields cannot be consolidated in this example. 1765 This example illustrates more typical transmission of mail into 1766 example.com from a user on a dialup connection example.net. The user 1767 appears to be legitimate as he/she had a valid password allowing 1768 authentication at the border MTA using SMTP AUTH. The SPF and Sender 1769 ID tests failed since example.com has not granted example.net 1770 authority to relay mail on its behalf. However, the DKIM test passed 1771 because the sending user had a private key matching one of 1772 example.com's published public keys and used it to sign the message. 1774 C.6. Service Provided, Multi-Tiered Authentication Done 1776 A message that had authentication done at various stages, one of 1777 which was outside the receiving ADMD: 1779 Authentication-Results: example.com; 1780 dkim=pass reason="good signature" 1781 header.i=@mail-router.example.net; 1782 dkim=fail reason="bad signature" 1783 header.i=@newyork.example.com 1784 Received: from mail-router.example.net 1785 (mail-router.example.net [192.0.2.250]) 1786 by chicago.example.com (8.11.6/8.11.6) 1787 for 1788 with ESMTP id i7PK0sH7021929; 1789 Fri, Feb 15 2002 17:19:22 -0800 1790 DKIM-Signature: v=1; a=rsa-sha256; s=furble; 1791 d=mail-router.example.net; t=1188964198; c=relaxed/simple; 1792 h=From:Date:To:Message-Id:Subject:Authentication-Results; 1793 bh=ftA9J6GtX8OpwUECzHnCkRzKw1uk6FNiLfJl5Nmv49E=; 1794 b=oINEO8hgn/gnunsg ... 9n9ODSNFSDij3= 1795 Authentication-Results: example.net; 1796 dkim=pass (good signature) header.i=@newyork.example.com 1797 Received: from smtp.newyork.example.com 1798 (smtp.newyork.example.com [192.0.2.220]) 1799 by mail-router.example.net (8.11.6/8.11.6) 1800 with ESMTP id g1G0r1kA003489; 1801 Fri, Feb 15 2002 17:19:07 -0800 1802 DKIM-Signature: v=1; a=rsa-sha256; s=gatsby; 1803 d=newyork.example.com; 1804 t=1188964191; c=simple/simple; 1805 h=From:Date:To:Message-Id:Subject; 1806 bh=sEu28nfs9fuZGD/pSr7ANysbY3jtdaQ3Xv9xPQtS0m7=; 1807 b=EToRSuvUfQVP3Bkz ... rTB0t0gYnBVCM= 1808 From: sender@newyork.example.com 1809 Date: Fri, Feb 15 2002 16:54:30 -0800 1810 To: meetings@example.net 1811 Message-Id: <12345.abc@newyork.example.com> 1812 Subject: here's a sample 1814 Example 6: Headers Reporting Results from Multiple MTAs in Different 1815 ADMDs 1817 In this example, we see multi-tiered authentication with an extended 1818 trust boundary. 1820 The message was sent from someone at example.com's New York office 1821 (newyork.example.com) to a mailing list managed at an intermediary. 1823 The message was signed at the origin using DKIM. 1825 The message was sent to a mailing list service provider called 1826 example.net, which is used by example.com. There, 1827 meetings@example.net is expanded to a long list of recipients, one of 1828 whom is at the Chicago office. In this example, we will assume that 1829 the trust boundary for chicago.example.com includes the mailing list 1830 server at example.net. 1832 The mailing list server there first authenticated the message and 1833 affixed an Authentication-Results header field indicating such using 1834 its DNS domain name for the authserv-id. It then altered the message 1835 by affixing some footer text to the body, including some 1836 administrivia such as unsubscription instructions. Finally, the 1837 mailing list server affixes a second DKIM signature and begins 1838 distribution of the message. 1840 The border MTA for chicago.example.com explicitly trusts results from 1841 mail-router.example.net, so that header field is not removed. It 1842 performs evaluation of both signatures and determines that the first 1843 (most recent) is a "pass" but, because of the aforementioned 1844 modifications, the second is a "fail". However, the first signature 1845 included the Authentication-Results header added at mail- 1846 router.example.net that validated the second signature. Thus, 1847 indirectly, it can be determined that the authentications claimed by 1848 both signatures are indeed valid. 1850 Note that two styles of presenting metadata about the result are in 1851 use here. In one case, the "reason=" clause is present, which is 1852 intended for easy extraction by parsers; in the other case, the CFWS 1853 production of the ABNF is used to include such data as a header field 1854 comment. The latter can be harder for parsers to extract given the 1855 varied supported syntaxes of mail header fields. 1857 C.7. Comment-Heavy Example 1859 The formal syntax permits comments within the content in a number of 1860 places. For the sake of illustration, this example is also legal: 1862 Authentication-Results: foo.example.net (foobar) 1 (baz); 1863 dkim (Because I like it) / 1 (One yay) = (wait for it) fail 1864 policy (A dot can go here) . (like that) expired 1865 (this surprised me) = (as I wasn't expecting it) 1362471462 1867 Example 7: A Very Comment-Heavy but Perfectly Legal Example 1869 Appendix D. Operational Considerations about Message Authentication 1871 This protocol is predicated on the idea that authentication (and 1872 presumably in the future, reputation) work is typically done by 1873 border MTAs rather than MUAs or intermediate MTAs; the latter merely 1874 make use of the results determined by the former. Certainly this is 1875 not mandatory for participation in electronic mail or message 1876 authentication, but this protocol and its deployment to date are 1877 based on that model. The assumption satisfies several common ADMD 1878 requirements: 1880 1. Service operators prefer to resolve the handling of problem 1881 messages as close to the border of the ADMD as possible. This 1882 enables, for example, rejection of messages at the SMTP level 1883 rather than generating a DSN internally. Thus, doing any of the 1884 authentication or reputation work exclusively at the MUA or 1885 intermediate MTA renders this desire unattainable. 1887 2. Border MTAs are more likely to have direct access to external 1888 sources of authentication or reputation information since modern 1889 MUAs are more likely to be heavily firewalled. Thus, some MUAs 1890 might not even be able to complete the task of performing 1891 authentication or reputation evaluations without complex proxy 1892 configurations or similar burdens. 1894 3. MUAs rely upon the upstream MTAs within their trust boundaries to 1895 make correct (as much as is possible) evaluations about the 1896 message's envelope, header, and content. Thus, MUAs don't need 1897 to know how to do the work that upstream MTAs do; they only need 1898 the results of that work. 1900 4. Evaluations about the quality of a message, from simple token 1901 matching (e.g., a list of preferred DNS domains) to cryptanalysis 1902 (e.g., public/private key work), are at least a little bit 1903 expensive and thus need to be minimized. To that end, performing 1904 those tests at the border MTA is far preferred to doing that work 1905 at each MUA that handles a message. If an ADMD's environment 1906 adheres to common messaging protocols, a reputation query or an 1907 authentication check performed by a border MTA would return the 1908 same result as the same query performed by an MUA. By contrast, 1909 in an environment where the MUA does the work, a message arriving 1910 for multiple recipients would thus cause authentication or 1911 reputation evaluation to be done more than once for the same 1912 message (i.e., at each MUA), causing needless amplification of 1913 resource use and creating a possible denial-of-service attack 1914 vector. 1916 5. Minimizing change is good. As new authentication and reputation 1917 methods emerge, the list of methods supported by this header 1918 field would presumably be extended. If MUAs simply consume the 1919 contents of this header field rather than actually attempt to do 1920 authentication and/or reputation work, then MUAs only need to 1921 learn to parse this header field once; emergence of new methods 1922 requires only a configuration change at the MUAs and software 1923 changes at the MTAs (which are presumably fewer in number). When 1924 choosing to implement these functions in MTAs vs. MUAs, the 1925 issues of individual flexibility, infrastructure inertia, and 1926 scale of effort must be considered. It is typically easier to 1927 change a single MUA than an MTA because the modification affects 1928 fewer users and can be pursued with less care. However, changing 1929 many MUAs is more effort than changing a smaller number of MTAs. 1931 6. For decisions affecting message delivery and display, assessment 1932 based on authentication and reputation is best performed close to 1933 the time of message transit, as a message makes its journey 1934 toward a user's inbox, not afterwards. DKIM keys and IP address 1935 reputations, etc., can change over time or even become invalid, 1936 and users can take a long time to read a message once delivered. 1937 The value of this work thus degrades, perhaps quickly, once the 1938 delivery process has completed. This seriously diminishes the 1939 value of this work when done other than at MTAs. 1941 Many operational choices are possible within an ADMD, including the 1942 venue for performing authentication and/or reputation assessment. 1943 The current specification does not dictate any of those choices. 1944 Rather, it facilitates those cases in which information produced by 1945 one stage of analysis needs to be transported with the message to the 1946 next stage. 1948 Appendix E. Change History 1950 E.1. RFC7001 to -00 1952 o Remove "Changes since RFC5451" section; add this "Change History" 1953 section. 1955 o Restore XML to previous format. (No visible changes). 1957 o Reset "Acknowledgments". 1959 o Add "To-Do" section. 1961 E.2. -00 to -01 1963 o Apply RFC7410. 1965 o Update all the RFC4408 references to RFC7208. 1967 o Add section explaining "property" values. (Errata #4201) 1969 o Remove "To-Do" section. 1971 E.3. -01 to -02 1973 o Consolidate new sections. 1975 Author's Address 1977 Murray S. Kucherawy 1978 270 Upland Drive 1979 San Francisco, CA 94127 1980 US 1982 EMail: superuser@gmail.com