idnits 2.17.00 (12 Aug 2021) /tmp/idnits52534/draft-nottingham-rfc5785bis-09.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 abstract seems to contain references ([2], [3], [4], [1]), which it shouldn't. Please replace those with straight textual mentions of the documents in question. -- The draft header indicates that this document obsoletes RFC8307, but the abstract doesn't seem to directly say this. It does mention RFC8307 though, so this could be OK. -- The draft header indicates that this document updates RFC7230, but the abstract doesn't seem to directly say this. It does mention RFC7230 though, so this could be OK. -- The draft header indicates that this document updates RFC6455, but the abstract doesn't seem to directly say this. It does mention RFC6455 though, so this could be OK. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year (Using the creation date from RFC7230, updated by this document, for RFC5378 checks: 2007-12-21) -- The document seems to lack a disclaimer for pre-RFC5378 work, but may have content which was first submitted before 10 November 2008. If you have contacted all the original authors and they are all willing to grant the BCP78 rights to the IETF Trust, then this is fine, and you can ignore this comment. If not, you may need to add the pre-RFC5378 disclaimer. (See the Legal Provisions document at https://trustee.ietf.org/license-info for more information.) -- The document date (February 26, 2019) is 1179 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) -- Looks like a reference, but probably isn't: '1' on line 460 -- Looks like a reference, but probably isn't: '2' on line 462 -- Looks like a reference, but probably isn't: '3' on line 464 -- Looks like a reference, but probably isn't: '4' on line 466 -- Looks like a reference, but probably isn't: '5' on line 468 -- Obsolete informational reference (is this intentional?): RFC 5785 (Obsoleted by RFC 8615) -- Obsolete informational reference (is this intentional?): RFC 7320 (Obsoleted by RFC 8820) Summary: 1 error (**), 0 flaws (~~), 1 warning (==), 12 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 Network Working Group M. Nottingham 3 Internet-Draft February 26, 2019 4 Obsoletes: 5785, 8307 (if approved) 5 Updates: 7230, 6455 (if approved) 6 Intended status: Standards Track 7 Expires: August 30, 2019 9 Well-Known Uniform Resource Identifiers (URIs) 10 draft-nottingham-rfc5785bis-09 12 Abstract 14 This memo defines a path prefix for "well-known locations", "/.well- 15 known/", in selected Uniform Resource Identifier (URI) schemes. 17 In doing so, it obsoletes RFC 5785 and RFC 8307, and updates the URI 18 schemes defined in RFC 7230 and RFC 6455 to reserve that space. 20 Note to Readers 22 _RFC EDITOR: please remove this section before publication_ 24 This draft is a proposed revision of RFC5875. 26 The issues list for this draft can be found at 27 https://github.com/mnot/I-D/labels/rfc5785bis [1]. 29 The most recent (often, unpublished) draft is at 30 https://mnot.github.io/I-D/rfc5785bis/ [2]. 32 Recent changes are listed at https://github.com/mnot/I-D/commits/gh- 33 pages/rfc5785bis [3]. 35 See also the draft's current status in the IETF datatracker, at 36 https://datatracker.ietf.org/doc/draft-nottingham-rfc5785bis/ [4]. 38 Status of This Memo 40 This Internet-Draft is submitted in full conformance with the 41 provisions of BCP 78 and BCP 79. 43 Internet-Drafts are working documents of the Internet Engineering 44 Task Force (IETF). Note that other groups may also distribute 45 working documents as Internet-Drafts. The list of current Internet- 46 Drafts is at https://datatracker.ietf.org/drafts/current/. 48 Internet-Drafts are draft documents valid for a maximum of six months 49 and may be updated, replaced, or obsoleted by other documents at any 50 time. It is inappropriate to use Internet-Drafts as reference 51 material or to cite them other than as "work in progress." 53 This Internet-Draft will expire on August 30, 2019. 55 Copyright Notice 57 Copyright (c) 2019 IETF Trust and the persons identified as the 58 document authors. All rights reserved. 60 This document is subject to BCP 78 and the IETF Trust's Legal 61 Provisions Relating to IETF Documents 62 (https://trustee.ietf.org/license-info) in effect on the date of 63 publication of this document. Please review these documents 64 carefully, as they describe your rights and restrictions with respect 65 to this document. Code Components extracted from this document must 66 include Simplified BSD License text as described in Section 4.e of 67 the Trust Legal Provisions and are provided without warranty as 68 described in the Simplified BSD License. 70 Table of Contents 72 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 2 73 2. Notational Conventions . . . . . . . . . . . . . . . . . . . 3 74 3. Well-Known URIs . . . . . . . . . . . . . . . . . . . . . . . 3 75 3.1. Registering Well-Known URIs . . . . . . . . . . . . . . . 5 76 4. Security Considerations . . . . . . . . . . . . . . . . . . . 6 77 4.1. Interaction with Web Browsing . . . . . . . . . . . . . . 6 78 4.2. Scoping Applications . . . . . . . . . . . . . . . . . . 7 79 4.3. Hidden Capabilities . . . . . . . . . . . . . . . . . . . 8 80 5. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 8 81 5.1. The Well-Known URI Registry . . . . . . . . . . . . . . . 8 82 6. References . . . . . . . . . . . . . . . . . . . . . . . . . 8 83 6.1. Normative References . . . . . . . . . . . . . . . . . . 8 84 6.2. Informative References . . . . . . . . . . . . . . . . . 9 85 6.3. URIs . . . . . . . . . . . . . . . . . . . . . . . . . . 10 86 Appendix A. Frequently Asked Questions . . . . . . . . . . . . . 11 87 Appendix B. Changes from RFC5785 . . . . . . . . . . . . . . . . 11 88 Author's Address . . . . . . . . . . . . . . . . . . . . . . . . 11 90 1. Introduction 92 Some applications on the Web require the discovery of information 93 about an origin [RFC6454] (sometimes called "site-wide metadata") 94 before making a request. For example, the Robots Exclusion Protocol 95 (http://www.robotstxt.org/ [5]) specifies a way for automated 96 processes to obtain permission to access resources; likewise, the 97 Platform for Privacy Preferences [P3P] tells user-agents how to 98 discover privacy policy before interacting with an origin server. 100 While there are several ways to access per-resource metadata (e.g., 101 HTTP header fields, WebDAV's PROPFIND [RFC4918]), the perceived 102 overhead (either in terms of client-perceived latency and/or 103 deployment difficulties) associated with them often precludes their 104 use in these scenarios. 106 At the same time, it has become more popular to use HTTP as a 107 substrate for non-Web protocols. Sometimes, such protocols need a 108 way to locate one or more resources on a given host. 110 When this happens, one solution is to designate a "well-known 111 location" for data or services related to the origin overall, so that 112 it can be easily located. However, this approach has the drawback of 113 risking collisions, both with other such designated "well-known 114 locations" and with resources that the origin has created (or wishes 115 to create). Furthermore, defining well-known locations usurp's the 116 origin's control over its own URI space [RFC7320]. 118 To address these uses, this memo defines a path prefix in HTTP(S) 119 URIs for these "well-known locations", "/.well-known/". Future 120 specifications that need to define a resource for such metadata can 121 register their use to avoid collisions and minimise impingement upon 122 origins' URI space. 124 Well-known URIs can also be used with other URI schemes, but only 125 when those schemes' definitions explicitly allow it. 127 2. Notational Conventions 129 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 130 "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and 131 "OPTIONAL" in this document are to be interpreted as described in BCP 132 14 [RFC2119] [RFC8174] when, and only when, they appear in all 133 capitals, as shown here. 135 3. Well-Known URIs 137 A well-known URI is a URI [RFC3986] whose path component begins with 138 the characters "/.well-known/", and whose scheme is "http" [RFC7230], 139 "https" [RFC7230], "ws" [RFC6455], "wss" [RFC6455], or another scheme 140 that has explicitly been specified to use well-known URIs. 142 For example, if an application registers the name 'example', the 143 corresponding well-known URI on 'http://www.example.com/' would be 144 'http://www.example.com/.well-known/example'. 146 Applications that wish to mint new well-known URIs MUST register 147 them, following the procedures in Section 5.1, subject to the 148 following requirements. 150 Registered names MUST conform to the segment-nz production in 151 [RFC3986]. This means they cannot contain the "/" character. 153 Registered names for a specific application SHOULD be correspondingly 154 precise; "squatting" on generic terms is not encouraged. For 155 example, if the Example application wants a well-known location for 156 metadata, an appropriate registered name might be "example-metadata" 157 or even "example.com-metadata", not "metadata". 159 At a minimum, a registration will reference a specification that 160 defines the format and associated media type(s) to be obtained by 161 dereferencing the well-known URI, along with the URI scheme(s) that 162 the well-known URI can be used with. If no URI schemes are 163 explicitly specified, "http" and "https" are assumed. 165 Typically, applications will use the default port for the given 166 scheme; if an alternative port is used, it MUST be explicitly 167 specified by the application in question. 169 Registrations MAY also contain additional information, such as the 170 syntax of additional path components, query strings and/or fragment 171 identifiers to be appended to the well-known URI, or protocol- 172 specific details (e.g., HTTP [RFC7231] method handling). 174 Note that this specification defines neither how to determine the 175 hostname to use to find the well-known URI for a particular 176 application, nor the scope of the metadata discovered by 177 dereferencing the well-known URI; both should be defined by the 178 application itself. 180 Also, this specification does not define a format or media-type for 181 the resource located at "/.well-known/" and clients should not expect 182 a resource to exist at that location. 184 Well-known URIs are rooted in the top of the path's hierarchy; they 185 are not well-known by definition in other parts of the path. For 186 example, "/.well-known/example" is a well-known URI, whereas 187 "/foo/.well-known/example" is not. 189 See also Section 4 for Security Considerations regarding well-known 190 locations. 192 3.1. Registering Well-Known URIs 194 The "Well-Known URIs" registry is located at 195 "https://www.iana.org/assignments/well-known-uris/". Registration 196 requests can be made by following the instructions located there or 197 by sending an email to the "wellknown-uri-review@ietf.org" mailing 198 list. 200 Registration requests consist of at least the following information: 202 URI suffix: The name requested for the well-known URI, relative to 203 "/.well-known/"; e.g., "example". 205 Change controller: For Standards-Track RFCs, state "IETF". For 206 others, give the name of the responsible party. Other details 207 (e.g., e-mail address, home page URI) may also be included. 209 Specification document(s): Reference to the document that specifies 210 the field, preferably including a URI that can be used to retrieve 211 a copy of the document. An indication of the relevant sections 212 may also be included, but is not required. 214 Status: One of "permanent" or "provisional". See guidance below. 216 Related information: Optionally, citations to additional documents 217 containing further relevant information. 219 General requirements for registered values are described in 220 Section 3. 222 Values defined by standards-track RFCs and other open standards (in 223 the sense of [RFC2026], Section 7.1.1) have a status of "permanent". 224 Other values can also be registered as permanent, if the Experts find 225 that they are in use, in consultation with the community. Other 226 values should be registered as "provisional". 228 Provisional entries can be removed by the Experts if - in 229 consultation with the community - the Experts find that they are not 230 in use. The Experts can change a provisional entry's status to 231 permanent at any time. 233 Note that well-known URIs can be registered by third parties 234 (including the expert(s)), if the expert(s) determines that an 235 unregistered well-known URI is widely deployed and not likely to be 236 registered in a timely manner otherwise. Such registrations still 237 are subject to the requirements defined, including the need to 238 reference a specification. 240 4. Security Considerations 242 Applications minting new well-known URIs, as well as administrators 243 deploying them, will need to consider several security-related 244 issues, including (but not limited to) exposure of sensitive data, 245 denial-of-service attacks (in addition to normal load issues), server 246 and client authentication, vulnerability to DNS rebinding attacks, 247 and attacks where limited access to a server grants the ability to 248 affect how well-known URIs are served. 250 4.1. Interaction with Web Browsing 252 Applications using well-known URIs for "http" or "https" URLs need to 253 be aware that well-known resources will be accessible to Web 254 browsers, and therefore are able to be manipulated by content 255 obtained from other parts of that origin. If an attacker is able to 256 inject content (e.g., through a Cross-Site Scripting vulnerability), 257 they will be able to make potentially arbitrary requests to the well- 258 known resource. 260 HTTP and HTTPS also use origins as a security boundary for many other 261 mechanisms, including (but not limited to) Cookies [RFC6265], Web 262 Storage [WEBSTORAGE] and many capabilities. 264 Applications defining well-known locations should not assume that 265 they have sole access to these mechanisms, or that they are the only 266 application using the origin. Depending on the nature of the 267 application, mitigations can include: 269 o Encrypting sensitive information 271 o Allowing flexibility in the use of identifiers (e.g., Cookie 272 names) to avoid collisions with other applications 274 o Using the 'HttpOnly' flag on Cookies to assure that cookies are 275 not exposed to browser scripting languages [RFC6265] 277 o Using the 'Path' parameter on Cookies to assure that they are not 278 available to other parts of the origin [RFC6265] 280 o Using X-Content-Type-Options: nosniff [FETCH] to assure that 281 content under attacker control can't be coaxed into a form that is 282 interpreted as active content by a Web browser 284 Other good practices include: 286 o Using an application-specific media type in the Content-Type 287 header field, and requiring clients to fail if it is not used 289 o Using Content-Security-Policy [CSP] to constrain the capabilities 290 of active content (such as HTML [HTML5]), thereby mitigating 291 Cross-Site Scripting attacks 293 o Using Referrer-Policy [REFERRER-POLICY] to prevent sensitive data 294 in URLs from being leaked in the Referer request header field 296 o Avoiding use of compression on any sensitive information (e.g., 297 authentication tokens, passwords), as the scripting environment 298 offered by Web browsers allows an attacker to repeatedly probe the 299 compression space; if the attacker has access to the path of the 300 communication, they can use this capability to recover that 301 information. 303 4.2. Scoping Applications 305 This memo does not specify the scope of applicability for the 306 information obtained from a well-known URI, and does not specify how 307 to discover a well-known URI for a particular application. 309 Individual applications using this mechanism must define both 310 aspects; if this is not specified, security issues can arise from 311 implementation deviations and confusion about boundaries between 312 applications. 314 Applying metadata discovered in a well-known URI to resources other 315 than those co-located on the same origin risks administrative as well 316 as security issues. For example, allowing 317 "https://example.com/.well-known/example" to apply policy to 318 "https://department.example.com", "https://www.example.com" or even 319 "https://www.example.com:8000" assumes a relationship between hosts 320 where there might be none, giving control to a potential attacker. 322 Likewise, specifying that a well-known URI on a particular hostname 323 is to be used to bootstrap a protocol can cause a large number of 324 undesired requests. For example, if a well-known HTTPS URI is used 325 to find policy about a separate service such as e-mail, it can result 326 in a flood of requests to Web servers, even if they don't implement 327 the well-known URI. Such undesired requests can resemble a denial- 328 of-services attack. 330 4.3. Hidden Capabilities 332 Applications using well-known locations should consider that some 333 server administrators might be unaware of its existence (especially 334 on operating systems that hide directories whose names begin with 335 "."). This means that if an attacker has write access to the .well- 336 known directory, they would be able to control its contents, possibly 337 without the administrator realising it. 339 5. IANA Considerations 341 5.1. The Well-Known URI Registry 343 This specification updates the registration procedures for the "Well- 344 Known URI" registry, first defined in [RFC5785]; see Section 3.1. 346 Well-known URIs are registered on the advice of one or more Experts, 347 with a Specification Required (using terminology from [RFC8126]). 349 The Experts' primary considerations in evaluating registration 350 requests are: 352 o Conformance to the requirements in Section 3 354 o The availability and stability of the specifying document 356 o The considerations outlined in Section 4 358 IANA will direct any incoming requests regarding the registry to this 359 document and, if defined, the processes established by the expert(s); 360 typically, this will mean referring them to the registry Web page. 362 Upon publication, IANA should: 364 o Update the status of all existing registrations to "permanent". 366 6. References 368 6.1. Normative References 370 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 371 Requirement Levels", BCP 14, RFC 2119, 372 DOI 10.17487/RFC2119, March 1997, 373 . 375 [RFC3986] Berners-Lee, T., Fielding, R., and L. Masinter, "Uniform 376 Resource Identifier (URI): Generic Syntax", STD 66, 377 RFC 3986, DOI 10.17487/RFC3986, January 2005, 378 . 380 [RFC6454] Barth, A., "The Web Origin Concept", RFC 6454, 381 DOI 10.17487/RFC6454, December 2011, 382 . 384 [RFC6455] Fette, I. and A. Melnikov, "The WebSocket Protocol", 385 RFC 6455, DOI 10.17487/RFC6455, December 2011, 386 . 388 [RFC7230] Fielding, R., Ed. and J. Reschke, Ed., "Hypertext Transfer 389 Protocol (HTTP/1.1): Message Syntax and Routing", 390 RFC 7230, DOI 10.17487/RFC7230, June 2014, 391 . 393 [RFC8126] Cotton, M., Leiba, B., and T. Narten, "Guidelines for 394 Writing an IANA Considerations Section in RFCs", BCP 26, 395 RFC 8126, DOI 10.17487/RFC8126, June 2017, 396 . 398 [RFC8174] Leiba, B., "Ambiguity of Uppercase vs Lowercase in RFC 399 2119 Key Words", BCP 14, RFC 8174, DOI 10.17487/RFC8174, 400 May 2017, . 402 6.2. Informative References 404 [CSP] West, M., "Content Security Policy Level 3", World Wide 405 Web Consortium WD WD-CSP3-20160913, September 2016, 406 . 408 [FETCH] WHATWG, "Fetch - Living Standard", n.d., 409 . 411 [HTML5] WHATWG, "HTML - Living Standard", n.d., 412 . 414 [P3P] Marchiori, M., "The Platform for Privacy Preferences 1.0 415 (P3P1.0) Specification", World Wide Web Consortium 416 Recommendation REC-P3P-20020416, April 2002, 417 . 419 [REFERRER-POLICY] 420 Eisinger, J. and E. Stark, "Referrer Policy", World Wide 421 Web Consortium CR CR-referrer-policy-20170126, January 422 2017, 423 . 425 [RFC2026] Bradner, S., "The Internet Standards Process -- Revision 426 3", BCP 9, RFC 2026, DOI 10.17487/RFC2026, October 1996, 427 . 429 [RFC4918] Dusseault, L., Ed., "HTTP Extensions for Web Distributed 430 Authoring and Versioning (WebDAV)", RFC 4918, 431 DOI 10.17487/RFC4918, June 2007, 432 . 434 [RFC5785] Nottingham, M. and E. Hammer-Lahav, "Defining Well-Known 435 Uniform Resource Identifiers (URIs)", RFC 5785, 436 DOI 10.17487/RFC5785, April 2010, 437 . 439 [RFC6265] Barth, A., "HTTP State Management Mechanism", RFC 6265, 440 DOI 10.17487/RFC6265, April 2011, 441 . 443 [RFC7231] Fielding, R., Ed. and J. Reschke, Ed., "Hypertext Transfer 444 Protocol (HTTP/1.1): Semantics and Content", RFC 7231, 445 DOI 10.17487/RFC7231, June 2014, 446 . 448 [RFC7320] Nottingham, M., "URI Design and Ownership", BCP 190, 449 RFC 7320, DOI 10.17487/RFC7320, July 2014, 450 . 452 [WEBSTORAGE] 453 Hickson, I., "Web Storage (Second Edition)", World Wide 454 Web Consortium Recommendation REC-webstorage-20160419, 455 April 2016, 456 . 458 6.3. URIs 460 [1] https://github.com/mnot/I-D/labels/rfc5785bis 462 [2] https://mnot.github.io/I-D/rfc5785bis/ 464 [3] https://github.com/mnot/I-D/commits/gh-pages/rfc5785bis 466 [4] https://datatracker.ietf.org/doc/draft-nottingham-rfc5785bis/ 468 [5] http://www.robotstxt.org/ 470 Appendix A. Frequently Asked Questions 472 Aren't well-known locations bad for the Web? They are, but for 473 various reasons - both technical and social - they are sometimes 474 necessary. This memo defines a "sandbox" for them, to reduce the 475 risks of collision and to minimise the impact upon pre-existing 476 URIs on sites. 478 Why /.well-known? It's short, descriptive, and according to search 479 indices, not widely used. 481 What impact does this have on existing mechanisms, such as P3P and 482 robots.txt? 483 None, until they choose to use this mechanism. 485 Why aren't per-directory well-known locations defined? Allowing 486 every URI path segment to have a well-known location (e.g., 487 "/images/.well-known/") would increase the risks of colliding with 488 a pre-existing URI on a site, and generally these solutions are 489 found not to scale well, because they're too "chatty". 491 Appendix B. Changes from RFC5785 493 o Allow non-Web well-known locations 495 o Adjust IANA instructions 497 o Update references 499 o Various other clarifications 501 o Add "ws" and "wss" schemes 503 Author's Address 505 Mark Nottingham 507 Email: mnot@mnot.net 508 URI: https://www.mnot.net/