idnits 2.17.1 draft-ietf-uta-smtp-tlsrpt-20.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 : ---------------------------------------------------------------------------- ** There is 1 instance of too long lines in the document, the longest one being 1 character in excess of 72. == There are 1 instance of lines with non-RFC2606-compliant FQDNs in the document. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year ** The document contains RFC2119-like boilerplate, but doesn't seem to mention RFC 2119. The boilerplate contains a reference [BCP 14], but that reference does not seem to mention RFC 2119 either. -- The document date (May 2, 2018) is 2179 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: 'BCP 14' is mentioned on line 151, but not defined == Missing Reference: 'CFWS' is mentioned on line 696, but not defined == Outdated reference: A later version (-21) exists of draft-ietf-uta-mta-sts-15 ** Downref: Normative reference to an Informational RFC: RFC 1952 ** Obsolete normative reference: RFC 4408 (Obsoleted by RFC 7208) ** Obsolete normative reference: RFC 6125 (Obsoleted by RFC 9525) ** Downref: Normative reference to an Informational RFC: RFC 6713 ** Obsolete normative reference: RFC 7231 (Obsoleted by RFC 9110) -- Obsolete informational reference (is this intentional?): RFC 3501 (Obsoleted by RFC 9051) -- Obsolete informational reference (is this intentional?): RFC 7321 (Obsoleted by RFC 8221) Summary: 7 errors (**), 0 flaws (~~), 5 warnings (==), 3 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 Using TLS in Applications D. Margolis 3 Internet-Draft Google, Inc 4 Intended status: Standards Track A. Brotman 5 Expires: November 3, 2018 Comcast, Inc 6 B. Ramakrishnan 7 Yahoo!, Inc 8 J. Jones 9 Microsoft, Inc 10 M. Risher 11 Google, Inc 12 May 2, 2018 14 SMTP TLS Reporting 15 draft-ietf-uta-smtp-tlsrpt-20 17 Abstract 19 A number of protocols exist for establishing encrypted channels 20 between SMTP Mail Transfer Agents, including STARTTLS, DANE TLSA, and 21 MTA-STS. These protocols can fail due to misconfiguration or active 22 attack, leading to undelivered messages or delivery over unencrypted 23 or unauthenticated channels. This document describes a reporting 24 mechanism and format by which sending systems can share statistics 25 and specific information about potential failures with recipient 26 domains. Recipient domains can then use this information to both 27 detect potential attacks and diagnose unintentional 28 misconfigurations. 30 Status of This Memo 32 This Internet-Draft is submitted in full conformance with the 33 provisions of BCP 78 and BCP 79. 35 Internet-Drafts are working documents of the Internet Engineering 36 Task Force (IETF). Note that other groups may also distribute 37 working documents as Internet-Drafts. The list of current Internet- 38 Drafts is at http://datatracker.ietf.org/drafts/current/. 40 Internet-Drafts are draft documents valid for a maximum of six months 41 and may be updated, replaced, or obsoleted by other documents at any 42 time. It is inappropriate to use Internet-Drafts as reference 43 material or to cite them other than as "work in progress." 45 This Internet-Draft will expire on November 3, 2018. 47 Copyright Notice 49 Copyright (c) 2018 IETF Trust and the persons identified as the 50 document authors. All rights reserved. 52 This document is subject to BCP 78 and the IETF Trust's Legal 53 Provisions Relating to IETF Documents 54 (http://trustee.ietf.org/license-info) in effect on the date of 55 publication of this document. Please review these documents 56 carefully, as they describe your rights and restrictions with respect 57 to this document. Code Components extracted from this document must 58 include Simplified BSD License text as described in Section 4.e of 59 the Trust Legal Provisions and are provided without warranty as 60 described in the Simplified BSD License. 62 Table of Contents 64 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 3 65 1.1. Terminology . . . . . . . . . . . . . . . . . . . . . . . 4 66 2. Related Technologies . . . . . . . . . . . . . . . . . . . . 4 67 3. Reporting Policy . . . . . . . . . . . . . . . . . . . . . . 4 68 3.1. Example Reporting Policy . . . . . . . . . . . . . . . . 7 69 3.1.1. Report using MAILTO . . . . . . . . . . . . . . . . . 7 70 3.1.2. Report using HTTPS . . . . . . . . . . . . . . . . . 7 71 4. Reporting Schema . . . . . . . . . . . . . . . . . . . . . . 7 72 4.1. Report Time-frame . . . . . . . . . . . . . . . . . . . . 8 73 4.2. Delivery Summary . . . . . . . . . . . . . . . . . . . . 8 74 4.2.1. Success Count . . . . . . . . . . . . . . . . . . . . 8 75 4.2.2. Failure Count . . . . . . . . . . . . . . . . . . . . 8 76 4.3. Result Types . . . . . . . . . . . . . . . . . . . . . . 8 77 4.3.1. Negotiation Failures . . . . . . . . . . . . . . . . 9 78 4.3.2. Policy Failures . . . . . . . . . . . . . . . . . . . 9 79 4.3.3. General Failures . . . . . . . . . . . . . . . . . . 10 80 4.3.4. Transient Failures . . . . . . . . . . . . . . . . . 10 81 4.4. JSON Report Schema . . . . . . . . . . . . . . . . . . . 10 82 4.5. Policy Samples . . . . . . . . . . . . . . . . . . . . . 13 83 5. Report Delivery . . . . . . . . . . . . . . . . . . . . . . . 14 84 5.1. Report Filename . . . . . . . . . . . . . . . . . . . . . 14 85 5.2. Compression . . . . . . . . . . . . . . . . . . . . . . . 15 86 5.3. Email Transport . . . . . . . . . . . . . . . . . . . . . 15 87 5.3.1. Example Report . . . . . . . . . . . . . . . . . . . 16 88 5.4. HTTPS Transport . . . . . . . . . . . . . . . . . . . . . 17 89 5.5. Delivery Retry . . . . . . . . . . . . . . . . . . . . . 18 90 5.6. Metadata Variances . . . . . . . . . . . . . . . . . . . 18 91 6. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 18 92 6.1. Message headers . . . . . . . . . . . . . . . . . . . . . 18 93 6.2. Report Type . . . . . . . . . . . . . . . . . . . . . . . 18 94 6.3. +gzip Media Type Suffix . . . . . . . . . . . . . . . . . 19 95 6.4. application/tlsrpt+json Media Type . . . . . . . . . . . 20 96 6.5. application/tlsrpt+gzip Media Type . . . . . . . . . . . 21 97 6.6. STARTTLS Validation Result Types . . . . . . . . . . . . 22 98 7. Security Considerations . . . . . . . . . . . . . . . . . . . 22 99 8. References . . . . . . . . . . . . . . . . . . . . . . . . . 24 100 8.1. Normative References . . . . . . . . . . . . . . . . . . 24 101 8.2. Informative References . . . . . . . . . . . . . . . . . 26 102 Appendix A. Example Reporting Policy . . . . . . . . . . . . . . 27 103 A.1. Report using MAILTO . . . . . . . . . . . . . . . . . . . 27 104 A.2. Report using HTTPS . . . . . . . . . . . . . . . . . . . 27 105 Appendix B. Example JSON Report . . . . . . . . . . . . . . . . 27 106 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 29 108 1. Introduction 110 The STARTTLS extension to SMTP [RFC3207] allows SMTP clients and 111 hosts to establish secure SMTP sessions over TLS. The protocol 112 design uses an approach that has come to be known as "Opportunistic 113 Security" (OS) [RFC7435]. This method maintains interoperability 114 with clients that do not support STARTTLS, but means that any 115 attacker could potentially eavesdrop on a session. An attacker could 116 perform a downgrade or interception attack by deleting parts of the 117 SMTP session (such as the "250 STARTTLS" response) or redirect the 118 entire SMTP session (perhaps by overwriting the resolved MX record of 119 the delivery domain). 121 Because such "downgrade attacks" are not necessarily apparent to the 122 receiving MTA, this document defines a mechanism for sending domains 123 to report on failures at multiple stages of the MTA-to-MTA 124 conversation. 126 Recipient domains may also use the mechanisms defined by MTA-STS 127 [I-D.ietf-uta-mta-sts] or DANE [RFC6698] to publish additional 128 encryption and authentication requirements; this document defines a 129 mechanism for sending domains that are compatible with MTA-STS or 130 DANE to share success and failure statistics with recipient domains. 132 Specifically, this document defines a reporting schema that covers 133 failures in routing, DNS resolution, STARTTLS negotiation, and both 134 DANE [RFC6698] and MTA-STS [I-D.ietf-uta-mta-sts] policy validation 135 errors, and a standard TXT record that recipient domains can use to 136 indicate where reports in this format should be sent. The report can 137 also serve as a heartbeat that systems are successfully negotiating 138 TLS during sessions as expected. 140 This document is intended as a companion to the specification for 141 SMTP MTA Strict Transport Security [I-D.ietf-uta-mta-sts], as well as 142 adds reporting abilities for those implementing DANE [RFC7672]. 144 1.1. Terminology 146 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 147 "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and 148 "OPTIONAL" in this document are to be interpreted as described in 149 [BCP 14] [RFC2119] [RFC8174] when, and only when, they appear in all 150 capitals, as shown here. 152 We also define the following terms for further use in this document: 154 o MTA-STS Policy: A mechanism by which administrators can specify 155 the expected TLS availability, presented identity, and desired 156 actions for a given email recipient domain. MTA-STS is defined in 157 [I-D.ietf-uta-mta-sts]. 159 o DANE Policy: A mechanism by which administrators can specify 160 constraints to be used to validate certificates presented by an 161 MTA. DANE is defined in [RFC6698] and [RFC7672]. 163 o TLSRPT Policy: A policy specifying the endpoint to which sending 164 MTAs should deliver reports. 166 o Policy Domain: The domain against which an MTA-STS or DANE Policy 167 is defined. This should be the same as the recipient envelope 168 domain [RFC5321], such as if the message were going to 169 "alice@example.com', the policy domain would be "example.com". 171 o Sending MTA: The MTA initiating the relay of an email message. 173 o Aggregate Report URI (rua): A comma-separated list of locations 174 where the report is to be submitted. 176 2. Related Technologies 178 o This document is intended as a companion to the specification for 179 SMTP MTA Strict Transport Security [I-D.ietf-uta-mta-sts]. 181 o SMTP-TLSRPT defines a mechanism for sending domains that are 182 compatible with MTA-STS or DANE to share success and failure 183 statistics with recipient domains. DANE is defined in [RFC6698] 184 and MTA-STS is defined in [I-D.ietf-uta-mta-sts]. 186 3. Reporting Policy 188 A domain publishes a record to its DNS indicating that it wishes to 189 receive reports. These SMTP TLSRPT policies are distributed via DNS 190 from the Policy Domain's zone, as TXT records (similar to DMARC 191 policies) under the name "_smtp._tls". For example, for the Policy 192 Domain "example.com", the recipient's TLSRPT policy can be retrieved 193 from "_smtp._tls.example.com". 195 Policies consist of the following directives: 197 o "v": This document defines version 1 of TLSRPT, for which this 198 value MUST be equal to "TLSRPTv1". Other versions may be defined 199 in later documents. 201 o "rua": A URI specifying the endpoint to which aggregate 202 information about policy validation results should be sent (see 203 Section 4, "Reporting Schema", for more information). Two URI 204 schemes are supported: "mailto" and "https". As with DMARC 205 [RFC7489], the policy domain can specify a comma-separated list of 206 URIs. 208 o In the case of "https", reports should be submitted via POST 209 ([RFC7231]) to the specified URI. Report submitters MAY ignore 210 certificate validation errors when submitting reports via https. 212 o In the case of "mailto", reports should be submitted to the 213 specified email address ([RFC6068]). When sending failure reports 214 via SMTP, sending MTAs MUST deliver reports despite any TLS- 215 related failures and SHOULD NOT include this SMTP session in the 216 next report. When sending failure reports via HTTPS, sending MTAs 217 MAY deliver reports despite any TLS-related faliures. This may 218 mean that the reports are delivered in the clear. Reports sent 219 via SMTP MUST contain a valid DKIM [RFC6376] signature by the 220 reporting domain. Reports lacking such a signature MUST be 221 ignored by the recipient. DKIM signatures must not use the "l=" 222 attribute to limit the body length used in the signature. The 223 DKIM TXT record must contain the appropriate service type 224 declaration, "s=tlsrpt", and if not present the receiving system 225 SHOULD ignore reports signed using this record. 227 The formal definition of the "_smtp._tls" TXT record, defined using 228 [RFC5234] & [RFC7405], is as follows: 230 tlsrpt-record = tlsrpt-version 1*(field-delim tlsrpt-field) 231 [field-delim] 233 field-delim = *WSP ";" *WSP 235 tlsrpt-field = tlsrpt-rua / ; Note that the 236 tlsrpt-extension ; tlsrpt-rua record is 237 ; required. 239 tlsrpt-version = %s"v=TLSRPTv1" 241 tlsrpt-rua = %s"rua=" 242 tlsrpt-uri *(*WSP "," *WSP tlsrpt-uri) 244 tlsrpt-uri = URI 245 ; "URI" is imported from [RFC3986]; 246 ; commas (ASCII 0x2C), exclamation 247 ; points (ASCII 0x21), and semicolons 248 ; (ASCII 0x3B) MUST be encoded 250 tlsrpt-extension = tlsrpt-ext-name "=" tlsrpt-ext-value 252 tlsrpt-ext-name = (ALPHA / DIGIT) *31(ALPHA / 253 DIGIT / "_" / "-" / ".") 255 tlsrpt-ext-value = 1*(%x21-3A / %x3C / %x3E-7E) 256 ; chars excluding "=", ";", SP, and control 257 ; chars 259 If multiple TXT records for "_smtp._tls" are returned by the 260 resolver, records which do not begin with "v=TLSRPTv1;" are 261 discarded. If the number of resulting records is not one, senders 262 MUST assume the recipient domain does not implement TLSRPT. If the 263 resulting TXT record contains multiple strings (as described in 264 Section 3.1.3 of [RFC4408]), then the record MUST be treated as if 265 those strings are concatenated together without adding spaces. 267 The record supports the abillity to declare more than one rua, and if 268 there exists more than one, the reporter MAY attempt to deliver to 269 each of the supported rua destinations. A receiver MAY opt to only 270 attempt delivery to one of the endpoints, however the report SHOULD 271 NOT be considered successfully delivered until one of the endpoints 272 accepts delivery of the report. 274 Parsers MUST accept TXT records which are syntactically valid (i.e. 275 valid key-value pairs separated by semi-colons) and implementing a 276 superset of this specification, in which case unknown fields SHALL be 277 ignored. 279 3.1. Example Reporting Policy 281 3.1.1. Report using MAILTO 283 _smtp._tls.example.com. IN TXT \ 284 "v=TLSRPTv1;rua=mailto:reports@example.com" 286 3.1.2. Report using HTTPS 288 _smtp._tls.example.com. IN TXT \ 289 "v=TLSRPTv1; \ 290 rua=https://reporting.example.com/v1/tlsrpt" 292 4. Reporting Schema 294 The report is composed as a plain text file encoded in the I-JSON 295 format ([RFC7493]). 297 Aggregate reports contain the following fields: 299 o Report metadata: 301 * The organization responsible for the report 303 * Contact information for one or more responsible parties for the 304 contents of the report 306 * A unique identifier for the report 308 * The reporting date range for the report 310 o Policy, consisting of: 312 * One of the following policy types: (1) The MTA-STS policy 313 applied (as a string) (2) The DANE TLSA record applied (as a 314 string, with each RR entry of the RRset listed and separated by 315 a semicolon) (3) The literal string "no-policy-found", if 316 neither a DANE nor MTA-STS policy could be found. 318 * The domain for which the policy is applied 320 * The MX host 322 o Aggregate counts, comprising result type, sending MTA IP, 323 receiving MTA hostname, session count, and an optional additional 324 information field containing a URI for recipients to review 325 further information on a failure type. 327 Note that the failure types are non-exclusive; an aggregate report 328 may contain overlapping "counts" of failure types when a single send 329 attempt encountered multiple errors. Reporters may report multiple 330 applied policies (for example, an MTA-STS policy and a DANE TLSA 331 record for the same domain and MX). Because of this, even in the 332 case where only a single policy was applied, the "policies" field of 333 the report body MUST be an array and not a singular value. 335 In the case of multiple failure types, the "failure-details" array 336 would contain multiple entries. Each entry would have its own set of 337 infomation pertaining to that failure type. 339 4.1. Report Time-frame 341 The report SHOULD cover a full day, from 0000-2400 UTC. This should 342 allow for easier correlation of failure events. To avoid a Denial of 343 Service against the system processing the reports, the reports should 344 be delivered after some delay, perhaps several hours. 346 4.2. Delivery Summary 348 4.2.1. Success Count 350 o "total-successful-session-count": This indicates that the sending 351 MTA was able to successfully negotiate a policy-compliant TLS 352 connection, and serves to provide a "heartbeat" to receiving 353 domains that reporting is functional and tabulating correctly. 354 This field contains an aggregate count of successful connections 355 for the reporting system. 357 4.2.2. Failure Count 359 o "total-failure-session-count": This indicates that the sending MTA 360 was unable to successfully establish a connection with the 361 receiving platform. Section 4.3, "Result Types", will elaborate 362 on the failed negotiation attempts. This field contains an 363 aggregate count of failed connections. 365 4.3. Result Types 367 The list of result types will start with the minimal set below, and 368 is expected to grow over time based on real-world experience. The 369 initial set is: 371 4.3.1. Negotiation Failures 373 o "starttls-not-supported": This indicates that the recipient MX did 374 not support STARTTLS. 376 o "certificate-host-mismatch": This indicates that the certificate 377 presented did not adhere to the constraints specified in the MTA- 378 STS or DANE policy, e.g. if the MX hostname does not match any 379 identities listed in the Subject Alternate Name (SAN) [RFC5280]. 381 o "certificate-expired": This indicates that the certificate has 382 expired. 384 o "certificate-not-trusted": This a label that covers multiple 385 certificate related failures that include, but not limited to 386 errors such as untrusted/unknown CAs, certificate name 387 constraints, certificate chain errors etc. When using this 388 declaration, the reporting MTA SHOULD utilize the "failure-reason- 389 code" to provide more information to the receiving entity. 391 o "validation-failure": This indicates a general failure for a 392 reason not matching a category above. When using this 393 declaration, the reporting MTA SHOULD utilize the "failure-reason- 394 code" to provide more information to the receiving entity. 396 4.3.2. Policy Failures 398 4.3.2.1. DANE-specific Policy Failures 400 o "tlsa-invalid": This indicates a validation error in the TLSA 401 record associated with a DANE policy. None of the records in the 402 RRset were found to be valid. 404 o "dnssec-invalid": This would indicate that no valid records were 405 returned from the recursive resolver. The request returned with 406 SERVFAIL for the requested TLSA record. 408 o "dane-required": This indicates that the sending system is 409 configured to require DANE TLSA records for all the MX hosts of 410 the destination domain, but no DNSSEC-validated TLSA records were 411 present for the MX host that is the subject of the report. 412 Mandatory DANE for SMTP is described in section 6 of [RFC7672]. 413 Such policies may be created by mutual agreement between two 414 organizations that frequently exchange sensitive content via 415 email. 417 4.3.2.2. MTA-STS-specific Policy Failures 419 o "sts-policy-invalid": This indicates a validation error for the 420 overall MTA-STS policy. 422 o "sts-webpki-invalid": This indicates that the MTA-STS policy could 423 not be authenticated using PKIX validation. 425 4.3.3. General Failures 427 When a negotiation failure can not be categorized into one of the 428 "Negotiation Failures" stated above, the reporter SHOULD use the 429 "validation-failure" category. As TLS grows and becomes more 430 complex, new mechanisms may not be easily categorized. This allows 431 for a generic feedback category. When this category is used, the 432 reporter SHOULD also use the "failure-reason-code" to give some 433 feedback to the receiving entity. This is intended to be a short 434 text field, and the contents of the field should be an error code or 435 error text, such as "X509_V_ERR_UNHANDLED_CRITICAL_CRL_EXTENSION". 437 4.3.4. Transient Failures 439 Transient errors due to too-busy network, TCP timeouts, etc. are not 440 required to be reported. 442 4.4. JSON Report Schema 444 The JSON schema is derived from the HPKP JSON schema [RFC7469] (cf. 445 Section 3) 447 { 448 "organization-name": organization-name, 449 "date-range": { 450 "start-datetime": date-time, 451 "end-datetime": date-time 452 }, 453 "contact-info": email-address, 454 "report-id": report-id, 455 "policies": [{ 456 "policy": { 457 "policy-type": policy-type, 458 "policy-string": policy-string, 459 "policy-domain": domain, 460 "mx-host": mx-host-pattern 461 }, 462 "summary": { 463 "total-successful-session-count": total-successful-session-count, 464 "total-failure-session-count": total-failure-session-count 465 }, 466 "failure-details": [ 467 { 468 "result-type": result-type, 469 "sending-mta-ip": ip-address, 470 "receiving-mx-hostname": receiving-mx-hostname, 471 "receiving-mx-helo": receiving-mx-helo, 472 "receiving-ip": receiving-ip, 473 "failed-session-count": failed-session-count, 474 "additional-information": additional-info-uri, 475 "failure-reason-code": failure-reason-code 476 } 477 ] 478 } 479 ] 480 } 482 JSON Report Format 484 o "organization-name": The name of the organization responsible for 485 the report. It is provided as a string. 487 o "date-time": The date-time indicates the start- and end-times for 488 the report range. It is provided as a string formatted according 489 to Section 5.6, "Internet Date/Time Format", of [RFC3339]. The 490 report should be for a full UTC day, 0000-2400. 492 o "email-address": The contact information for a responsible party 493 of the report. It is provided as a string formatted according to 494 Section 3.4.1, "Addr-Spec", of [RFC5321]. 496 o "report-id": A unique identifier for the report. Report authors 497 may use whatever scheme they prefer to generate a unique 498 identifier. It is provided as a string. 500 o "policy-type": The type of policy that was applied by the sending 501 domain. Presently, the only three valid choices are "tlsa", 502 "sts", and the literal string "no-policy-found". It is provided 503 as a string. 505 o "policy-string": An encoding of the applied policy as a JSON array 506 of strings, whether TLSA record ([RFC6698] section 2.3) or MTA-STS 507 policy. Examples follow in the next section. 509 o "domain": The Policy Domain is the domain against which the MTA- 510 STS or DANE policy is defined. In the case of Internationalized 511 Domain Names ([RFC5891]), the domain MUST consist of the Punycode- 512 encoded A-labels ([RFC3492]) and not the U-labels. 514 o "mx-host-pattern": The pattern of MX hostnames from the applied 515 policy. It is provided as a string, and is interpreted in the 516 same manner as the "Checking of Wildcard Certificates" rules in 517 Section 6.4.3 of [RFC6125]. In the case of Internationalized 518 Domain Names ([RFC5891]), the domain MUST consist of the Punycode- 519 encoded A-labels ([RFC3492]) and not the U-labels. 521 o "result-type": A value from Section 4.3, "Result Types", above. 523 o "ip-address": The IP address of the sending MTA that attempted the 524 STARTTLS connection. It is provided as a string representation of 525 an IPv4 (see below) or IPv6 ([RFC5952]) address in dot-decimal or 526 colon-hexadecimal notation. 528 o "receiving-mx-hostname": The hostname of the receiving MTA MX 529 record with which the sending MTA attempted to negotiate a 530 STARTTLS connection. 532 o "receiving-mx-helo": (optional) The HELO or EHLO string from the 533 banner announced during the reported session. 535 o "receiving-ip": The destination IP address that was using when 536 creating the outbound session. It is provided as a string 537 representation of an IPv4 (see below) or IPv6 ([RFC5952]) address 538 in dot-decimal or colon-hexadecimal notation. 540 o "total-successful-session-count": The aggregate count (integer, 541 encoded as a JSON number) of successfully negotiated TLS-enabled 542 connections to the receiving site. 544 o "total-failure-session-count": The aggregate count (integer, 545 encoded as a JSON number) of failures to negotiate a TLS-enabled 546 connection to the receiving site. 548 o "failed-session-count": The number of (attempted) sessions that 549 match the relevant "result-type" for this section (integer, 550 encoded as a JSON number). 552 o "additional-info-uri": An optional URI [RFC3986] pointing to 553 additional information around the relevant "result-type". For 554 example, this URI might host the complete certificate chain 555 presented during an attempted STARTTLS session. 557 o "failure-reason-code": A text field to include a TLS-related error 558 code or error message. 560 For report purposes, an IPv4 Address is defined via the following 561 ABNF: 563 IPv4address = dec-octet "." dec-octet "." dec-octet "." dec-octet 564 dec-octet = DIGIT ; 0-9 565 / %x31-39 DIGIT ; 10-99 566 / "1" 2DIGIT ; 100-199 567 / "2" %x30-34 DIGIT ; 200-249 568 / "25" %x30-35 ; 250-255 570 4.5. Policy Samples 572 Part of the report body includes the policy that is applied when 573 attemping relay to the destination. 575 For DANE TLSA policies, this is a JSON array of strings each 576 representing the RDATA of a single TLSA resource record as a space- 577 separated list of its four TLSA fields; the fields are in 578 presentation format (defined in [RFC6698] Section 2.2) with no 579 internal spaces or grouping parentheses: 581 [ 582 "3 0 1 1F850A337E6DB9C609C522D136A475638CC43E1ED424F8EEC8513D747D1D085D", 583 "3 0 1 12350A337E6DB9C6123522D136A475638CC43E1ED424F8EEC8513D747D1D1234" 584 ] 586 For MTA-STS policies, this is an array of JSON strings that 587 represents the policy that is declared by the receiving site, 588 including any errors that may be present. Note that where there are 589 multiple "mx" values, they must be listed as separate "mx" elements 590 in the policy array, rather as a single nested "mx" sub-array. 592 [ 593 "version: STSv1", 594 "mode: report", 595 "mx: mx1.example.com", 596 "mx: mx2.example.com", 597 "mx: mx.backup-example.com", 598 "max_age: 12345678" 599 ] 601 5. Report Delivery 603 Reports can be delivered either as an email message via SMTP or via 604 HTTP POST. 606 5.1. Report Filename 608 The filename is RECOMMENDED to be constructed using the following 609 ABNF: 611 filename = sender "!" policy-domain "!" begin-timestamp 612 "!" end-timestamp [ "!" unique-id ] "." extension 614 unique-id = 1*(ALPHA / DIGIT) 616 sender = domain ; From the [RFC5321] that is used 617 ; as the domain for the `contact-info` 618 ; address in the report body 620 policy-domain = domain 622 begin-timestamp = 1*DIGIT 623 ; seconds since 00:00:00 UTC January 1, 1970 624 ; indicating start of the time range contained 625 ; in the report 627 end-timestamp = 1*DIGIT 628 ; seconds since 00:00:00 UTC January 1, 1970 629 ; indicating end of the time range contained 630 ; in the report 632 extension = "json" / "json.gz" 634 The extension MUST be "json" for a plain JSON file, or "json.gz" for 635 a JSON file compressed using GZIP. 637 "unique-id" allows an optional unique ID generated by the Sending MTA 638 to distinguish among multiple reports generated simultaneously by 639 different sources within the same Policy Domain. For example, this 640 is a possible filename for a compressed report to the Policy Domain 641 "example.net" from the Sending MTA "mail.sndr.example.com": 643 "mail.sndr.example.com!example.net!1470013207!1470186007!001.json.gz" 645 5.2. Compression 647 The report SHOULD be subjected to GZIP [RFC1952] compression for both 648 email and HTTPS transport. Declining to apply compression can cause 649 the report to be too large for a receiver to process (a commonly 650 observed receiver limit is ten megabytes); compressing the file 651 increases the chances of acceptance of the report at some compute 652 cost. 654 5.3. Email Transport 656 The report MAY be delivered by email. To make the reports machine- 657 parsable for the receivers, we define a top-level media type 658 "multipart/report" with a new parameter "report-type="tlsrpt"". 659 Inside it, there are two parts: The first part is human readable, 660 typically "text/plain", and the second part is machine readable with 661 a new media type defined called "application/tlsrpt+json". If 662 compressed, the report should use the media type "application/ 663 tlsrpt+gzip". 665 In addition, the following two new top level message header fields 666 are defined: 668 "TLS-Report-Domain: Receiver-Domain" 670 "TLS-Report-Submitter: Sender-Domain" 672 The "TLS-Report-Submitter" value MUST match the value found in the 673 [RFC5321] domain from the "contact-info" from the report body. These 674 message headers MUST be included and should allow for easy searching 675 for all reports submitted by a report domain or a particular 676 submitter, for example in IMAP [RFC3501]: 678 "s SEARCH HEADER "TLS-Report-Domain" "example.com"" 680 It is presumed that the aggregate reporting address will be equipped 681 to process new message header fields and extract MIME parts with the 682 prescribed media type and filename, and ignore the rest. These 683 additional headers SHOULD be included in the DKIM [RFC6376] signature 684 for the message. 686 The [RFC5322].Subject field for report submissions SHOULD conform to 687 the following ABNF: 689 tlsrpt-subject = %s"Report" FWS ; "Report" 690 %s"Domain:" FWS ; "Domain:" 691 domain-name FWS ; per [RFC6376] 692 %s"Submitter:" FWS ; "Submitter:" 693 domain-name FWS ; per [RFC6376] 694 %s"Report-ID:" FWS ; "Report-ID: 695 "<" id-left "@" id-right ">" ; per [RFC5322] 696 [CFWS] ; per [RFC5322] 697 ; (as with FWS) 699 The first domain-name indicates the DNS domain name about which the 700 report was generated. The second domain-name indicates the DNS 701 domain name representing the Sending MTA generating the report. The 702 purpose of the Report-ID: portion of the field is to enable the 703 Policy Domain to identify and ignore duplicate reports that might be 704 sent by a Sending MTA. 706 For instance, this is a possible Subject field for a report to the 707 Policy Domain "example.net" from the Sending MTA 708 "mail.sender.example.com". It is line-wrapped as allowed by 709 [RFC5322]: 711 Subject: Report Domain: example.net 712 Submitter: mail.sender.example.com 713 Report-ID: <735ff.e317+bf22029@mailexample.net> 715 5.3.1. Example Report 716 From: tlsrpt@mail.sender.example.com 717 Date: Fri, May 09 2017 16:54:30 -0800 718 To: mts-sts-tlsrpt@example.net 719 Subject: Report Domain: example.net 720 Submitter: mail.sender.example.com 721 Report-ID: <735ff.e317+bf22029@example.net> 722 TLS-Report-Domain: example.net 723 TLS-Report-Submitter: mail.sender.example.com 724 MIME-Version: 1.0 725 Content-Type: multipart/report; report-type="tlsrpt"; 726 boundary="----=_NextPart_000_024E_01CC9B0A.AFE54C00" 727 Content-Language: en-us 729 This is a multipart message in MIME format. 731 ------=_NextPart_000_024E_01CC9B0A.AFE54C00 732 Content-Type: text/plain; charset="us-ascii" 733 Content-Transfer-Encoding: 7bit 735 This is an aggregate TLS report from mail.sender.example.com 737 ------=_NextPart_000_024E_01CC9B0A.AFE54C00 738 Content-Type: application/tlsrpt+gzip 739 Content-Transfer-Encoding: base64 740 Content-Disposition: attachment; 741 filename="mail.sender.example!example.com! 742 1013662812!1013749130.json.gz" 744 746 ------=_NextPart_000_024E_01CC9B0A.AFE54C00-- 747 ... 749 Note that, when sending failure reports via SMTP, sending MTAs MUST 750 NOT honor MTA-STS or DANE TLSA failures. 752 5.4. HTTPS Transport 754 The report MAY be delivered by POST to HTTPS. If compressed, the 755 report SHOULD use the media type "application/tlsrpt+gzip", and 756 "application/tlsrpt+json" otherwise (see section Section 6, "IANA 757 Considerations"). 759 The receiving system MUST return a "successful" response from its 760 HTTPS server, typically a 200 or 201 HTTP code [RFC7321]. Other 761 codes could indicate a delivery failure, and may be retried as per 762 local sender policy. The receiving system is not expected to process 763 reports at receipt time, and MAY store them for processing at a later 764 time. 766 5.5. Delivery Retry 768 In the event of a delivery failure, regardless of the delivery 769 method, a sender SHOULD attempt redelivery for up to 24hrs after the 770 initial attempt. As previously stated the reports are optional, so 771 while it is ideal to attempt redelivery, it is not required. If 772 multiple retries are attempted, ideally they SHOULD be done with 773 exponential backoff. 775 5.6. Metadata Variances 777 As stated above, there are a variable number of ways to declare 778 information about the data therein. If any of items declared via 779 subject or filename disagree with the report, the report MUST be 780 considered the authoritative source. 782 6. IANA Considerations 784 The following are the IANA considerations discussed in this document. 786 6.1. Message headers 788 Below is the Internet Assigned Numbers Authority (IANA) Permanent 789 Message Header Field registration information per [RFC3864]. 791 Header field name: TLS-Report-Domain 792 Applicable protocol: mail 793 Status: standard 794 Author/Change controller: IETF 795 Specification document(s): this one 797 Header field name: TLS-Report-Submitter 798 Applicable protocol: mail 799 Status: standard 800 Author/Change controller: IETF 801 Specification document(s): this one 803 6.2. Report Type 805 This document registers a new parameter "report-type="tlsrpt"" under 806 "multipart/report" top-level media type for use with [RFC6522]. 808 The media type suitable for use as a report-type is defined in the 809 following section. 811 6.3. +gzip Media Type Suffix 813 This document registers a new media type suffix "+gzip". The GZIP 814 format is a public domain, cross-platform, interoperable file storage 815 and transfer format, specified in [RFC1952]; it supports compression 816 and is used as the underlying representation by a variety of file 817 formats. The media type "application/gzip" has been registered for 818 such files. The suffix "+gzip" MAY be used with any media type whose 819 representation follows that established for "application/gzip". The 820 media type structured syntax suffix registration form follows: 822 Type name: GZIP file storage and transfer format 824 +suffix: +gzip 826 References: [RFC1952][RFC6713] 828 Encoding considerations: GZIP is a binary encoding. 830 Fragment identifier considerations: The syntax and semantics of 831 fragment identifiers specified for +gzip SHOULD be as specified for 832 "application/gzip". (At publication of this document, there is no 833 fragment identification syntax defined for "application/gzip".) The 834 syntax and semantics for fragment identifiers for a specific "xxx/ 835 yyy+gzip" SHOULD be processed as follows: 837 For cases defined in +gzip, where the fragment identifier 838 resolves per the +gzip rules, then process as specified in 839 +gzip. 841 For cases defined in +gzip, where the fragment identifier does 842 not resolve per the +gzip rules, then process as specified in 843 "xxx/yyy+gzip". 845 For cases not defined in +gzip, then process as specified in 846 "xxx/yyy+gzip". 848 Interoperability considerations: n/a 850 Security considerations: GZIP format doesn't provide encryption. See 851 also security considerations of [RFC6713]. Each individual media 852 type registered with a +gzip suffix can have additional security 853 considerations 855 Contact: art@ietf.org 857 Author/Change controller: Internet Engineering Task Force 858 (mailto:iesg@ietf.org). 860 6.4. application/tlsrpt+json Media Type 862 This document registers multiple media types, beginning with Table 1 863 below. 865 +-------------+----------------+-------------+-------------------+ 866 | Type | Subtype | File extn | Specification | 867 +-------------+----------------+-------------+-------------------+ 868 | application | tlsrpt+json | .json | Section 5.3 | 869 +-------------+----------------+-------------+-------------------+ 870 Table 1: SMTP TLS Reporting Media Type 872 Type name: application 874 Subtype name: tlsrpt+json 876 Required parameters: n/a 878 Optional parameters: n/a 880 Encoding considerations: Encoding considerations are identical to 881 those specified for the "application/json" media type. See 882 [RFC7493]. 884 Security considerations: Security considerations relating to SMTP TLS 885 Reporting are discussed in Section 7. Security considerations 886 related to zlib compression are discussed in [RFC6713]. 888 Interoperability considerations: This document specifies format of 889 conforming messages and the interpretation thereof. 891 Published specification: Section 5.3 of this document. 893 Applications that use this media type: Mail User Agents (MUA) and 894 Mail Transfer Agents. 896 Additional information: 898 Magic number(s): The first two bytes are 0x1f, 0x8b. 900 File extension(s): ".json" 902 Macintosh file type code(s): n/a 904 Person & email address to contact for further information: See 905 Authors' Addresses section. 907 Intended usage: COMMON 908 Restrictions on usage: n/a 910 Author: See Authors' Addresses section. 912 Change controller: Internet Engineering Task Force 913 (mailto:iesg@ietf.org). 915 6.5. application/tlsrpt+gzip Media Type 917 +-------------+----------------+-------------+-------------------+ 918 | Type | Subtype | File extn | Specification | 919 +-------------+----------------+-------------+-------------------+ 920 | application | tlsrpt+gzip | .gz | Section 5.3 | 921 +-------------+----------------+-------------+-------------------+ 922 Table 2: SMTP TLS Reporting Media Type 924 Type name: application 926 Subtype name: tlsrpt+gzip 928 Required parameters: n/a 930 Optional parameters: n/a 932 Encoding considerations: Binary 934 Security considerations: Security considerations relating to SMTP TLS 935 Reporting are discussed in Section 7. 937 Interoperability considerations: This document specifies format of 938 conforming messages and the interpretation thereof. 940 Published specification: Section 5.3 of this document. 942 Applications that use this media type: Mail User Agents (MUA) and 943 Mail Transfer Agents. 945 Additional information: 947 Magic number(s): n/a 949 File extension(s): ".gz" 951 Macintosh file type code(s): n/a 953 Person & email address to contact for further information: See 954 Authors' Addresses section. 956 Intended usage: COMMON 958 Restrictions on usage: n/a 960 Author: See Authors' Addresses section. 962 Change controller: Internet Engineering Task Force 963 (mailto:iesg@ietf.org). 965 6.6. STARTTLS Validation Result Types 967 This document creates a new registry, "STARTTLS Validation Result 968 Types". The initial entries in the registry are: 970 +-------------------------------+ 971 | Result Type | 972 +-------------------------------+ 973 | "starttls-not-supported" | 974 | "certificate-host-mismatch" | 975 | "certificate-expired" | 976 | "tlsa-invalid" | 977 | "dnssec-invalid" | 978 | "dane-required" | 979 | "certificate-not-trusted" | 980 | "sts-policy-invalid" | 981 | "sts-webpki-invalid" | 982 | "validation-failure" | 983 +-------------------------------+ 985 The above entries are described in section Section 4.3, "Result 986 Types." New result types can be added to this registry using "Expert 987 Review" IANA registration policy. 989 7. Security Considerations 991 SMTP TLS Reporting provides transparency into misconfigurations or 992 attempts to intercept or tamper with mail between hosts who support 993 STARTTLS. There are several security risks presented by the 994 existence of this reporting channel: 996 o Flooding of the Aggregate report URI (rua) endpoint: An attacker 997 could flood the endpoint with excessive reporting traffic and 998 prevent the receiving domain from accepting additional reports. 999 This type of Denial-of-Service attack would limit visibility into 1000 STARTTLS failures, leaving the receiving domain blind to an 1001 ongoing attack. 1003 o Untrusted content: An attacker could inject malicious code into 1004 the report, opening a vulnerability in the receiving domain. 1005 Implementers are advised to take precautions against evaluating 1006 the contents of the report. 1008 o Report snooping: An attacker could create a bogus TLSRPT record to 1009 receive statistics about a domain the attacker does not own. 1010 Since an attacker able to poison DNS is already able to receive 1011 counts of SMTP connections (and, absent DANE or MTA-STS policies, 1012 actual SMTP message payloads), this does not present a significant 1013 new vulnerability. 1015 o Ignoring HTTPS validation when submitting reports: When reporting 1016 benign misconfigurations, it is likely that a misconfigured SMTP 1017 server may also mean a misconfigured HTTPS server; as a result, 1018 reporters who required HTTPS validity on the reporting endpoint 1019 may fail to alert administrators about such misconfigurations. 1020 Conversely, in the event of an actual attack, an attacker who 1021 wished to create a gap in reporting and could intercept HTTPS 1022 reports could, just as easily, simply thwart the resolution of the 1023 TLSRPT TXT record or establishment of the TCP session to the HTTPS 1024 endpoint. Furthermore, such a man-in-the-middle attacker could 1025 discover most or all of the metadata exposed in a report merely 1026 through passive observation. As a result, we consider the risks 1027 of failure to deliver reports on misconfigurations to outweigh 1028 those of attackers intercepting reports. 1030 o Reports as DDoS: TLSRPT allows specifying destinations for the 1031 reports that are outside the authority of the Policy Domain, which 1032 allows domains to delegate processing of reports to a partner 1033 organization. However, an attacker who controls the Policy Domain 1034 DNS could also use this mechanism to direct the reports to an 1035 unwitting victim, flooding that victim with excessive reports. 1036 DMARC [RFC7489] defines a solution for verifying delegation to 1037 avoid such attacks; the need for this is greater with DMARC, 1038 however, because DMARC allows an attacker to trigger reports to a 1039 target from an innocent third party by sending that third party 1040 mail (which triggers a report from the third party to the target). 1041 In the case of TLSRPT, the attacker would have to induce the third 1042 party to send the attacker mail in order to trigger reports from 1043 the third party to the victim; this reduces the risk of such an 1044 attack and the need for a verification mechanism. 1046 Finally, because TLSRPT is intended to help administrators discover 1047 man-in-the-middle attacks against transport-layer encryption, 1048 including attacks designed to thwart negotiation of encrypted 1049 connections (by downgrading opportunistic encryption or, in the case 1050 of MTA-STS, preventing discovery of a new MTA-STS policy), we must 1051 also consider the risk that an adversary who can induce such a 1052 downgrade attack can also prevent discovery of the TLSRPT TXT record 1053 (and thus prevent discovery of the successful downgrade attack). 1054 Administrators are thus encouraged to deploy TLSRPT TXT records with 1055 a large TTL (reducing the window for successful application of 1056 transient attacks against DNS resolution of the record) or to deploy 1057 DNSSEC on the deploying zone. 1059 8. References 1061 8.1. Normative References 1063 [I-D.ietf-uta-mta-sts] 1064 Margolis, D., Risher, M., Ramakrishnan, B., Brotman, A., 1065 and J. Jones, "SMTP MTA Strict Transport Security (MTA- 1066 STS)", draft-ietf-uta-mta-sts-15 (work in progress), April 1067 2018. 1069 [RFC1952] Deutsch, P., "GZIP file format specification version 4.3", 1070 RFC 1952, DOI 10.17487/RFC1952, May 1996, 1071 . 1073 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 1074 Requirement Levels", BCP 14, RFC 2119, 1075 DOI 10.17487/RFC2119, March 1997, . 1078 [RFC3339] Klyne, G. and C. Newman, "Date and Time on the Internet: 1079 Timestamps", RFC 3339, DOI 10.17487/RFC3339, July 2002, 1080 . 1082 [RFC3492] Costello, A., "Punycode: A Bootstring encoding of Unicode 1083 for Internationalized Domain Names in Applications 1084 (IDNA)", RFC 3492, DOI 10.17487/RFC3492, March 2003, 1085 . 1087 [RFC3986] Berners-Lee, T., Fielding, R., and L. Masinter, "Uniform 1088 Resource Identifier (URI): Generic Syntax", STD 66, 1089 RFC 3986, DOI 10.17487/RFC3986, January 2005, 1090 . 1092 [RFC4408] Wong, M. and W. Schlitt, "Sender Policy Framework (SPF) 1093 for Authorizing Use of Domains in E-Mail, Version 1", 1094 RFC 4408, DOI 10.17487/RFC4408, April 2006, 1095 . 1097 [RFC5234] Crocker, D., Ed. and P. Overell, "Augmented BNF for Syntax 1098 Specifications: ABNF", STD 68, RFC 5234, 1099 DOI 10.17487/RFC5234, January 2008, . 1102 [RFC5280] Cooper, D., Santesson, S., Farrell, S., Boeyen, S., 1103 Housley, R., and W. Polk, "Internet X.509 Public Key 1104 Infrastructure Certificate and Certificate Revocation List 1105 (CRL) Profile", RFC 5280, DOI 10.17487/RFC5280, May 2008, 1106 . 1108 [RFC5321] Klensin, J., "Simple Mail Transfer Protocol", RFC 5321, 1109 DOI 10.17487/RFC5321, October 2008, . 1112 [RFC5322] Resnick, P., Ed., "Internet Message Format", RFC 5322, 1113 DOI 10.17487/RFC5322, October 2008, . 1116 [RFC5891] Klensin, J., "Internationalized Domain Names in 1117 Applications (IDNA): Protocol", RFC 5891, 1118 DOI 10.17487/RFC5891, August 2010, . 1121 [RFC5952] Kawamura, S. and M. Kawashima, "A Recommendation for IPv6 1122 Address Text Representation", RFC 5952, 1123 DOI 10.17487/RFC5952, August 2010, . 1126 [RFC6068] Duerst, M., Masinter, L., and J. Zawinski, "The 'mailto' 1127 URI Scheme", RFC 6068, DOI 10.17487/RFC6068, October 2010, 1128 . 1130 [RFC6125] Saint-Andre, P. and J. Hodges, "Representation and 1131 Verification of Domain-Based Application Service Identity 1132 within Internet Public Key Infrastructure Using X.509 1133 (PKIX) Certificates in the Context of Transport Layer 1134 Security (TLS)", RFC 6125, DOI 10.17487/RFC6125, March 1135 2011, . 1137 [RFC6376] Crocker, D., Ed., Hansen, T., Ed., and M. Kucherawy, Ed., 1138 "DomainKeys Identified Mail (DKIM) Signatures", STD 76, 1139 RFC 6376, DOI 10.17487/RFC6376, September 2011, 1140 . 1142 [RFC6522] Kucherawy, M., Ed., "The Multipart/Report Media Type for 1143 the Reporting of Mail System Administrative Messages", 1144 STD 73, RFC 6522, DOI 10.17487/RFC6522, January 2012, 1145 . 1147 [RFC6698] Hoffman, P. and J. Schlyter, "The DNS-Based Authentication 1148 of Named Entities (DANE) Transport Layer Security (TLS) 1149 Protocol: TLSA", RFC 6698, DOI 10.17487/RFC6698, August 1150 2012, . 1152 [RFC6713] Levine, J., "The 'application/zlib' and 'application/gzip' 1153 Media Types", RFC 6713, DOI 10.17487/RFC6713, August 2012, 1154 . 1156 [RFC7231] Fielding, R., Ed. and J. Reschke, Ed., "Hypertext Transfer 1157 Protocol (HTTP/1.1): Semantics and Content", RFC 7231, 1158 DOI 10.17487/RFC7231, June 2014, . 1161 [RFC7405] Kyzivat, P., "Case-Sensitive String Support in ABNF", 1162 RFC 7405, DOI 10.17487/RFC7405, December 2014, 1163 . 1165 [RFC7493] Bray, T., Ed., "The I-JSON Message Format", RFC 7493, 1166 DOI 10.17487/RFC7493, March 2015, . 1169 [RFC7672] Dukhovni, V. and W. Hardaker, "SMTP Security via 1170 Opportunistic DNS-Based Authentication of Named Entities 1171 (DANE) Transport Layer Security (TLS)", RFC 7672, 1172 DOI 10.17487/RFC7672, October 2015, . 1175 [RFC8174] Leiba, B., "Ambiguity of Uppercase vs Lowercase in RFC 1176 2119 Key Words", BCP 14, RFC 8174, DOI 10.17487/RFC8174, 1177 May 2017, . 1179 8.2. Informative References 1181 [RFC3207] Hoffman, P., "SMTP Service Extension for Secure SMTP over 1182 Transport Layer Security", RFC 3207, DOI 10.17487/RFC3207, 1183 February 2002, . 1185 [RFC3501] Crispin, M., "INTERNET MESSAGE ACCESS PROTOCOL - VERSION 1186 4rev1", RFC 3501, DOI 10.17487/RFC3501, March 2003, 1187 . 1189 [RFC3864] Klyne, G., Nottingham, M., and J. Mogul, "Registration 1190 Procedures for Message Header Fields", BCP 90, RFC 3864, 1191 DOI 10.17487/RFC3864, September 2004, . 1194 [RFC7321] McGrew, D. and P. Hoffman, "Cryptographic Algorithm 1195 Implementation Requirements and Usage Guidance for 1196 Encapsulating Security Payload (ESP) and Authentication 1197 Header (AH)", RFC 7321, DOI 10.17487/RFC7321, August 2014, 1198 . 1200 [RFC7435] Dukhovni, V., "Opportunistic Security: Some Protection 1201 Most of the Time", RFC 7435, DOI 10.17487/RFC7435, 1202 December 2014, . 1204 [RFC7469] Evans, C., Palmer, C., and R. Sleevi, "Public Key Pinning 1205 Extension for HTTP", RFC 7469, DOI 10.17487/RFC7469, April 1206 2015, . 1208 [RFC7489] Kucherawy, M., Ed. and E. Zwicky, Ed., "Domain-based 1209 Message Authentication, Reporting, and Conformance 1210 (DMARC)", RFC 7489, DOI 10.17487/RFC7489, March 2015, 1211 . 1213 Appendix A. Example Reporting Policy 1215 A.1. Report using MAILTO 1217 _smtp._tls.mail.example.com. IN TXT \ 1218 "v=TLSRPTv1;rua=mailto:reports@example.com" 1220 A.2. Report using HTTPS 1222 _smtp._tls.mail.example.com. IN TXT \ 1223 "v=TLSRPTv1; \ 1224 rua=https://reporting.example.com/v1/tlsrpt" 1226 Appendix B. Example JSON Report 1228 Below is an example JSON report for messages from Company-X to 1229 Company-Y, where 100 sessions were attempted to Company Y servers 1230 with an expired certificate and 200 sessions were attempted to 1231 Company Y servers that did not successfully respond to the "STARTTLS" 1232 command. Additionally 3 sessions failed due to 1233 "X509_V_ERR_PROXY_PATH_LENGTH_EXCEEDED". 1235 { 1236 "organization-name": "Company-X", 1237 "date-range": { 1238 "start-datetime": "2016-04-01T00:00:00Z", 1239 "end-datetime": "2016-04-01T23:59:59Z" 1240 }, 1241 "contact-info": "sts-reporting@company-x.example", 1242 "report-id": "5065427c-23d3-47ca-b6e0-946ea0e8c4be", 1243 "policies": [{ 1244 "policy": { 1245 "policy-type": "sts", 1246 "policy-string": ["version: STSv1","mode: report", 1247 "mx: .mail.company-y.example","max_age: 86400"], 1248 "policy-domain": "company-y.example", 1249 "mx-host": ".mail.company-y.example" 1250 }, 1251 "summary": { 1252 "total-successful-session-count": 5326, 1253 "total-failure-session-count": 303 1254 }, 1255 "failure-details": [{ 1256 "result-type": "certificate-expired", 1257 "sending-mta-ip": "2001:db8:abcd:0012::1", 1258 "receiving-mx-hostname": "mx1.mail.company-y.example", 1259 "failed-session-count": 100 1260 }, { 1261 "result-type": "starttls-not-supported", 1262 "sending-mta-ip": "2001:db8:abcd:0013::1", 1263 "receiving-mx-hostname": "mx2.mail.company-y.example", 1264 "receiving-ip": "203.0.113.56", 1265 "failed-session-count": 200, 1266 "additional-information": "https://reports.company-x.example/ 1267 report_info ? id = 5065427 c - 23 d3# StarttlsNotSupported " 1268 }, { 1269 "result-type": "validation-failure", 1270 "sending-mta-ip": "198.51.100.62", 1271 "receiving-ip": "203.0.113.58", 1272 "receiving-mx-hostname": "mx-backup.mail.company-y.example", 1273 "failed-session-count": 3, 1274 "failure-error-code": "X509_V_ERR_PROXY_PATH_LENGTH_EXCEEDED" 1275 }] 1276 }] 1277 } 1279 Authors' Addresses 1281 Daniel Margolis 1282 Google, Inc 1284 Email: dmargolis@google.com 1286 Alexander Brotman 1287 Comcast, Inc 1289 Email: alex_brotman@comcast.com 1291 Binu Ramakrishnan 1292 Yahoo!, Inc 1294 Email: rbinu@oath.com 1296 Janet Jones 1297 Microsoft, Inc 1299 Email: janet.jones@microsoft.com 1301 Mark Risher 1302 Google, Inc 1304 Email: risher@google.com