idnits 2.17.1 draft-west-leave-secure-cookies-alone-00.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 document seems to lack an IANA Considerations section. (See Section 2.2 of https://www.ietf.org/id-info/checklist for how to handle the case when there are no actions for IANA.) Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year == The document doesn't use any RFC 2119 keywords, yet seems to have RFC 2119 boilerplate text. -- The document date (October 6, 2015) is 3125 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) No issues found here. Summary: 1 error (**), 0 flaws (~~), 2 warnings (==), 1 comment (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 HTTPbis M. West 3 Internet-Draft Google, Inc 4 Updates: 6265 (if approved) October 6, 2015 5 Intended status: Standards Track 6 Expires: April 8, 2016 8 Deprecate modification of 'secure' cookies from non-secure origins 9 draft-west-leave-secure-cookies-alone-00 11 Abstract 13 This document updates RFC6265 by removing the ability for a non- 14 secure origin to set cookies with a 'secure' flag, and to overwrite 15 cookies whose 'secure' flag is set. This deprecation improves the 16 isolation between HTTP and HTTPS origins, and reduces the risk of 17 malicious interference. 19 Status of This Memo 21 This Internet-Draft is submitted in full conformance with the 22 provisions of BCP 78 and BCP 79. 24 Internet-Drafts are working documents of the Internet Engineering 25 Task Force (IETF). Note that other groups may also distribute 26 working documents as Internet-Drafts. The list of current Internet- 27 Drafts is at http://datatracker.ietf.org/drafts/current/. 29 Internet-Drafts are draft documents valid for a maximum of six months 30 and may be updated, replaced, or obsoleted by other documents at any 31 time. It is inappropriate to use Internet-Drafts as reference 32 material or to cite them other than as "work in progress." 34 This Internet-Draft will expire on April 8, 2016. 36 Copyright Notice 38 Copyright (c) 2015 IETF Trust and the persons identified as the 39 document authors. All rights reserved. 41 This document is subject to BCP 78 and the IETF Trust's Legal 42 Provisions Relating to IETF Documents 43 (http://trustee.ietf.org/license-info) in effect on the date of 44 publication of this document. Please review these documents 45 carefully, as they describe your rights and restrictions with respect 46 to this document. Code Components extracted from this document must 47 include Simplified BSD License text as described in Section 4.e of 48 the Trust Legal Provisions and are provided without warranty as 49 described in the Simplified BSD License. 51 Table of Contents 53 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 2 54 2. Terminology and notation . . . . . . . . . . . . . . . . . . 2 55 3. Recommendations . . . . . . . . . . . . . . . . . . . . . . . 2 56 4. Security Considerations . . . . . . . . . . . . . . . . . . . 3 57 5. References . . . . . . . . . . . . . . . . . . . . . . . . . 3 58 5.1. Normative References . . . . . . . . . . . . . . . . . . 3 59 5.2. Informative References . . . . . . . . . . . . . . . . . 3 60 Appendix A. Acknowledgements . . . . . . . . . . . . . . . . . . 4 61 Author's Address . . . . . . . . . . . . . . . . . . . . . . . . 4 63 1. Introduction 65 Section 8.5 and Section 8.6 of [RFC6265] spell out some of the 66 drawbacks of cookies' implementation: due to historical accident, 67 non-secure origins can set cookies which will be delivered to secure 68 origins in a manner indistinguishable from cookies set by that origin 69 itself. This enables a number of attacks, which have been recently 70 spelled out in some detail in [COOKIE-INTEGRITY]. 72 We can mitigate the risk of these attacks by making it more difficult 73 for non-secure origins to influence the state of secure origins. 74 Accordingly, this document recommends the deprecation and removal of 75 non-secure origins' ability to write cookies with a 'secure' flag, 76 and their ability to overwrite cookies whose 'secure' flag is set. 78 2. Terminology and notation 80 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 81 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this 82 document are to be interpreted as described in [RFC2119]. 84 The "scheme" component of a URI is defined in Section 3 of [RFC3986]. 86 3. Recommendations 88 This document updates Section 5.3 of [RFC6265] as follows: 90 1. After step 8 of the current algorithm, which sets the cookie's 91 "secure-only-flag", execute the following step: 93 8. If the "scheme" component of the "request-uri" is not 94 "https", and the cookie's "secure-only-flag" is "true", then 95 abort these steps and ignore the newly created cookie 96 entirely. 98 2. Before step 3 of step 11 of the current algorithm, execute the 99 following step: 101 3. If the "scheme" component of the "request-uri" is not 102 "https", and the "old-cookie"'s "secure-only-flag" is set, 103 then abort these steps and ignore the newly create cookie 104 entirely. 106 4. Security Considerations 108 This specification increases a site's confidence that secure cookies 109 it sets will remain unmodified by insecure pages on hosts which it 110 'domain-match's. Ideally, sites would use HSTS as described in 111 [RFC6797] to defend more robustly against the dangers of non-secure 112 transport in general, but until adoption of that protection becomes 113 ubiquitous, this deprecation this document recommends will mitigate a 114 number of risks. 116 5. References 118 5.1. Normative References 120 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 121 Requirement Levels", BCP 14, RFC 2119, DOI 10.17487/ 122 RFC2119, March 1997, 123 . 125 [RFC3986] Berners-Lee, T., Fielding, R., and L. Masinter, "Uniform 126 Resource Identifier (URI): Generic Syntax", STD 66, RFC 127 3986, DOI 10.17487/RFC3986, January 2005, 128 . 130 [RFC6265] Barth, A., "HTTP State Management Mechanism", RFC 6265, 131 DOI 10.17487/RFC6265, April 2011, 132 . 134 5.2. Informative References 136 [COOKIE-INTEGRITY] 137 Zheng, X., Jiang, J., Liang, J., Duan, H., Chen, S., Wan, 138 T., and N. Weaver, "Cookies Lack Integrity: Real-World 139 Implications", n.d., . 142 [RFC6797] Hodges, J., Jackson, C., and A. Barth, "HTTP Strict 143 Transport Security (HSTS)", RFC 6797, DOI 10.17487/ 144 RFC6797, November 2012, 145 . 147 Appendix A. Acknowledgements 149 Richard Barnes encouraged a formalization of the deprecation 150 proposal. [COOKIE-INTEGRITY] was a useful exploration of the issues 151 [RFC6265] described. 153 Author's Address 155 Mike West 156 Google, Inc 158 Email: mkwst@google.com 159 URI: https://mikewest.org/