--- 1/draft-ietf-uta-smtp-require-tls-04.txt 2018-11-20 15:15:37.739830458 -0800 +++ 2/draft-ietf-uta-smtp-require-tls-05.txt 2018-11-20 15:15:37.771831234 -0800 @@ -1,18 +1,18 @@ Internet Engineering Task Force J. Fenton Internet-Draft Altmode Networks -Intended status: Standards Track September 26, 2018 -Expires: March 30, 2019 +Intended status: Standards Track November 20, 2018 +Expires: May 24, 2019 SMTP Require TLS Option - draft-ietf-uta-smtp-require-tls-04 + draft-ietf-uta-smtp-require-tls-05 Abstract The SMTP STARTTLS option, used in negotiating transport-level encryption of SMTP connections, is not as useful from a security standpoint as it might be because of its opportunistic nature; message delivery is, by default, prioritized over security. This document describes an SMTP service extension, REQUIRETLS, and message header field, RequireTLS. If the REQUIRETLS option or RequireTLS message header field is used when sending a message, it asserts a @@ -30,71 +30,72 @@ Internet-Drafts are working documents of the Internet Engineering Task Force (IETF). Note that other groups may also distribute working documents as Internet-Drafts. The list of current Internet- Drafts is at https://datatracker.ietf.org/drafts/current/. Internet-Drafts are draft documents valid for a maximum of six months and may be updated, replaced, or obsoleted by other documents at any time. It is inappropriate to use Internet-Drafts as reference material or to cite them other than as "work in progress." - This Internet-Draft will expire on March 30, 2019. + This Internet-Draft will expire on May 24, 2019. Copyright Notice Copyright (c) 2018 IETF Trust and the persons identified as the document authors. All rights reserved. This document is subject to BCP 78 and the IETF Trust's Legal Provisions Relating to IETF Documents (https://trustee.ietf.org/license-info) in effect on the date of publication of this document. Please review these documents carefully, as they describe your rights and restrictions with respect to this document. Code Components extracted from this document must include Simplified BSD License text as described in Section 4.e of the Trust Legal Provisions and are provided without warranty as described in the Simplified BSD License. Table of Contents - 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 2 + 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 3 1.1. Requirements Language . . . . . . . . . . . . . . . . . . 3 2. The REQUIRETLS Service Extension . . . . . . . . . . . . . . 4 3. The RequireTLS Header Field . . . . . . . . . . . . . . . . . 4 4. REQUIRETLS Semantics . . . . . . . . . . . . . . . . . . . . 5 4.1. REQUIRETLS Receipt Requirements . . . . . . . . . . . . . 5 4.2. REQUIRETLS Sender Requirements . . . . . . . . . . . . . 5 4.2.1. Sending with TLS Required . . . . . . . . . . . . . . 5 4.2.2. Sending with TLS Optional . . . . . . . . . . . . . . 6 4.3. REQUIRETLS Submission . . . . . . . . . . . . . . . . . . 7 4.4. Delivery of REQUIRETLS messages . . . . . . . . . . . . . 7 5. Non-delivery message handling . . . . . . . . . . . . . . . . 7 6. Mailing list considerations . . . . . . . . . . . . . . . . . 8 7. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 8 8. Security Considerations . . . . . . . . . . . . . . . . . . . 9 - 8.1. Passive attacks . . . . . . . . . . . . . . . . . . . . . 9 + 8.1. Passive attacks . . . . . . . . . . . . . . . . . . . . . 10 8.2. Active attacks . . . . . . . . . . . . . . . . . . . . . 10 8.3. Bad Actor MTAs . . . . . . . . . . . . . . . . . . . . . 10 - 9. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . 10 + 9. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . 11 10. Revision History . . . . . . . . . . . . . . . . . . . . . . 11 - 10.1. Changes since -03 Draft . . . . . . . . . . . . . . . . 11 - 10.2. Changes since -02 Draft . . . . . . . . . . . . . . . . 11 - 10.3. Changes since -01 Draft . . . . . . . . . . . . . . . . 11 - 10.4. Changes since -00 Draft . . . . . . . . . . . . . . . . 11 - 10.5. Changes since fenton-03 Draft . . . . . . . . . . . . . 12 - 10.6. Changes Since -02 Draft . . . . . . . . . . . . . . . . 12 - 10.7. Changes Since -01 Draft . . . . . . . . . . . . . . . . 12 - 10.8. Changes Since -00 Draft . . . . . . . . . . . . . . . . 12 + 10.1. Changes since -04 Draft . . . . . . . . . . . . . . . . 11 + 10.2. Changes since -03 Draft . . . . . . . . . . . . . . . . 11 + 10.3. Changes since -02 Draft . . . . . . . . . . . . . . . . 11 + 10.4. Changes since -01 Draft . . . . . . . . . . . . . . . . 12 + 10.5. Changes since -00 Draft . . . . . . . . . . . . . . . . 12 + 10.6. Changes since fenton-03 Draft . . . . . . . . . . . . . 12 + 10.7. Changes Since -02 Draft . . . . . . . . . . . . . . . . 12 + 10.8. Changes Since -01 Draft . . . . . . . . . . . . . . . . 12 + 10.9. Changes Since -00 Draft . . . . . . . . . . . . . . . . 13 11. References . . . . . . . . . . . . . . . . . . . . . . . . . 13 11.1. Normative References . . . . . . . . . . . . . . . . . . 13 - 11.2. Informative References . . . . . . . . . . . . . . . . . 14 - Author's Address . . . . . . . . . . . . . . . . . . . . . . . . 14 + 11.2. Informative References . . . . . . . . . . . . . . . . . 15 + Author's Address . . . . . . . . . . . . . . . . . . . . . . . . 15 1. Introduction The SMTP [RFC5321] STARTTLS service extension [RFC3207] provides a means by which an SMTP server and client can establish a Transport Layer Security (TLS) protected session for the transmission of email messages. By default, TLS is used only upon mutual agreement (successful negotiation) of STARTTLS between the client and server; if this is not possible, the message is sent without transport encryption. Furthermore, it is common practice for the client to @@ -153,20 +154,27 @@ to a server not also supporting the REQUIRETLS extension. In order to specify REQUIRETLS treatment for a given message, the REQUIRETLS option is specified on the MAIL FROM command when that message is transmitted. This option MUST only be specified in the context of an SMTP session meeting the security requirements that have been specified: o The session itself MUST employ TLS transmission. + o If the SMTP server to which the message is being transmitted is + identified through an MX record lookup, its name MUST be validated + via a DNSSEC signature on the recipient domain's MX record, or the + MX hostname MUST be validated by an MTA-STS policy as described in + Section 4.1 of RFC 8461 [RFC8461]. DNSSEC is defined in RFC 4033 + [RFC4033], RFC 4034 [RFC4034], and RFC 4035 [RFC4035]. + o The certificate presented by the SMTP server MUST either verify successfully in a trust chain leading to a certificate trusted by the SMTP client or it MUST verify succesfully using DANE as specified in RFC 7672 [RFC7672]. For trust chains, the choice of trusted (root) certificates is at the discretion of the SMTP client. o Following the negotiation of STARTTLS, the SMTP server MUST advertise in the subsequent EHLO response that it supports REQUIRETLS. @@ -212,38 +220,44 @@ 4.2. REQUIRETLS Sender Requirements 4.2.1. Sending with TLS Required When sending a message tagged as requiring TLS, the sending (client) MTA MUST: 1. Look up the SMTP server to which the message is to be sent as described in [RFC5321] Section 5.1. - 2. Open an SMTP session with the peer SMTP server using the EHLO + 2. If the server lookup is accomplished via the recipient domain's + MX record (the usual case) and is not accompanied by a valid + DNSSEC signature, the client MUST also validate the SMTP server + name using MTA-STS as described in Section 4.1 of RFC 8461 + [RFC8461]. + + 3. Open an SMTP session with the peer SMTP server using the EHLO verb. - 3. Establish a TLS-protected SMTP session with its peer SMTP server + 4. Establish a TLS-protected SMTP session with its peer SMTP server and authenticate the server's certificate as specified in [RFC6125] or [RFC7672] as applicable. - 4. Ensure that the response to the subsequent EHLO following + 5. Ensure that the response to the subsequent EHLO following establishment of the TLS protection advertises the REQUIRETLS capability. - 5. The SMTP client SHOULD also require that meaningfully secure + 6. The SMTP client SHOULD also require that meaningfully secure cipher algorithms and key lengths be negotiated with the server. The choices of key lengths and algorithms change over time, so a specific requirement is not presented here. If any of the above steps fail, the client MUST issue a QUIT to the - server and repeat steps 2-4 with each host on the recipient domain's + server and repeat steps 2-5 with each host on the recipient domain's list of MX hosts in an attempt to find a mail path that meets the sender's requirements. The client MAY send other, unprotected, messages to that server if it has any prior to issuing the QUIT. If there are no more MX hosts, the client MUST NOT transmit the message to the domain. Following such a failure, the SMTP client MUST send a non-delivery notification to the reverse-path of the failed message as described in section 3.6 of [RFC5321]. The following status codes [RFC5248] SHOULD be used: @@ -437,24 +451,27 @@ insecurely. A second form of attack is a man-in-the-middle attack where the attacker terminates the TLS connection rather than the intended SMTP server. This is possible when, as is commonly the case, the SMTP client either does not verify the server's certificate or establishes the connection even when the verification fails. REQUIRETLS requires successful certificate validation before sending the message. Another active attack involves the spoofing of DNS MX records of the - recipient domain. An attacker having this capability could cause the - message to be redirected to a mail server under the attacker's own - control, which would presumably have a valid certificate. REQUIRETLS - does not address this attack. + recipient domain. An attacker having this capability could + potentially cause the message to be redirected to a mail server under + the attacker's own control, which would presumably have a valid + certificate. REQUIRETLS requires that the recipient domain's MX + record lookup be validated either using DNSSEC or via a published + MTA-STS policy that specifies the acceptable SMTP server hostname(s) + for the recipient domain. 8.3. Bad Actor MTAs A bad-actor MTA along the message transmission path could misrepresent its support of REQUIRETLS and/or actively strip REQUIRETLS tags from messages it handles. However, since intermediate MTAs are already trusted with the cleartext of messages they handle, and are not part of the threat model for transport-layer security, they are also not part of the threat model for REQUIRETLS. @@ -469,92 +486,97 @@ The author would like to acknowledge many helpful suggestions on the ietf-smtp and uta mailing lists, in particular those of Viktor Dukhovni, Chris Newman, Tony Finch, Jeremy Harris, Arvel Hathcock, John Klensin, John Levine, Rolf Sonneveld, and Per Thorsheim. 10. Revision History To be removed by RFC Editor upon publication as an RFC. -10.1. Changes since -03 Draft +10.1. Changes since -04 Draft + + Require validation of SMTP server hostname via DNSSEC or MTA-STS + policy when TLS is required. + +10.2. Changes since -03 Draft Working Group Last Call changes, including: o Correct reference for SMTP DANE o Clarify that RequireTLS: NO applies to both MTA-STS and DANE policies o Correct newly-defined status codes o Update MTA-STS references to RFC -10.2. Changes since -02 Draft +10.3. Changes since -02 Draft o More complete documentation for IANA registration requests. o Changed bounce handling to use RET parameters of RFC 3461, along with slightly more liberal transmission of bounces even if REQUIRETLS can't be negotiated. -10.3. Changes since -01 Draft +10.4. Changes since -01 Draft o Converted DEEP references to RFC 8314. o Removed REQUIRETLS options: CHAIN, DANE, and DNSSEC. o Editorial corrections, notably making the header field name consistent (RequireTLS rather than Require-TLS). -10.4. Changes since -00 Draft +10.5. Changes since -00 Draft o Created new header field, Require-TLS, for use by "NO" option. o Removed "NO" option from SMTP service extension. o Recommend DEEP requirements for delivery of messages requiring TLS. o Assorted copy edits -10.5. Changes since fenton-03 Draft +10.6. Changes since fenton-03 Draft o Wording improvements from Rolf Sonneveld review 22 July 2017 o A few copy edits o Conversion from individual to UTA WG draft -10.6. Changes Since -02 Draft +10.7. Changes Since -02 Draft o Incorporation of "MAY TLS" functionality as REQUIRETLS=NO per suggestion on UTA WG mailing list. o Additional guidance on bounce messages -10.7. Changes Since -01 Draft +10.8. Changes Since -01 Draft o Specified retries when multiple MX hosts exist for a given domain. o Clarified generation of non-delivery messages o Specified requirements for application of REQUIRETLS to mail forwarders and mailing lists. o Clarified DNSSEC requirements to include MX lookup only. o Corrected terminology regarding message retrieval vs. delivery. o Changed category to standards track. -10.8. Changes Since -00 Draft +10.9. Changes Since -00 Draft o Conversion of REQUIRETLS from an SMTP verb to a MAIL FROM parameter to better associate REQUIRETLS requirements with transmission of individual messages. o Addition of an option to require DNSSEC lookup of the remote mail server, since this affects the common name of the certificate that is presented. o Clarified the wording to more clearly state that TLS sessions must @@ -587,20 +609,35 @@ [RFC3207] Hoffman, P., "SMTP Service Extension for Secure SMTP over Transport Layer Security", RFC 3207, DOI 10.17487/RFC3207, February 2002, . [RFC3461] Moore, K., "Simple Mail Transfer Protocol (SMTP) Service Extension for Delivery Status Notifications (DSNs)", RFC 3461, DOI 10.17487/RFC3461, January 2003, . + [RFC4033] Arends, R., Austein, R., Larson, M., Massey, D., and S. + Rose, "DNS Security Introduction and Requirements", + RFC 4033, DOI 10.17487/RFC4033, March 2005, + . + + [RFC4034] Arends, R., Austein, R., Larson, M., Massey, D., and S. + Rose, "Resource Records for the DNS Security Extensions", + RFC 4034, DOI 10.17487/RFC4034, March 2005, + . + + [RFC4035] Arends, R., Austein, R., Larson, M., Massey, D., and S. + Rose, "Protocol Modifications for the DNS Security + Extensions", RFC 4035, DOI 10.17487/RFC4035, March 2005, + . + [RFC5248] Hansen, T. and J. Klensin, "A Registry for SMTP Enhanced Mail System Status Codes", BCP 138, RFC 5248, DOI 10.17487/RFC5248, June 2008, . [RFC5321] Klensin, J., "Simple Mail Transfer Protocol", RFC 5321, DOI 10.17487/RFC5321, October 2008, . [RFC6125] Saint-Andre, P. and J. Hodges, "Representation and @@ -612,20 +649,25 @@ [RFC8174] Leiba, B., "Ambiguity of Uppercase vs Lowercase in RFC 2119 Key Words", BCP 14, RFC 8174, DOI 10.17487/RFC8174, May 2017, . [RFC8314] Moore, K. and C. Newman, "Cleartext Considered Obsolete: Use of Transport Layer Security (TLS) for Email Submission and Access", RFC 8314, DOI 10.17487/RFC8314, January 2018, . + [RFC8461] Margolis, D., Risher, M., Ramakrishnan, B., Brotman, A., + and J. Jones, "SMTP MTA Strict Transport Security (MTA- + STS)", RFC 8461, DOI 10.17487/RFC8461, September 2018, + . + [SMTPStatusCodes] Internet Assigned Numbers Authority (IANA), "Simple Mail Transfer Protocol (SMTP) Enhanced Status Codes Registry", 2008, . 11.2. Informative References [RFC1939] Myers, J. and M. Rose, "Post Office Protocol - Version 3", STD 53, RFC 1939, DOI 10.17487/RFC1939, May 1996, @@ -644,22 +686,18 @@ Mail Extensions (S/MIME) Version 3.2 Message Specification", RFC 5751, DOI 10.17487/RFC5751, January 2010, . [RFC7672] Dukhovni, V. and W. Hardaker, "SMTP Security via Opportunistic DNS-Based Authentication of Named Entities (DANE) Transport Layer Security (TLS)", RFC 7672, DOI 10.17487/RFC7672, October 2015, . - [RFC8461] Margolis, D., Risher, M., Ramakrishnan, B., Brotman, A., - and J. Jones, "SMTP MTA Strict Transport Security (MTA- - STS)", RFC 8461, DOI 10.17487/RFC8461, September 2018, - . - Author's Address + Jim Fenton Altmode Networks Los Altos, California 94024 USA Email: fenton@bluepopcorn.net