idnits 2.17.1 draft-ietf-httpbis-bcp56bis-05.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], [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 RFC3205, but the abstract doesn't seem to mention this, which it should. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year -- The document date (May 1, 2018) is 2180 days in the past. Is this intentional? Checking references for intended status: Best Current Practice ---------------------------------------------------------------------------- (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 1328 -- Looks like a reference, but probably isn't: '2' on line 1330 -- Looks like a reference, but probably isn't: '3' on line 1332 ** Obsolete normative reference: RFC 2818 (Obsoleted by RFC 9110) ** Obsolete normative reference: RFC 7230 (Obsoleted by RFC 9110, RFC 9112) ** Obsolete normative reference: RFC 7231 (Obsoleted by RFC 9110) ** Obsolete normative reference: RFC 7232 (Obsoleted by RFC 9110) ** Obsolete normative reference: RFC 7233 (Obsoleted by RFC 9110) ** Obsolete normative reference: RFC 7234 (Obsoleted by RFC 9111) ** Obsolete normative reference: RFC 7235 (Obsoleted by RFC 9110) ** Obsolete normative reference: RFC 7320 (Obsoleted by RFC 8820) ** Obsolete normative reference: RFC 7540 (Obsoleted by RFC 9113) == Outdated reference: A later version (-19) exists of draft-ietf-httpbis-header-structure-04 -- Obsolete informational reference (is this intentional?): RFC 793 (Obsoleted by RFC 9293) -- Obsolete informational reference (is this intentional?): RFC 3205 (Obsoleted by RFC 9205) -- Obsolete informational reference (is this intentional?): RFC 5785 (Obsoleted by RFC 8615) -- Obsolete informational reference (is this intentional?): RFC 7049 (Obsoleted by RFC 8949) -- Obsolete informational reference (is this intentional?): RFC 7538 (Obsoleted by RFC 9110) -- Obsolete informational reference (is this intentional?): RFC 7807 (Obsoleted by RFC 9457) Summary: 10 errors (**), 0 flaws (~~), 2 warnings (==), 11 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 HTTP M. Nottingham 3 Internet-Draft May 1, 2018 4 Obsoletes: 3205 (if approved) 5 Intended status: Best Current Practice 6 Expires: November 2, 2018 8 On the use of HTTP as a Substrate 9 draft-ietf-httpbis-bcp56bis-05 11 Abstract 13 HTTP is often used as a substrate for other application protocols 14 (a.k.a. HTTP-based APIs). This document specifies best practices 15 for these protocols' use of HTTP. 17 Note to Readers 19 Discussion of this draft takes place on the HTTP working group 20 mailing list (ietf-http-wg@w3.org), which is archived at 21 https://lists.w3.org/Archives/Public/ietf-http-wg/ [1]. 23 Working Group information can be found at http://httpwg.github.io/ 24 [2]; source code and issues list for this draft can be found at 25 https://github.com/httpwg/http-extensions/labels/bcp56bis [3]. 27 Status of This Memo 29 This Internet-Draft is submitted in full conformance with the 30 provisions of BCP 78 and BCP 79. 32 Internet-Drafts are working documents of the Internet Engineering 33 Task Force (IETF). Note that other groups may also distribute 34 working documents as Internet-Drafts. The list of current Internet- 35 Drafts is at https://datatracker.ietf.org/drafts/current/. 37 Internet-Drafts are draft documents valid for a maximum of six months 38 and may be updated, replaced, or obsoleted by other documents at any 39 time. It is inappropriate to use Internet-Drafts as reference 40 material or to cite them other than as "work in progress." 42 This Internet-Draft will expire on November 2, 2018. 44 Copyright Notice 46 Copyright (c) 2018 IETF Trust and the persons identified as the 47 document authors. All rights reserved. 49 This document is subject to BCP 78 and the IETF Trust's Legal 50 Provisions Relating to IETF Documents 51 (https://trustee.ietf.org/license-info) in effect on the date of 52 publication of this document. Please review these documents 53 carefully, as they describe your rights and restrictions with respect 54 to this document. Code Components extracted from this document must 55 include Simplified BSD License text as described in Section 4.e of 56 the Trust Legal Provisions and are provided without warranty as 57 described in the Simplified BSD License. 59 Table of Contents 61 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 3 62 1.1. Notational Conventions . . . . . . . . . . . . . . . . . 4 63 2. Is HTTP Being Used? . . . . . . . . . . . . . . . . . . . . . 4 64 3. What's Important About HTTP . . . . . . . . . . . . . . . . . 5 65 3.1. Generic Semantics . . . . . . . . . . . . . . . . . . . . 5 66 3.2. Links . . . . . . . . . . . . . . . . . . . . . . . . . . 6 67 3.3. Rich Functionality . . . . . . . . . . . . . . . . . . . 7 68 4. Best Practices for Using HTTP . . . . . . . . . . . . . . . . 7 69 4.1. Specifying the Use of HTTP . . . . . . . . . . . . . . . 8 70 4.2. Defining HTTP Resources . . . . . . . . . . . . . . . . . 8 71 4.3. Specifying Client Behaviours . . . . . . . . . . . . . . 9 72 4.4. HTTP URLs . . . . . . . . . . . . . . . . . . . . . . . . 10 73 4.4.1. Initial URL Discovery . . . . . . . . . . . . . . . . 11 74 4.4.2. URL Schemes . . . . . . . . . . . . . . . . . . . . . 11 75 4.4.3. Transport Ports . . . . . . . . . . . . . . . . . . . 12 76 4.5. HTTP Methods . . . . . . . . . . . . . . . . . . . . . . 12 77 4.5.1. GET . . . . . . . . . . . . . . . . . . . . . . . . . 13 78 4.5.2. OPTIONS . . . . . . . . . . . . . . . . . . . . . . . 14 79 4.6. HTTP Status Codes . . . . . . . . . . . . . . . . . . . . 14 80 4.6.1. Redirection . . . . . . . . . . . . . . . . . . . . . 16 81 4.7. HTTP Header Fields . . . . . . . . . . . . . . . . . . . 17 82 4.8. Defining Message Payloads . . . . . . . . . . . . . . . . 18 83 4.9. HTTP Caching . . . . . . . . . . . . . . . . . . . . . . 18 84 4.10. Application State . . . . . . . . . . . . . . . . . . . . 20 85 4.11. Client Authentication . . . . . . . . . . . . . . . . . . 20 86 4.12. Co-Existing with Web Browsing . . . . . . . . . . . . . . 21 87 4.13. Application Boundaries . . . . . . . . . . . . . . . . . 22 88 4.14. Server Push . . . . . . . . . . . . . . . . . . . . . . . 23 89 5. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 24 90 6. Security Considerations . . . . . . . . . . . . . . . . . . . 24 91 7. References . . . . . . . . . . . . . . . . . . . . . . . . . 24 92 7.1. Normative References . . . . . . . . . . . . . . . . . . 24 93 7.2. Informative References . . . . . . . . . . . . . . . . . 26 94 7.3. URIs . . . . . . . . . . . . . . . . . . . . . . . . . . 29 95 Appendix A. Changes from RFC 3205 . . . . . . . . . . . . . . . 29 96 Author's Address . . . . . . . . . . . . . . . . . . . . . . . . 29 98 1. Introduction 100 HTTP [RFC7230] is often used as a substrate for applications other 101 than Web browsing; this is sometimes referred to as creating "HTTP- 102 based APIs", or just "HTTP APIs". This is done for a variety of 103 reasons, including: 105 o familiarity by implementers, specifiers, administrators, 106 developers and users, 108 o availability of a variety of client, server and proxy 109 implementations, 111 o ease of use, 113 o availability of Web browsers, 115 o reuse of existing mechanisms like authentication and encryption, 117 o presence of HTTP servers and clients in target deployments, and 119 o its ability to traverse firewalls. 121 These protocols are often ad hoc; they are intended for only 122 deployment by one or a few servers, and consumption by a limited set 123 of clients. As a result, a body of practices and tools has arisen 124 around defining HTTP-based APIs that favours these conditions. 126 However, when such a protocol is standarised, it is typically 127 deployed on multiple uncoordinated servers, implemented a number of 128 times, and consumed by a broader variety of clients. Such diversity 129 brings a different set of concerns, and tools and practices intended 130 for a single-server deployment might not be suitable. 132 For example, HTTP-based APIs deployed in these circumstances need to 133 more carefully consider how extensibility and evolution of the 134 service will be handled, how different deployment requirements will 135 be accommodated, and how clients will evolve with the API. 137 More generally, application protocols using HTTP face a number of 138 design decisions, including: 140 o Should it define a new URL scheme? Use new ports? 142 o Should it use standard HTTP methods and status codes, or define 143 new ones? 145 o How can the maximum value be extracted from the use of HTTP? 146 o How does it coexist with other uses of HTTP - especially Web 147 browsing? 149 o How can interoperability problems and "protocol dead ends" be 150 avoided? 152 This document contains best current practices regarding the use of 153 HTTP by applications other than Web browsing. Section 2 defines what 154 applications it applies to; Section 3 surveys the properties of HTTP 155 that are important to preserve, and Section 4 conveys best practices 156 for those applications that do use HTTP. 158 It is written primarily to guide IETF efforts to define application 159 protocols using HTTP for deployment on the Internet, but might be 160 applicable in other situations. Note that the requirements herein do 161 not necessarily apply to the development of generic HTTP extensions. 163 1.1. Notational Conventions 165 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 166 "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and 167 "OPTIONAL" in this document are to be interpreted as described in BCP 168 14 [RFC2119] [RFC8174] when, and only when, they appear in all 169 capitals, as shown here. 171 2. Is HTTP Being Used? 173 Different applications have different goals when using HTTP. In this 174 document, we say an application is "using HTTP" when any of the 175 following conditions are true: 177 o The transport port in use is 80 or 443, 179 o The URL scheme "http" or "https" is used, 181 o The ALPN protocol ID [RFC7301] generically identifies HTTP (e.g., 182 "http/1.1", "h2", "h2c"), or 184 o The IANA registries defined for HTTP are updated or modified. 186 When an application is using HTTP, all of the requirements of the 187 HTTP protocol suite are in force (including but not limited to 188 [RFC7230], [RFC7231], [RFC7232], [RFC7233], [RFC7234], [RFC7235] and 189 [RFC7540]). 191 An application might not be using HTTP according to this definition, 192 but still relying upon the HTTP specifications in some manner. For 193 example, an application might wish to avoid re-specifying parts of 194 the message format, but change others; or, it might want to use a 195 different set of methods. 197 Such applications are referred to as "protocols based upon HTTP" in 198 this document. These have more freedom to modify protocol 199 operations, but are also likely to lose at least a portion of the 200 benefits outlined above, as most HTTP implementations won't be easily 201 adaptable to these changes, and as the protocol diverges from HTTP, 202 the benefit of mindshare will be lost. 204 Protocols that are based upon HTTP MUST NOT reuse HTTP's URL schemes, 205 transport ports, ALPN protocol IDs or IANA registries; rather, they 206 are encouraged to establish their own. 208 3. What's Important About HTTP 210 There are many ways that applications using HTTP are defined and 211 deployed, and sometimes they are brought to the IETF for 212 standardisation. In that process, what might be workable for 213 deployment in a limited fashion isn't appropriate for standardisation 214 and the corresponding broader deployment. 216 This section examines the facets of the protocol that are important 217 to preserve in these situations. 219 3.1. Generic Semantics 221 When writing an application's specification, it's often tempting to 222 specify exactly how HTTP is to be implemented, supported and used. 224 However, this can easily lead to an unintended profile of HTTP's 225 behaviour. For example, it's common to see specifications with 226 language like this: 228 A `POST` request MUST result in a `201 Created` response. 230 This forms an expectation in the client that the response will always 231 be "201 Created", when in fact there are a number of reasons why the 232 status code might differ in a real deployment. If the client does 233 not anticipate this, the application's deployment is brittle. 235 Much of the value of HTTP is in its generic semantics - that is, the 236 protocol elements defined by HTTP are potentially applicable to every 237 resource, not specific to a particular context. Application-specific 238 semantics are expressed in the payload; mostly, in the body, but also 239 in header fields. 241 This allows a HTTP message to be examined by generic HTTP software 242 (e.g., HTTP servers, intermediaries, client implementations), and its 243 handling to be correctly determined. It also allows people to 244 leverage their knowledge of HTTP semantics without special-casing 245 them for a particular application. 247 Therefore, applications that use HTTP MUST NOT re-define, refine or 248 overlay the semantics of defined protocol elements. Instead, they 249 should focus their specifications on protocol elements that are 250 specific to that application; namely their HTTP resources. 252 See Section 4.2 for details. 254 3.2. Links 256 Another common practice is assuming that the HTTP server's name space 257 (or a portion thereof) is exclusively for the use of a single 258 application. This effectively overlays special, application-specific 259 semantics onto that space, precludes other applications from using 260 it. 262 As explained in [RFC7320], such "squatting" on a part of the URL 263 space by a standard usurps the server's authority over its own 264 resources, can cause deployment issues, and is therefore bad practice 265 in standards. 267 Instead of statically defining URL components like paths, it is 268 RECOMMENDED that applications using HTTP define links in payloads, to 269 allow flexibility in deployment. 271 Using runtime links in this fashion has a number of other benefits - 272 especially when an application is to have multiple implementations 273 and/or deployments (as is often the case for those that are 274 standardised). 276 For example, navigating with a link allows a request to be routed to 277 a different server without the overhead of a redirection, thereby 278 supporting deployment across machines well. 280 It also becomes possible to "mix and match" different applications on 281 the same server, and offers a natural mechanism for extensibility, 282 versioning and capability management, since the document containing 283 the links can also contain information about their targets. 285 Using links also offers a form of cache invalidation that's seen on 286 the Web; when a resource's state changes, the application can change 287 its link to it so that a fresh copy is always fetched. 289 3.3. Rich Functionality 291 The simplest possible use of HTTP is to POST data to a single URL, 292 thereby effectively tunnelling through the protocol. 294 This "RPC" style of communication does get some benefit from using 295 HTTP - namely, message framing and the availability of 296 implementations - but fails to realise many others when used 297 exclusively: 299 o Caching for server scalability, latency and bandwidth reduction, 300 and reliability; 302 o Granularity of access control (through use of a rich space of 303 URLs); 305 o Partial content to selectively request part of a response; 307 o Definition of an information space using URLs; and 309 o The ability to interact with the application easily using a Web 310 browser. 312 Using such a high-level protocol to tunnel simple semantics has 313 downsides too; because of its more advanced capabilities, breadth of 314 deployment and age, HTTP's complexity can cause interoperability 315 problems that could be avoided by using a simpler substrate (e.g., 316 WebSockets [RFC6455], if browser support is necessary, or TCP 317 [RFC0793] if not), or making the application be based upon HTTP, 318 instead of using it (as defined in Section 2). 320 Applications that use HTTP are encouraged to accommodate the various 321 features that the protocol offers, so that their users receive the 322 maximum benefit from it. This document does not require specific 323 features to be used, since the appropriate design tradeoffs are 324 highly specific to a given situation. However, following the 325 practices in Section 4 will help make them available. 327 4. Best Practices for Using HTTP 329 This section contains best practices regarding the use of HTTP by 330 applications, including practices for specific HTTP protocol 331 elements. 333 4.1. Specifying the Use of HTTP 335 When specifying the use of HTTP, an application SHOULD use [RFC7230] 336 as the primary reference; it is not necessary to reference all of the 337 specifications in the HTTP suite unless there are specific reasons to 338 do so (e.g., a particular feature is called out). 340 Applications using HTTP SHOULD NOT specify a minimum version of HTTP 341 to be used; because it is a hop-by-hop protocol, a HTTP connection 342 can be handled by implementations that are not controlled by the 343 application; for example, proxies, CDNs, firewalls and so on. 344 Requiring a particular version of HTTP makes it difficult to use in 345 these situations, and harms interoperability for little reason (since 346 HTTP's semantics are stable between protocol versions). 348 However, if an application's deployment would benefit from the use of 349 a particular version of HTTP (for example, HTTP/2's multiplexing), 350 this SHOULD be noted. 352 Applications using HTTP MUST NOT specify a maximum version, to 353 preserve the protocol's ability to evolve. 355 When specifying examples of protocol interactions, applications 356 SHOULD document both the request and response messages, with full 357 headers, preferably in HTTP/1.1 format. For example: 359 GET /thing HTTP/1.1 360 Host: example.com 361 Accept: application/things+json 362 User-Agent: Foo/1.0 364 HTTP/1.1 200 OK 365 Content-Type: application/things+json 366 Content-Length: 500 367 Server: Bar/2.2 369 [payload here] 371 4.2. Defining HTTP Resources 373 Applications that use HTTP should focus on defining the following 374 application-specific protocol elements: 376 o Media types [RFC6838], often based upon a format convention such 377 as JSON [RFC8259], 379 o HTTP header fields, as per Section 4.7, and 380 o The behaviour of resources, as identified by link relations 381 [RFC8288]. 383 By composing these protocol elements, an application can define a set 384 of resources, identified by link relations, that implement specified 385 behaviours, including: 387 o Retrieval of their state using GET, in one or more formats 388 identified by media type; 390 o Resource creation or update using POST or PUT, with an 391 appropriately identified request body format; 393 o Data processing using POST and identified request and response 394 body format(s); and 396 o Resource deletion using DELETE. 398 For example, an application might specify: 400 Resources linked to with the "example-widget" link relation type are 401 Widgets. The state of a Widget can be fetched in the 402 "application/example-widget+json" format, and can be updated by PUT 403 to the same link. Widget resources can be deleted. 405 The "Example-Count" response header field on Widget representations 406 indicates how many Widgets are held by the sender. 408 The "application/example-widget+json" format is a JSON [RFC8259] 409 format representing the state of a Widget. It contains links to 410 related information in the link indicated by the Link header field 411 value with the "example-other-info" link relation type. 413 4.3. Specifying Client Behaviours 415 HTTP does not mandate some behaviours that have nevertheless become 416 very common; if these are not explicitly specified by applications 417 using HTTP, there may be confusion and interoperability problems. 418 This section recommends default handling for these mechanisms. 420 o Redirect handling - Applications need to specify how redirects are 421 expected to be handled; see Section 4.6.1. 423 o Cookies - Applications using HTTP MUST explicitly reference the 424 Cookie specification [RFC6265] if they are required. 426 o Certificates - Applications using HTTP MUST specify that TLS 427 certificates are to be checked according to [RFC2818] when HTTPS 428 is used. 430 In general, applications using HTTP ought to align their usage as 431 closely as possible with Web browsers, to avoid interoperability 432 issues when they are used. See Section 4.12. 434 If an application using HTTP has browser compatibility as a goal, 435 client interaction ought to be defined in terms of [FETCH], since 436 that is the abstraction that browsers use for HTTP; it enforces many 437 of these best practices. 439 Applications using HTTP MUST NOT require HTTP features that are 440 usually negotiated to be supported. For example, requiring that 441 clients support responses with a certain content-encoding ([RFC7231], 442 Section 3.1.2.2) instead of negotiating for it ([RFC7231], 443 Section 5.3.4) means that otherwise conformant clients cannot 444 interoperate with the application. Applications MAY encourage the 445 implementation of such features, though. 447 4.4. HTTP URLs 449 In HTTP, URLs are opaque identifiers under the control of the server. 450 As outlined in [RFC7320], standards cannot usurp this space, since it 451 might conflict with existing resources, and constrain implementation 452 and deployment. 454 In other words, applications that use HTTP shouldn't associate 455 application semantics with specific URL paths on arbitrary servers. 456 Doing so inappropriately conflates the identity of the resource (its 457 URL) with the capabilities that resource supports, bringing about 458 many of the same interoperability problems that [RFC4367] warns of. 460 For example, specifying that a "GET to the URL /foo retrieves a bar 461 document" is bad practice. Likewise, specifying "The widget API is 462 at the path /bar" violates [RFC7320]. 464 Instead, applications that use HTTP are encouraged to ensure that 465 URLs are discovered at runtime, allowing HTTP-based services to 466 describe their own capabilities. One way to do this is to use typed 467 links [RFC8288] to convey the URIs that are in use, as well as the 468 semantics of the resources that they identify. See Section 4.2 for 469 details. 471 4.4.1. Initial URL Discovery 473 Generally, a client will begin interacting with a given application 474 server by requesting an initial document that contains information 475 about that particular deployment, potentially including links to 476 other relevant resources. 478 Applications that use HTTP are encouraged to allow an arbitrary URL 479 to be used as that entry point. For example, rather than specifying 480 "the initial document is at "/foo/v1", they should allow a deployment 481 to use any URL as the entry point for the application. 483 In cases where doing so is impractical (e.g., it is not possible to 484 convey a whole URL, but only a hostname) standard applications that 485 use HTTP can request a well-known URL [RFC5785] as an entry point. 487 4.4.2. URL Schemes 489 Applications that use HTTP will typically employ the "http" and/or 490 "https" URL schemes. "https" is RECOMMENDED to provide 491 authentication, integrity and confidentiality, as well as mitigate 492 pervasive monitoring attacks [RFC7258]. 494 However, application-specific schemes can be defined as well. 496 When defining an URL scheme for an application using HTTP, there are 497 a number of tradeoffs and caveats to keep in mind: 499 o Unmodified Web browsers will not support the new scheme. While it 500 is possible to register new URL schemes with Web browsers (e.g. 501 registerProtocolHandler() in [HTML5], as well as several 502 proprietary approaches), support for these mechanisms is not 503 shared by all browsers, and their capabilities vary. 505 o Existing non-browser clients, intermediaries, servers and 506 associated software will not recognise the new scheme. For 507 example, a client library might fail to dispatch the request; a 508 cache might refuse to store the response, and a proxy might fail 509 to forward the request. 511 o Because URLs occur in HTTP artefacts commonly, often being 512 generated automatically (e.g., in the "Location" response header), 513 it can be difficult to assure that the new scheme is used 514 consistently. 516 o The resources identified by the new scheme will still be available 517 using "http" and/or "https" URLs. Those URLs can "leak" into use, 518 which can present security and operability issues. For example, 519 using a new scheme to assure that requests don't get sent to a 520 "normal" Web site is likely to fail. 522 o Features that rely upon the URL's origin [RFC6454], such as the 523 Web's same-origin policy, will be impacted by a change of scheme. 525 o HTTP-specific features such as cookies [RFC6265], authentication 526 [RFC7235], caching [RFC7234], and CORS [FETCH] might or might not 527 work correctly, depending on how they are defined and implemented. 528 Generally, they are designed and implemented with an assumption 529 that the URL will always be "http" or "https". 531 o Web features that require a secure context [SECCTXT] will likely 532 treat a new scheme as insecure. 534 See [RFC7595] for more information about minting new URL schemes. 536 4.4.3. Transport Ports 538 Applications that use HTTP can use the applicable default port (80 539 for HTTP, 443 for HTTPS), or they can be deployed upon other ports. 540 This decision can be made at deployment time, or might be encouraged 541 by the application's specification (e.g., by registering a port for 542 that application). 544 If a non-default port is used, it needs to be reflected in the 545 authority of all URLs for that resource; the only mechanism for 546 changing a default port is changing the scheme (see Section 4.4.2). 548 Using a port other than the default has privacy implications (i.e., 549 the protocol can now be distinguished from other traffic), as well as 550 operability concerns (as some networks might block or otherwise 551 interfere with it). Privacy implications should be documented in 552 Security Considerations. 554 See [RFC7605] for further guidance. 556 4.5. HTTP Methods 558 Applications that use HTTP MUST confine themselves to using 559 registered HTTP methods such as GET, POST, PUT, DELETE, and PATCH. 561 New HTTP methods are rare; they are required to be registered with 562 IETF Review (see [RFC7232]), and are also required to be generic. 563 That means that they need to be potentially applicable to all 564 resources, not just those of one application. 566 While historically some applications (e.g., [RFC4791]) have defined 567 non-generic methods, [RFC7231] now forbids this. 569 When authors believe that a new method is required, they are 570 encouraged to engage with the HTTP community early, and document 571 their proposal as a separate HTTP extension, rather than as part of 572 an application's specification. 574 4.5.1. GET 576 GET is one of the most common and useful HTTP methods; its retrieval 577 semantics allow caching, side-effect free linking and forms the basis 578 of many of the benefits of using HTTP. 580 A common use of GET is to perform queries, often using the query 581 component of the URL; this is this a familiar pattern from Web 582 browsing, and the results can be cached, improving efficiency of an 583 often expensive process. 585 In some cases, however, GET might be unwieldy for expressing queries, 586 because of the limited syntax of the URL; in particular, if binary 587 data forms part of the query terms, it needs to be encoded to conform 588 to URL syntax. 590 While this is not an issue for short queries, it can become one for 591 larger query terms, or ones which need to sustain a high rate of 592 requests. Additionally, some HTTP implementations limit the size of 593 URLs they support - although modern HTTP software has much more 594 generous limits than previously (typically, considerably more than 595 8000 octets, as required by [RFC7230], Section 3.1.1). 597 In these cases, an application using HTTP might consider using POST 598 to express queries in the request body; doing so avoids encoding 599 overhead and URL length limits in implementations. However, in doing 600 so it should be noted that the benefits of GET such as caching and 601 linking to query results are lost. Therefore, applications using 602 HTTP that feel a need to allow POST queries ought consider allowing 603 both methods. 605 Applications that use HTTP SHOULD NOT define GET requests to have 606 side effects, since implementations can and do retry HTTP GET 607 requests that fail. 609 Finally, note that while HTTP allows GET requests to have a body 610 syntactically, this is done only to allow parsers to be generic; as 611 per [RFC7231], Section 4.3.1, a body on a GET has no meaning, and 612 will be either ignored or rejected by generic HTTP software. 614 4.5.2. OPTIONS 616 The OPTIONS method was defined for metadata retrieval, and is used 617 both by WebDAV [RFC4918] and CORS [FETCH]. Because HTTP-based APIs 618 often need to retrieve metadata about resources, it is often 619 considered for their use. 621 However, OPTIONS does have significant limitations: 623 o It isn't possible to link to the metadata with a simple URL, 624 because OPTIONS is not the default GET method. 626 o OPTIONS responses are not cacheable, because HTTP caches operate 627 on representations of the resource (i.e., GET and HEAD). If 628 OPTIONS responses are cached separately, their interaction with 629 HTTP cache expiry, secondary keys and other mechanisms needs to be 630 considered. 632 o OPTIONS is "chatty" - always separating metadata out into a 633 separate request increases the number of requests needed to 634 interact with the application. 636 o Implementation support for OPTIONS is not universal; some servers 637 do not expose the ability to respond to OPTIONS requests without 638 significant effort. 640 Instead of OPTIONS, one of these alternative approaches might be more 641 appropriate: 643 o For server-wide metadata, create a well-known URI [RFC5785], or 644 using an already existing one if it's appropriate (e.g., HostMeta 645 [RFC6415]). 647 o For metadata about a specific resource, use a Link response 648 header, or a link in the representation format for that resource. 649 See [RFC8288]. Note that the Link header is available on HEAD 650 responses, which is useful if the client wants to discover a 651 resource's capabilities before they interact with it. 653 4.6. HTTP Status Codes 655 The primary function of a HTTP status code is to convey semantics for 656 the benefit of generic HTTP software, not to convey application- 657 specific semantics. 659 In particular, status codes are often generated or overwritten by 660 intermediaries, as well as server and client implementations; for 661 example, when network errors are encountered, a captive portal is 662 present, when an implementation is overloaded, or it thinks it is 663 under attack. As a result, the status code that a server-side 664 application generates and the one that the client software receives 665 often differ. 667 This means that status codes are not a reliable way to carry 668 application-specific signals. Specifying that a particular status 669 code has a specific meaning in the context of an application can have 670 unintended side effects; if that status code is generated by a 671 generic HTTP component can lead clients to believe that the 672 application is in a state that wasn't intended. 674 Instead, applications using HTTP should specify the implications of 675 general classes of responses (e.g., "successful response" for 2xx; 676 "client error" for 4xx and "server error" for 5xx), conveying any 677 application-specific information in the message body and/or HTTP 678 header fields, not the status code. [RFC7807] provides one way for 679 applications using HTTP to do so for error conditions. 681 There are limited exceptions to this; for example, applications might 682 use 201 (Created) or 404 (Not Found) to convey application semantics 683 that are compatible with the generic HTTP semantics of those status 684 codes. In general, though, applications should resist the temptation 685 to map their semantics into fine-grained status codes. 687 Because the set of registered HTTP status codes can expand, 688 applications using HTTP should explicitly point out that clients 689 ought to be able to handle all applicable status codes gracefully 690 (i.e., falling back to the generic "n00" semantics of a given status 691 code; e.g., "499" can be safely handled as "400" by clients that 692 don't recognise it). This is preferable to creating a "laundry list" 693 of potential status codes, since such a list is never complete. 695 Applications using HTTP MUST NOT re-specify the semantics of HTTP 696 status codes, even if it is only by copying their definition. They 697 MUST NOT require specific reason phrases to be used; the reason 698 phrase has no function in HTTP, and is not guaranteed to be preserved 699 by implementations, and the reason phrase is not carried at all in 700 the [RFC7540] message format. 702 Applications that use HTTP MUST only use registered HTTP status 703 codes. As with methods, new HTTP status codes are rare, and required 704 (by [RFC7231]) to be registered with IETF review. Similarly, HTTP 705 status codes are generic; they are required (by [RFC7231]) to be 706 potentially applicable to all resources, not just to those of one 707 application. 709 When authors believe that a new status code is required, they are 710 encouraged to engage with the HTTP community early, and document 711 their proposal as a separate HTTP extension, rather than as part of 712 an application's specification. 714 4.6.1. Redirection 716 The 3xx series of status codes specified in [RFC7231], Section 6.4 717 are used to direct the user agent to another resource to satisfy the 718 request. The most common of these are 301, 302, 307 and 308 719 ([RFC7538]), all of which use the Location response header field to 720 indicate where the client should send the request to. 722 There are two ways that this group of status codes differ: 724 o Whether they are permanent or temporary. Permanent redirects can 725 be used to update links stored in the client (e.g., bookmarks), 726 whereas temporary ones can not. Note that this has no effect on 727 HTTP caching; it is completely separate. 729 o Whether they allow the redirected request to change the request 730 method from POST to GET. Web browsers generally do change POST to 731 GET for 301 and 302; therefore, 308 and 307 were created to allow 732 redirection without changing the method. 734 This table summarises their relationships: 736 +-------------------------------------------+-----------+-----------+ 737 | | Permanent | Temporary | 738 +-------------------------------------------+-----------+-----------+ 739 | Allows changing the request method from | 301 | 302 | 740 | POST to GET | | | 741 | Does not allow changing the request | 308 | 307 | 742 | method | | | 743 +-------------------------------------------+-----------+-----------+ 745 As noted in [RFC7231], a user agent is allowed to automatically 746 follow a 3xx redirect that has a Location response header field, even 747 if they don't understand the semantics of the specific status code. 748 However, they aren't required to do so; therefore, if an application 749 using HTTP desires redirects to be automatically followed, it needs 750 to explicitly specify the circumstances when this is required. 752 Applications using HTTP SHOULD specify that 301 and 302 responses 753 change the subsequent request method from POST (but no other method) 754 to GET, to be compatible with browsers. 756 Generally, when a redirected request is made, its header fields are 757 copied from the original request's. However, they can be modified by 758 various mechanisms; e.g., sent Authorization ([RFC7235]) and Cookie 759 ([RFC6265]) headers will change if the origin (and sometimes path) of 760 the request changes. Applications using HTTP SHOULD specify if any 761 request headers need to be modified or removed upon a redirect; 762 however, this behaviour cannot be relied upon, since a generic client 763 (like a browser) will be unaware of such requirements. 765 4.7. HTTP Header Fields 767 Applications that use HTTP MAY define new HTTP header fields. 768 Typically, using HTTP header fields is appropriate in a few different 769 situations: 771 o Their content is useful to intermediaries (who often wish to avoid 772 parsing the body), and/or 774 o Their content is useful to generic HTTP software (e.g., clients, 775 servers), and/or 777 o It is not possible to include their content in the message body 778 (usually because a format does not allow it). 780 New header fields MUST be registered, as per [RFC7231] and [RFC3864]. 782 See [RFC7231], Section 8.3.1 for guidelines to consider when minting 783 new header fields. [I-D.ietf-httpbis-header-structure] provides a 784 common structure for new header fields, and avoids many issues in 785 their parsing and handling; it is RECOMMENDED that new header fields 786 use it. 788 It is RECOMMENDED that header field names be short (even when HTTP/2 789 header compression is in effect, there is an overhead) but 790 appropriately specific. In particular, if a header field is specific 791 to an application, an identifier for that application SHOULD form a 792 prefix to the header field name, separated by a "-". 794 For example, if the "example" application needs to create three 795 headers, they might be called "example-foo", "example-bar" and 796 "example-baz". Note that the primary motivation here is to avoid 797 consuming more generic header names, not to reserve a portion of the 798 namespace for the application; see [RFC6648] for related 799 considerations. 801 The semantics of existing HTTP header fields MUST NOT be re-defined 802 without updating their registration or defining an extension to them 803 (if allowed). For example, an application using HTTP cannot specify 804 that the "Location" header has a special meaning in a certain 805 context. 807 See Section 4.9 for the interaction between headers and HTTP caching; 808 in particular, request headers that are used to "select" a response 809 have impact there, and need to be carefully considered. 811 See Section 4.10 for considerations regarding header fields that 812 carry application state (e.g., Cookie). 814 4.8. Defining Message Payloads 816 There are many potential formats for payloads; for example, JSON 817 [RFC8259], XML [XML], and CBOR [RFC7049]. Best practices for their 818 use are out of scope for this document. 820 Applications SHOULD register distinct media types for each format 821 they define; this makes it possible to identify them unambiguously 822 and negotiate for their use. See [RFC6838] for more information. 824 4.9. HTTP Caching 826 HTTP caching [RFC7234] is one of the primary benefits of using HTTP 827 for applications; it provides scalability, reduces latency and 828 improves reliability. Furthermore, HTTP caches are readily available 829 in browsers and other clients, networks as forward and reverse 830 proxies, Content Delivery Networks and as part of server software. 832 Assigning even a short freshness lifetime ([RFC7234], Section 4.2) - 833 e.g., 5 seconds - allows a response to be reused to satisfy multiple 834 clients, and/or a single client making the same request repeatedly. 835 In general, if it is safe to reuse something, consider assigning a 836 freshness lifetime; cache implementations take active measures to 837 remove content intelligently when they are out of space, so "it will 838 fill up the cache" is not a valid concern. 840 The most common method for specifying freshness is the max-age 841 response directive ([RFC7234], Section 5.2.2.8). The Expires header 842 ([RFC7234], Section 5.3) can also be used, but it is not necessary to 843 specify it; all modern cache implementations support Cache-Control, 844 and specifying freshness as a delta is both more convenient in most 845 cases, and less error-prone. 847 Understand that stale responses (e.g., one with "Cache-Control: max- 848 age=0") can be reused when the cache is disconnected from the origin 849 server; this can be useful for handling network issues. See 850 [RFC7234], Section 4.2.4, and also [RFC5861] for additional controls 851 over stale content. 853 Stale responses can be refreshed by assigning a validator, saving 854 both transfer bandwidth and latency for large responses; see 855 [RFC7232]. 857 If an application defines a request header field that might be used 858 by a server to change the response's headers or body, authors should 859 point out that this has implications for caching; in general, such 860 resources need to either make their responses uncacheable (e.g., with 861 the "no-store" cache-control directive defined in [RFC7234], 862 Section 5.2.2.3) or consistently send the Vary response header 863 ([RFC7231], Section 7.1.4). 865 For example, this response: 867 HTTP/1.1 200 OK 868 Content-Type: application/example+xml 869 Cache-Control: max-age=60 870 ETag: "sa0f8wf20fs0f" 871 Vary: Accept-Encoding 873 [content] 875 can be stored for 60 seconds by both private and shared caches, can 876 be revalidated with If-None-Match, and varies on the Accept-Encoding 877 request header field. 879 In some situations, responses without explicit cache directives 880 (e.g., Cache-Control or Expires) will be stored and served using a 881 heuristic freshness lifetime; see [RFC7234], Section 4.2.2. As the 882 heuristic is not under control of the application, it is generally 883 preferable to set an explicit freshness lifetime. 885 If caching of a response is not desired, the appropriate response 886 directive is "Cache-Control: no-store". This only need be sent in 887 situations where the response might be cached; see [RFC7234], 888 Section 3. Note that "Cache-Control: no-cache" allows a response to 889 be stored, just not reused by a cache; it does not prevent caching 890 (despite its name). 892 For example, this response cannot be stored or reused by a cache: 894 HTTP/1.1 200 OK 895 Content-Type: application/example+xml 896 Cache-Control: no-store 898 [content] 899 When an application has a need to express a lifetime that's separate 900 from the freshness lifetime, this should be expressed separately, 901 either in the response's body or in a separate header field. When 902 this happens, the relationship between HTTP caching and that lifetime 903 need to be carefully considered, since the response will be used as 904 long as it is considered fresh. 906 Like other functions, HTTP caching is generic; it does not have 907 knowledge of the application in use. Therefore, caching extensions 908 need to be backwards-compatible, as per [RFC7234], Section 5.2.3. 910 4.10. Application State 912 Applications that use HTTP MAY use stateful cookies [RFC6265] to 913 identify a client and/or store client-specific data to contextualise 914 requests. 916 When used, it is important to carefully specify the scoping and use 917 of cookies; if the application exposes sensitive data or capabilities 918 (e.g., by acting as an ambient authority), exploits are possible. 919 Mitigations include using a request-specific token to assure the 920 intent of the client. 922 Applications MUST NOT make assumptions about the relationship between 923 separate requests on a single transport connection; doing so breaks 924 many of the assumptions of HTTP as a stateless protocol, and will 925 cause problems in interoperability, security, operability and 926 evolution. 928 4.11. Client Authentication 930 Applications that use HTTP MAY use HTTP authentication [RFC7235] to 931 identify clients. The Basic authentication scheme [RFC7617] MUST NOT 932 be used unless the underlying transport is authenticated, integrity- 933 protected and confidential (e.g., as provided the "HTTPS" URL scheme, 934 or another using TLS). The Digest scheme [RFC7616] MUST NOT be used 935 unless the underlying transport is similarly secure, or the chosen 936 hash algorithm is not "MD5". 938 When used, it is important to carefully specify the scoping and use 939 of authentication; if the application exposes sensitive data or 940 capabilities (e.g., by acting as an ambient authority), exploits are 941 possible. Mitigations include using a request-specific token to 942 assure the intent of the client. 944 4.12. Co-Existing with Web Browsing 946 Even if there is not an intent for an application that uses HTTP to 947 be used with a Web browser, its resources will remain available to 948 browsers and other HTTP clients. 950 This means that all such applications need to consider how browsers 951 will interact with them, particularly regarding security. 953 For example, if an application's state can be changed using a POST 954 request, a Web browser can easily be coaxed into making that request 955 by a HTML form on an arbitrary Web site. 957 Or, If content returned from the application's resources is under 958 control of an attacker (for example, part of the request is reflected 959 in the response, or the response contains external information that 960 might be under the control of the attacker), a cross-site scripting 961 attack is possible, whereby an attacker can inject code into the 962 browser and access data and capabilities on that origin. 964 This is only a small sample of the kinds of issues that applications 965 using HTTP must consider. Generally, the best approach is to 966 consider the application actually as a Web application, and to follow 967 best practices for their secure development. 969 A complete enumeration of such practices is out of scope for this 970 document, but some considerations include: 972 o Using an application-specific media type in the Content-Type 973 header, and requiring clients to fail if it is not used 975 o Using X-Content-Type-Options: nosniff [FETCH]} to assure that 976 content under attacker control can't be coaxed into a form that is 977 interpreted as active content by a Web browser 979 o Using Content-Security-Policy [CSP] to constrain the capabilities 980 of active content (such as HTML [HTML5]), thereby mitigating 981 Cross-Site Scripting attacks 983 o Using Referrer-Policy [REFERRER-POLICY] to prevent sensitive data 984 in URLs from being leaked in the Referer request header 986 o Using the 'HttpOnly' flag on Cookies to assure that cookies are 987 not exposed to browser scripting languages [RFC6265] 989 o Avoiding use of compression on any sensitive information (e.g., 990 authentication tokens, passwords), as the scripting environment 991 offered by Web browsers allows an attacker to repeatedly probe the 992 compression space; if the attacker has access to the path of the 993 communication, they can use this capability to recover that 994 information. 996 Depending on how they are intended to be deployed, specifications for 997 applications using HTTP might require the use of these mechanisms in 998 specific ways, or might merely point them out in Security 999 Considerations. 1001 An example of a HTTP response from an application that does not 1002 intend for its content to be treated as active by browsers might look 1003 like this: 1005 HTTP/1.1 200 OK 1006 Content-Type: application/example+json 1007 X-Content-Type-Options: nosniff 1008 Content-Security-Policy: default-src 'none' 1009 Cache-Control: max-age=3600 1010 Referrer-Policy: no-referrer 1012 [content] 1014 If an application using HTTP has browser compatibility as a goal, 1015 client interaction ought to be defined in terms of [FETCH], since 1016 that is the abstraction that browsers use for HTTP; it enforces many 1017 of these best practices. 1019 4.13. Application Boundaries 1021 Because the origin [RFC6454] is how many HTTP capabilities are 1022 scoped, applications also need to consider how deployments might 1023 interact with other applications (including Web browsing) on the same 1024 origin. 1026 For example, if Cookies [RFC6265] are used to carry application 1027 state, they will be sent with all requests to the origin by default, 1028 unless scoped by path, and the application might receive cookies from 1029 other applications on the origin. This can lead to security issues, 1030 as well as collision in cookie names. 1032 One solution to these issues is to require a dedicated hostname for 1033 the application, so that it has a unique origin. However, it is 1034 often desirable to allow multiple applications to be deployed on a 1035 single hostname; doing so provides the most deployment flexibility 1036 and enables them to be "mixed" together (See [RFC7320] for details). 1037 Therefore, applications using HTTP should strive to allow multiple 1038 applications on an origin. 1040 To enable this, when specifying the use of Cookies, HTTP 1041 authentication realms [RFC7235], or other origin-wide HTTP 1042 mechanisms, applications using HTTP SHOULD NOT mandate the use of a 1043 particular identifier, but instead let deployments configure them. 1044 Consideration SHOULD be given to scoping them to part of the origin, 1045 using their specified mechanisms for doing so. 1047 Modern Web browsers constrain the ability of content from one origin 1048 to access resources from another, to avoid leaking private 1049 information. As a result, applications that wish to expose cross- 1050 origin data to browsers will need to implement the CORS protocol; see 1051 [FETCH]. 1053 4.14. Server Push 1055 HTTP/2 adds the ability for servers to "push" request/response pairs 1056 to clients in [RFC7540], Section 8.2. While server push seems like a 1057 natural fit for many common application semantics (e.g., "fanout" and 1058 publish/subscribe), a few caveats should be noted: 1060 o Server push is hop-by-hop; that is, it is not automatically 1061 forwarded by intermediaries. As a result, it might not work 1062 easily (or at all) with proxies, reverse proxies, and Content 1063 Delivery Networks. 1065 o Server push can have negative performance impact on HTTP when used 1066 incorrectly; in particular, if there is contention with resources 1067 that have actually been requested by the client. 1069 o Server push is implemented differently in different clients, 1070 especially regarding interaction with HTTP caching, and 1071 capabilities might vary. 1073 o APIs for server push are currently unavailable in some 1074 implementations, and vary widely in others. In particular, there 1075 is no current browser API for it. 1077 o Server push is not supported in HTTP/1.1 or HTTP/1.0. 1079 o Server push does not form part of the "core" semantics of HTTP, 1080 and therefore might not be supported by future versions of the 1081 protocol. 1083 Applications wishing to optimise cases where the client can perform 1084 work related to requests before the full response is available (e.g., 1085 fetching links for things likely to be contained within) might 1086 benefit from using the 103 (Early Hints) status code; see [RFC8297]. 1088 Applications using server push directly need to enforce the 1089 requirements regarding authority in [RFC7540], Section 8.2, to avoid 1090 cross-origin push attacks. 1092 5. IANA Considerations 1094 This document has no requirements for IANA. 1096 6. Security Considerations 1098 Section 4.10 discusses the impact of using stateful mechanisms in the 1099 protocol as ambient authority, and suggests a mitigation. 1101 Section 4.4.2 requires support for 'https' URLs, and discourages the 1102 use of 'http' URLs, to provide authentication, integrity and 1103 confidentiality, as well as mitigate pervasive monitoring attacks. 1105 Section 4.12 highlights the implications of Web browsers' 1106 capabilities on applications that use HTTP. 1108 Section 4.13 discusses the issues that arise when applications are 1109 deployed on the same origin as Web sites (and other applications). 1111 Section 4.14 highlights risks of using HTTP/2 server push in a manner 1112 other than specified. 1114 Applications that use HTTP in a manner that involves modification of 1115 implementations - for example, requiring support for a new URL 1116 scheme, or a non-standard method - risk having those implementations 1117 "fork" from their parent HTTP implementations, with the possible 1118 result that they do not benefit from patches and other security 1119 improvements incorporated upstream. 1121 7. References 1123 7.1. Normative References 1125 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 1126 Requirement Levels", BCP 14, RFC 2119, 1127 DOI 10.17487/RFC2119, March 1997, 1128 . 1130 [RFC2818] Rescorla, E., "HTTP Over TLS", RFC 2818, 1131 DOI 10.17487/RFC2818, May 2000, 1132 . 1134 [RFC3864] Klyne, G., Nottingham, M., and J. Mogul, "Registration 1135 Procedures for Message Header Fields", BCP 90, RFC 3864, 1136 DOI 10.17487/RFC3864, September 2004, 1137 . 1139 [RFC6454] Barth, A., "The Web Origin Concept", RFC 6454, 1140 DOI 10.17487/RFC6454, December 2011, 1141 . 1143 [RFC6648] Saint-Andre, P., Crocker, D., and M. Nottingham, 1144 "Deprecating the "X-" Prefix and Similar Constructs in 1145 Application Protocols", BCP 178, RFC 6648, 1146 DOI 10.17487/RFC6648, June 2012, 1147 . 1149 [RFC6838] Freed, N., Klensin, J., and T. Hansen, "Media Type 1150 Specifications and Registration Procedures", BCP 13, 1151 RFC 6838, DOI 10.17487/RFC6838, January 2013, 1152 . 1154 [RFC7230] Fielding, R., Ed. and J. Reschke, Ed., "Hypertext Transfer 1155 Protocol (HTTP/1.1): Message Syntax and Routing", 1156 RFC 7230, DOI 10.17487/RFC7230, June 2014, 1157 . 1159 [RFC7231] Fielding, R., Ed. and J. Reschke, Ed., "Hypertext Transfer 1160 Protocol (HTTP/1.1): Semantics and Content", RFC 7231, 1161 DOI 10.17487/RFC7231, June 2014, 1162 . 1164 [RFC7232] Fielding, R., Ed. and J. Reschke, Ed., "Hypertext Transfer 1165 Protocol (HTTP/1.1): Conditional Requests", RFC 7232, 1166 DOI 10.17487/RFC7232, June 2014, 1167 . 1169 [RFC7233] Fielding, R., Ed., Lafon, Y., Ed., and J. Reschke, Ed., 1170 "Hypertext Transfer Protocol (HTTP/1.1): Range Requests", 1171 RFC 7233, DOI 10.17487/RFC7233, June 2014, 1172 . 1174 [RFC7234] Fielding, R., Ed., Nottingham, M., Ed., and J. Reschke, 1175 Ed., "Hypertext Transfer Protocol (HTTP/1.1): Caching", 1176 RFC 7234, DOI 10.17487/RFC7234, June 2014, 1177 . 1179 [RFC7235] Fielding, R., Ed. and J. Reschke, Ed., "Hypertext Transfer 1180 Protocol (HTTP/1.1): Authentication", RFC 7235, 1181 DOI 10.17487/RFC7235, June 2014, 1182 . 1184 [RFC7301] Friedl, S., Popov, A., Langley, A., and E. Stephan, 1185 "Transport Layer Security (TLS) Application-Layer Protocol 1186 Negotiation Extension", RFC 7301, DOI 10.17487/RFC7301, 1187 July 2014, . 1189 [RFC7320] Nottingham, M., "URI Design and Ownership", BCP 190, 1190 RFC 7320, DOI 10.17487/RFC7320, July 2014, 1191 . 1193 [RFC7540] Belshe, M., Peon, R., and M. Thomson, Ed., "Hypertext 1194 Transfer Protocol Version 2 (HTTP/2)", RFC 7540, 1195 DOI 10.17487/RFC7540, May 2015, 1196 . 1198 [RFC8174] Leiba, B., "Ambiguity of Uppercase vs Lowercase in RFC 1199 2119 Key Words", BCP 14, RFC 8174, DOI 10.17487/RFC8174, 1200 May 2017, . 1202 [RFC8288] Nottingham, M., "Web Linking", RFC 8288, 1203 DOI 10.17487/RFC8288, October 2017, 1204 . 1206 7.2. Informative References 1208 [CSP] West, M., "Content Security Policy Level 3", World Wide 1209 Web Consortium WD WD-CSP3-20160913, September 2016, 1210 . 1212 [FETCH] WHATWG, "Fetch - Living Standard", n.d., 1213 . 1215 [HTML5] WHATWG, "HTML - Living Standard", n.d., 1216 . 1218 [I-D.ietf-httpbis-header-structure] 1219 Nottingham, M. and P. Kamp, "Structured Headers for HTTP", 1220 draft-ietf-httpbis-header-structure-04 (work in progress), 1221 March 2018. 1223 [REFERRER-POLICY] 1224 Eisinger, J. and E. Stark, "Referrer Policy", World Wide 1225 Web Consortium CR CR-referrer-policy-20170126, January 1226 2017, 1227 . 1229 [RFC0793] Postel, J., "Transmission Control Protocol", STD 7, 1230 RFC 793, DOI 10.17487/RFC0793, September 1981, 1231 . 1233 [RFC3205] Moore, K., "On the use of HTTP as a Substrate", BCP 56, 1234 RFC 3205, DOI 10.17487/RFC3205, February 2002, 1235 . 1237 [RFC4367] Rosenberg, J., Ed. and IAB, "What's in a Name: False 1238 Assumptions about DNS Names", RFC 4367, 1239 DOI 10.17487/RFC4367, February 2006, 1240 . 1242 [RFC4791] Daboo, C., Desruisseaux, B., and L. Dusseault, 1243 "Calendaring Extensions to WebDAV (CalDAV)", RFC 4791, 1244 DOI 10.17487/RFC4791, March 2007, 1245 . 1247 [RFC4918] Dusseault, L., Ed., "HTTP Extensions for Web Distributed 1248 Authoring and Versioning (WebDAV)", RFC 4918, 1249 DOI 10.17487/RFC4918, June 2007, 1250 . 1252 [RFC5785] Nottingham, M. and E. Hammer-Lahav, "Defining Well-Known 1253 Uniform Resource Identifiers (URIs)", RFC 5785, 1254 DOI 10.17487/RFC5785, April 2010, 1255 . 1257 [RFC5861] Nottingham, M., "HTTP Cache-Control Extensions for Stale 1258 Content", RFC 5861, DOI 10.17487/RFC5861, May 2010, 1259 . 1261 [RFC6265] Barth, A., "HTTP State Management Mechanism", RFC 6265, 1262 DOI 10.17487/RFC6265, April 2011, 1263 . 1265 [RFC6415] Hammer-Lahav, E., Ed. and B. Cook, "Web Host Metadata", 1266 RFC 6415, DOI 10.17487/RFC6415, October 2011, 1267 . 1269 [RFC6455] Fette, I. and A. Melnikov, "The WebSocket Protocol", 1270 RFC 6455, DOI 10.17487/RFC6455, December 2011, 1271 . 1273 [RFC7049] Bormann, C. and P. Hoffman, "Concise Binary Object 1274 Representation (CBOR)", RFC 7049, DOI 10.17487/RFC7049, 1275 October 2013, . 1277 [RFC7258] Farrell, S. and H. Tschofenig, "Pervasive Monitoring Is an 1278 Attack", BCP 188, RFC 7258, DOI 10.17487/RFC7258, May 1279 2014, . 1281 [RFC7538] Reschke, J., "The Hypertext Transfer Protocol Status Code 1282 308 (Permanent Redirect)", RFC 7538, DOI 10.17487/RFC7538, 1283 April 2015, . 1285 [RFC7595] Thaler, D., Ed., Hansen, T., and T. Hardie, "Guidelines 1286 and Registration Procedures for URI Schemes", BCP 35, 1287 RFC 7595, DOI 10.17487/RFC7595, June 2015, 1288 . 1290 [RFC7605] Touch, J., "Recommendations on Using Assigned Transport 1291 Port Numbers", BCP 165, RFC 7605, DOI 10.17487/RFC7605, 1292 August 2015, . 1294 [RFC7616] Shekh-Yusef, R., Ed., Ahrens, D., and S. Bremer, "HTTP 1295 Digest Access Authentication", RFC 7616, 1296 DOI 10.17487/RFC7616, September 2015, 1297 . 1299 [RFC7617] Reschke, J., "The 'Basic' HTTP Authentication Scheme", 1300 RFC 7617, DOI 10.17487/RFC7617, September 2015, 1301 . 1303 [RFC7807] Nottingham, M. and E. Wilde, "Problem Details for HTTP 1304 APIs", RFC 7807, DOI 10.17487/RFC7807, March 2016, 1305 . 1307 [RFC8259] Bray, T., Ed., "The JavaScript Object Notation (JSON) Data 1308 Interchange Format", STD 90, RFC 8259, 1309 DOI 10.17487/RFC8259, December 2017, 1310 . 1312 [RFC8297] Oku, K., "An HTTP Status Code for Indicating Hints", 1313 RFC 8297, DOI 10.17487/RFC8297, December 2017, 1314 . 1316 [SECCTXT] West, M., "Secure Contexts", World Wide Web Consortium CR 1317 CR-secure-contexts-20160915, September 2016, 1318 . 1320 [XML] Bray, T., Paoli, J., Sperberg-McQueen, M., Maler, E., and 1321 F. Yergeau, "Extensible Markup Language (XML) 1.0 (Fifth 1322 Edition)", World Wide Web Consortium Recommendation REC- 1323 xml-20081126, November 2008, 1324 . 1326 7.3. URIs 1328 [1] https://lists.w3.org/Archives/Public/ietf-http-wg/ 1330 [2] http://httpwg.github.io/ 1332 [3] https://github.com/httpwg/http-extensions/labels/bcp56bis 1334 Appendix A. Changes from RFC 3205 1336 [RFC3205] captured the Best Current Practice in the early 2000's, 1337 based on the concerns facing protocol designers at the time. Use of 1338 HTTP has changed considerably since then, and as a result this 1339 document is substantially different. As a result, the changes are 1340 too numerous to list individually. 1342 Author's Address 1344 Mark Nottingham 1346 Email: mnot@mnot.net 1347 URI: https://www.mnot.net/