idnits 2.17.1
draft-ietf-httpbis-messaging-12.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:
----------------------------------------------------------------------------
== There is 1 instance of lines with non-ascii characters in the document.
Checking nits according to https://www.ietf.org/id-info/checklist :
----------------------------------------------------------------------------
-- The draft header indicates that this document obsoletes RFC7230, but the
abstract doesn't seem to directly say this. It does mention RFC7230
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
== Line 710 has weird spacing: '...ncoding stan...'
== The document seems to contain a disclaimer for pre-RFC5378 work, but was
first submitted on or after 10 November 2008. The disclaimer is usually
necessary only for documents that revise or obsolete older RFCs, and that
take significant amounts of text from those RFCs. If you can contact all
authors of the source material and they are willing to grant the BCP78
rights to the IETF Trust, you can and should remove the disclaimer.
Otherwise, the disclaimer is needed and you can ignore this comment.
(See the Legal Provisions document at
https://trustee.ietf.org/license-info for more information.)
-- The document date (October 2, 2020) is 1302 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)
== Unused Reference: 'RFC3986' is defined on line 1891, but no explicit
reference was found in the text
== Unused Reference: 'RFC7231' is defined on line 1980, but no explicit
reference was found in the text
== Outdated reference: A later version (-19) exists of
draft-ietf-httpbis-cache-12
-- Possible downref: Normative reference to a draft: ref. 'Caching'
** Downref: Normative reference to an Informational RFC: RFC 1950
** Downref: Normative reference to an Informational RFC: RFC 1951
** Downref: Normative reference to an Informational RFC: RFC 1952
== Outdated reference: A later version (-19) exists of
draft-ietf-httpbis-semantics-12
-- Possible downref: Normative reference to a draft: ref. 'Semantics'
-- Possible downref: Non-RFC (?) normative reference: ref. 'USASCII'
-- Possible downref: Non-RFC (?) normative reference: ref. 'Welch'
-- Obsolete informational reference (is this intentional?): RFC 7230 (ref.
'Err4667') (Obsoleted by RFC 9110, RFC 9112)
-- Obsolete informational reference (is this intentional?): RFC 2068
(Obsoleted by RFC 2616)
-- Duplicate reference: RFC7230, mentioned in 'RFC7230', was also mentioned
in 'Err4667'.
-- Obsolete informational reference (is this intentional?): RFC 7230
(Obsoleted by RFC 9110, RFC 9112)
-- Obsolete informational reference (is this intentional?): RFC 7231
(Obsoleted by RFC 9110)
Summary: 3 errors (**), 0 flaws (~~), 8 warnings (==), 11 comments (--).
Run idnits with the --verbose option for more detailed information about
the items above.
--------------------------------------------------------------------------------
2 HTTP Working Group R. Fielding, Ed.
3 Internet-Draft Adobe
4 Obsoletes: 7230 (if approved) M. Nottingham, Ed.
5 Intended status: Standards Track Fastly
6 Expires: April 5, 2021 J. Reschke, Ed.
7 greenbytes
8 October 2, 2020
10 HTTP/1.1 Messaging
11 draft-ietf-httpbis-messaging-12
13 Abstract
15 The Hypertext Transfer Protocol (HTTP) is a stateless application-
16 level protocol for distributed, collaborative, hypertext information
17 systems. This document specifies the HTTP/1.1 message syntax,
18 message parsing, connection management, and related security
19 concerns.
21 This document obsoletes portions of RFC 7230.
23 Editorial Note
25 This note is to be removed before publishing as an RFC.
27 Discussion of this draft takes place on the HTTP working group
28 mailing list (ietf-http-wg@w3.org), which is archived at
29 .
31 Working Group information can be found at ;
32 source code and issues list for this draft can be found at
33 .
35 The changes in this draft are summarized in Appendix D.13.
37 Status of This Memo
39 This Internet-Draft is submitted in full conformance with the
40 provisions of BCP 78 and BCP 79.
42 Internet-Drafts are working documents of the Internet Engineering
43 Task Force (IETF). Note that other groups may also distribute
44 working documents as Internet-Drafts. The list of current Internet-
45 Drafts is at https://datatracker.ietf.org/drafts/current/.
47 Internet-Drafts are draft documents valid for a maximum of six months
48 and may be updated, replaced, or obsoleted by other documents at any
49 time. It is inappropriate to use Internet-Drafts as reference
50 material or to cite them other than as "work in progress."
52 This Internet-Draft will expire on April 5, 2021.
54 Copyright Notice
56 Copyright (c) 2020 IETF Trust and the persons identified as the
57 document authors. All rights reserved.
59 This document is subject to BCP 78 and the IETF Trust's Legal
60 Provisions Relating to IETF Documents (https://trustee.ietf.org/
61 license-info) in effect on the date of publication of this document.
62 Please review these documents carefully, as they describe your rights
63 and restrictions with respect to this document. Code Components
64 extracted from this document must include Simplified BSD License text
65 as described in Section 4.e of the Trust Legal Provisions and are
66 provided without warranty as described in the Simplified BSD License.
68 This document may contain material from IETF Documents or IETF
69 Contributions published or made publicly available before November
70 10, 2008. The person(s) controlling the copyright in some of this
71 material may not have granted the IETF Trust the right to allow
72 modifications of such material outside the IETF Standards Process.
73 Without obtaining an adequate license from the person(s) controlling
74 the copyright in such materials, this document may not be modified
75 outside the IETF Standards Process, and derivative works of it may
76 not be created outside the IETF Standards Process, except to format
77 it for publication as an RFC or to translate it into languages other
78 than English.
80 Table of Contents
82 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 4
83 1.1. Requirements Notation . . . . . . . . . . . . . . . . . . 5
84 1.2. Syntax Notation . . . . . . . . . . . . . . . . . . . . . 5
85 2. Message . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
86 2.1. Message Format . . . . . . . . . . . . . . . . . . . . . 6
87 2.2. Message Parsing . . . . . . . . . . . . . . . . . . . . . 7
88 2.3. HTTP Version . . . . . . . . . . . . . . . . . . . . . . 8
89 3. Request Line . . . . . . . . . . . . . . . . . . . . . . . . 9
90 3.1. Method . . . . . . . . . . . . . . . . . . . . . . . . . 10
91 3.2. Request Target . . . . . . . . . . . . . . . . . . . . . 10
92 3.2.1. origin-form . . . . . . . . . . . . . . . . . . . . . 11
93 3.2.2. absolute-form . . . . . . . . . . . . . . . . . . . . 11
94 3.2.3. authority-form . . . . . . . . . . . . . . . . . . . 12
95 3.2.4. asterisk-form . . . . . . . . . . . . . . . . . . . . 12
96 3.3. Reconstructing the Target URI . . . . . . . . . . . . . . 13
97 4. Status Line . . . . . . . . . . . . . . . . . . . . . . . . . 14
98 5. Field Syntax . . . . . . . . . . . . . . . . . . . . . . . . 15
99 5.1. Field Line Parsing . . . . . . . . . . . . . . . . . . . 16
100 5.2. Obsolete Line Folding . . . . . . . . . . . . . . . . . . 17
101 6. Message Body . . . . . . . . . . . . . . . . . . . . . . . . 17
102 6.1. Transfer-Encoding . . . . . . . . . . . . . . . . . . . . 18
103 6.2. Content-Length . . . . . . . . . . . . . . . . . . . . . 19
104 6.3. Message Body Length . . . . . . . . . . . . . . . . . . . 20
105 7. Transfer Codings . . . . . . . . . . . . . . . . . . . . . . 22
106 7.1. Chunked Transfer Coding . . . . . . . . . . . . . . . . . 23
107 7.1.1. Chunk Extensions . . . . . . . . . . . . . . . . . . 24
108 7.1.2. Chunked Trailer Section . . . . . . . . . . . . . . . 25
109 7.1.3. Decoding Chunked . . . . . . . . . . . . . . . . . . 25
110 7.2. Transfer Codings for Compression . . . . . . . . . . . . 26
111 7.3. Transfer Coding Registry . . . . . . . . . . . . . . . . 26
112 7.4. Negotiating Transfer Codings . . . . . . . . . . . . . . 27
113 8. Handling Incomplete Messages . . . . . . . . . . . . . . . . 27
114 9. Connection Management . . . . . . . . . . . . . . . . . . . . 28
115 9.1. Establishment . . . . . . . . . . . . . . . . . . . . . . 28
116 9.2. Associating a Response to a Request . . . . . . . . . . . 29
117 9.3. Persistence . . . . . . . . . . . . . . . . . . . . . . . 29
118 9.3.1. Retrying Requests . . . . . . . . . . . . . . . . . . 30
119 9.3.2. Pipelining . . . . . . . . . . . . . . . . . . . . . 30
120 9.4. Concurrency . . . . . . . . . . . . . . . . . . . . . . . 31
121 9.5. Failures and Timeouts . . . . . . . . . . . . . . . . . . 32
122 9.6. Tear-down . . . . . . . . . . . . . . . . . . . . . . . . 32
123 9.7. TLS Connection Initiation . . . . . . . . . . . . . . . . 34
124 9.8. TLS Connection Closure . . . . . . . . . . . . . . . . . 34
125 10. Enclosing Messages as Data . . . . . . . . . . . . . . . . . 35
126 10.1. Media Type message/http . . . . . . . . . . . . . . . . 35
127 10.2. Media Type application/http . . . . . . . . . . . . . . 36
128 11. Security Considerations . . . . . . . . . . . . . . . . . . . 37
129 11.1. Response Splitting . . . . . . . . . . . . . . . . . . . 37
130 11.2. Request Smuggling . . . . . . . . . . . . . . . . . . . 38
131 11.3. Message Integrity . . . . . . . . . . . . . . . . . . . 38
132 11.4. Message Confidentiality . . . . . . . . . . . . . . . . 39
133 12. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 39
134 12.1. Field Name Registration . . . . . . . . . . . . . . . . 39
135 12.2. Media Type Registration . . . . . . . . . . . . . . . . 39
136 12.3. Transfer Coding Registration . . . . . . . . . . . . . . 40
137 12.4. ALPN Protocol ID Registration . . . . . . . . . . . . . 40
138 13. References . . . . . . . . . . . . . . . . . . . . . . . . . 40
139 13.1. Normative References . . . . . . . . . . . . . . . . . . 40
140 13.2. Informative References . . . . . . . . . . . . . . . . . 41
141 Appendix A. Collected ABNF . . . . . . . . . . . . . . . . . . . 43
142 Appendix B. Differences between HTTP and MIME . . . . . . . . . 44
143 B.1. MIME-Version . . . . . . . . . . . . . . . . . . . . . . 45
144 B.2. Conversion to Canonical Form . . . . . . . . . . . . . . 45
145 B.3. Conversion of Date Formats . . . . . . . . . . . . . . . 45
146 B.4. Conversion of Content-Encoding . . . . . . . . . . . . . 46
147 B.5. Conversion of Content-Transfer-Encoding . . . . . . . . . 46
148 B.6. MHTML and Line Length Limitations . . . . . . . . . . . . 46
149 Appendix C. HTTP Version History . . . . . . . . . . . . . . . . 46
150 C.1. Changes from HTTP/1.0 . . . . . . . . . . . . . . . . . . 47
151 C.1.1. Multihomed Web Servers . . . . . . . . . . . . . . . 47
152 C.1.2. Keep-Alive Connections . . . . . . . . . . . . . . . 48
153 C.1.3. Introduction of Transfer-Encoding . . . . . . . . . . 48
154 C.2. Changes from RFC 7230 . . . . . . . . . . . . . . . . . . 49
155 Appendix D. Change Log . . . . . . . . . . . . . . . . . . . . . 49
156 D.1. Between RFC7230 and draft 00 . . . . . . . . . . . . . . 49
157 D.2. Since draft-ietf-httpbis-messaging-00 . . . . . . . . . . 50
158 D.3. Since draft-ietf-httpbis-messaging-01 . . . . . . . . . . 50
159 D.4. Since draft-ietf-httpbis-messaging-02 . . . . . . . . . . 51
160 D.5. Since draft-ietf-httpbis-messaging-03 . . . . . . . . . . 51
161 D.6. Since draft-ietf-httpbis-messaging-04 . . . . . . . . . . 51
162 D.7. Since draft-ietf-httpbis-messaging-05 . . . . . . . . . . 52
163 D.8. Since draft-ietf-httpbis-messaging-06 . . . . . . . . . . 52
164 D.9. Since draft-ietf-httpbis-messaging-07 . . . . . . . . . . 52
165 D.10. Since draft-ietf-httpbis-messaging-08 . . . . . . . . . . 53
166 D.11. Since draft-ietf-httpbis-messaging-09 . . . . . . . . . . 53
167 D.12. Since draft-ietf-httpbis-messaging-10 . . . . . . . . . . 53
168 D.13. Since draft-ietf-httpbis-messaging-11 . . . . . . . . . . 53
169 Acknowledgments . . . . . . . . . . . . . . . . . . . . . . . . . 54
170 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 54
172 1. Introduction
174 The Hypertext Transfer Protocol (HTTP) is a stateless application-
175 level request/response protocol that uses extensible semantics and
176 self-descriptive messages for flexible interaction with network-based
177 hypertext information systems. HTTP is defined by a series of
178 documents that collectively form the HTTP/1.1 specification:
180 o "HTTP Semantics" [Semantics]
182 o "HTTP Caching" [Caching]
184 o "HTTP/1.1 Messaging" (this document)
185 This document defines HTTP/1.1 message syntax and framing
186 requirements and their associated connection management. Our goal is
187 to define all of the mechanisms necessary for HTTP/1.1 message
188 handling that are independent of message semantics, thereby defining
189 the complete set of requirements for message parsers and message-
190 forwarding intermediaries.
192 This document obsoletes the portions of RFC 7230 related to HTTP/1.1
193 messaging and connection management, with the changes being
194 summarized in Appendix C.2. The other parts of RFC 7230 are
195 obsoleted by "HTTP Semantics" [Semantics].
197 1.1. Requirements Notation
199 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
200 "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and
201 "OPTIONAL" in this document are to be interpreted as described in BCP
202 14 [RFC2119] [RFC8174] when, and only when, they appear in all
203 capitals, as shown here.
205 Conformance criteria and considerations regarding error handling are
206 defined in Section 2 of [Semantics].
208 1.2. Syntax Notation
210 This specification uses the Augmented Backus-Naur Form (ABNF)
211 notation of [RFC5234], extended with the notation for case-
212 sensitivity in strings defined in [RFC7405].
214 It also uses a list extension, defined in Section 5.7.1 of
215 [Semantics], that allows for compact definition of comma-separated
216 lists using a '#' operator (similar to how the '*' operator indicates
217 repetition). Appendix A shows the collected grammar with all list
218 operators expanded to standard ABNF notation.
220 As a convention, ABNF rule names prefixed with "obs-" denote
221 "obsolete" grammar rules that appear for historical reasons.
223 The following core rules are included by reference, as defined in
224 [RFC5234], Appendix B.1: ALPHA (letters), CR (carriage return), CRLF
225 (CR LF), CTL (controls), DIGIT (decimal 0-9), DQUOTE (double quote),
226 HEXDIG (hexadecimal 0-9/A-F/a-f), HTAB (horizontal tab), LF (line
227 feed), OCTET (any 8-bit sequence of data), SP (space), and VCHAR (any
228 visible [USASCII] character).
230 The rules below are defined in [Semantics]:
232 BWS =
233 OWS =
234 RWS =
235 absolute-URI =
236 absolute-path =
237 authority =
238 comment =
239 field-name =
240 field-value =
241 obs-text =
242 port =
243 query =
244 quoted-string =
245 token =
246 uri-host =
248 2. Message
250 2.1. Message Format
252 An HTTP/1.1 message consists of a start-line followed by a CRLF and a
253 sequence of octets in a format similar to the Internet Message Format
254 [RFC5322]: zero or more header field lines (collectively referred to
255 as the "headers" or the "header section"), an empty line indicating
256 the end of the header section, and an optional message body.
258 HTTP-message = start-line CRLF
259 *( field-line CRLF )
260 CRLF
261 [ message-body ]
263 A message can be either a request from client to server or a response
264 from server to client. Syntactically, the two types of message
265 differ only in the start-line, which is either a request-line (for
266 requests) or a status-line (for responses), and in the algorithm for
267 determining the length of the message body (Section 6).
269 start-line = request-line / status-line
271 In theory, a client could receive requests and a server could receive
272 responses, distinguishing them by their different start-line formats.
273 In practice, servers are implemented to only expect a request (a
274 response is interpreted as an unknown or invalid request method) and
275 clients are implemented to only expect a response.
277 Although HTTP makes use of some protocol elements similar to the
278 Multipurpose Internet Mail Extensions (MIME) [RFC2045], see
279 Appendix B for the differences between HTTP and MIME messages.
281 2.2. Message Parsing
283 The normal procedure for parsing an HTTP message is to read the
284 start-line into a structure, read each header field line into a hash
285 table by field name until the empty line, and then use the parsed
286 data to determine if a message body is expected. If a message body
287 has been indicated, then it is read as a stream until an amount of
288 octets equal to the message body length is read or the connection is
289 closed.
291 A recipient MUST parse an HTTP message as a sequence of octets in an
292 encoding that is a superset of US-ASCII [USASCII]. Parsing an HTTP
293 message as a stream of Unicode characters, without regard for the
294 specific encoding, creates security vulnerabilities due to the
295 varying ways that string processing libraries handle invalid
296 multibyte character sequences that contain the octet LF (%x0A).
297 String-based parsers can only be safely used within protocol elements
298 after the element has been extracted from the message, such as within
299 a header field line value after message parsing has delineated the
300 individual field lines.
302 Although the line terminator for the start-line and header fields is
303 the sequence CRLF, a recipient MAY recognize a single LF as a line
304 terminator and ignore any preceding CR.
306 A sender MUST NOT generate a bare CR (a CR character not immediately
307 followed by LF) within any protocol elements other than the payload
308 body. A recipient of such a bare CR MUST consider that element to be
309 invalid or replace each bare CR with SP before processing the element
310 or forwarding the message.
312 Older HTTP/1.0 user agent implementations might send an extra CRLF
313 after a POST request as a workaround for some early server
314 applications that failed to read message body content that was not
315 terminated by a line-ending. An HTTP/1.1 user agent MUST NOT preface
316 or follow a request with an extra CRLF. If terminating the request
317 message body with a line-ending is desired, then the user agent MUST
318 count the terminating CRLF octets as part of the message body length.
320 In the interest of robustness, a server that is expecting to receive
321 and parse a request-line SHOULD ignore at least one empty line (CRLF)
322 received prior to the request-line.
324 A sender MUST NOT send whitespace between the start-line and the
325 first header field. A recipient that receives whitespace between the
326 start-line and the first header field MUST either reject the message
327 as invalid or consume each whitespace-preceded line without further
328 processing of it (i.e., ignore the entire line, along with any
329 subsequent lines preceded by whitespace, until a properly formed
330 header field is received or the header section is terminated).
332 The presence of such whitespace in a request might be an attempt to
333 trick a server into ignoring that field line or processing the line
334 after it as a new request, either of which might result in a security
335 vulnerability if other implementations within the request chain
336 interpret the same message differently. Likewise, the presence of
337 such whitespace in a response might be ignored by some clients or
338 cause others to cease parsing.
340 When a server listening only for HTTP request messages, or processing
341 what appears from the start-line to be an HTTP request message,
342 receives a sequence of octets that does not match the HTTP-message
343 grammar aside from the robustness exceptions listed above, the server
344 SHOULD respond with a 400 (Bad Request) response.
346 2.3. HTTP Version
348 HTTP uses a "." numbering scheme to indicate versions
349 of the protocol. This specification defines version "1.1".
350 Section 5.1 of [Semantics] specifies the semantics of HTTP version
351 numbers.
353 The version of an HTTP/1.x message is indicated by an HTTP-version
354 field in the start-line. HTTP-version is case-sensitive.
356 HTTP-version = HTTP-name "/" DIGIT "." DIGIT
357 HTTP-name = %s"HTTP"
359 When an HTTP/1.1 message is sent to an HTTP/1.0 recipient [RFC1945]
360 or a recipient whose version is unknown, the HTTP/1.1 message is
361 constructed such that it can be interpreted as a valid HTTP/1.0
362 message if all of the newer features are ignored. This specification
363 places recipient-version requirements on some new features so that a
364 conformant sender will only use compatible features until it has
365 determined, through configuration or the receipt of a message, that
366 the recipient supports HTTP/1.1.
368 Intermediaries that process HTTP messages (i.e., all intermediaries
369 other than those acting as tunnels) MUST send their own HTTP-version
370 in forwarded messages. In other words, they are not allowed to
371 blindly forward the start-line without ensuring that the protocol
372 version in that message matches a version to which that intermediary
373 is conformant for both the receiving and sending of messages.
374 Forwarding an HTTP message without rewriting the HTTP-version might
375 result in communication errors when downstream recipients use the
376 message sender's version to determine what features are safe to use
377 for later communication with that sender.
379 A server MAY send an HTTP/1.0 response to an HTTP/1.1 request if it
380 is known or suspected that the client incorrectly implements the HTTP
381 specification and is incapable of correctly processing later version
382 responses, such as when a client fails to parse the version number
383 correctly or when an intermediary is known to blindly forward the
384 HTTP-version even when it doesn't conform to the given minor version
385 of the protocol. Such protocol downgrades SHOULD NOT be performed
386 unless triggered by specific client attributes, such as when one or
387 more of the request header fields (e.g., User-Agent) uniquely match
388 the values sent by a client known to be in error.
390 3. Request Line
392 A request-line begins with a method token, followed by a single space
393 (SP), the request-target, another single space (SP), and ends with
394 the protocol version.
396 request-line = method SP request-target SP HTTP-version
398 Although the request-line grammar rule requires that each of the
399 component elements be separated by a single SP octet, recipients MAY
400 instead parse on whitespace-delimited word boundaries and, aside from
401 the CRLF terminator, treat any form of whitespace as the SP separator
402 while ignoring preceding or trailing whitespace; such whitespace
403 includes one or more of the following octets: SP, HTAB, VT (%x0B), FF
404 (%x0C), or bare CR. However, lenient parsing can result in request
405 smuggling security vulnerabilities if there are multiple recipients
406 of the message and each has its own unique interpretation of
407 robustness (see Section 11.2).
409 HTTP does not place a predefined limit on the length of a request-
410 line, as described in Section 2 of [Semantics]. A server that
411 receives a method longer than any that it implements SHOULD respond
412 with a 501 (Not Implemented) status code. A server that receives a
413 request-target longer than any URI it wishes to parse MUST respond
414 with a 414 (URI Too Long) status code (see Section 14.5.15 of
415 [Semantics]).
417 Various ad hoc limitations on request-line length are found in
418 practice. It is RECOMMENDED that all HTTP senders and recipients
419 support, at a minimum, request-line lengths of 8000 octets.
421 3.1. Method
423 The method token indicates the request method to be performed on the
424 target resource. The request method is case-sensitive.
426 method = token
428 The request methods defined by this specification can be found in
429 Section 8 of [Semantics], along with information regarding the HTTP
430 method registry and considerations for defining new methods.
432 3.2. Request Target
434 The request-target identifies the target resource upon which to apply
435 the request. The client derives a request-target from its desired
436 target URI. There are four distinct formats for the request-target,
437 depending on both the method being requested and whether the request
438 is to a proxy.
440 request-target = origin-form
441 / absolute-form
442 / authority-form
443 / asterisk-form
445 No whitespace is allowed in the request-target. Unfortunately, some
446 user agents fail to properly encode or exclude whitespace found in
447 hypertext references, resulting in those disallowed characters being
448 sent as the request-target in a malformed request-line.
450 Recipients of an invalid request-line SHOULD respond with either a
451 400 (Bad Request) error or a 301 (Moved Permanently) redirect with
452 the request-target properly encoded. A recipient SHOULD NOT attempt
453 to autocorrect and then process the request without a redirect, since
454 the invalid request-line might be deliberately crafted to bypass
455 security filters along the request chain.
457 A client MUST send a Host header field in all HTTP/1.1 request
458 messages. If the target URI includes an authority component, then a
459 client MUST send a field value for Host that is identical to that
460 authority component, excluding any userinfo subcomponent and its "@"
461 delimiter (Section 4.2.1 of [Semantics]). If the authority component
462 is missing or undefined for the target URI, then a client MUST send a
463 Host header field with an empty field value.
465 A server MUST respond with a 400 (Bad Request) status code to any
466 HTTP/1.1 request message that lacks a Host header field and to any
467 request message that contains more than one Host header field or a
468 Host header field with an invalid field value.
470 3.2.1. origin-form
472 The most common form of request-target is the origin-form.
474 origin-form = absolute-path [ "?" query ]
476 When making a request directly to an origin server, other than a
477 CONNECT or server-wide OPTIONS request (as detailed below), a client
478 MUST send only the absolute path and query components of the target
479 URI as the request-target. If the target URI's path component is
480 empty, the client MUST send "/" as the path within the origin-form of
481 request-target. A Host header field is also sent, as defined in
482 Section 6.1.2 of [Semantics].
484 For example, a client wishing to retrieve a representation of the
485 resource identified as
487 http://www.example.org/where?q=now
489 directly from the origin server would open (or reuse) a TCP
490 connection to port 80 of the host "www.example.org" and send the
491 lines:
493 GET /where?q=now HTTP/1.1
494 Host: www.example.org
496 followed by the remainder of the request message.
498 3.2.2. absolute-form
500 When making a request to a proxy, other than a CONNECT or server-wide
501 OPTIONS request (as detailed below), a client MUST send the target
502 URI in absolute-form as the request-target.
504 absolute-form = absolute-URI
506 The proxy is requested to either service that request from a valid
507 cache, if possible, or make the same request on the client's behalf
508 to either the next inbound proxy server or directly to the origin
509 server indicated by the request-target. Requirements on such
510 "forwarding" of messages are defined in Section 6.4 of [Semantics].
512 An example absolute-form of request-line would be:
514 GET http://www.example.org/pub/WWW/TheProject.html HTTP/1.1
516 A client MUST send a Host header field in an HTTP/1.1 request even if
517 the request-target is in the absolute-form, since this allows the
518 Host information to be forwarded through ancient HTTP/1.0 proxies
519 that might not have implemented Host.
521 When a proxy receives a request with an absolute-form of request-
522 target, the proxy MUST ignore the received Host header field (if any)
523 and instead replace it with the host information of the request-
524 target. A proxy that forwards such a request MUST generate a new
525 Host field value based on the received request-target rather than
526 forward the received Host field value.
528 When an origin server receives a request with an absolute-form of
529 request-target, the origin server MUST ignore the received Host
530 header field (if any) and instead use the host information of the
531 request-target. Note that if the request-target does not have an
532 authority component, an empty Host header field will be sent in this
533 case.
535 To allow for transition to the absolute-form for all requests in some
536 future version of HTTP, a server MUST accept the absolute-form in
537 requests, even though HTTP/1.1 clients will only send them in
538 requests to proxies.
540 3.2.3. authority-form
542 The authority-form of request-target is only used for CONNECT
543 requests (Section 8.3.6 of [Semantics]).
545 authority-form = authority
547 When making a CONNECT request to establish a tunnel through one or
548 more proxies, a client MUST send only the target URI's authority
549 component (excluding any userinfo and its "@" delimiter) as the
550 request-target. For example,
552 CONNECT www.example.com:80 HTTP/1.1
554 3.2.4. asterisk-form
556 The asterisk-form of request-target is only used for a server-wide
557 OPTIONS request (Section 8.3.7 of [Semantics]).
559 asterisk-form = "*"
561 When a client wishes to request OPTIONS for the server as a whole, as
562 opposed to a specific named resource of that server, the client MUST
563 send only "*" (%x2A) as the request-target. For example,
564 OPTIONS * HTTP/1.1
566 If a proxy receives an OPTIONS request with an absolute-form of
567 request-target in which the URI has an empty path and no query
568 component, then the last proxy on the request chain MUST send a
569 request-target of "*" when it forwards the request to the indicated
570 origin server.
572 For example, the request
574 OPTIONS http://www.example.org:8001 HTTP/1.1
576 would be forwarded by the final proxy as
578 OPTIONS * HTTP/1.1
579 Host: www.example.org:8001
581 after connecting to port 8001 of host "www.example.org".
583 3.3. Reconstructing the Target URI
585 Since the request-target often contains only part of the user agent's
586 target URI, a server constructs its value to properly service the
587 request (Section 6.1 of [Semantics]).
589 If the request-target is in absolute-form, the target URI is the same
590 as the request-target. Otherwise, the target URI is constructed as
591 follows:
593 o If the server's configuration (or outbound gateway) provides a
594 fixed URI scheme, that scheme is used for the target URI.
595 Otherwise, if the request is received over a secured connection,
596 the target URI's scheme is "https"; if not, the scheme is "http".
598 o If the server's configuration (or outbound gateway) provides a
599 fixed URI authority component, that authority is used for the
600 target URI. If not, then if the request-target is in
601 authority-form, the target URI's authority component is the same
602 as the request-target. If not, then if a Host header field is
603 supplied with a non-empty field-value, the authority component is
604 the same as the Host field-value. Otherwise, the authority
605 component is assigned the default name configured for the server
606 and, if the connection's incoming TCP port number differs from the
607 default port for the target URI's scheme, then a colon (":") and
608 the incoming port number (in decimal form) are appended to the
609 authority component.
611 o If the request-target is in authority-form or asterisk-form, the
612 target URI's combined path and query component is empty.
613 Otherwise, the combined path and query component is the same as
614 the request-target.
616 o The components of the target URI, once determined as above, can be
617 combined into absolute-URI form by concatenating the scheme,
618 "://", authority, and combined path and query component.
620 Example 1: the following message received over an insecure TCP
621 connection
623 GET /pub/WWW/TheProject.html HTTP/1.1
624 Host: www.example.org:8080
626 has a target URI of
628 http://www.example.org:8080/pub/WWW/TheProject.html
630 Example 2: the following message received over a secured connection
632 OPTIONS * HTTP/1.1
633 Host: www.example.org
635 has a target URI of
637 https://www.example.org
639 Recipients of an HTTP/1.0 request that lacks a Host header field
640 might need to use heuristics (e.g., examination of the URI path for
641 something unique to a particular host) in order to guess the target
642 URI's authority component.
644 4. Status Line
646 The first line of a response message is the status-line, consisting
647 of the protocol version, a space (SP), the status code, another
648 space, and ending with an OPTIONAL textual phrase describing the
649 status code.
651 status-line = HTTP-version SP status-code SP [reason-phrase]
653 Although the status-line grammar rule requires that each of the
654 component elements be separated by a single SP octet, recipients MAY
655 instead parse on whitespace-delimited word boundaries and, aside from
656 the line terminator, treat any form of whitespace as the SP separator
657 while ignoring preceding or trailing whitespace; such whitespace
658 includes one or more of the following octets: SP, HTAB, VT (%x0B), FF
659 (%x0C), or bare CR. However, lenient parsing can result in response
660 splitting security vulnerabilities if there are multiple recipients
661 of the message and each has its own unique interpretation of
662 robustness (see Section 11.1).
664 The status-code element is a 3-digit integer code describing the
665 result of the server's attempt to understand and satisfy the client's
666 corresponding request. The rest of the response message is to be
667 interpreted in light of the semantics defined for that status code.
668 See Section 14 of [Semantics] for information about the semantics of
669 status codes, including the classes of status code (indicated by the
670 first digit), the status codes defined by this specification,
671 considerations for the definition of new status codes, and the IANA
672 registry.
674 status-code = 3DIGIT
676 The reason-phrase element exists for the sole purpose of providing a
677 textual description associated with the numeric status code, mostly
678 out of deference to earlier Internet application protocols that were
679 more frequently used with interactive text clients.
681 reason-phrase = 1*( HTAB / SP / VCHAR / obs-text )
683 A client SHOULD ignore the reason-phrase content because it is not a
684 reliable channel for information (it might be translated for a given
685 locale, overwritten by intermediaries, or discarded when the message
686 is forwarded via other versions of HTTP). A server MUST send the
687 space that separates status-code from the reason-phrase even when the
688 reason-phrase is absent (i.e., the status-line would end with the
689 three octets SP CR LF).
691 5. Field Syntax
693 Each field line consists of a case-insensitive field name followed by
694 a colon (":"), optional leading whitespace, the field line value, and
695 optional trailing whitespace.
697 field-line = field-name ":" OWS field-value OWS
699 Most HTTP field names and the rules for parsing within field values
700 are defined in Section 5.4 of [Semantics]. This section covers the
701 generic syntax for header field inclusion within, and extraction
702 from, HTTP/1.1 messages. In addition, the following header fields
703 are defined by this document because they are specific to HTTP/1.1
704 message processing:
706 ------------------- ---------- ------
707 Field Name Status Ref.
708 ------------------- ---------- ------
709 MIME-Version standard B.1
710 Transfer-Encoding standard 6.1
711 ------------------- ---------- ------
713 Table 1
715 Furthermore, the field name "Close" is reserved, since using that
716 name as an HTTP header field might conflict with the "close"
717 connection option of the Connection header field (Section 6.4.1 of
718 [Semantics]).
720 ------------ ---------- ----------- ------------
721 Field Name Status Reference Comments
722 ------------ ---------- ----------- ------------
723 Close standard Section 5 (reserved)
724 ------------ ---------- ----------- ------------
726 Table 2
728 5.1. Field Line Parsing
730 Messages are parsed using a generic algorithm, independent of the
731 individual field names. The contents within a given field line value
732 are not parsed until a later stage of message interpretation (usually
733 after the message's entire header section has been processed).
735 No whitespace is allowed between the field name and colon. In the
736 past, differences in the handling of such whitespace have led to
737 security vulnerabilities in request routing and response handling. A
738 server MUST reject any received request message that contains
739 whitespace between a header field name and colon with a response
740 status code of 400 (Bad Request). A proxy MUST remove any such
741 whitespace from a response message before forwarding the message
742 downstream.
744 A field line value might be preceded and/or followed by optional
745 whitespace (OWS); a single SP preceding the field line value is
746 preferred for consistent readability by humans. The field line value
747 does not include any leading or trailing whitespace: OWS occurring
748 before the first non-whitespace octet of the field line value or
749 after the last non-whitespace octet of the field line value ought to
750 be excluded by parsers when extracting the field line value from a
751 header field line.
753 5.2. Obsolete Line Folding
755 Historically, HTTP header field line values could be extended over
756 multiple lines by preceding each extra line with at least one space
757 or horizontal tab (obs-fold). This specification deprecates such
758 line folding except within the message/http media type
759 (Section 10.1).
761 obs-fold = OWS CRLF RWS
762 ; obsolete line folding
764 A sender MUST NOT generate a message that includes line folding
765 (i.e., that has any field line value that contains a match to the
766 obs-fold rule) unless the message is intended for packaging within
767 the message/http media type.
769 A server that receives an obs-fold in a request message that is not
770 within a message/http container MUST either reject the message by
771 sending a 400 (Bad Request), preferably with a representation
772 explaining that obsolete line folding is unacceptable, or replace
773 each received obs-fold with one or more SP octets prior to
774 interpreting the field value or forwarding the message downstream.
776 A proxy or gateway that receives an obs-fold in a response message
777 that is not within a message/http container MUST either discard the
778 message and replace it with a 502 (Bad Gateway) response, preferably
779 with a representation explaining that unacceptable line folding was
780 received, or replace each received obs-fold with one or more SP
781 octets prior to interpreting the field value or forwarding the
782 message downstream.
784 A user agent that receives an obs-fold in a response message that is
785 not within a message/http container MUST replace each received
786 obs-fold with one or more SP octets prior to interpreting the field
787 value.
789 6. Message Body
791 The message body (if any) of an HTTP message is used to carry the
792 payload body (Section 5.5.4 of [Semantics]) of that request or
793 response. The message body is identical to the payload body unless a
794 transfer coding has been applied, as described in Section 6.1.
796 message-body = *OCTET
798 The rules for determining when a message body is present in an
799 HTTP/1.1 message differ for requests and responses.
801 The presence of a message body in a request is signaled by a
802 Content-Length or Transfer-Encoding header field. Request message
803 framing is independent of method semantics, even if the method does
804 not define any use for a message body.
806 The presence of a message body in a response depends on both the
807 request method to which it is responding and the response status code
808 (Section 4), and corresponds to when a payload body is allowed; see
809 Section 5.5.4 of [Semantics].
811 6.1. Transfer-Encoding
813 The Transfer-Encoding header field lists the transfer coding names
814 corresponding to the sequence of transfer codings that have been (or
815 will be) applied to the payload body in order to form the message
816 body. Transfer codings are defined in Section 7.
818 Transfer-Encoding = #transfer-coding
820 Transfer-Encoding is analogous to the Content-Transfer-Encoding field
821 of MIME, which was designed to enable safe transport of binary data
822 over a 7-bit transport service ([RFC2045], Section 6). However, safe
823 transport has a different focus for an 8bit-clean transfer protocol.
824 In HTTP's case, Transfer-Encoding is primarily intended to accurately
825 delimit a dynamically generated payload and to distinguish payload
826 encodings that are only applied for transport efficiency or security
827 from those that are characteristics of the selected resource.
829 A recipient MUST be able to parse the chunked transfer coding
830 (Section 7.1) because it plays a crucial role in framing messages
831 when the payload body size is not known in advance. A sender MUST
832 NOT apply chunked more than once to a message body (i.e., chunking an
833 already chunked message is not allowed). If any transfer coding
834 other than chunked is applied to a request payload body, the sender
835 MUST apply chunked as the final transfer coding to ensure that the
836 message is properly framed. If any transfer coding other than
837 chunked is applied to a response payload body, the sender MUST either
838 apply chunked as the final transfer coding or terminate the message
839 by closing the connection.
841 For example,
843 Transfer-Encoding: gzip, chunked
845 indicates that the payload body has been compressed using the gzip
846 coding and then chunked using the chunked coding while forming the
847 message body.
849 Unlike Content-Encoding (Section 7.5.1 of [Semantics]), Transfer-
850 Encoding is a property of the message, not of the representation, and
851 any recipient along the request/response chain MAY decode the
852 received transfer coding(s) or apply additional transfer coding(s) to
853 the message body, assuming that corresponding changes are made to the
854 Transfer-Encoding field value. Additional information about the
855 encoding parameters can be provided by other header fields not
856 defined by this specification.
858 Transfer-Encoding MAY be sent in a response to a HEAD request or in a
859 304 (Not Modified) response (Section 14.4.5 of [Semantics]) to a GET
860 request, neither of which includes a message body, to indicate that
861 the origin server would have applied a transfer coding to the message
862 body if the request had been an unconditional GET. This indication
863 is not required, however, because any recipient on the response chain
864 (including the origin server) can remove transfer codings when they
865 are not needed.
867 A server MUST NOT send a Transfer-Encoding header field in any
868 response with a status code of 1xx (Informational) or 204 (No
869 Content). A server MUST NOT send a Transfer-Encoding header field in
870 any 2xx (Successful) response to a CONNECT request (Section 8.3.6 of
871 [Semantics]).
873 Transfer-Encoding was added in HTTP/1.1. It is generally assumed
874 that implementations advertising only HTTP/1.0 support will not
875 understand how to process a transfer-encoded payload. A client MUST
876 NOT send a request containing Transfer-Encoding unless it knows the
877 server will handle HTTP/1.1 requests (or later minor revisions); such
878 knowledge might be in the form of specific user configuration or by
879 remembering the version of a prior received response. A server MUST
880 NOT send a response containing Transfer-Encoding unless the
881 corresponding request indicates HTTP/1.1 (or later minor revisions).
883 A server that receives a request message with a transfer coding it
884 does not understand SHOULD respond with 501 (Not Implemented).
886 6.2. Content-Length
888 When a message does not have a Transfer-Encoding header field, a
889 Content-Length header field can provide the anticipated size, as a
890 decimal number of octets, for a potential payload body. For messages
891 that do include a payload body, the Content-Length field value
892 provides the framing information necessary for determining where the
893 body (and message) ends. For messages that do not include a payload
894 body, the Content-Length indicates the size of the selected
895 representation (Section 7.7 of [Semantics]).
897 | *Note:* HTTP's use of Content-Length for message framing
898 | differs significantly from the same field's use in MIME, where
899 | it is an optional field used only within the "message/external-
900 | body" media-type.
902 6.3. Message Body Length
904 The length of a message body is determined by one of the following
905 (in order of precedence):
907 1. Any response to a HEAD request and any response with a 1xx
908 (Informational), 204 (No Content), or 304 (Not Modified) status
909 code is always terminated by the first empty line after the
910 header fields, regardless of the header fields present in the
911 message, and thus cannot contain a message body.
913 2. Any 2xx (Successful) response to a CONNECT request implies that
914 the connection will become a tunnel immediately after the empty
915 line that concludes the header fields. A client MUST ignore any
916 Content-Length or Transfer-Encoding header fields received in
917 such a message.
919 3. If a Transfer-Encoding header field is present and the chunked
920 transfer coding (Section 7.1) is the final encoding, the message
921 body length is determined by reading and decoding the chunked
922 data until the transfer coding indicates the data is complete.
924 If a Transfer-Encoding header field is present in a response and
925 the chunked transfer coding is not the final encoding, the
926 message body length is determined by reading the connection until
927 it is closed by the server. If a Transfer-Encoding header field
928 is present in a request and the chunked transfer coding is not
929 the final encoding, the message body length cannot be determined
930 reliably; the server MUST respond with the 400 (Bad Request)
931 status code and then close the connection.
933 If a message is received with both a Transfer-Encoding and a
934 Content-Length header field, the Transfer-Encoding overrides the
935 Content-Length. Such a message might indicate an attempt to
936 perform request smuggling (Section 11.2) or response splitting
937 (Section 11.1) and ought to be handled as an error. A sender
938 MUST remove the received Content-Length field prior to forwarding
939 such a message downstream.
941 4. If a message is received without Transfer-Encoding and with an
942 invalid Content-Length header field, then the message framing is
943 invalid and the recipient MUST treat it as an unrecoverable
944 error, unless the field value can be successfully parsed as a
945 comma-separated list (Section 5.7.1 of [Semantics]), all values
946 in the list are valid, and all values in the list are the same.
947 If this is a request message, the server MUST respond with a 400
948 (Bad Request) status code and then close the connection. If this
949 is a response message received by a proxy, the proxy MUST close
950 the connection to the server, discard the received response, and
951 send a 502 (Bad Gateway) response to the client. If this is a
952 response message received by a user agent, the user agent MUST
953 close the connection to the server and discard the received
954 response.
956 5. If a valid Content-Length header field is present without
957 Transfer-Encoding, its decimal value defines the expected message
958 body length in octets. If the sender closes the connection or
959 the recipient times out before the indicated number of octets are
960 received, the recipient MUST consider the message to be
961 incomplete and close the connection.
963 6. If this is a request message and none of the above are true, then
964 the message body length is zero (no message body is present).
966 7. Otherwise, this is a response message without a declared message
967 body length, so the message body length is determined by the
968 number of octets received prior to the server closing the
969 connection.
971 Since there is no way to distinguish a successfully completed, close-
972 delimited response message from a partially received message
973 interrupted by network failure, a server SHOULD generate encoding or
974 length-delimited messages whenever possible. The close-delimiting
975 feature exists primarily for backwards compatibility with HTTP/1.0.
977 | *Note:* Request messages are never close-delimited because they
978 | are always explicitly framed by length or transfer coding, with
979 | the absence of both implying the request ends immediately after
980 | the header section.
982 A server MAY reject a request that contains a message body but not a
983 Content-Length by responding with 411 (Length Required).
985 Unless a transfer coding other than chunked has been applied, a
986 client that sends a request containing a message body SHOULD use a
987 valid Content-Length header field if the message body length is known
988 in advance, rather than the chunked transfer coding, since some
989 existing services respond to chunked with a 411 (Length Required)
990 status code even though they understand the chunked transfer coding.
991 This is typically because such services are implemented via a gateway
992 that requires a content-length in advance of being called and the
993 server is unable or unwilling to buffer the entire request before
994 processing.
996 A user agent that sends a request containing a message body MUST send
997 a valid Content-Length header field if it does not know the server
998 will handle HTTP/1.1 (or later) requests; such knowledge can be in
999 the form of specific user configuration or by remembering the version
1000 of a prior received response.
1002 If the final response to the last request on a connection has been
1003 completely received and there remains additional data to read, a user
1004 agent MAY discard the remaining data or attempt to determine if that
1005 data belongs as part of the prior response body, which might be the
1006 case if the prior message's Content-Length value is incorrect. A
1007 client MUST NOT process, cache, or forward such extra data as a
1008 separate response, since such behavior would be vulnerable to cache
1009 poisoning.
1011 7. Transfer Codings
1013 Transfer coding names are used to indicate an encoding transformation
1014 that has been, can be, or might need to be applied to a payload body
1015 in order to ensure "safe transport" through the network. This
1016 differs from a content coding in that the transfer coding is a
1017 property of the message rather than a property of the representation
1018 that is being transferred.
1020 transfer-coding = token *( OWS ";" OWS transfer-parameter )
1022 Parameters are in the form of a name=value pair.
1024 transfer-parameter = token BWS "=" BWS ( token / quoted-string )
1026 All transfer-coding names are case-insensitive and ought to be
1027 registered within the HTTP Transfer Coding registry, as defined in
1028 Section 7.3. They are used in the TE (Section 9.1.4 of [Semantics])
1029 and Transfer-Encoding (Section 6.1) header fields.
1031 ------------ ------------------------------- -----------
1032 Name Description Reference
1033 ------------ ------------------------------- -----------
1034 chunked Transfer in a series of Section
1035 chunks 7.1
1036 compress UNIX "compress" data format Section
1037 [Welch] 7.2
1038 deflate "deflate" compressed data Section
1039 ([RFC1951]) inside the "zlib" 7.2
1040 data format ([RFC1950])
1041 gzip GZIP file format [RFC1952] Section
1042 7.2
1043 trailers (reserved) Section 7
1044 x-compress Deprecated (alias for Section
1045 compress) 7.2
1046 x-gzip Deprecated (alias for gzip) Section
1047 7.2
1048 ------------ ------------------------------- -----------
1050 Table 3
1052 | *Note:* the coding name "trailers" is reserved because its use
1053 | would conflict with the keyword "trailers" in the TE header
1054 | field (Section 9.1.4 of [Semantics]).
1056 7.1. Chunked Transfer Coding
1058 The chunked transfer coding wraps the payload body in order to
1059 transfer it as a series of chunks, each with its own size indicator,
1060 followed by an OPTIONAL trailer section containing trailer fields.
1061 Chunked enables content streams of unknown size to be transferred as
1062 a sequence of length-delimited buffers, which enables the sender to
1063 retain connection persistence and the recipient to know when it has
1064 received the entire message.
1066 chunked-body = *chunk
1067 last-chunk
1068 trailer-section
1069 CRLF
1071 chunk = chunk-size [ chunk-ext ] CRLF
1072 chunk-data CRLF
1073 chunk-size = 1*HEXDIG
1074 last-chunk = 1*("0") [ chunk-ext ] CRLF
1076 chunk-data = 1*OCTET ; a sequence of chunk-size octets
1078 The chunk-size field is a string of hex digits indicating the size of
1079 the chunk-data in octets. The chunked transfer coding is complete
1080 when a chunk with a chunk-size of zero is received, possibly followed
1081 by a trailer section, and finally terminated by an empty line.
1083 A recipient MUST be able to parse and decode the chunked transfer
1084 coding.
1086 Note that HTTP/1.1 does not define any means to limit the size of a
1087 chunked response such that an intermediary can be assured of
1088 buffering the entire response.
1090 The chunked encoding does not define any parameters. Their presence
1091 SHOULD be treated as an error.
1093 7.1.1. Chunk Extensions
1095 The chunked encoding allows each chunk to include zero or more chunk
1096 extensions, immediately following the chunk-size, for the sake of
1097 supplying per-chunk metadata (such as a signature or hash), mid-
1098 message control information, or randomization of message body size.
1100 chunk-ext = *( BWS ";" BWS chunk-ext-name
1101 [ BWS "=" BWS chunk-ext-val ] )
1103 chunk-ext-name = token
1104 chunk-ext-val = token / quoted-string
1106 The chunked encoding is specific to each connection and is likely to
1107 be removed or recoded by each recipient (including intermediaries)
1108 before any higher-level application would have a chance to inspect
1109 the extensions. Hence, use of chunk extensions is generally limited
1110 to specialized HTTP services such as "long polling" (where client and
1111 server can have shared expectations regarding the use of chunk
1112 extensions) or for padding within an end-to-end secured connection.
1114 A recipient MUST ignore unrecognized chunk extensions. A server
1115 ought to limit the total length of chunk extensions received in a
1116 request to an amount reasonable for the services provided, in the
1117 same way that it applies length limitations and timeouts for other
1118 parts of a message, and generate an appropriate 4xx (Client Error)
1119 response if that amount is exceeded.
1121 7.1.2. Chunked Trailer Section
1123 A trailer section allows the sender to include additional fields at
1124 the end of a chunked message in order to supply metadata that might
1125 be dynamically generated while the message body is sent, such as a
1126 message integrity check, digital signature, or post-processing
1127 status. The proper use and limitations of trailer fields are defined
1128 in Section 5.6 of [Semantics].
1130 trailer-section = *( field-line CRLF )
1132 A recipient that decodes and removes the chunked encoding from a
1133 message (e.g., for storage or forwarding to a non-HTTP/1.1 peer) MUST
1134 discard any received trailer fields, store/forward them separately
1135 from the header fields, or selectively merge into the header section
1136 only those trailer fields corresponding to header field definitions
1137 that are understood by the recipient to explicitly permit and define
1138 how their corresponding trailer field value can be safely merged.
1140 7.1.3. Decoding Chunked
1142 A process for decoding the chunked transfer coding can be represented
1143 in pseudo-code as:
1145 length := 0
1146 read chunk-size, chunk-ext (if any), and CRLF
1147 while (chunk-size > 0) {
1148 read chunk-data and CRLF
1149 append chunk-data to decoded-body
1150 length := length + chunk-size
1151 read chunk-size, chunk-ext (if any), and CRLF
1152 }
1153 read trailer field
1154 while (trailer field is not empty) {
1155 if (trailer fields are stored/forwarded separately) {
1156 append trailer field to existing trailer fields
1157 }
1158 else if (trailer field is understood and defined as mergeable) {
1159 merge trailer field with existing header fields
1160 }
1161 else {
1162 discard trailer field
1163 }
1164 read trailer field
1165 }
1166 Content-Length := length
1167 Remove "chunked" from Transfer-Encoding
1168 Remove Trailer from existing header fields
1170 7.2. Transfer Codings for Compression
1172 The following transfer coding names for compression are defined by
1173 the same algorithm as their corresponding content coding:
1175 compress (and x-compress)
1176 See Section 7.5.1.1 of [Semantics].
1178 deflate
1179 See Section 7.5.1.2 of [Semantics].
1181 gzip (and x-gzip)
1182 See Section 7.5.1.3 of [Semantics].
1184 The compression codings do not define any parameters. Their presence
1185 SHOULD be treated as an error.
1187 7.3. Transfer Coding Registry
1189 The "HTTP Transfer Coding Registry" defines the namespace for
1190 transfer coding names. It is maintained at
1191 .
1193 Registrations MUST include the following fields:
1195 o Name
1197 o Description
1199 o Pointer to specification text
1201 Names of transfer codings MUST NOT overlap with names of content
1202 codings (Section 7.5.1 of [Semantics]) unless the encoding
1203 transformation is identical, as is the case for the compression
1204 codings defined in Section 7.2.
1206 The TE header field (Section 9.1.4 of [Semantics]) uses a pseudo
1207 parameter named "q" as rank value when multiple transfer codings are
1208 acceptable. Future registrations of transfer codings SHOULD NOT
1209 define parameters called "q" (case-insensitively) in order to avoid
1210 ambiguities.
1212 Values to be added to this namespace require IETF Review (see
1213 Section 4.8 of [RFC8126]), and MUST conform to the purpose of
1214 transfer coding defined in this specification.
1216 Use of program names for the identification of encoding formats is
1217 not desirable and is discouraged for future encodings.
1219 7.4. Negotiating Transfer Codings
1221 The TE field (Section 9.1.4 of [Semantics]) is used in HTTP/1.1 to
1222 indicate what transfer-codings, besides chunked, the client is
1223 willing to accept in the response, and whether or not the client is
1224 willing to accept trailer fields in a chunked transfer coding.
1226 A client MUST NOT send the chunked transfer coding name in TE;
1227 chunked is always acceptable for HTTP/1.1 recipients.
1229 Three examples of TE use are below.
1231 TE: deflate
1232 TE:
1233 TE: trailers, deflate;q=0.5
1235 When multiple transfer codings are acceptable, the client MAY rank
1236 the codings by preference using a case-insensitive "q" parameter
1237 (similar to the qvalues used in content negotiation fields,
1238 Section 11.1.1.2 of [Semantics]). The rank value is a real number in
1239 the range 0 through 1, where 0.001 is the least preferred and 1 is
1240 the most preferred; a value of 0 means "not acceptable".
1242 If the TE field value is empty or if no TE field is present, the only
1243 acceptable transfer coding is chunked. A message with no transfer
1244 coding is always acceptable.
1246 The keyword "trailers" indicates that the sender will not discard
1247 trailer fields, as described in Section 5.6 of [Semantics].
1249 Since the TE header field only applies to the immediate connection, a
1250 sender of TE MUST also send a "TE" connection option within the
1251 Connection header field (Section 6.4.1 of [Semantics]) in order to
1252 prevent the TE field from being forwarded by intermediaries that do
1253 not support its semantics.
1255 8. Handling Incomplete Messages
1257 A server that receives an incomplete request message, usually due to
1258 a canceled request or a triggered timeout exception, MAY send an
1259 error response prior to closing the connection.
1261 A client that receives an incomplete response message, which can
1262 occur when a connection is closed prematurely or when decoding a
1263 supposedly chunked transfer coding fails, MUST record the message as
1264 incomplete. Cache requirements for incomplete responses are defined
1265 in Section 3 of [Caching].
1267 If a response terminates in the middle of the header section (before
1268 the empty line is received) and the status code might rely on header
1269 fields to convey the full meaning of the response, then the client
1270 cannot assume that meaning has been conveyed; the client might need
1271 to repeat the request in order to determine what action to take next.
1273 A message body that uses the chunked transfer coding is incomplete if
1274 the zero-sized chunk that terminates the encoding has not been
1275 received. A message that uses a valid Content-Length is incomplete
1276 if the size of the message body received (in octets) is less than the
1277 value given by Content-Length. A response that has neither chunked
1278 transfer coding nor Content-Length is terminated by closure of the
1279 connection and, thus, is considered complete regardless of the number
1280 of message body octets received, provided that the header section was
1281 received intact.
1283 9. Connection Management
1285 HTTP messaging is independent of the underlying transport- or
1286 session-layer connection protocol(s). HTTP only presumes a reliable
1287 transport with in-order delivery of requests and the corresponding
1288 in-order delivery of responses. The mapping of HTTP request and
1289 response structures onto the data units of an underlying transport
1290 protocol is outside the scope of this specification.
1292 As described in Section 6.2 of [Semantics], the specific connection
1293 protocols to be used for an HTTP interaction are determined by client
1294 configuration and the target URI. For example, the "http" URI scheme
1295 (Section 4.2.1 of [Semantics]) indicates a default connection of TCP
1296 over IP, with a default TCP port of 80, but the client might be
1297 configured to use a proxy via some other connection, port, or
1298 protocol.
1300 HTTP implementations are expected to engage in connection management,
1301 which includes maintaining the state of current connections,
1302 establishing a new connection or reusing an existing connection,
1303 processing messages received on a connection, detecting connection
1304 failures, and closing each connection. Most clients maintain
1305 multiple connections in parallel, including more than one connection
1306 per server endpoint. Most servers are designed to maintain thousands
1307 of concurrent connections, while controlling request queues to enable
1308 fair use and detect denial-of-service attacks.
1310 9.1. Establishment
1312 It is beyond the scope of this specification to describe how
1313 connections are established via various transport- or session-layer
1314 protocols. Each connection applies to only one transport link.
1316 9.2. Associating a Response to a Request
1318 HTTP/1.1 does not include a request identifier for associating a
1319 given request message with its corresponding one or more response
1320 messages. Hence, it relies on the order of response arrival to
1321 correspond exactly to the order in which requests are made on the
1322 same connection. More than one response message per request only
1323 occurs when one or more informational responses (1xx, see
1324 Section 14.2 of [Semantics]) precede a final response to the same
1325 request.
1327 A client that has more than one outstanding request on a connection
1328 MUST maintain a list of outstanding requests in the order sent and
1329 MUST associate each received response message on that connection to
1330 the highest ordered request that has not yet received a final (non-
1331 1xx) response.
1333 If an HTTP/1.1 client receives data on a connection that doesn't have
1334 any outstanding requests, it MUST NOT consider them to be a response
1335 to a not-yet-issued request; it SHOULD close the connection, since
1336 message delimitation is now ambiguous, unless the data consists only
1337 of one or more CRLF (which can be discarded, as per Section 2.2).
1339 9.3. Persistence
1341 HTTP/1.1 defaults to the use of "persistent connections", allowing
1342 multiple requests and responses to be carried over a single
1343 connection. The "close" connection option is used to signal that a
1344 connection will not persist after the current request/response. HTTP
1345 implementations SHOULD support persistent connections.
1347 A recipient determines whether a connection is persistent or not
1348 based on the most recently received message's protocol version and
1349 Connection header field (Section 6.4.1 of [Semantics]), if any:
1351 o If the "close" connection option is present, the connection will
1352 not persist after the current response; else,
1354 o If the received protocol is HTTP/1.1 (or later), the connection
1355 will persist after the current response; else,
1357 o If the received protocol is HTTP/1.0, the "keep-alive" connection
1358 option is present, either the recipient is not a proxy or the
1359 message is a response, and the recipient wishes to honor the
1360 HTTP/1.0 "keep-alive" mechanism, the connection will persist after
1361 the current response; otherwise,
1363 o The connection will close after the current response.
1365 A client that does not support persistent connections MUST send the
1366 "close" connection option in every request message.
1368 A server that does not support persistent connections MUST send the
1369 "close" connection option in every response message that does not
1370 have a 1xx (Informational) status code.
1372 A client MAY send additional requests on a persistent connection
1373 until it sends or receives a "close" connection option or receives an
1374 HTTP/1.0 response without a "keep-alive" connection option.
1376 In order to remain persistent, all messages on a connection need to
1377 have a self-defined message length (i.e., one not defined by closure
1378 of the connection), as described in Section 6. A server MUST read
1379 the entire request message body or close the connection after sending
1380 its response, since otherwise the remaining data on a persistent
1381 connection would be misinterpreted as the next request. Likewise, a
1382 client MUST read the entire response message body if it intends to
1383 reuse the same connection for a subsequent request.
1385 A proxy server MUST NOT maintain a persistent connection with an
1386 HTTP/1.0 client (see Section 19.7.1 of [RFC2068] for information and
1387 discussion of the problems with the Keep-Alive header field
1388 implemented by many HTTP/1.0 clients).
1390 See Appendix C.1.2 for more information on backwards compatibility
1391 with HTTP/1.0 clients.
1393 9.3.1. Retrying Requests
1395 Connections can be closed at any time, with or without intention.
1396 Implementations ought to anticipate the need to recover from
1397 asynchronous close events. The conditions under which a client can
1398 automatically retry a sequence of outstanding requests are defined in
1399 Section 8.2.2 of [Semantics].
1401 9.3.2. Pipelining
1403 A client that supports persistent connections MAY "pipeline" its
1404 requests (i.e., send multiple requests without waiting for each
1405 response). A server MAY process a sequence of pipelined requests in
1406 parallel if they all have safe methods (Section 8.2.1 of
1407 [Semantics]), but it MUST send the corresponding responses in the
1408 same order that the requests were received.
1410 A client that pipelines requests SHOULD retry unanswered requests if
1411 the connection closes before it receives all of the corresponding
1412 responses. When retrying pipelined requests after a failed
1413 connection (a connection not explicitly closed by the server in its
1414 last complete response), a client MUST NOT pipeline immediately after
1415 connection establishment, since the first remaining request in the
1416 prior pipeline might have caused an error response that can be lost
1417 again if multiple requests are sent on a prematurely closed
1418 connection (see the TCP reset problem described in Section 9.6).
1420 Idempotent methods (Section 8.2.2 of [Semantics]) are significant to
1421 pipelining because they can be automatically retried after a
1422 connection failure. A user agent SHOULD NOT pipeline requests after
1423 a non-idempotent method, until the final response status code for
1424 that method has been received, unless the user agent has a means to
1425 detect and recover from partial failure conditions involving the
1426 pipelined sequence.
1428 An intermediary that receives pipelined requests MAY pipeline those
1429 requests when forwarding them inbound, since it can rely on the
1430 outbound user agent(s) to determine what requests can be safely
1431 pipelined. If the inbound connection fails before receiving a
1432 response, the pipelining intermediary MAY attempt to retry a sequence
1433 of requests that have yet to receive a response if the requests all
1434 have idempotent methods; otherwise, the pipelining intermediary
1435 SHOULD forward any received responses and then close the
1436 corresponding outbound connection(s) so that the outbound user
1437 agent(s) can recover accordingly.
1439 9.4. Concurrency
1441 A client ought to limit the number of simultaneous open connections
1442 that it maintains to a given server.
1444 Previous revisions of HTTP gave a specific number of connections as a
1445 ceiling, but this was found to be impractical for many applications.
1446 As a result, this specification does not mandate a particular maximum
1447 number of connections but, instead, encourages clients to be
1448 conservative when opening multiple connections.
1450 Multiple connections are typically used to avoid the "head-of-line
1451 blocking" problem, wherein a request that takes significant server-
1452 side processing and/or has a large payload blocks subsequent requests
1453 on the same connection. However, each connection consumes server
1454 resources. Furthermore, using multiple connections can cause
1455 undesirable side effects in congested networks.
1457 Note that a server might reject traffic that it deems abusive or
1458 characteristic of a denial-of-service attack, such as an excessive
1459 number of open connections from a single client.
1461 9.5. Failures and Timeouts
1463 Servers will usually have some timeout value beyond which they will
1464 no longer maintain an inactive connection. Proxy servers might make
1465 this a higher value since it is likely that the client will be making
1466 more connections through the same proxy server. The use of
1467 persistent connections places no requirements on the length (or
1468 existence) of this timeout for either the client or the server.
1470 A client or server that wishes to time out SHOULD issue a graceful
1471 close on the connection. Implementations SHOULD constantly monitor
1472 open connections for a received closure signal and respond to it as
1473 appropriate, since prompt closure of both sides of a connection
1474 enables allocated system resources to be reclaimed.
1476 A client, server, or proxy MAY close the transport connection at any
1477 time. For example, a client might have started to send a new request
1478 at the same time that the server has decided to close the "idle"
1479 connection. From the server's point of view, the connection is being
1480 closed while it was idle, but from the client's point of view, a
1481 request is in progress.
1483 A server SHOULD sustain persistent connections, when possible, and
1484 allow the underlying transport's flow-control mechanisms to resolve
1485 temporary overloads, rather than terminate connections with the
1486 expectation that clients will retry. The latter technique can
1487 exacerbate network congestion.
1489 A client sending a message body SHOULD monitor the network connection
1490 for an error response while it is transmitting the request. If the
1491 client sees a response that indicates the server does not wish to
1492 receive the message body and is closing the connection, the client
1493 SHOULD immediately cease transmitting the body and close its side of
1494 the connection.
1496 9.6. Tear-down
1498 The Connection header field (Section 6.4.1 of [Semantics]) provides a
1499 "close" connection option that a sender SHOULD send when it wishes to
1500 close the connection after the current request/response pair.
1502 A client that sends a "close" connection option MUST NOT send further
1503 requests on that connection (after the one containing "close") and
1504 MUST close the connection after reading the final response message
1505 corresponding to this request.
1507 A server that receives a "close" connection option MUST initiate a
1508 close of the connection (see below) after it sends the final response
1509 to the request that contained "close". The server SHOULD send a
1510 "close" connection option in its final response on that connection.
1511 The server MUST NOT process any further requests received on that
1512 connection.
1514 A server that sends a "close" connection option MUST initiate a close
1515 of the connection (see below) after it sends the response containing
1516 "close". The server MUST NOT process any further requests received
1517 on that connection.
1519 A client that receives a "close" connection option MUST cease sending
1520 requests on that connection and close the connection after reading
1521 the response message containing the "close"; if additional pipelined
1522 requests had been sent on the connection, the client SHOULD NOT
1523 assume that they will be processed by the server.
1525 If a server performs an immediate close of a TCP connection, there is
1526 a significant risk that the client will not be able to read the last
1527 HTTP response. If the server receives additional data from the
1528 client on a fully closed connection, such as another request that was
1529 sent by the client before receiving the server's response, the
1530 server's TCP stack will send a reset packet to the client;
1531 unfortunately, the reset packet might erase the client's
1532 unacknowledged input buffers before they can be read and interpreted
1533 by the client's HTTP parser.
1535 To avoid the TCP reset problem, servers typically close a connection
1536 in stages. First, the server performs a half-close by closing only
1537 the write side of the read/write connection. The server then
1538 continues to read from the connection until it receives a
1539 corresponding close by the client, or until the server is reasonably
1540 certain that its own TCP stack has received the client's
1541 acknowledgement of the packet(s) containing the server's last
1542 response. Finally, the server fully closes the connection.
1544 It is unknown whether the reset problem is exclusive to TCP or might
1545 also be found in other transport connection protocols.
1547 Note that a TCP connection that is half-closed by the client does not
1548 delimit a request message, nor does it imply that the client is no
1549 longer interested in a response. In general, transport signals
1550 cannot be relied upon to signal edge cases, since HTTP/1.1 is
1551 independent of transport.
1553 9.7. TLS Connection Initiation
1555 Conceptually, HTTP/TLS is simply sending HTTP messages over a
1556 connection secured via TLS [RFC8446].
1558 The HTTP client also acts as the TLS client. It initiates a
1559 connection to the server on the appropriate port and sends the TLS
1560 ClientHello to begin the TLS handshake. When the TLS handshake has
1561 finished, the client may then initiate the first HTTP request. All
1562 HTTP data MUST be sent as TLS "application data", but is otherwise
1563 treated like a normal connection for HTTP (including potential reuse
1564 as a persistent connection).
1566 9.8. TLS Connection Closure
1568 TLS provides a facility for secure connection closure. When a valid
1569 closure alert is received, an implementation can be assured that no
1570 further data will be received on that connection. TLS
1571 implementations MUST initiate an exchange of closure alerts before
1572 closing a connection. A TLS implementation MAY, after sending a
1573 closure alert, close the connection without waiting for the peer to
1574 send its closure alert, generating an "incomplete close". Note that
1575 an implementation which does this MAY choose to reuse the session.
1576 This SHOULD only be done when the application knows (typically
1577 through detecting HTTP message boundaries) that it has received all
1578 the message data that it cares about.
1580 As specified in [RFC8446], any implementation which receives a
1581 connection close without first receiving a valid closure alert (a
1582 "premature close") MUST NOT reuse that session. Note that a
1583 premature close does not call into question the security of the data
1584 already received, but simply indicates that subsequent data might
1585 have been truncated. Because TLS is oblivious to HTTP request/
1586 response boundaries, it is necessary to examine the HTTP data itself
1587 (specifically the Content-Length header) to determine whether the
1588 truncation occurred inside a message or between messages.
1590 When encountering a premature close, a client SHOULD treat as
1591 completed all requests for which it has received as much data as
1592 specified in the Content-Length header.
1594 A client detecting an incomplete close SHOULD recover gracefully. It
1595 MAY resume a TLS session closed in this fashion.
1597 Clients MUST send a closure alert before closing the connection.
1598 Clients which are unprepared to receive any more data MAY choose not
1599 to wait for the server's closure alert and simply close the
1600 connection, thus generating an incomplete close on the server side.
1602 Servers SHOULD be prepared to receive an incomplete close from the
1603 client, since the client can often determine when the end of server
1604 data is. Servers SHOULD be willing to resume TLS sessions closed in
1605 this fashion.
1607 Servers MUST attempt to initiate an exchange of closure alerts with
1608 the client before closing the connection. Servers MAY close the
1609 connection after sending the closure alert, thus generating an
1610 incomplete close on the client side.
1612 10. Enclosing Messages as Data
1614 10.1. Media Type message/http
1616 The message/http media type can be used to enclose a single HTTP
1617 request or response message, provided that it obeys the MIME
1618 restrictions for all "message" types regarding line length and
1619 encodings.
1621 Type name: message
1623 Subtype name: http
1625 Required parameters: N/A
1627 Optional parameters: version, msgtype
1629 version: The HTTP-version number of the enclosed message (e.g.,
1630 "1.1"). If not present, the version can be determined from the
1631 first line of the body.
1633 msgtype: The message type - "request" or "response". If not
1634 present, the type can be determined from the first line of the
1635 body.
1637 Encoding considerations: only "7bit", "8bit", or "binary" are
1638 permitted
1640 Security considerations: see Section 11
1642 Interoperability considerations: N/A
1644 Published specification: This specification (see Section 10.1).
1646 Applications that use this media type: N/A
1648 Fragment identifier considerations: N/A
1649 Additional information: Magic number(s): N/A
1651 Deprecated alias names for this type: N/A
1653 File extension(s): N/A
1655 Macintosh file type code(s): N/A
1657 Person and email address to contact for further information: See Aut
1658 hors' Addresses section.
1660 Intended usage: COMMON
1662 Restrictions on usage: N/A
1664 Author: See Authors' Addresses section.
1666 Change controller: IESG
1668 10.2. Media Type application/http
1670 The application/http media type can be used to enclose a pipeline of
1671 one or more HTTP request or response messages (not intermixed).
1673 Type name: application
1675 Subtype name: http
1677 Required parameters: N/A
1679 Optional parameters: version, msgtype
1681 version: The HTTP-version number of the enclosed messages (e.g.,
1682 "1.1"). If not present, the version can be determined from the
1683 first line of the body.
1685 msgtype: The message type - "request" or "response". If not
1686 present, the type can be determined from the first line of the
1687 body.
1689 Encoding considerations: HTTP messages enclosed by this type are in
1690 "binary" format; use of an appropriate Content-Transfer-Encoding
1691 is required when transmitted via email.
1693 Security considerations: see Section 11
1695 Interoperability considerations: N/A
1696 Published specification: This specification (see Section 10.2).
1698 Applications that use this media type: N/A
1700 Fragment identifier considerations: N/A
1702 Additional information: Deprecated alias names for this type: N/A
1704 Magic number(s): N/A
1706 File extension(s): N/A
1708 Macintosh file type code(s): N/A
1710 Person and email address to contact for further information: See Aut
1711 hors' Addresses section.
1713 Intended usage: COMMON
1715 Restrictions on usage: N/A
1717 Author: See Authors' Addresses section.
1719 Change controller: IESG
1721 11. Security Considerations
1723 This section is meant to inform developers, information providers,
1724 and users of known security considerations relevant to HTTP message
1725 syntax, parsing, and routing. Security considerations about HTTP
1726 semantics and payloads are addressed in [Semantics].
1728 11.1. Response Splitting
1730 Response splitting (a.k.a, CRLF injection) is a common technique,
1731 used in various attacks on Web usage, that exploits the line-based
1732 nature of HTTP message framing and the ordered association of
1733 requests to responses on persistent connections [Klein]. This
1734 technique can be particularly damaging when the requests pass through
1735 a shared cache.
1737 Response splitting exploits a vulnerability in servers (usually
1738 within an application server) where an attacker can send encoded data
1739 within some parameter of the request that is later decoded and echoed
1740 within any of the response header fields of the response. If the
1741 decoded data is crafted to look like the response has ended and a
1742 subsequent response has begun, the response has been split and the
1743 content within the apparent second response is controlled by the
1744 attacker. The attacker can then make any other request on the same
1745 persistent connection and trick the recipients (including
1746 intermediaries) into believing that the second half of the split is
1747 an authoritative answer to the second request.
1749 For example, a parameter within the request-target might be read by
1750 an application server and reused within a redirect, resulting in the
1751 same parameter being echoed in the Location header field of the
1752 response. If the parameter is decoded by the application and not
1753 properly encoded when placed in the response field, the attacker can
1754 send encoded CRLF octets and other content that will make the
1755 application's single response look like two or more responses.
1757 A common defense against response splitting is to filter requests for
1758 data that looks like encoded CR and LF (e.g., "%0D" and "%0A").
1759 However, that assumes the application server is only performing URI
1760 decoding, rather than more obscure data transformations like charset
1761 transcoding, XML entity translation, base64 decoding, sprintf
1762 reformatting, etc. A more effective mitigation is to prevent
1763 anything other than the server's core protocol libraries from sending
1764 a CR or LF within the header section, which means restricting the
1765 output of header fields to APIs that filter for bad octets and not
1766 allowing application servers to write directly to the protocol
1767 stream.
1769 11.2. Request Smuggling
1771 Request smuggling ([Linhart]) is a technique that exploits
1772 differences in protocol parsing among various recipients to hide
1773 additional requests (which might otherwise be blocked or disabled by
1774 policy) within an apparently harmless request. Like response
1775 splitting, request smuggling can lead to a variety of attacks on HTTP
1776 usage.
1778 This specification has introduced new requirements on request
1779 parsing, particularly with regard to message framing in Section 6.3,
1780 to reduce the effectiveness of request smuggling.
1782 11.3. Message Integrity
1784 HTTP does not define a specific mechanism for ensuring message
1785 integrity, instead relying on the error-detection ability of
1786 underlying transport protocols and the use of length or chunk-
1787 delimited framing to detect completeness. Additional integrity
1788 mechanisms, such as hash functions or digital signatures applied to
1789 the content, can be selectively added to messages via extensible
1790 metadata fields. Historically, the lack of a single integrity
1791 mechanism has been justified by the informal nature of most HTTP
1792 communication. However, the prevalence of HTTP as an information
1793 access mechanism has resulted in its increasing use within
1794 environments where verification of message integrity is crucial.
1796 User agents are encouraged to implement configurable means for
1797 detecting and reporting failures of message integrity such that those
1798 means can be enabled within environments for which integrity is
1799 necessary. For example, a browser being used to view medical history
1800 or drug interaction information needs to indicate to the user when
1801 such information is detected by the protocol to be incomplete,
1802 expired, or corrupted during transfer. Such mechanisms might be
1803 selectively enabled via user agent extensions or the presence of
1804 message integrity metadata in a response. At a minimum, user agents
1805 ought to provide some indication that allows a user to distinguish
1806 between a complete and incomplete response message (Section 8) when
1807 such verification is desired.
1809 11.4. Message Confidentiality
1811 HTTP relies on underlying transport protocols to provide message
1812 confidentiality when that is desired. HTTP has been specifically
1813 designed to be independent of the transport protocol, such that it
1814 can be used over many different forms of encrypted connection, with
1815 the selection of such transports being identified by the choice of
1816 URI scheme or within user agent configuration.
1818 The "https" scheme can be used to identify resources that require a
1819 confidential connection, as described in Section 4.2.2 of
1820 [Semantics].
1822 12. IANA Considerations
1824 The change controller for the following registrations is: "IETF
1825 (iesg@ietf.org) - Internet Engineering Task Force".
1827 12.1. Field Name Registration
1829 Please update the "Hypertext Transfer Protocol (HTTP) Field Name
1830 Registry" at with the
1831 field names listed in the two tables of Section 5.
1833 12.2. Media Type Registration
1835 Please update the "Media Types" registry at
1836 with the registration
1837 information in Section 10.1 and Section 10.2 for the media types
1838 "message/http" and "application/http", respectively.
1840 12.3. Transfer Coding Registration
1842 Please update the "HTTP Transfer Coding Registry" at
1843 with the
1844 registration procedure of Section 7.3 and the content coding names
1845 summarized in the table of Section 7.
1847 12.4. ALPN Protocol ID Registration
1849 Please update the "TLS Application-Layer Protocol Negotiation (ALPN)
1850 Protocol IDs" registry at with the
1852 registration below:
1854 ---------- ----------------------------- ----------------
1855 Protocol Identification Sequence Reference
1856 ---------- ----------------------------- ----------------
1857 HTTP/1.1 0x68 0x74 0x74 0x70 0x2f (this
1858 0x31 0x2e 0x31 ("http/1.1") specification)
1859 ---------- ----------------------------- ----------------
1861 Table 4
1863 13. References
1865 13.1. Normative References
1867 [Caching] Fielding, R., Ed., Nottingham, M., Ed., and J. Reschke,
1868 Ed., "HTTP Caching", Work in Progress, Internet-Draft,
1869 draft-ietf-httpbis-cache-12, October 2, 2020,
1870 .
1872 [RFC1950] Deutsch, L.P. and J-L. Gailly, "ZLIB Compressed Data
1873 Format Specification version 3.3", RFC 1950,
1874 DOI 10.17487/RFC1950, May 1996,
1875 .
1877 [RFC1951] Deutsch, P., "DEFLATE Compressed Data Format Specification
1878 version 1.3", RFC 1951, DOI 10.17487/RFC1951, May 1996,
1879 .
1881 [RFC1952] Deutsch, P., Gailly, J-L., Adler, M., Deutsch, L.P., and
1882 G. Randers-Pehrson, "GZIP file format specification
1883 version 4.3", RFC 1952, DOI 10.17487/RFC1952, May 1996,
1884 .
1886 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate
1887 Requirement Levels", BCP 14, RFC 2119,
1888 DOI 10.17487/RFC2119, March 1997,
1889 .
1891 [RFC3986] Berners-Lee, T., Fielding, R., and L. Masinter, "Uniform
1892 Resource Identifier (URI): Generic Syntax", STD 66,
1893 RFC 3986, DOI 10.17487/RFC3986, January 2005,
1894 .
1896 [RFC5234] Crocker, D., Ed. and P. Overell, "Augmented BNF for Syntax
1897 Specifications: ABNF", STD 68, RFC 5234,
1898 DOI 10.17487/RFC5234, January 2008,
1899 .
1901 [RFC7405] Kyzivat, P., "Case-Sensitive String Support in ABNF",
1902 RFC 7405, DOI 10.17487/RFC7405, December 2014,
1903 .
1905 [RFC8174] Leiba, B., "Ambiguity of Uppercase vs Lowercase in RFC
1906 2119 Key Words", BCP 14, RFC 8174, DOI 10.17487/RFC8174,
1907 May 2017, .
1909 [RFC8446] Rescorla, E., "The Transport Layer Security (TLS) Protocol
1910 Version 1.3", RFC 8446, DOI 10.17487/RFC8446, August 2018,
1911 .
1913 [Semantics]
1914 Fielding, R., Ed., Nottingham, M., Ed., and J. Reschke,
1915 Ed., "HTTP Semantics", Work in Progress, Internet-Draft,
1916 draft-ietf-httpbis-semantics-12, October 2, 2020,
1917 .
1920 [USASCII] American National Standards Institute, "Coded Character
1921 Set -- 7-bit American Standard Code for Information
1922 Interchange", ANSI X3.4, 1986.
1924 [Welch] Welch, T. A., "A Technique for High-Performance Data
1925 Compression", IEEE Computer 17(6), June 1984.
1927 13.2. Informative References
1929 [Err4667] RFC Errata, Erratum ID 4667, RFC 7230,
1930 .
1932 [Klein] Klein, A., "Divide and Conquer - HTTP Response Splitting,
1933 Web Cache Poisoning Attacks, and Related Topics", March
1934 2004, .
1937 [Linhart] Linhart, C., Klein, A., Heled, R., and S. Orrin, "HTTP
1938 Request Smuggling", June 2005,
1939 .
1941 [RFC1945] Berners-Lee, T., Fielding, R.T., and H.F. Nielsen,
1942 "Hypertext Transfer Protocol -- HTTP/1.0", RFC 1945,
1943 DOI 10.17487/RFC1945, May 1996,
1944 .
1946 [RFC2045] Freed, N. and N.S. Borenstein, "Multipurpose Internet Mail
1947 Extensions (MIME) Part One: Format of Internet Message
1948 Bodies", RFC 2045, DOI 10.17487/RFC2045, November 1996,
1949 .
1951 [RFC2046] Freed, N. and N. Borenstein, "Multipurpose Internet Mail
1952 Extensions (MIME) Part Two: Media Types", RFC 2046,
1953 DOI 10.17487/RFC2046, November 1996,
1954 .
1956 [RFC2049] Freed, N. and N.S. Borenstein, "Multipurpose Internet Mail
1957 Extensions (MIME) Part Five: Conformance Criteria and
1958 Examples", RFC 2049, DOI 10.17487/RFC2049, November 1996,
1959 .
1961 [RFC2068] Fielding, R., Gettys, J., Mogul, J., Nielsen, H., and T.
1962 Berners-Lee, "Hypertext Transfer Protocol -- HTTP/1.1",
1963 RFC 2068, DOI 10.17487/RFC2068, January 1997,
1964 .
1966 [RFC2557] Palme, F., Hopmann, A., Shelness, N., and E. Stefferud,
1967 "MIME Encapsulation of Aggregate Documents, such as HTML
1968 (MHTML)", RFC 2557, DOI 10.17487/RFC2557, March 1999,
1969 .
1971 [RFC5322] Resnick, P., "Internet Message Format", RFC 5322,
1972 DOI 10.17487/RFC5322, October 2008,
1973 .
1975 [RFC7230] Fielding, R., Ed. and J. F. Reschke, Ed., "Hypertext
1976 Transfer Protocol (HTTP/1.1): Message Syntax and Routing",
1977 RFC 7230, DOI 10.17487/RFC7230, June 2014,
1978 .
1980 [RFC7231] Fielding, R., Ed. and J. F. Reschke, Ed., "Hypertext
1981 Transfer Protocol (HTTP/1.1): Semantics and Content",
1982 RFC 7231, DOI 10.17487/RFC7231, June 2014,
1983 .
1985 [RFC8126] Cotton, M., Leiba, B., and T. Narten, "Guidelines for
1986 Writing an IANA Considerations Section in RFCs", BCP 26,
1987 RFC 8126, DOI 10.17487/RFC8126, June 2017,
1988 .
1990 Appendix A. Collected ABNF
1992 In the collected ABNF below, list rules are expanded as per
1993 Section 5.7.1.1 of [Semantics].
1995 BWS =
1997 HTTP-message = start-line CRLF *( field-line CRLF ) CRLF [
1998 message-body ]
1999 HTTP-name = %x48.54.54.50 ; HTTP
2000 HTTP-version = HTTP-name "/" DIGIT "." DIGIT
2002 OWS =
2004 RWS =
2006 Transfer-Encoding = [ transfer-coding *( OWS "," OWS transfer-coding
2007 ) ]
2009 absolute-URI =
2010 absolute-form = absolute-URI
2011 absolute-path =
2012 asterisk-form = "*"
2013 authority =
2014 authority-form = authority
2016 chunk = chunk-size [ chunk-ext ] CRLF chunk-data CRLF
2017 chunk-data = 1*OCTET
2018 chunk-ext = *( BWS ";" BWS chunk-ext-name [ BWS "=" BWS chunk-ext-val
2019 ] )
2020 chunk-ext-name = token
2021 chunk-ext-val = token / quoted-string
2022 chunk-size = 1*HEXDIG
2023 chunked-body = *chunk last-chunk trailer-section CRLF
2024 comment =
2026 field-line = field-name ":" OWS field-value OWS
2027 field-name =
2028 field-value =
2030 last-chunk = 1*"0" [ chunk-ext ] CRLF
2032 message-body = *OCTET
2033 method = token
2035 obs-fold = OWS CRLF RWS
2036 obs-text =
2037 origin-form = absolute-path [ "?" query ]
2039 port =
2041 query =
2042 quoted-string =
2044 reason-phrase = 1*( HTAB / SP / VCHAR / obs-text )
2045 request-line = method SP request-target SP HTTP-version
2046 request-target = origin-form / absolute-form / authority-form /
2047 asterisk-form
2049 start-line = request-line / status-line
2050 status-code = 3DIGIT
2051 status-line = HTTP-version SP status-code SP [ reason-phrase ]
2053 token =
2054 trailer-section = *( field-line CRLF )
2055 transfer-coding = token *( OWS ";" OWS transfer-parameter )
2056 transfer-parameter = token BWS "=" BWS ( token / quoted-string )
2058 uri-host =
2060 Appendix B. Differences between HTTP and MIME
2062 HTTP/1.1 uses many of the constructs defined for the Internet Message
2063 Format [RFC5322] and the Multipurpose Internet Mail Extensions (MIME)
2064 [RFC2045] to allow a message body to be transmitted in an open
2065 variety of representations and with extensible fields. However, RFC
2066 2045 is focused only on email; applications of HTTP have many
2067 characteristics that differ from email; hence, HTTP has features that
2068 differ from MIME. These differences were carefully chosen to
2069 optimize performance over binary connections, to allow greater
2070 freedom in the use of new media types, to make date comparisons
2071 easier, and to acknowledge the practice of some early HTTP servers
2072 and clients.
2074 This appendix describes specific areas where HTTP differs from MIME.
2075 Proxies and gateways to and from strict MIME environments need to be
2076 aware of these differences and provide the appropriate conversions
2077 where necessary.
2079 B.1. MIME-Version
2081 HTTP is not a MIME-compliant protocol. However, messages can include
2082 a single MIME-Version header field to indicate what version of the
2083 MIME protocol was used to construct the message. Use of the MIME-
2084 Version header field indicates that the message is in full
2085 conformance with the MIME protocol (as defined in [RFC2045]).
2086 Senders are responsible for ensuring full conformance (where
2087 possible) when exporting HTTP messages to strict MIME environments.
2089 B.2. Conversion to Canonical Form
2091 MIME requires that an Internet mail body part be converted to
2092 canonical form prior to being transferred, as described in Section 4
2093 of [RFC2049]. Section 7.4.3 of [Semantics] describes the forms
2094 allowed for subtypes of the "text" media type when transmitted over
2095 HTTP. [RFC2046] requires that content with a type of "text"
2096 represent line breaks as CRLF and forbids the use of CR or LF outside
2097 of line break sequences. HTTP allows CRLF, bare CR, and bare LF to
2098 indicate a line break within text content.
2100 A proxy or gateway from HTTP to a strict MIME environment ought to
2101 translate all line breaks within text media types to the RFC 2049
2102 canonical form of CRLF. Note, however, this might be complicated by
2103 the presence of a Content-Encoding and by the fact that HTTP allows
2104 the use of some charsets that do not use octets 13 and 10 to
2105 represent CR and LF, respectively.
2107 Conversion will break any cryptographic checksums applied to the
2108 original content unless the original content is already in canonical
2109 form. Therefore, the canonical form is recommended for any content
2110 that uses such checksums in HTTP.
2112 B.3. Conversion of Date Formats
2114 HTTP/1.1 uses a restricted set of date formats (Section 5.7.7 of
2115 [Semantics]) to simplify the process of date comparison. Proxies and
2116 gateways from other protocols ought to ensure that any Date header
2117 field present in a message conforms to one of the HTTP/1.1 formats
2118 and rewrite the date if necessary.
2120 B.4. Conversion of Content-Encoding
2122 MIME does not include any concept equivalent to HTTP/1.1's Content-
2123 Encoding header field. Since this acts as a modifier on the media
2124 type, proxies and gateways from HTTP to MIME-compliant protocols
2125 ought to either change the value of the Content-Type header field or
2126 decode the representation before forwarding the message. (Some
2127 experimental applications of Content-Type for Internet mail have used
2128 a media-type parameter of ";conversions=" to perform
2129 a function equivalent to Content-Encoding. However, this parameter
2130 is not part of the MIME standards).
2132 B.5. Conversion of Content-Transfer-Encoding
2134 HTTP does not use the Content-Transfer-Encoding field of MIME.
2135 Proxies and gateways from MIME-compliant protocols to HTTP need to
2136 remove any Content-Transfer-Encoding prior to delivering the response
2137 message to an HTTP client.
2139 Proxies and gateways from HTTP to MIME-compliant protocols are
2140 responsible for ensuring that the message is in the correct format
2141 and encoding for safe transport on that protocol, where "safe
2142 transport" is defined by the limitations of the protocol being used.
2143 Such a proxy or gateway ought to transform and label the data with an
2144 appropriate Content-Transfer-Encoding if doing so will improve the
2145 likelihood of safe transport over the destination protocol.
2147 B.6. MHTML and Line Length Limitations
2149 HTTP implementations that share code with MHTML [RFC2557]
2150 implementations need to be aware of MIME line length limitations.
2151 Since HTTP does not have this limitation, HTTP does not fold long
2152 lines. MHTML messages being transported by HTTP follow all
2153 conventions of MHTML, including line length limitations and folding,
2154 canonicalization, etc., since HTTP transfers message-bodies as
2155 payload and, aside from the "multipart/byteranges" type (Section 13.5
2156 of [Semantics]), does not interpret the content or any MIME header
2157 lines that might be contained therein.
2159 Appendix C. HTTP Version History
2161 HTTP has been in use since 1990. The first version, later referred
2162 to as HTTP/0.9, was a simple protocol for hypertext data transfer
2163 across the Internet, using only a single request method (GET) and no
2164 metadata. HTTP/1.0, as defined by [RFC1945], added a range of
2165 request methods and MIME-like messaging, allowing for metadata to be
2166 transferred and modifiers placed on the request/response semantics.
2167 However, HTTP/1.0 did not sufficiently take into consideration the
2168 effects of hierarchical proxies, caching, the need for persistent
2169 connections, or name-based virtual hosts. The proliferation of
2170 incompletely implemented applications calling themselves "HTTP/1.0"
2171 further necessitated a protocol version change in order for two
2172 communicating applications to determine each other's true
2173 capabilities.
2175 HTTP/1.1 remains compatible with HTTP/1.0 by including more stringent
2176 requirements that enable reliable implementations, adding only those
2177 features that can either be safely ignored by an HTTP/1.0 recipient
2178 or only be sent when communicating with a party advertising
2179 conformance with HTTP/1.1.
2181 HTTP/1.1 has been designed to make supporting previous versions easy.
2182 A general-purpose HTTP/1.1 server ought to be able to understand any
2183 valid request in the format of HTTP/1.0, responding appropriately
2184 with an HTTP/1.1 message that only uses features understood (or
2185 safely ignored) by HTTP/1.0 clients. Likewise, an HTTP/1.1 client
2186 can be expected to understand any valid HTTP/1.0 response.
2188 Since HTTP/0.9 did not support header fields in a request, there is
2189 no mechanism for it to support name-based virtual hosts (selection of
2190 resource by inspection of the Host header field). Any server that
2191 implements name-based virtual hosts ought to disable support for
2192 HTTP/0.9. Most requests that appear to be HTTP/0.9 are, in fact,
2193 badly constructed HTTP/1.x requests caused by a client failing to
2194 properly encode the request-target.
2196 C.1. Changes from HTTP/1.0
2198 This section summarizes major differences between versions HTTP/1.0
2199 and HTTP/1.1.
2201 C.1.1. Multihomed Web Servers
2203 The requirements that clients and servers support the Host header
2204 field (Section 6.1.2 of [Semantics]), report an error if it is
2205 missing from an HTTP/1.1 request, and accept absolute URIs
2206 (Section 3.2) are among the most important changes defined by
2207 HTTP/1.1.
2209 Older HTTP/1.0 clients assumed a one-to-one relationship of IP
2210 addresses and servers; there was no other established mechanism for
2211 distinguishing the intended server of a request than the IP address
2212 to which that request was directed. The Host header field was
2213 introduced during the development of HTTP/1.1 and, though it was
2214 quickly implemented by most HTTP/1.0 browsers, additional
2215 requirements were placed on all HTTP/1.1 requests in order to ensure
2216 complete adoption. At the time of this writing, most HTTP-based
2217 services are dependent upon the Host header field for targeting
2218 requests.
2220 C.1.2. Keep-Alive Connections
2222 In HTTP/1.0, each connection is established by the client prior to
2223 the request and closed by the server after sending the response.
2224 However, some implementations implement the explicitly negotiated
2225 ("Keep-Alive") version of persistent connections described in
2226 Section 19.7.1 of [RFC2068].
2228 Some clients and servers might wish to be compatible with these
2229 previous approaches to persistent connections, by explicitly
2230 negotiating for them with a "Connection: keep-alive" request header
2231 field. However, some experimental implementations of HTTP/1.0
2232 persistent connections are faulty; for example, if an HTTP/1.0 proxy
2233 server doesn't understand Connection, it will erroneously forward
2234 that header field to the next inbound server, which would result in a
2235 hung connection.
2237 One attempted solution was the introduction of a Proxy-Connection
2238 header field, targeted specifically at proxies. In practice, this
2239 was also unworkable, because proxies are often deployed in multiple
2240 layers, bringing about the same problem discussed above.
2242 As a result, clients are encouraged not to send the Proxy-Connection
2243 header field in any requests.
2245 Clients are also encouraged to consider the use of Connection: keep-
2246 alive in requests carefully; while they can enable persistent
2247 connections with HTTP/1.0 servers, clients using them will need to
2248 monitor the connection for "hung" requests (which indicate that the
2249 client ought stop sending the header field), and this mechanism ought
2250 not be used by clients at all when a proxy is being used.
2252 C.1.3. Introduction of Transfer-Encoding
2254 HTTP/1.1 introduces the Transfer-Encoding header field (Section 6.1).
2255 Transfer codings need to be decoded prior to forwarding an HTTP
2256 message over a MIME-compliant protocol.
2258 C.2. Changes from RFC 7230
2260 Most of the sections introducing HTTP's design goals, history,
2261 architecture, conformance criteria, protocol versioning, URIs,
2262 message routing, and header fields have been moved to [Semantics].
2263 This document has been reduced to just the messaging syntax and
2264 connection management requirements specific to HTTP/1.1.
2266 Prohibited generation of bare CRs outside of payload body.
2267 (Section 2.2)
2269 In the ABNF for chunked extensions, re-introduced (bad) whitespace
2270 around ";" and "=". Whitespace was removed in [RFC7230], but that
2271 change was found to break existing implementations (see [Err4667]).
2272 (Section 7.1.1)
2274 Trailer field semantics now transcend the specifics of chunked
2275 encoding. The decoding algorithm for chunked (Section 7.1.3) has
2276 been updated to encourage storage/forwarding of trailer fields
2277 separately from the header section, to only allow merging into the
2278 header section if the recipient knows the corresponding field
2279 definition permits and defines how to merge, and otherwise to discard
2280 the trailer fields instead of merging. The trailer part is now
2281 called the trailer section to be more consistent with the header
2282 section and more distinct from a body part. (Section 7.1.2)
2284 Disallowed transfer coding parameters called "q" in order to avoid
2285 conflicts with the use of ranks in the TE header field.
2286 (Section 7.3)
2288 Appendix D. Change Log
2290 This section is to be removed before publishing as an RFC.
2292 D.1. Between RFC7230 and draft 00
2294 The changes were purely editorial:
2296 o Change boilerplate and abstract to indicate the "draft" status,
2297 and update references to ancestor specifications.
2299 o Adjust historical notes.
2301 o Update links to sibling specifications.
2303 o Replace sections listing changes from RFC 2616 by new empty
2304 sections referring to RFC 723x.
2306 o Remove acknowledgements specific to RFC 723x.
2308 o Move "Acknowledgements" to the very end and make them unnumbered.
2310 D.2. Since draft-ietf-httpbis-messaging-00
2312 The changes in this draft are editorial, with respect to HTTP as a
2313 whole, to move all core HTTP semantics into [Semantics]:
2315 o Moved introduction, architecture, conformance, and ABNF extensions
2316 from RFC 7230 (Messaging) to semantics [Semantics].
2318 o Moved discussion of MIME differences from RFC 7231 (Semantics) to
2319 Appendix B since they mostly cover transforming 1.1 messages.
2321 o Moved all extensibility tips, registration procedures, and
2322 registry tables from the IANA considerations to normative
2323 sections, reducing the IANA considerations to just instructions
2324 that will be removed prior to publication as an RFC.
2326 D.3. Since draft-ietf-httpbis-messaging-01
2328 o Cite RFC 8126 instead of RFC 5226 ()
2331 o Resolved erratum 4779, no change needed here
2332 (,
2333 )
2335 o In Section 7, fixed prose claiming transfer parameters allow bare
2336 names (,
2337 )
2339 o Resolved erratum 4225, no change needed here
2340 (,
2341 )
2343 o Replace "response code" with "response status code"
2344 (,
2345 )
2347 o In Section 9.3, clarify statement about HTTP/1.0 keep-alive
2348 (,
2349 )
2351 o In Section 7.1.1, re-introduce (bad) whitespace around ";" and "="
2352 (,
2353 , )
2356 o In Section 7.3, state that transfer codings should not use
2357 parameters named "q" (, )
2360 o In Section 7, mark coding name "trailers" as reserved in the IANA
2361 registry ()
2363 D.4. Since draft-ietf-httpbis-messaging-02
2365 o In Section 4, explain why the reason phrase should be ignored by
2366 clients ().
2368 o Add Section 9.2 to explain how request/response correlation is
2369 performed ()
2371 D.5. Since draft-ietf-httpbis-messaging-03
2373 o In Section 9.2, caution against treating data on a connection as
2374 part of a not-yet-issued request ()
2377 o In Section 7, remove the predefined codings from the ABNF and make
2378 it generic instead ()
2381 o Use RFC 7405 ABNF notation for case-sensitive string constants
2382 ()
2384 D.6. Since draft-ietf-httpbis-messaging-04
2386 o In Section 6.6 of [Semantics], clarify that protocol-name is to be
2387 matched case-insensitively ()
2390 o In Section 5.2, add leading optional whitespace to obs-fold ABNF
2391 (,
2392 )
2394 o In Section 4, add clarifications about empty reason phrases
2395 ()
2397 o Move discussion of retries from Section 9.3.1 into [Semantics]
2398 ()
2400 D.7. Since draft-ietf-httpbis-messaging-05
2402 o In Section 7.1.2, the trailer part has been renamed the trailer
2403 section (for consistency with the header section) and trailers are
2404 no longer merged as header fields by default, but rather can be
2405 discarded, kept separate from header fields, or merged with header
2406 fields only if understood and defined as being mergeable
2407 ()
2409 o In Section 2.1 and related Sections, move the trailing CRLF from
2410 the line grammars into the message format
2411 ()
2413 o Moved Section 2.3 down ()
2416 o In Section 6.6 of [Semantics], use 'websocket' instead of
2417 'HTTP/2.0' in examples ()
2420 o Move version non-specific text from Section 6 into semantics as
2421 "payload body" ()
2423 o In Section 9.8, add text from RFC 2818
2424 ()
2426 D.8. Since draft-ietf-httpbis-messaging-06
2428 o In Section 12.4, update the APLN protocol id for HTTP/1.1
2429 ()
2431 o In Section 5, align with updates to field terminology in semantics
2432 ()
2434 o In Section 6.4.1 of [Semantics], clarify that new connection
2435 options indeed need to be registered ()
2438 o In Section 1.1, reference RFC 8174 as well
2439 ()
2441 D.9. Since draft-ietf-httpbis-messaging-07
2443 o Move TE: trailers into [Semantics] ()
2446 o In Section 6.3, adjust requirements for handling multiple content-
2447 length values ()
2449 o Throughout, replace "effective request URI" with "target URI"
2450 ()
2452 o In Section 6.1, don't claim Transfer-Encoding is supported by
2453 HTTP/2 or later ()
2455 D.10. Since draft-ietf-httpbis-messaging-08
2457 o In Section 2.2, disallow bare CRs ()
2460 o Appendix A now uses the sender variant of the "#" list expansion
2461 ()
2463 o In Section 5, adjust IANA "Close" entry for new registry format
2464 ()
2466 D.11. Since draft-ietf-httpbis-messaging-09
2468 o Switch to xml2rfc v3 mode for draft generation
2469 ()
2471 D.12. Since draft-ietf-httpbis-messaging-10
2473 o In Section 6.3, note that TCP half-close does not delimit a
2474 request; talk about corresponding server-side behaviour in
2475 Section 9.6 ()
2477 o Moved requirements specific to HTTP/1.1 from [Semantics] into
2478 Section 3.2 ()
2480 o In Section 6.1 (Transfer-Encoding), adjust ABNF to allow empty
2481 lists ()
2483 o In Section 9.7, add text from RFC 2818
2484 ()
2486 o Moved definitions of "TE" and "Upgrade" into [Semantics]
2487 ()
2489 o Moved definition of "Connection" into [Semantics]
2490 ()
2492 D.13. Since draft-ietf-httpbis-messaging-11
2494 o Move IANA Upgrade Token Registry instructions to [Semantics]
2495 ()
2497 Acknowledgments
2499 See Appendix "Acknowledgments" of [Semantics].
2501 Authors' Addresses
2503 Roy T. Fielding (editor)
2504 Adobe
2505 345 Park Ave
2506 San Jose, CA 95110
2507 United States of America
2509 Email: fielding@gbiv.com
2510 URI: https://roy.gbiv.com/
2512 Mark Nottingham (editor)
2513 Fastly
2514 Prahran VIC
2515 Australia
2517 Email: mnot@mnot.net
2518 URI: https://www.mnot.net/
2520 Julian Reschke (editor)
2521 greenbytes GmbH
2522 Hafenweg 16
2523 48155 Münster
2524 Germany
2526 Email: julian.reschke@greenbytes.de
2527 URI: https://greenbytes.de/tech/webdav/