source: draft-ietf-httpbis/latest/p1-messaging.xml @ 877

Last change on this file since 877 was 877, checked in by fielding@…, 9 years ago

Addresses #159: HTTP(s) URI scheme definitions

Make clear that userinfo is not allowed.
Clarify the differences between "http" and "https".

  • Property svn:eol-style set to native
File size: 243.1 KB
Line 
1<?xml version="1.0" encoding="utf-8"?>
2<?xml-stylesheet type='text/xsl' href='../myxml2rfc.xslt'?>
3<!DOCTYPE rfc [
4  <!ENTITY MAY "<bcp14 xmlns='http://purl.org/net/xml2rfc/ext'>MAY</bcp14>">
5  <!ENTITY MUST "<bcp14 xmlns='http://purl.org/net/xml2rfc/ext'>MUST</bcp14>">
6  <!ENTITY MUST-NOT "<bcp14 xmlns='http://purl.org/net/xml2rfc/ext'>MUST NOT</bcp14>">
7  <!ENTITY OPTIONAL "<bcp14 xmlns='http://purl.org/net/xml2rfc/ext'>OPTIONAL</bcp14>">
8  <!ENTITY RECOMMENDED "<bcp14 xmlns='http://purl.org/net/xml2rfc/ext'>RECOMMENDED</bcp14>">
9  <!ENTITY REQUIRED "<bcp14 xmlns='http://purl.org/net/xml2rfc/ext'>REQUIRED</bcp14>">
10  <!ENTITY SHALL "<bcp14 xmlns='http://purl.org/net/xml2rfc/ext'>SHALL</bcp14>">
11  <!ENTITY SHALL-NOT "<bcp14 xmlns='http://purl.org/net/xml2rfc/ext'>SHALL NOT</bcp14>">
12  <!ENTITY SHOULD "<bcp14 xmlns='http://purl.org/net/xml2rfc/ext'>SHOULD</bcp14>">
13  <!ENTITY SHOULD-NOT "<bcp14 xmlns='http://purl.org/net/xml2rfc/ext'>SHOULD NOT</bcp14>">
14  <!ENTITY ID-VERSION "latest">
15  <!ENTITY ID-MONTH "July">
16  <!ENTITY ID-YEAR "2010">
17  <!ENTITY caching-overview       "<xref target='Part6' x:rel='#caching.overview' xmlns:x='http://purl.org/net/xml2rfc/ext'/>">
18  <!ENTITY cache-incomplete       "<xref target='Part6' x:rel='#errors.or.incomplete.response.cache.behavior' xmlns:x='http://purl.org/net/xml2rfc/ext'/>">
19  <!ENTITY payload                "<xref target='Part3' xmlns:x='http://purl.org/net/xml2rfc/ext'/>">
20  <!ENTITY media-types            "<xref target='Part3' x:rel='#media.types' xmlns:x='http://purl.org/net/xml2rfc/ext'/>">
21  <!ENTITY content-codings        "<xref target='Part3' x:rel='#content.codings' xmlns:x='http://purl.org/net/xml2rfc/ext'/>">
22  <!ENTITY CONNECT                "<xref target='Part2' x:rel='#CONNECT' xmlns:x='http://purl.org/net/xml2rfc/ext'/>">
23  <!ENTITY content.negotiation    "<xref target='Part3' x:rel='#content.negotiation' xmlns:x='http://purl.org/net/xml2rfc/ext'/>">
24  <!ENTITY diff-mime              "<xref target='Part3' x:rel='#differences.between.http.and.mime' xmlns:x='http://purl.org/net/xml2rfc/ext'/>">
25  <!ENTITY representation         "<xref target='Part3' x:rel='#representation' xmlns:x='http://purl.org/net/xml2rfc/ext'/>">
26  <!ENTITY entity-header-fields   "<xref target='Part3' x:rel='#entity.header.fields' xmlns:x='http://purl.org/net/xml2rfc/ext'/>">
27  <!ENTITY header-cache-control   "<xref target='Part6' x:rel='#header.cache-control' xmlns:x='http://purl.org/net/xml2rfc/ext'/>">
28  <!ENTITY header-expect          "<xref target='Part2' x:rel='#header.expect' xmlns:x='http://purl.org/net/xml2rfc/ext'/>">
29  <!ENTITY header-pragma          "<xref target='Part6' x:rel='#header.pragma' xmlns:x='http://purl.org/net/xml2rfc/ext'/>">
30  <!ENTITY header-warning         "<xref target='Part6' x:rel='#header.warning' xmlns:x='http://purl.org/net/xml2rfc/ext'/>">
31  <!ENTITY idempotent-methods     "<xref target='Part2' x:rel='#idempotent.methods' xmlns:x='http://purl.org/net/xml2rfc/ext'/>">
32  <!ENTITY request-header-fields  "<xref target='Part2' x:rel='#request.header.fields' xmlns:x='http://purl.org/net/xml2rfc/ext'/>">
33  <!ENTITY response-header-fields "<xref target='Part2' x:rel='#response.header.fields' xmlns:x='http://purl.org/net/xml2rfc/ext'/>">
34  <!ENTITY status-codes           "<xref target='Part2' x:rel='#status.codes' xmlns:x='http://purl.org/net/xml2rfc/ext'/>">
35  <!ENTITY status-100             "<xref target='Part2' x:rel='#status.100' xmlns:x='http://purl.org/net/xml2rfc/ext'/>">
36  <!ENTITY status-1xx             "<xref target='Part2' x:rel='#status.1xx' xmlns:x='http://purl.org/net/xml2rfc/ext'/>">
37  <!ENTITY status-414             "<xref target='Part2' x:rel='#status.414' xmlns:x='http://purl.org/net/xml2rfc/ext'/>">
38]>
39<?rfc toc="yes" ?>
40<?rfc symrefs="yes" ?>
41<?rfc sortrefs="yes" ?>
42<?rfc compact="yes"?>
43<?rfc subcompact="no" ?>
44<?rfc linkmailto="no" ?>
45<?rfc editing="no" ?>
46<?rfc comments="yes"?>
47<?rfc inline="yes"?>
48<?rfc rfcedstyle="yes"?>
49<?rfc-ext allow-markup-in-artwork="yes" ?>
50<?rfc-ext include-references-in-index="yes" ?>
51<rfc obsoletes="2616" updates="2817" category="std" x:maturity-level="draft"
52     ipr="pre5378Trust200902" docName="draft-ietf-httpbis-p1-messaging-&ID-VERSION;"
53     xmlns:x='http://purl.org/net/xml2rfc/ext'>
54<front>
55
56  <title abbrev="HTTP/1.1, Part 1">HTTP/1.1, part 1: URIs, Connections, and Message Parsing</title>
57
58  <author initials="R." surname="Fielding" fullname="Roy T. Fielding" role="editor">
59    <organization abbrev="Day Software">Day Software</organization>
60    <address>
61      <postal>
62        <street>23 Corporate Plaza DR, Suite 280</street>
63        <city>Newport Beach</city>
64        <region>CA</region>
65        <code>92660</code>
66        <country>USA</country>
67      </postal>
68      <phone>+1-949-706-5300</phone>
69      <facsimile>+1-949-706-5305</facsimile>
70      <email>fielding@gbiv.com</email>
71      <uri>http://roy.gbiv.com/</uri>
72    </address>
73  </author>
74
75  <author initials="J." surname="Gettys" fullname="Jim Gettys">
76    <organization abbrev="Alcatel-Lucent">Alcatel-Lucent Bell Labs</organization>
77    <address>
78      <postal>
79        <street>21 Oak Knoll Road</street>
80        <city>Carlisle</city>
81        <region>MA</region>
82        <code>01741</code>
83        <country>USA</country>
84      </postal>
85      <email>jg@freedesktop.org</email>
86      <uri>http://gettys.wordpress.com/</uri>
87    </address>
88  </author>
89 
90  <author initials="J." surname="Mogul" fullname="Jeffrey C. Mogul">
91    <organization abbrev="HP">Hewlett-Packard Company</organization>
92    <address>
93      <postal>
94        <street>HP Labs, Large Scale Systems Group</street>
95        <street>1501 Page Mill Road, MS 1177</street>
96        <city>Palo Alto</city>
97        <region>CA</region>
98        <code>94304</code>
99        <country>USA</country>
100      </postal>
101      <email>JeffMogul@acm.org</email>
102    </address>
103  </author>
104
105  <author initials="H." surname="Frystyk" fullname="Henrik Frystyk Nielsen">
106    <organization abbrev="Microsoft">Microsoft Corporation</organization>
107    <address>
108      <postal>
109        <street>1 Microsoft Way</street>
110        <city>Redmond</city>
111        <region>WA</region>
112        <code>98052</code>
113        <country>USA</country>
114      </postal>
115      <email>henrikn@microsoft.com</email>
116    </address>
117  </author>
118
119  <author initials="L." surname="Masinter" fullname="Larry Masinter">
120    <organization abbrev="Adobe Systems">Adobe Systems, Incorporated</organization>
121    <address>
122      <postal>
123        <street>345 Park Ave</street>
124        <city>San Jose</city>
125        <region>CA</region>
126        <code>95110</code>
127        <country>USA</country>
128      </postal>
129      <email>LMM@acm.org</email>
130      <uri>http://larry.masinter.net/</uri>
131    </address>
132  </author>
133 
134  <author initials="P." surname="Leach" fullname="Paul J. Leach">
135    <organization abbrev="Microsoft">Microsoft Corporation</organization>
136    <address>
137      <postal>
138        <street>1 Microsoft Way</street>
139        <city>Redmond</city>
140        <region>WA</region>
141        <code>98052</code>
142      </postal>
143      <email>paulle@microsoft.com</email>
144    </address>
145  </author>
146   
147  <author initials="T." surname="Berners-Lee" fullname="Tim Berners-Lee">
148    <organization abbrev="W3C/MIT">World Wide Web Consortium</organization>
149    <address>
150      <postal>
151        <street>MIT Computer Science and Artificial Intelligence Laboratory</street>
152        <street>The Stata Center, Building 32</street>
153        <street>32 Vassar Street</street>
154        <city>Cambridge</city>
155        <region>MA</region>
156        <code>02139</code>
157        <country>USA</country>
158      </postal>
159      <email>timbl@w3.org</email>
160      <uri>http://www.w3.org/People/Berners-Lee/</uri>
161    </address>
162  </author>
163
164  <author initials="Y." surname="Lafon" fullname="Yves Lafon" role="editor">
165    <organization abbrev="W3C">World Wide Web Consortium</organization>
166    <address>
167      <postal>
168        <street>W3C / ERCIM</street>
169        <street>2004, rte des Lucioles</street>
170        <city>Sophia-Antipolis</city>
171        <region>AM</region>
172        <code>06902</code>
173        <country>France</country>
174      </postal>
175      <email>ylafon@w3.org</email>
176      <uri>http://www.raubacapeu.net/people/yves/</uri>
177    </address>
178  </author>
179
180  <author initials="J. F." surname="Reschke" fullname="Julian F. Reschke" role="editor">
181    <organization abbrev="greenbytes">greenbytes GmbH</organization>
182    <address>
183      <postal>
184        <street>Hafenweg 16</street>
185        <city>Muenster</city><region>NW</region><code>48155</code>
186        <country>Germany</country>
187      </postal>
188      <phone>+49 251 2807760</phone>
189      <facsimile>+49 251 2807761</facsimile>
190      <email>julian.reschke@greenbytes.de</email>
191      <uri>http://greenbytes.de/tech/webdav/</uri>
192    </address>
193  </author>
194
195  <date month="&ID-MONTH;" year="&ID-YEAR;"/>
196  <workgroup>HTTPbis Working Group</workgroup>
197
198<abstract>
199<t>
200   The Hypertext Transfer Protocol (HTTP) is an application-level
201   protocol for distributed, collaborative, hypertext information
202   systems. HTTP has been in use by the World Wide Web global information
203   initiative since 1990. This document is Part 1 of the seven-part specification
204   that defines the protocol referred to as "HTTP/1.1" and, taken together,
205   obsoletes RFC 2616.  Part 1 provides an overview of HTTP and
206   its associated terminology, defines the "http" and "https" Uniform
207   Resource Identifier (URI) schemes, defines the generic message syntax
208   and parsing requirements for HTTP message frames, and describes
209   general security concerns for implementations.
210</t>
211</abstract>
212
213<note title="Editorial Note (To be removed by RFC Editor)">
214  <t>
215    Discussion of this draft should take place on the HTTPBIS working group
216    mailing list (ietf-http-wg@w3.org). The current issues list is
217    at <eref target="http://tools.ietf.org/wg/httpbis/trac/report/3"/>
218    and related documents (including fancy diffs) can be found at
219    <eref target="http://tools.ietf.org/wg/httpbis/"/>.
220  </t>
221  <t>
222    The changes in this draft are summarized in <xref target="changes.since.10"/>.
223  </t>
224</note>
225</front>
226<middle>
227<section title="Introduction" anchor="introduction">
228<t>
229   The Hypertext Transfer Protocol (HTTP) is an application-level
230   request/response protocol that uses extensible semantics and MIME-like
231   message payloads for flexible interaction with network-based hypertext
232   information systems. HTTP relies upon the Uniform Resource Identifier (URI)
233   standard <xref target="RFC3986"/> to indicate request targets and
234   relationships between resources.
235   Messages are passed in a format similar to that used by Internet mail
236   <xref target="RFC5322"/> and the Multipurpose Internet Mail Extensions
237   (MIME) <xref target="RFC2045"/> (see &diff-mime; for the differences
238   between HTTP and MIME messages).
239</t>
240<t>
241   HTTP is a generic interface protocol for information systems. It is
242   designed to hide the details of how a service is implemented by presenting
243   a uniform interface to clients that is independent of the types of
244   resources provided. Likewise, servers do not need to be aware of each
245   client's purpose: an HTTP request can be considered in isolation rather
246   than being associated with a specific type of client or a predetermined
247   sequence of application steps. The result is a protocol that can be used
248   effectively in many different contexts and for which implementations can
249   evolve independently over time.
250</t>
251<t>
252   HTTP is also designed for use as an intermediation protocol for translating
253   communication to and from non-HTTP information systems.
254   HTTP proxies and gateways can provide access to alternative information
255   services by translating their diverse protocols into a hypertext
256   format that can be viewed and manipulated by clients in the same way
257   as HTTP services.
258</t>
259<t>
260   One consequence of HTTP flexibility is that the protocol cannot be
261   defined in terms of what occurs behind the interface. Instead, we
262   are limited to defining the syntax of communication, the intent
263   of received communication, and the expected behavior of recipients.
264   If the communication is considered in isolation, then successful
265   actions should be reflected in corresponding changes to the
266   observable interface provided by servers. However, since multiple
267   clients may act in parallel and perhaps at cross-purposes, we
268   cannot require that such changes be observable beyond the scope
269   of a single response.
270</t>
271<t>
272   This document is Part 1 of the seven-part specification of HTTP,
273   defining the protocol referred to as "HTTP/1.1" and obsoleting
274   <xref target="RFC2616"/>.
275   Part 1 describes the architectural elements that are used or
276   referred to in HTTP, defines the "http" and "https" URI schemes,
277   describes overall network operation and connection management,
278   and defines HTTP message framing and forwarding requirements.
279   Our goal is to define all of the mechanisms necessary for HTTP message
280   handling that are independent of message semantics, thereby defining the
281   complete set of requirements for message parsers and
282   message-forwarding intermediaries.
283</t>
284
285<section title="Requirements" anchor="intro.requirements">
286<t>
287   The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
288   "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this
289   document are to be interpreted as described in <xref target="RFC2119"/>.
290</t>
291<t>
292   An implementation is not compliant if it fails to satisfy one or more
293   of the "MUST" or "REQUIRED" level requirements for the protocols it
294   implements. An implementation that satisfies all the "MUST" or "REQUIRED"
295   level and all the "SHOULD" level requirements for its protocols is said
296   to be "unconditionally compliant"; one that satisfies all the "MUST"
297   level requirements but not all the "SHOULD" level requirements for its
298   protocols is said to be "conditionally compliant".
299</t>
300</section>
301
302<section title="Syntax Notation" anchor="notation">
303<iref primary="true" item="Grammar" subitem="ALPHA"/>
304<iref primary="true" item="Grammar" subitem="CR"/>
305<iref primary="true" item="Grammar" subitem="CRLF"/>
306<iref primary="true" item="Grammar" subitem="CTL"/>
307<iref primary="true" item="Grammar" subitem="DIGIT"/>
308<iref primary="true" item="Grammar" subitem="DQUOTE"/>
309<iref primary="true" item="Grammar" subitem="HEXDIG"/>
310<iref primary="true" item="Grammar" subitem="LF"/>
311<iref primary="true" item="Grammar" subitem="OCTET"/>
312<iref primary="true" item="Grammar" subitem="SP"/>
313<iref primary="true" item="Grammar" subitem="VCHAR"/>
314<iref primary="true" item="Grammar" subitem="WSP"/>
315<t>
316   This specification uses the Augmented Backus-Naur Form (ABNF) notation
317   of <xref target="RFC5234"/>.
318</t>
319<t anchor="core.rules">
320  <x:anchor-alias value="ALPHA"/>
321  <x:anchor-alias value="CTL"/>
322  <x:anchor-alias value="CR"/>
323  <x:anchor-alias value="CRLF"/>
324  <x:anchor-alias value="DIGIT"/>
325  <x:anchor-alias value="DQUOTE"/>
326  <x:anchor-alias value="HEXDIG"/>
327  <x:anchor-alias value="LF"/>
328  <x:anchor-alias value="OCTET"/>
329  <x:anchor-alias value="SP"/>
330  <x:anchor-alias value="VCHAR"/>
331  <x:anchor-alias value="WSP"/>
332   The following core rules are included by
333   reference, as defined in <xref target="RFC5234" x:fmt="," x:sec="B.1"/>:
334   ALPHA (letters), CR (carriage return), CRLF (CR LF), CTL (controls),
335   DIGIT (decimal 0-9), DQUOTE (double quote),
336   HEXDIG (hexadecimal 0-9/A-F/a-f), LF (line feed),
337   OCTET (any 8-bit sequence of data), SP (space),
338   VCHAR (any visible <xref target="USASCII"/> character),
339   and WSP (whitespace).
340</t>
341<t>
342   As a syntactic convention, ABNF rule names prefixed with "obs-" denote
343   "obsolete" grammar rules that appear for historical reasons.
344</t>
345
346<section title="ABNF Extension: #rule" anchor="notation.abnf">
347<t>
348  The #rule extension to the ABNF rules of <xref target="RFC5234"/> is used to
349  improve readability.
350</t>
351<t>
352  A construct "#" is defined, similar to "*", for defining comma-delimited
353  lists of elements. The full form is "&lt;n&gt;#&lt;m&gt;element" indicating
354  at least &lt;n&gt; and at most &lt;m&gt; elements, each separated by a single
355  comma (",") and optional whitespace (OWS,
356  <xref target="basic.rules"/>).   
357</t>
358<figure><preamble>
359  Thus,
360</preamble><artwork type="example">
361  1#element =&gt; element *( OWS "," OWS element )
362</artwork></figure>
363<figure><preamble>
364  and:
365</preamble><artwork type="example">
366  #element =&gt; [ 1#element ]
367</artwork></figure>
368<figure><preamble>
369  and for n &gt;= 1 and m &gt; 1:
370</preamble><artwork type="example">
371  &lt;n&gt;#&lt;m&gt;element =&gt; element &lt;n-1&gt;*&lt;m-1&gt;( OWS "," OWS element )
372</artwork></figure>
373<t>
374  For compatibility with legacy list rules, recipients &SHOULD; accept empty
375  list elements. In other words, consumers would follow the list productions:
376</t>
377<figure><artwork type="example">
378  #element =&gt; [ ( "," / element ) *( OWS "," [ OWS element ] ) ]
379 
380  1#element =&gt; *( "," OWS ) element *( OWS "," [ OWS element ] )
381</artwork></figure>
382<t>
383  Note that empty elements do not contribute to the count of elements present,
384  though.
385</t>
386<t>
387  For example, given these ABNF productions:
388</t>
389<figure><artwork type="example">
390  example-list      = 1#example-list-elmt
391  example-list-elmt = token ; see <xref target="basic.rules"/> 
392</artwork></figure>
393<t>
394  Then these are valid values for example-list (not including the double
395  quotes, which are present for delimitation only):
396</t>
397<figure><artwork type="example">
398  "foo,bar"
399  " foo ,bar,"
400  "  foo , ,bar,charlie   "
401  "foo ,bar,   charlie "
402</artwork></figure>
403<t>
404  But these values would be invalid, as at least one non-empty element is
405  required:
406</t>
407<figure><artwork type="example">
408  ""
409  ","
410  ",   ,"
411</artwork></figure>
412<t>
413  <xref target="collected.abnf"/> shows the collected ABNF, with the list rules
414  expanded as explained above.
415</t>
416</section>
417
418<section title="Basic Rules" anchor="basic.rules">
419<t anchor="rule.CRLF">
420  <x:anchor-alias value="CRLF"/>
421   HTTP/1.1 defines the sequence CR LF as the end-of-line marker for all
422   protocol elements other than the message-body
423   (see <xref target="tolerant.applications"/> for tolerant applications).
424</t>
425<t anchor="rule.LWS">
426   This specification uses three rules to denote the use of linear
427   whitespace: OWS (optional whitespace), RWS (required whitespace), and
428   BWS ("bad" whitespace).
429</t>
430<t>
431   The OWS rule is used where zero or more linear whitespace characters may
432   appear. OWS &SHOULD; either not be produced or be produced as a single SP
433   character. Multiple OWS characters that occur within field-content &SHOULD;
434   be replaced with a single SP before interpreting the field value or
435   forwarding the message downstream.
436</t>
437<t>
438   RWS is used when at least one linear whitespace character is required to
439   separate field tokens. RWS &SHOULD; be produced as a single SP character.
440   Multiple RWS characters that occur within field-content &SHOULD; be
441   replaced with a single SP before interpreting the field value or
442   forwarding the message downstream.
443</t>
444<t>
445   BWS is used where the grammar allows optional whitespace for historical
446   reasons but senders &SHOULD-NOT; produce it in messages. HTTP/1.1
447   recipients &MUST; accept such bad optional whitespace and remove it before
448   interpreting the field value or forwarding the message downstream.
449</t>
450<t anchor="rule.whitespace">
451  <x:anchor-alias value="BWS"/>
452  <x:anchor-alias value="OWS"/>
453  <x:anchor-alias value="RWS"/>
454  <x:anchor-alias value="obs-fold"/>
455</t>
456<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="OWS"/><iref primary="true" item="Grammar" subitem="RWS"/><iref primary="true" item="Grammar" subitem="BWS"/>
457  <x:ref>OWS</x:ref>            = *( [ obs-fold ] <x:ref>WSP</x:ref> )
458                 ; "optional" whitespace
459  <x:ref>RWS</x:ref>            = 1*( [ obs-fold ] <x:ref>WSP</x:ref> )
460                 ; "required" whitespace
461  <x:ref>BWS</x:ref>            = <x:ref>OWS</x:ref>
462                 ; "bad" whitespace
463  <x:ref>obs-fold</x:ref>       = <x:ref>CRLF</x:ref>
464                 ; see <xref target="header.fields"/>
465</artwork></figure>
466<t anchor="rule.token.separators">
467  <x:anchor-alias value="tchar"/>
468  <x:anchor-alias value="token"/>
469  <x:anchor-alias value="special"/>
470  <x:anchor-alias value="word"/>
471   Many HTTP/1.1 header field values consist of words (token or quoted-string)
472   separated by whitespace or special characters. These special characters
473   &MUST; be in a quoted string to be used within a parameter value (as defined
474   in <xref target="transfer.codings"/>).
475</t>
476<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="word"/><iref primary="true" item="Grammar" subitem="token"/><iref primary="true" item="Grammar" subitem="tchar"/><iref primary="true" item="Grammar" subitem="special"/>
477  <x:ref>word</x:ref>           = <x:ref>token</x:ref> / <x:ref>quoted-string</x:ref>
478
479  <x:ref>token</x:ref>          = 1*<x:ref>tchar</x:ref>
480<!--
481  IMPORTANT: when editing "tchar" make sure that "special" is updated accordingly!!!
482 -->
483  <x:ref>tchar</x:ref>          = "!" / "#" / "$" / "%" / "&amp;" / "'" / "*"
484                 / "+" / "-" / "." / "^" / "_" / "`" / "|" / "~"
485                 / <x:ref>DIGIT</x:ref> / <x:ref>ALPHA</x:ref>
486                 ; any <x:ref>VCHAR</x:ref>, except <x:ref>special</x:ref>
487
488  <x:ref>special</x:ref>        = "(" / ")" / "&lt;" / ">" / "@" / ","
489                 / ";" / ":" / "\" / DQUOTE / "/" / "["
490                 / "]" / "?" / "=" / "{" / "}"
491</artwork></figure>
492<t anchor="rule.quoted-string">
493  <x:anchor-alias value="quoted-string"/>
494  <x:anchor-alias value="qdtext"/>
495  <x:anchor-alias value="obs-text"/>
496   A string of text is parsed as a single word if it is quoted using
497   double-quote marks.
498</t>
499<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="quoted-string"/><iref primary="true" item="Grammar" subitem="qdtext"/><iref primary="true" item="Grammar" subitem="obs-text"/>
500  <x:ref>quoted-string</x:ref>  = <x:ref>DQUOTE</x:ref> *( <x:ref>qdtext</x:ref> / <x:ref>quoted-pair</x:ref> ) <x:ref>DQUOTE</x:ref>
501  <x:ref>qdtext</x:ref>         = <x:ref>OWS</x:ref> / %x21 / %x23-5B / %x5D-7E / <x:ref>obs-text</x:ref>
502                 ; <x:ref>OWS</x:ref> / &lt;<x:ref>VCHAR</x:ref> except <x:ref>DQUOTE</x:ref> and "\"&gt; / <x:ref>obs-text</x:ref> 
503  <x:ref>obs-text</x:ref>       = %x80-FF
504</artwork></figure>
505<t anchor="rule.quoted-pair">
506  <x:anchor-alias value="quoted-pair"/>
507   The backslash character ("\") can be used as a single-character
508   quoting mechanism within quoted-string constructs:
509</t>
510<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="quoted-pair"/>
511  <x:ref>quoted-pair</x:ref>    = "\" ( <x:ref>WSP</x:ref> / <x:ref>VCHAR</x:ref> / <x:ref>obs-text</x:ref> )
512</artwork></figure>
513<t>
514   Producers &SHOULD-NOT; escape characters that do not require escaping
515   (i.e., other than DQUOTE and the backslash character).
516</t>
517</section>
518
519<section title="ABNF Rules defined in other Parts of the Specification" anchor="abnf.dependencies">
520  <x:anchor-alias value="request-header"/>
521  <x:anchor-alias value="response-header"/>
522  <x:anchor-alias value="entity-header"/>
523  <x:anchor-alias value="Cache-Control"/>
524  <x:anchor-alias value="Pragma"/>
525  <x:anchor-alias value="Warning"/>
526<t>
527  The ABNF rules below are defined in other parts:
528</t>
529<figure><!-- Part2--><artwork type="abnf2616">
530  <x:ref>request-header</x:ref>  = &lt;request-header, defined in &request-header-fields;&gt;
531  <x:ref>response-header</x:ref> = &lt;response-header, defined in &response-header-fields;&gt;
532</artwork></figure>
533<figure><!-- Part3--><artwork type="abnf2616">
534  <x:ref>entity-header</x:ref>   = &lt;entity-header, defined in &entity-header-fields;&gt;
535</artwork></figure>
536<figure><!-- Part6--><artwork type="abnf2616">
537  <x:ref>Cache-Control</x:ref>   = &lt;Cache-Control, defined in &header-pragma;&gt;
538  <x:ref>Pragma</x:ref>          = &lt;Pragma, defined in &header-pragma;&gt;
539  <x:ref>Warning</x:ref>         = &lt;Warning, defined in &header-warning;&gt;
540</artwork></figure>
541</section>
542
543</section>
544</section>
545
546<section title="HTTP architecture" anchor="architecture">
547<t>
548   HTTP was created for the World Wide Web architecture
549   and has evolved over time to support the scalability needs of a worldwide
550   hypertext system. Much of that architecture is reflected in the terminology
551   and syntax productions used to define HTTP.
552</t>
553
554<section title="Client/Server Operation" anchor="operation">
555<iref item="client"/>
556<iref item="server"/>
557<iref item="connection"/>
558<t>
559   HTTP is a request/response protocol that operates by exchanging messages
560   across a reliable transport or session-layer connection. An HTTP client
561   is a program that establishes a connection to a server for the purpose
562   of sending one or more HTTP requests.  An HTTP server is a program that
563   accepts connections in order to service HTTP requests by sending HTTP
564   responses.
565</t>
566<iref item="user agent"/>
567<iref item="origin server"/>
568<t>
569   Note that the terms "client" and "server" refer only to the roles that
570   these programs perform for a particular connection.  The same program
571   may act as a client on some connections and a server on others.  We use
572   the term "user agent" to refer to the program that initiates a request,
573   such as a WWW browser, editor, or spider (web-traversing robot), and
574   the term "origin server" to refer to the program that can originate
575   authoritative responses to a request.
576</t>
577<t>
578   Most HTTP communication consists of a retrieval request (GET) for
579   a representation of some resource identified by a URI.  In the
580   simplest case, this may be accomplished via a single connection (v)
581   between the user agent (UA) and the origin server (O).
582</t>
583<figure><artwork type="drawing">
584       request chain ------------------------&gt;
585    UA -------------------v------------------- O
586       &lt;----------------------- response chain
587</artwork></figure>
588<iref item="message"/>
589<iref item="request"/>
590<iref item="response"/>
591<t>
592   A client sends an HTTP request to the server in the form of a request
593   message (<xref target="request"/>), beginning with a method, URI, and
594   protocol version, followed by MIME-like header fields containing
595   request modifiers, client information, and payload metadata, an empty
596   line to indicate the end of the header section, and finally the payload
597   body (if any).
598</t>
599<t>
600   A server responds to the client's request by sending an HTTP response
601   message (<xref target="response"/>), beginning with a status line that
602   includes the protocol version, a success or error code, and textual
603   reason phrase, followed by MIME-like header fields containing server
604   information, resource metadata, and payload metadata, an empty line to
605   indicate the end of the header section, and finally the payload body (if any).
606</t>
607<t>
608   The following example illustrates a typical message exchange for a
609   GET request on the URI "http://www.example.com/hello.txt":
610</t>
611<figure><preamble>
612client request:
613</preamble><artwork type="message/http; msgtype=&#34;request&#34;" x:indent-with="  ">
614GET /hello.txt HTTP/1.1
615User-Agent: curl/7.16.3 libcurl/7.16.3 OpenSSL/0.9.7l zlib/1.2.3
616Host: www.example.com
617Accept: */*
618
619</artwork></figure>
620<figure><preamble>
621server response:
622</preamble><artwork type="message/http; msgtype=&#34;response&#34;" x:indent-with="  ">
623HTTP/1.1 200 OK
624Date: Mon, 27 Jul 2009 12:28:53 GMT
625Server: Apache
626Last-Modified: Wed, 22 Jul 2009 19:15:56 GMT
627ETag: "34aa387-d-1568eb00"
628Accept-Ranges: bytes
629Content-Length: <x:length-of target="exbody"/>
630Vary: Accept-Encoding
631Content-Type: text/plain
632
633<x:span anchor="exbody">Hello World!
634</x:span></artwork></figure>
635</section>
636
637<section title="Intermediaries" anchor="intermediaries">
638<t>
639   A more complicated situation occurs when one or more intermediaries
640   are present in the request/response chain. There are three common
641   forms of intermediary: proxy, gateway, and tunnel.  In some cases,
642   a single intermediary may act as an origin server, proxy, gateway,
643   or tunnel, switching behavior based on the nature of each request.
644</t>
645<figure><artwork type="drawing">
646       request chain --------------------------------------&gt;
647    UA -----v----- A -----v----- B -----v----- C -----v----- O
648       &lt;------------------------------------- response chain
649</artwork></figure>
650<t>
651   The figure above shows three intermediaries (A, B, and C) between the
652   user agent and origin server. A request or response message that
653   travels the whole chain will pass through four separate connections.
654   Some HTTP communication options
655   may apply only to the connection with the nearest, non-tunnel
656   neighbor, only to the end-points of the chain, or to all connections
657   along the chain. Although the diagram is linear, each participant may
658   be engaged in multiple, simultaneous communications. For example, B
659   may be receiving requests from many clients other than A, and/or
660   forwarding requests to servers other than C, at the same time that it
661   is handling A's request.
662</t>
663<t>
664<iref item="upstream"/><iref item="downstream"/>
665<iref item="inbound"/><iref item="outbound"/>
666   We use the terms "upstream" and "downstream" to describe various
667   requirements in relation to the directional flow of a message:
668   all messages flow from upstream to downstream.
669   Likewise, we use the terms "inbound" and "outbound" to refer to
670   directions in relation to the request path: "inbound" means toward
671   the origin server and "outbound" means toward the user agent.
672</t>
673<t><iref item="proxy"/>
674   A proxy is a message forwarding agent that is selected by the
675   client, usually via local configuration rules, to receive requests
676   for some type(s) of absolute URI and attempt to satisfy those
677   requests via translation through the HTTP interface.  Some translations
678   are minimal, such as for proxy requests for "http" URIs, whereas
679   other requests may require translation to and from entirely different
680   application-layer protocols. Proxies are often used to group an
681   organization's HTTP requests through a common intermediary for the
682   sake of security, annotation services, or shared caching.
683</t>
684<t><iref item="gateway"/><iref item="reverse proxy"/>
685   A gateway (a.k.a., reverse proxy) is a receiving agent that acts
686   as a layer above some other server(s) and translates the received
687   requests to the underlying server's protocol.  Gateways are often
688   used for load balancing or partitioning HTTP services across
689   multiple machines.
690   Unlike a proxy, a gateway receives requests as if it were the
691   origin server for the requested resource; the requesting client
692   will not be aware that it is communicating with a gateway.
693   A gateway communicates with the client as if the gateway is the
694   origin server and thus is subject to all of the requirements on
695   origin servers for that connection.  A gateway communicates
696   with inbound servers using any protocol it desires, including
697   private extensions to HTTP that are outside the scope of this
698   specification.
699</t>
700<t><iref item="tunnel"/>
701   A tunnel acts as a blind relay between two connections
702   without changing the messages. Once active, a tunnel is not
703   considered a party to the HTTP communication, though the tunnel may
704   have been initiated by an HTTP request. A tunnel ceases to exist when
705   both ends of the relayed connection are closed. Tunnels are used to
706   extend a virtual connection through an intermediary, such as when
707   transport-layer security is used to establish private communication
708   through a shared firewall proxy.
709</t>
710</section>
711
712<section title="Caches" anchor="caches">
713<iref item="cache"/>
714<t>
715   Any party to HTTP communication that is not acting as a tunnel may
716   employ an internal cache for handling requests.
717   A cache is a local store of previous response messages and the
718   subsystem that controls its message storage, retrieval, and deletion.
719   A cache stores cacheable responses in order to reduce the response
720   time and network bandwidth consumption on future, equivalent
721   requests. Any client or server may include a cache, though a cache
722   cannot be used by a server while it is acting as a tunnel.
723</t>
724<t>
725   The effect of a cache is that the request/response chain is shortened
726   if one of the participants along the chain has a cached response
727   applicable to that request. The following illustrates the resulting
728   chain if B has a cached copy of an earlier response from O (via C)
729   for a request which has not been cached by UA or A.
730</t>
731<figure><artwork type="drawing">
732          request chain ----------&gt;
733       UA -----v----- A -----v----- B - - - - - - C - - - - - - O
734          &lt;--------- response chain
735</artwork></figure>
736<t><iref item="cacheable"/>
737   A response is cacheable if a cache is allowed to store a copy of
738   the response message for use in answering subsequent requests.
739   Even when a response is cacheable, there may be additional
740   constraints placed by the client or by the origin server on when
741   that cached response can be used for a particular request. HTTP
742   requirements for cache behavior and cacheable responses are
743   defined in &caching-overview;
744</t>
745<t>
746   There are a wide variety of architectures and configurations
747   of caches and proxies deployed across the World Wide Web and
748   inside large organizations. These systems include national hierarchies
749   of proxy caches to save transoceanic bandwidth, systems that
750   broadcast or multicast cache entries, organizations that distribute
751   subsets of cached data via optical media, and so on.
752</t>
753</section>
754
755<section title="Transport Independence" anchor="transport-independence">
756<t>
757  HTTP systems are used in a wide variety of environments, from
758  corporate intranets with high-bandwidth links to long-distance
759  communication over low-power radio links and intermittent connectivity.
760</t>
761<t>
762   HTTP communication usually takes place over TCP/IP connections. The
763   default port is TCP 80 (<eref target="http://www.iana.org/assignments/port-numbers"/>), but other ports can be used. This does
764   not preclude HTTP from being implemented on top of any other protocol
765   on the Internet, or on other networks. HTTP only presumes a reliable
766   transport; any protocol that provides such guarantees can be used;
767   the mapping of the HTTP/1.1 request and response structures onto the
768   transport data units of the protocol in question is outside the scope
769   of this specification.
770</t>
771<t>
772   In HTTP/1.0, most implementations used a new connection for each
773   request/response exchange. In HTTP/1.1, a connection may be used for
774   one or more request/response exchanges, although connections may be
775   closed for a variety of reasons (see <xref target="persistent.connections"/>).
776</t>
777</section>
778
779<section title="HTTP Version" anchor="http.version">
780  <x:anchor-alias value="HTTP-Version"/>
781  <x:anchor-alias value="HTTP-Prot-Name"/>
782<t>
783   HTTP uses a "&lt;major&gt;.&lt;minor&gt;" numbering scheme to indicate versions
784   of the protocol. The protocol versioning policy is intended to allow
785   the sender to indicate the format of a message and its capacity for
786   understanding further HTTP communication, rather than the features
787   obtained via that communication. No change is made to the version
788   number for the addition of message components which do not affect
789   communication behavior or which only add to extensible field values.
790   The &lt;minor&gt; number is incremented when the changes made to the
791   protocol add features which do not change the general message parsing
792   algorithm, but which may add to the message semantics and imply
793   additional capabilities of the sender. The &lt;major&gt; number is
794   incremented when the format of a message within the protocol is
795   changed. See <xref target="RFC2145"/> for a fuller explanation.
796</t>
797<t>
798   The version of an HTTP message is indicated by an HTTP-Version field
799   in the first line of the message. HTTP-Version is case-sensitive.
800</t>
801<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="HTTP-Version"/><iref primary="true" item="Grammar" subitem="HTTP-Prot-Name"/>
802  <x:ref>HTTP-Version</x:ref>   = <x:ref>HTTP-Prot-Name</x:ref> "/" 1*<x:ref>DIGIT</x:ref> "." 1*<x:ref>DIGIT</x:ref>
803  <x:ref>HTTP-Prot-Name</x:ref> = <x:abnf-char-sequence>"HTTP"</x:abnf-char-sequence> ; "HTTP", case-sensitive
804</artwork></figure>
805<t>
806   Note that the major and minor numbers &MUST; be treated as separate
807   integers and that each &MAY; be incremented higher than a single digit.
808   Thus, HTTP/2.4 is a lower version than HTTP/2.13, which in turn is
809   lower than HTTP/12.3. Leading zeros &MUST; be ignored by recipients and
810   &MUST-NOT; be sent.
811</t>
812<t>
813   An application that sends a request or response message that includes
814   HTTP-Version of "HTTP/1.1" &MUST; be at least conditionally compliant
815   with this specification. Applications that are at least conditionally
816   compliant with this specification &SHOULD; use an HTTP-Version of
817   "HTTP/1.1" in their messages, and &MUST; do so for any message that is
818   not compatible with HTTP/1.0. For more details on when to send
819   specific HTTP-Version values, see <xref target="RFC2145"/>.
820</t>
821<t>
822   The HTTP version of an application is the highest HTTP version for
823   which the application is at least conditionally compliant.
824</t>
825<t>
826   Proxy and gateway applications need to be careful when forwarding
827   messages in protocol versions different from that of the application.
828   Since the protocol version indicates the protocol capability of the
829   sender, a proxy/gateway &MUST-NOT; send a message with a version
830   indicator which is greater than its actual version. If a higher
831   version request is received, the proxy/gateway &MUST; either downgrade
832   the request version, or respond with an error, or switch to tunnel
833   behavior.
834</t>
835<t>
836   Due to interoperability problems with HTTP/1.0 proxies discovered
837   since the publication of <xref target="RFC2068"/>, caching proxies &MUST;, gateways
838   &MAY;, and tunnels &MUST-NOT; upgrade the request to the highest version
839   they support. The proxy/gateway's response to that request &MUST; be in
840   the same major version as the request.
841</t>
842<x:note>
843  <t>
844    <x:h>Note:</x:h> Converting between versions of HTTP may involve modification
845    of header fields required or forbidden by the versions involved.
846  </t>
847</x:note>
848</section>
849
850<section title="Uniform Resource Identifiers" anchor="uri">
851<iref primary="true" item="resource"/>
852<t>
853   Uniform Resource Identifiers (URIs) <xref target="RFC3986"/> are used
854   throughout HTTP as the means for identifying resources. URI references
855   are used to target requests, indicate redirects, and define relationships.
856   HTTP does not limit what a resource may be; it merely defines an interface
857   that can be used to interact with a resource via HTTP. More information on
858   the scope of URIs and resources can be found in <xref target="RFC3986"/>.
859</t>
860  <x:anchor-alias value="URI-reference"/>
861  <x:anchor-alias value="absolute-URI"/>
862  <x:anchor-alias value="relative-part"/>
863  <x:anchor-alias value="authority"/>
864  <x:anchor-alias value="path-abempty"/>
865  <x:anchor-alias value="path-absolute"/>
866  <x:anchor-alias value="port"/>
867  <x:anchor-alias value="query"/>
868  <x:anchor-alias value="uri-host"/>
869  <x:anchor-alias value="partial-URI"/>
870<t>
871   This specification adopts the definitions of "URI-reference",
872   "absolute-URI", "relative-part", "port", "host",
873   "path-abempty", "path-absolute", "query", and "authority" from
874   <xref target="RFC3986"/>. In addition, we define a partial-URI rule for
875   protocol elements that allow a relative URI without a fragment.
876</t>
877<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="URI-reference"/><iref primary="true" item="Grammar" subitem="absolute-URI"/><iref primary="true" item="Grammar" subitem="authority"/><iref primary="true" item="Grammar" subitem="path-absolute"/><iref primary="true" item="Grammar" subitem="port"/><iref primary="true" item="Grammar" subitem="query"/><iref primary="true" item="Grammar" subitem="uri-host"/>
878  <x:ref>URI-reference</x:ref> = &lt;URI-reference, defined in <xref target="RFC3986" x:fmt="," x:sec="4.1"/>&gt;
879  <x:ref>absolute-URI</x:ref>  = &lt;absolute-URI, defined in <xref target="RFC3986" x:fmt="," x:sec="4.3"/>&gt;
880  <x:ref>relative-part</x:ref> = &lt;relative-part, defined in <xref target="RFC3986" x:fmt="," x:sec="4.2"/>&gt;
881  <x:ref>authority</x:ref>     = &lt;authority, defined in <xref target="RFC3986" x:fmt="," x:sec="3.2"/>&gt;
882  <x:ref>path-abempty</x:ref>  = &lt;path-abempty, defined in <xref target="RFC3986" x:fmt="," x:sec="3.3"/>&gt;
883  <x:ref>path-absolute</x:ref> = &lt;path-absolute, defined in <xref target="RFC3986" x:fmt="," x:sec="3.3"/>&gt;
884  <x:ref>port</x:ref>          = &lt;port, defined in <xref target="RFC3986" x:fmt="," x:sec="3.2.3"/>&gt;
885  <x:ref>query</x:ref>         = &lt;query, defined in <xref target="RFC3986" x:fmt="," x:sec="3.4"/>&gt;
886  <x:ref>uri-host</x:ref>      = &lt;host, defined in <xref target="RFC3986" x:fmt="," x:sec="3.2.2"/>&gt;
887 
888  <x:ref>partial-URI</x:ref>   = relative-part [ "?" query ]
889</artwork></figure>
890<t>
891   Each protocol element in HTTP that allows a URI reference will indicate in
892   its ABNF production whether the element allows only a URI in absolute form
893   (absolute-URI), any relative reference (relative-ref), or some other subset
894   of the URI-reference grammar. Unless otherwise indicated, URI references
895   are parsed relative to the request target (the default base URI for both
896   the request and its corresponding response).
897</t>
898
899<section title="http URI scheme" anchor="http.uri">
900  <x:anchor-alias value="http-URI"/>
901  <iref item="http URI scheme" primary="true"/>
902  <iref item="URI scheme" subitem="http" primary="true"/>
903<t>
904   The "http" URI scheme is hereby defined for the purpose of minting
905   identifiers according to their association with the hierarchical
906   namespace governed by a potential HTTP origin server listening for
907   TCP connections on a given port.
908   The HTTP server is identified via the generic syntax's
909   <x:ref>authority</x:ref> component, which includes a host
910   identifier and optional TCP port, and the remainder of the URI is
911   considered to be identifying data corresponding to a resource for
912   which that server might provide an HTTP interface.
913</t>
914<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="http-URI"/>
915  <x:ref>http-URI</x:ref> = "http:" "//" <x:ref>authority</x:ref> <x:ref>path-abempty</x:ref> [ "?" <x:ref>query</x:ref> ]
916</artwork></figure>
917<t>
918   The host identifier within an <x:ref>authority</x:ref> component is
919   defined in <xref target="RFC3986" x:fmt="," x:sec="3.2.2"/>.  If host is
920   provided as an IP literal or IPv4 address, then the HTTP server is any
921   listener on the indicated TCP port at that IP address. If host is a
922   registered name, then that name is considered an indirect identifier
923   and the recipient might use a name resolution service, such as DNS,
924   to find the address of a listener for that host.
925   The host &MUST-NOT; be empty; if an "http" URI is received with an
926   empty host, then it &MUST; be rejected as invalid.
927   If the port subcomponent is empty or not given, then TCP port 80 is
928   assumed (the default reserved port for WWW services).
929</t>
930<t>
931   Regardless of the form of host identifier, access to that host is not
932   implied by the mere presence of its name or address. The host may or may
933   not exist and, even when it does exist, may or may not be running an
934   HTTP server or listening to the indicated port. The "http" URI scheme
935   makes use of the delegated nature of Internet names and addresses to
936   establish a naming authority (whatever entity has the ability to place
937   an HTTP server at that Internet name or address) and allows that
938   authority to determine which names are valid and how they might be used.
939</t>
940<t>
941   When an "http" URI is used within a context that calls for access to the
942   indicated resource, a client &MAY; attempt access by resolving
943   the host to an IP address, establishing a TCP connection to that address
944   on the indicated port, and sending an HTTP request message to the server
945   containing the URI's identifying data as described in <xref target="request"/>.
946   If the server responds to that request with a non-interim HTTP response
947   message, as described in <xref target="response"/>, then that response
948   is considered an authoritative answer to the client's request.
949</t>
950<t>
951   Although HTTP is independent of the transport protocol, the "http"
952   scheme is specific to TCP-based services because the name delegation
953   process depends on TCP for establishing authority.
954   An HTTP service based on some other underlying connection protocol
955   would presumably be identified using a different URI scheme, just as
956   the "https" scheme (below) is used for servers that require an SSL/TLS
957   transport layer on a connection. Other protocols may also be used to
958   provide access to "http" identified resources --- it is only the
959   authoritative interface used for mapping the namespace that is
960   specific to TCP.
961</t>
962<t>
963   The URI generic syntax for authority also includes a deprecated
964   userinfo subcomponent (<xref target="RFC3986" x:fmt="," x:sec="3.2.1"/>)
965   for including user authentication information in the URI.  The userinfo
966   subcomponent (and its "@" delimiter) &MUST-NOT; be used in an "http"
967   URI.  URI reference recipients &SHOULD; parse for the existence of
968   userinfo and treat its presence as an error, likely indicating that
969   the deprecated subcomponent is being used to obscure the authority
970   for the sake of phishing attacks.
971</t>
972</section>
973
974<section title="https URI scheme" anchor="https.uri">
975   <x:anchor-alias value="https-URI"/>
976   <iref item="https URI scheme"/>
977   <iref item="URI scheme" subitem="https"/>
978<t>
979   The "https" URI scheme is hereby defined for the purpose of minting
980   identifiers according to their association with the hierarchical
981   namespace governed by a potential HTTP origin server listening for
982   SSL/TLS-secured connections on a given TCP port.
983</t>
984<t>
985   All of the requirements listed above for the "http" scheme are also
986   requirements for the "https" scheme, except that a default TCP port
987   of 443 is assumed if the port subcomponent is empty or not given,
988   and the TCP connection &MUST; be secured for privacy through the
989   use of strong encryption prior to sending the first HTTP request.
990</t>
991<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="https-URI"/>
992  <x:ref>https-URI</x:ref> = "https:" "//" <x:ref>authority</x:ref> <x:ref>path-abempty</x:ref> [ "?" <x:ref>query</x:ref> ]
993</artwork></figure>
994<t>
995   Unlike the "http" scheme, responses to "https" identified requests
996   are never "public" and thus are ineligible for shared caching.
997   Their default is "private" and may be further constrained via use
998   of the Cache-Control header field.
999</t>
1000<t>
1001   Resources made available via the "https" scheme have no shared
1002   identity with the "http" scheme even if their resource identifiers
1003   only differ by the single "s" in the scheme name.  They are
1004   different services governed by different authorities.  However,
1005   some extensions to HTTP that apply to entire host domains, such
1006   as the Cookie protocol, do allow one service to effect communication
1007   with the other services based on host domain matching.
1008</t>
1009<t>
1010   The process for authoritative access to an "https" identified
1011   resource is defined in <xref target="RFC2818"/>.
1012</t>
1013</section>
1014
1015<section title="http and https URI Normalization and Comparison" anchor="uri.comparison">
1016<t>
1017   Since the "http" and "https" schemes conform to the URI generic syntax,
1018   such URIs are normalized and compared according to the algorithm defined
1019   in <xref target="RFC3986" x:fmt="," x:sec="6"/>, using the defaults
1020   described above for each scheme.
1021</t>
1022<t>
1023   If the port is equal to the default port for a scheme, the normal
1024   form is to elide the port subcomponent. Likewise, an empty path
1025   component is equivalent to an absolute path of "/", so the normal
1026   form is to provide a path of "/" instead. The scheme and host
1027   are case-insensitive and normally provided in lowercase; all
1028   other components are compared in a case-sensitive manner.
1029   Characters other than those in the "reserved" set are equivalent
1030   to their percent-encoded octets (see <xref target="RFC3986"
1031   x:fmt="," x:sec="2.1"/>): the normal form is to not encode them.
1032</t>
1033<t>
1034   For example, the following three URIs are equivalent:
1035</t>
1036<figure><artwork type="example">
1037   http://example.com:80/~smith/home.html
1038   http://EXAMPLE.com/%7Esmith/home.html
1039   http://EXAMPLE.com:/%7esmith/home.html
1040</artwork></figure>
1041<t>
1042   <cref anchor="TODO-not-here" source="roy">This paragraph does not belong here.</cref>
1043   If path-abempty is the empty string (i.e., there is no slash "/"
1044   path separator following the authority), then the "http" URI
1045   &MUST; be given as "/" when
1046   used as a request-target (<xref target="request-target"/>). If a proxy
1047   receives a host name which is not a fully qualified domain name, it
1048   &MAY; add its domain to the host name it received. If a proxy receives
1049   a fully qualified domain name, the proxy &MUST-NOT; change the host
1050   name.
1051</t>
1052</section>
1053</section>
1054</section>
1055
1056<section title="HTTP Message" anchor="http.message">
1057<x:anchor-alias value="generic-message"/>
1058<x:anchor-alias value="message.types"/>
1059<x:anchor-alias value="HTTP-message"/>
1060<x:anchor-alias value="start-line"/>
1061<iref item="header section"/>
1062<iref item="headers"/>
1063<iref item="header field"/>
1064<t>
1065   All HTTP/1.1 messages consist of a start-line followed by a sequence of
1066   characters in a format similar to the Internet Message Format
1067   <xref target="RFC5322"/>: zero or more header fields (collectively
1068   referred to as the "headers" or the "header section"), an empty line
1069   indicating the end of the header section, and an optional message-body.
1070</t>
1071<t>
1072   An HTTP message can either be a request from client to server or a
1073   response from server to client.  Syntactically, the two types of message
1074   differ only in the start-line, which is either a Request-Line (for requests)
1075   or a Status-Line (for responses), and in the algorithm for determining
1076   the length of the message-body (<xref target="message.body"/>).
1077   In theory, a client could receive requests and a server could receive
1078   responses, distinguishing them by their different start-line formats,
1079   but in practice servers are implemented to only expect a request
1080   (a response is interpreted as an unknown or invalid request method)
1081   and clients are implemented to only expect a response.
1082</t>
1083<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="HTTP-message"/>
1084  <x:ref>HTTP-message</x:ref>    = <x:ref>start-line</x:ref>
1085                    *( <x:ref>header-field</x:ref> <x:ref>CRLF</x:ref> )
1086                    <x:ref>CRLF</x:ref>
1087                    [ <x:ref>message-body</x:ref> ]
1088  <x:ref>start-line</x:ref>      = <x:ref>Request-Line</x:ref> / <x:ref>Status-Line</x:ref>
1089</artwork></figure>
1090<t>
1091   Whitespace (WSP) &MUST-NOT; be sent between the start-line and the first
1092   header field. The presence of whitespace might be an attempt to trick a
1093   noncompliant implementation of HTTP into ignoring that field or processing
1094   the next line as a new request, either of which may result in security
1095   issues when implementations within the request chain interpret the
1096   same message differently. HTTP/1.1 servers &MUST; reject such a message
1097   with a 400 (Bad Request) response.
1098</t>
1099
1100<section title="Message Parsing Robustness" anchor="message.robustness">
1101<t>
1102   In the interest of robustness, servers &SHOULD; ignore at least one
1103   empty line received where a Request-Line is expected. In other words, if
1104   the server is reading the protocol stream at the beginning of a
1105   message and receives a CRLF first, it should ignore the CRLF.
1106</t>
1107<t>
1108   Some old HTTP/1.0 client implementations generate an extra CRLF
1109   after a POST request as a lame workaround for some early server
1110   applications that failed to read message-body content that was
1111   not terminated by a line-ending. An HTTP/1.1 client &MUST-NOT;
1112   preface or follow a request with an extra CRLF.  If terminating
1113   the request message-body with a line-ending is desired, then the
1114   client &MUST; include the terminating CRLF octets as part of the
1115   message-body length.
1116</t>
1117<t>
1118   The normal procedure for parsing an HTTP message is to read the
1119   start-line into a structure, read each header field into a hash
1120   table by field name until the empty line, and then use the parsed
1121   data to determine if a message-body is expected.  If a message-body
1122   has been indicated, then it is read as a stream until an amount
1123   of octets equal to the message-body length is read or the connection
1124   is closed.  Care must be taken to parse an HTTP message as a sequence
1125   of octets in an encoding that is a superset of US-ASCII.  Attempting
1126   to parse HTTP as a stream of Unicode characters in a character encoding
1127   like UTF-16 may introduce security flaws due to the differing ways
1128   that such parsers interpret invalid characters.
1129</t>
1130</section>
1131
1132<section title="Header Fields" anchor="header.fields">
1133  <x:anchor-alias value="header-field"/>
1134  <x:anchor-alias value="field-content"/>
1135  <x:anchor-alias value="field-name"/>
1136  <x:anchor-alias value="field-value"/>
1137  <x:anchor-alias value="OWS"/>
1138<t>
1139   Each HTTP header field consists of a case-insensitive field name
1140   followed by a colon (":"), optional whitespace, and the field value.
1141</t>
1142<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="header-field"/><iref primary="true" item="Grammar" subitem="field-name"/><iref primary="true" item="Grammar" subitem="field-value"/><iref primary="true" item="Grammar" subitem="field-content"/>
1143  <x:ref>header-field</x:ref>   = <x:ref>field-name</x:ref> ":" <x:ref>OWS</x:ref> [ <x:ref>field-value</x:ref> ] <x:ref>OWS</x:ref>
1144  <x:ref>field-name</x:ref>     = <x:ref>token</x:ref>
1145  <x:ref>field-value</x:ref>    = *( <x:ref>field-content</x:ref> / <x:ref>OWS</x:ref> )
1146  <x:ref>field-content</x:ref>  = *( <x:ref>WSP</x:ref> / <x:ref>VCHAR</x:ref> / <x:ref>obs-text</x:ref> )
1147</artwork></figure>
1148<t>
1149   No whitespace is allowed between the header field name and colon. For
1150   security reasons, any request message received containing such whitespace
1151   &MUST; be rejected with a response code of 400 (Bad Request). A proxy
1152   &MUST; remove any such whitespace from a response message before
1153   forwarding the message downstream.
1154</t>
1155<t>
1156   A field value &MAY; be preceded by optional whitespace (OWS); a single SP is
1157   preferred. The field value does not include any leading or trailing white
1158   space: OWS occurring before the first non-whitespace character of the
1159   field value or after the last non-whitespace character of the field value
1160   is ignored and &SHOULD; be removed before further processing (as this does
1161   not change the meaning of the header field).
1162</t>
1163<t>
1164   The order in which header fields with differing field names are
1165   received is not significant. However, it is "good practice" to send
1166   header fields that contain control data first, such as Host on
1167   requests and Date on responses, so that implementations can decide
1168   when not to handle a message as early as possible.  A server &MUST;
1169   wait until the entire header section is received before interpreting
1170   a request message, since later header fields might include conditionals,
1171   authentication credentials, or deliberately misleading duplicate
1172   header fields that would impact request processing.
1173</t>
1174<t>
1175   Multiple header fields with the same field name &MUST-NOT; be
1176   sent in a message unless the entire field value for that
1177   header field is defined as a comma-separated list [i.e., #(values)].
1178   Multiple header fields with the same field name can be combined into
1179   one "field-name: field-value" pair, without changing the semantics of the
1180   message, by appending each subsequent field value to the combined
1181   field value in order, separated by a comma. The order in which
1182   header fields with the same field name are received is therefore
1183   significant to the interpretation of the combined field value;
1184   a proxy &MUST-NOT; change the order of these field values when
1185   forwarding a message.
1186</t>
1187<x:note>
1188  <t>
1189   <x:h>Note:</x:h> The "Set-Cookie" header as implemented in
1190   practice (as opposed to how it is specified in <xref target="RFC2109"/>)
1191   can occur multiple times, but does not use the list syntax, and thus cannot
1192   be combined into a single line. (See Appendix A.2.3 of <xref target="Kri2001"/>
1193   for details.) Also note that the Set-Cookie2 header specified in
1194   <xref target="RFC2965"/> does not share this problem.
1195  </t>
1196</x:note>
1197<t>
1198   Historically, HTTP header field values could be extended over multiple
1199   lines by preceding each extra line with at least one space or horizontal
1200   tab character (line folding). This specification deprecates such line
1201   folding except within the message/http media type
1202   (<xref target="internet.media.type.message.http"/>).
1203   HTTP/1.1 senders &MUST-NOT; produce messages that include line folding
1204   (i.e., that contain any field-content that matches the obs-fold rule) unless
1205   the message is intended for packaging within the message/http media type.
1206   HTTP/1.1 recipients &SHOULD; accept line folding and replace any embedded
1207   obs-fold whitespace with a single SP prior to interpreting the field value
1208   or forwarding the message downstream.
1209</t>
1210<t>
1211   Historically, HTTP has allowed field content with text in the ISO-8859-1
1212   <xref target="ISO-8859-1"/> character encoding and supported other
1213   character sets only through use of <xref target="RFC2047"/> encoding.
1214   In practice, most HTTP header field values use only a subset of the
1215   US-ASCII character encoding <xref target="USASCII"/>. Newly defined
1216   header fields &SHOULD; limit their field values to US-ASCII characters.
1217   Recipients &SHOULD; treat other (obs-text) octets in field content as
1218   opaque data.
1219</t>
1220<t anchor="rule.comment">
1221  <x:anchor-alias value="comment"/>
1222  <x:anchor-alias value="ctext"/>
1223   Comments can be included in some HTTP header fields by surrounding
1224   the comment text with parentheses. Comments are only allowed in
1225   fields containing "comment" as part of their field value definition.
1226</t>
1227<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="comment"/><iref primary="true" item="Grammar" subitem="ctext"/>
1228  <x:ref>comment</x:ref>        = "(" *( <x:ref>ctext</x:ref> / <x:ref>quoted-cpair</x:ref> / <x:ref>comment</x:ref> ) ")"
1229  <x:ref>ctext</x:ref>          = <x:ref>OWS</x:ref> / %x21-27 / %x2A-5B / %x5D-7E / <x:ref>obs-text</x:ref>
1230                 ; <x:ref>OWS</x:ref> / &lt;<x:ref>VCHAR</x:ref> except "(", ")", and "\"&gt; / <x:ref>obs-text</x:ref>
1231</artwork></figure>
1232<t anchor="rule.quoted-cpair">
1233  <x:anchor-alias value="quoted-cpair"/>
1234   The backslash character ("\") can be used as a single-character
1235   quoting mechanism within comment constructs:
1236</t>
1237<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="quoted-cpair"/>
1238  <x:ref>quoted-cpair</x:ref>    = "\" ( <x:ref>WSP</x:ref> / <x:ref>VCHAR</x:ref> / <x:ref>obs-text</x:ref> )
1239</artwork></figure>
1240<t>
1241   Producers &SHOULD-NOT; escape characters that do not require escaping
1242   (i.e., other than the backslash character "\" and the parentheses "(" and
1243   ")").
1244</t>
1245</section>
1246
1247<section title="Message Body" anchor="message.body">
1248  <x:anchor-alias value="message-body"/>
1249<t>
1250   The message-body (if any) of an HTTP message is used to carry the
1251   payload body associated with the request or response. The message-body
1252   differs from the payload body only when a transfer-coding has been
1253   applied, as indicated by the Transfer-Encoding header field (<xref target="header.transfer-encoding"/>).
1254</t>
1255<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="message-body"/>
1256  <x:ref>message-body</x:ref> = *OCTET
1257</artwork></figure>
1258<t>
1259   When one or more transfer-codings are applied to a payload body,
1260   usually for the sake of stream-delimiting or data compression, the
1261   Transfer-Encoding header field &MUST; be provided with the list of
1262   transfer-codings applied. Transfer-Encoding is a property of the message,
1263   not of the payload, and thus &MAY; be added or removed by any implementation
1264   along the request/response chain under the constraints found in
1265   <xref target="transfer.codings"/>.
1266</t>
1267<t>
1268   The rules for when a message-body is allowed in a message differ for
1269   requests and responses.
1270</t>
1271<t>
1272   The presence of a message-body in a request is signaled by the
1273   inclusion of a Content-Length or Transfer-Encoding header field in
1274   the request's header fields, even if the request method does not
1275   define any use for a message-body.  This allows the request
1276   message framing algorithm to be independent of method semantics.
1277   A server &MUST; read the entire request message-body or close
1278   the connection after sending its response.
1279</t>
1280<t>
1281   For response messages, whether or not a message-body is included with
1282   a message is dependent on both the request method and the response
1283   status code (<xref target="status.code.and.reason.phrase"/>).
1284   Responses to the HEAD request method never include a message-body
1285   because the associated response header fields (e.g., Transfer-Encoding,
1286   Content-Length, etc.) only indicate what their values would have been
1287   if the method had been GET.  All 1xx (Informational), 204 (No Content),
1288   and 304 (Not Modified) responses &MUST-NOT; include a message-body.
1289   All other responses do include a message-body, although the body
1290   &MAY; be of zero length.
1291</t>
1292<t>
1293   The length of the message-body is determined by one of the following
1294   (in order of precedence):
1295</t>
1296<t>
1297  <list style="numbers">
1298    <x:lt><t>
1299     Any response to a HEAD request and any response with a status
1300     code of 100-199, 204, or 304 is always terminated by the first
1301     empty line after the header fields, regardless of the header
1302     fields present in the message, and thus cannot contain a message-body.
1303    </t></x:lt>
1304    <x:lt><t>
1305     If a Transfer-Encoding header field (<xref target="header.transfer-encoding"/>)
1306     is present and the "chunked" transfer-coding (<xref target="transfer.codings"/>)
1307     is used, the message-body length is determined by reading and decoding the
1308     chunked data until the transfer-coding indicates the data is complete.
1309    </t>
1310    <t>
1311     If a message is received with both a Transfer-Encoding header field and a
1312     Content-Length header field, the Transfer-Encoding overrides the Content-Length.
1313     Such a message may indicate an attempt to perform request or response
1314     smuggling (bypass of security-related checks on message routing or content)
1315     and thus should be handled as an error.  The provided Content-Length &MUST;
1316     be removed, prior to forwarding the message downstream, or replaced with
1317     the real message-body length after the transfer-coding is decoded.
1318    </t>
1319    <t>
1320     If a Transfer-Encoding header field is present in a response and the
1321     "chunked" transfer-coding is not present, the message-body length is
1322     determined by reading the connection until it is closed by the server.
1323     If a Transfer-Encoding header field is present in a request and the
1324     "chunked" transfer-coding is not the final encoding, the message-body
1325     length cannot be determined reliably; the server &MUST; respond with
1326     400 (Bad Request) and then close the connection.
1327    </t></x:lt>
1328    <x:lt><t>
1329     If a valid Content-Length header field (<xref target="header.content-length"/>)
1330     is present without Transfer-Encoding, its decimal value in octets defines
1331     the message-body length.  If the actual number of octets sent in the message
1332     is less than the indicated Content-Length, the recipient &MUST; consider
1333     the message to be incomplete and treat the connection as no longer usable.
1334     If the actual number of octets sent in the message is less than the indicated
1335     Content-Length, the recipient &MUST; only process the message-body up to the
1336     field value's number of octets; the remainder of the message &MUST; either
1337     be discarded or treated as the next message in a pipeline.  For the sake of
1338     robustness, a user-agent &MAY; attempt to detect and correct such an error
1339     in message framing if it is parsing the response to the last request on
1340     on a connection and the connection has been closed by the server.
1341    </t>
1342    <t>
1343     If a message is received with multiple Content-Length header fields or a
1344     Content-Length header field with an invalid value, the message framing
1345     is invalid and &MUST; be treated as an error to prevent request or
1346     response smuggling.
1347     If this is a request message, the server &MUST; respond with
1348     a 400 (Bad Request) status and then close the connection.
1349     If this is a response message received by a proxy or gateway, the proxy
1350     or gateway &MUST; discard the received response, send a 502 (Bad Gateway)
1351     status as its downstream response, and then close the connection.
1352     If this is a response message received by a user-agent, the message-body
1353     length is determined by reading the connection until it is closed;
1354     an error &SHOULD; be indicated to the user.
1355    </t></x:lt>
1356    <x:lt><t>
1357     If this is a request message and none of the above are true, then the
1358     message-body length is zero (no message-body is present).
1359    </t></x:lt>
1360    <x:lt><t>
1361     Otherwise, this is a response message without a declared message-body
1362     length, so the message-body length is determined by the number of octets
1363     received prior to the server closing the connection.
1364    </t></x:lt>
1365  </list>
1366</t>
1367<t>
1368   Since there is no way to distinguish a successfully completed,
1369   close-delimited message from a partially-received message interrupted
1370   by network failure, implementations &SHOULD; use encoding or
1371   length-delimited messages whenever possible.  The close-delimiting
1372   feature exists primarily for backwards compatibility with HTTP/1.0.
1373</t>
1374<t>
1375   A server &MAY; reject a request that contains a message-body but
1376   not a Content-Length by responding with 411 (Length Required).
1377</t>
1378<t>
1379   Unless a transfer-coding other than "chunked" has been applied,
1380   a client that sends a request containing a message-body &SHOULD;
1381   use a valid Content-Length header field if the message-body length
1382   is known in advance, rather than the "chunked" encoding, since some
1383   existing services respond to "chunked" with a 411 (Length Required)
1384   status code even though they understand the chunked encoding.  This
1385   is typically because such services are implemented via a gateway that
1386   requires a content-length in advance of being called and the server
1387   is unable or unwilling to buffer the entire request before processing.
1388</t>
1389<t>
1390   A client that sends a request containing a message-body &MUST; include a
1391   valid Content-Length header field if it does not know the server will
1392   handle HTTP/1.1 (or later) requests; such knowledge can be in the form
1393   of specific user configuration or by remembering the version of a prior
1394   received response.
1395</t>
1396<t>
1397   Request messages that are prematurely terminated, possibly due to a
1398   cancelled connection or a server-imposed time-out exception, &MUST;
1399   result in closure of the connection; sending an HTTP/1.1 error response
1400   prior to closing the connection is &OPTIONAL;.
1401   Response messages that are prematurely terminated, usually by closure
1402   of the connection prior to receiving the expected number of octets or by
1403   failure to decode a transfer-encoded message-body, &MUST; be recorded
1404   as incomplete.  A user agent &MUST-NOT; render an incomplete response
1405   message-body as if it were complete (i.e., some indication must be given
1406   to the user that an error occurred).  Cache requirements for incomplete
1407   responses are defined in &cache-incomplete;.
1408</t>
1409</section>
1410
1411<section title="General Header Fields" anchor="general.header.fields">
1412  <x:anchor-alias value="general-header"/>
1413<t>
1414   There are a few header fields which have general applicability for
1415   both request and response messages, but which do not apply to the
1416   payload being transferred. These header fields apply only to the
1417   message being transmitted.
1418</t>
1419<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="general-header"/>
1420  <x:ref>general-header</x:ref> = <x:ref>Cache-Control</x:ref>            ; &header-cache-control;
1421                 / <x:ref>Connection</x:ref>               ; <xref target="header.connection"/>
1422                 / <x:ref>Date</x:ref>                     ; <xref target="header.date"/>
1423                 / <x:ref>Pragma</x:ref>                   ; &header-pragma;
1424                 / <x:ref>Trailer</x:ref>                  ; <xref target="header.trailer"/>
1425                 / <x:ref>Transfer-Encoding</x:ref>        ; <xref target="header.transfer-encoding"/>
1426                 / <x:ref>Upgrade</x:ref>                  ; <xref target="header.upgrade"/>
1427                 / <x:ref>Via</x:ref>                      ; <xref target="header.via"/>
1428                 / <x:ref>Warning</x:ref>                  ; &header-warning;
1429</artwork></figure>
1430<t>
1431   General-header field names can be extended reliably only in
1432   combination with a change in the protocol version. However, new or
1433   experimental header fields may be given the semantics of general
1434   header fields if all parties in the communication recognize them to
1435   be general-header fields. Unrecognized header fields are treated as
1436   entity-header fields.
1437</t>
1438</section>
1439</section>
1440
1441<section title="Request" anchor="request">
1442  <x:anchor-alias value="Request"/>
1443<t>
1444   A request message from a client to a server includes, within the
1445   first line of that message, the method to be applied to the resource,
1446   the identifier of the resource, and the protocol version in use.
1447</t>
1448<!--                 Host                      ; should be moved here eventually -->
1449<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="Request"/>
1450  <x:ref>Request</x:ref>       = <x:ref>Request-Line</x:ref>              ; <xref target="request-line"/>
1451                  *(( <x:ref>general-header</x:ref>        ; <xref target="general.header.fields"/>
1452                   / <x:ref>request-header</x:ref>         ; &request-header-fields;
1453                   / <x:ref>entity-header</x:ref> ) <x:ref>CRLF</x:ref> ) ; &entity-header-fields;
1454                  <x:ref>CRLF</x:ref>
1455                  [ <x:ref>message-body</x:ref> ]          ; <xref target="message.body"/>
1456</artwork></figure>
1457
1458<section title="Request-Line" anchor="request-line">
1459  <x:anchor-alias value="Request-Line"/>
1460<t>
1461   The Request-Line begins with a method token, followed by the
1462   request-target and the protocol version, and ending with CRLF. The
1463   elements are separated by SP characters. No CR or LF is allowed
1464   except in the final CRLF sequence.
1465</t>
1466<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="Request-Line"/>
1467  <x:ref>Request-Line</x:ref>   = <x:ref>Method</x:ref> <x:ref>SP</x:ref> <x:ref>request-target</x:ref> <x:ref>SP</x:ref> <x:ref>HTTP-Version</x:ref> <x:ref>CRLF</x:ref>
1468</artwork></figure>
1469
1470<section title="Method" anchor="method">
1471  <x:anchor-alias value="Method"/>
1472<t>
1473   The Method  token indicates the method to be performed on the
1474   resource identified by the request-target. The method is case-sensitive.
1475</t>
1476<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="Method"/><iref primary="true" item="Grammar" subitem="extension-method"/>
1477  <x:ref>Method</x:ref>         = <x:ref>token</x:ref>
1478</artwork></figure>
1479</section>
1480
1481<section title="request-target" anchor="request-target">
1482  <x:anchor-alias value="request-target"/>
1483<t>
1484   The request-target
1485   identifies the resource upon which to apply the request.
1486</t>
1487<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="request-target"/>
1488  <x:ref>request-target</x:ref> = "*"
1489                 / <x:ref>absolute-URI</x:ref>
1490                 / ( <x:ref>path-absolute</x:ref> [ "?" <x:ref>query</x:ref> ] )
1491                 / <x:ref>authority</x:ref>
1492</artwork></figure>
1493<t>
1494   The four options for request-target are dependent on the nature of the
1495   request.
1496</t>   
1497<t>
1498   The asterisk "*" means that the request does not apply to a
1499   particular resource, but to the server itself, and is only allowed
1500   when the method used does not necessarily apply to a resource. One
1501   example would be
1502</t>
1503<figure><artwork type="message/http; msgtype=&#34;request&#34;" x:indent-with="  ">
1504OPTIONS * HTTP/1.1
1505</artwork></figure>
1506<t>
1507   The absolute-URI form is &REQUIRED; when the request is being made to a
1508   proxy. The proxy is requested to forward the request or service it
1509   from a valid cache, and return the response. Note that the proxy &MAY;
1510   forward the request on to another proxy or directly to the server
1511   specified by the absolute-URI. In order to avoid request loops, a
1512   proxy &MUST; be able to recognize all of its server names, including
1513   any aliases, local variations, and the numeric IP address. An example
1514   Request-Line would be:
1515</t>
1516<figure><artwork type="message/http; msgtype=&#34;request&#34;" x:indent-with="  ">
1517GET http://www.example.org/pub/WWW/TheProject.html HTTP/1.1
1518</artwork></figure>
1519<t>
1520   To allow for transition to absolute-URIs in all requests in future
1521   versions of HTTP, all HTTP/1.1 servers &MUST; accept the absolute-URI
1522   form in requests, even though HTTP/1.1 clients will only generate
1523   them in requests to proxies.
1524</t>
1525<t>
1526   The authority form is only used by the CONNECT method (&CONNECT;).
1527</t>
1528<t>
1529   The most common form of request-target is that used to identify a
1530   resource on an origin server or gateway. In this case the absolute
1531   path of the URI &MUST; be transmitted (see <xref target="http.uri"/>, path-absolute) as
1532   the request-target, and the network location of the URI (authority) &MUST;
1533   be transmitted in a Host header field. For example, a client wishing
1534   to retrieve the resource above directly from the origin server would
1535   create a TCP connection to port 80 of the host "www.example.org" and send
1536   the lines:
1537</t>
1538<figure><artwork type="message/http; msgtype=&#34;request&#34;" x:indent-with="  ">
1539GET /pub/WWW/TheProject.html HTTP/1.1
1540Host: www.example.org
1541</artwork></figure>
1542<t>
1543   followed by the remainder of the Request. Note that the absolute path
1544   cannot be empty; if none is present in the original URI, it &MUST; be
1545   given as "/" (the server root).
1546</t>
1547<t>
1548   If a proxy receives a request without any path in the request-target and
1549   the method specified is capable of supporting the asterisk form of
1550   request-target, then the last proxy on the request chain &MUST; forward the
1551   request with "*" as the final request-target.
1552</t>
1553<figure><preamble>   
1554   For example, the request
1555</preamble><artwork type="message/http; msgtype=&#34;request&#34;" x:indent-with="  ">
1556OPTIONS http://www.example.org:8001 HTTP/1.1
1557</artwork></figure>
1558<figure><preamble>   
1559  would be forwarded by the proxy as
1560</preamble><artwork type="message/http; msgtype=&#34;request&#34;" x:indent-with="  ">
1561OPTIONS * HTTP/1.1
1562Host: www.example.org:8001
1563</artwork>
1564<postamble>
1565   after connecting to port 8001 of host "www.example.org".
1566</postamble>
1567</figure>
1568<t>
1569   The request-target is transmitted in the format specified in
1570   <xref target="http.uri"/>. If the request-target is percent-encoded
1571   (<xref target="RFC3986" x:fmt="," x:sec="2.1"/>), the origin server
1572   &MUST; decode the request-target in order to
1573   properly interpret the request. Servers &SHOULD; respond to invalid
1574   request-targets with an appropriate status code.
1575</t>
1576<t>
1577   A transparent proxy &MUST-NOT; rewrite the "path-absolute" part of the
1578   received request-target when forwarding it to the next inbound server,
1579   except as noted above to replace a null path-absolute with "/" or "*".
1580</t>
1581<x:note>
1582  <t>
1583    <x:h>Note:</x:h> The "no rewrite" rule prevents the proxy from changing the
1584    meaning of the request when the origin server is improperly using
1585    a non-reserved URI character for a reserved purpose.  Implementors
1586    should be aware that some pre-HTTP/1.1 proxies have been known to
1587    rewrite the request-target.
1588  </t>
1589</x:note>
1590<t>
1591   HTTP does not place a pre-defined limit on the length of a request-target.
1592   A server &MUST; be prepared to receive URIs of unbounded length and
1593   respond with the 414 (URI Too Long) status if the received
1594   request-target would be longer than the server wishes to handle
1595   (see &status-414;).
1596</t>
1597<t>
1598   Various ad-hoc limitations on request-target length are found in practice.
1599   It is &RECOMMENDED; that all HTTP senders and recipients support
1600   request-target lengths of 8000 or more octets.
1601</t>
1602<x:note>
1603  <t>
1604    <x:h>Note:</x:h> Fragments (<xref target="RFC3986" x:fmt="," x:sec="3.5"/>)
1605    are not part of the request-target and thus will not be transmitted
1606    in an HTTP request.
1607  </t>
1608</x:note>
1609</section>
1610</section>
1611
1612<section title="The Resource Identified by a Request" anchor="the.resource.identified.by.a.request">
1613<t>
1614   The exact resource identified by an Internet request is determined by
1615   examining both the request-target and the Host header field.
1616</t>
1617<t>
1618   An origin server that does not allow resources to differ by the
1619   requested host &MAY; ignore the Host header field value when
1620   determining the resource identified by an HTTP/1.1 request. (But see
1621   <xref target="changes.to.simplify.multi-homed.web.servers.and.conserve.ip.addresses"/>
1622   for other requirements on Host support in HTTP/1.1.)
1623</t>
1624<t>
1625   An origin server that does differentiate resources based on the host
1626   requested (sometimes referred to as virtual hosts or vanity host
1627   names) &MUST; use the following rules for determining the requested
1628   resource on an HTTP/1.1 request:
1629  <list style="numbers">
1630    <t>If request-target is an absolute-URI, the host is part of the
1631     request-target. Any Host header field value in the request &MUST; be
1632     ignored.</t>
1633    <t>If the request-target is not an absolute-URI, and the request includes
1634     a Host header field, the host is determined by the Host header
1635     field value.</t>
1636    <t>If the host as determined by rule 1 or 2 is not a valid host on
1637     the server, the response &MUST; be a 400 (Bad Request) error message.</t>
1638  </list>
1639</t>
1640<t>
1641   Recipients of an HTTP/1.0 request that lacks a Host header field &MAY;
1642   attempt to use heuristics (e.g., examination of the URI path for
1643   something unique to a particular host) in order to determine what
1644   exact resource is being requested.
1645</t>
1646</section>
1647
1648<section title="Effective Request URI" anchor="effective.request.uri">
1649  <iref primary="true" item="Effective Request URI"/>
1650<t>
1651   HTTP requests often do not carry the absolute URI (<xref target="RFC3986" x:fmt="," x:sec="4.3"/>)
1652   for the resource they are intended for; instead, the value needs to be inferred from the
1653   request-target, Host header and other context. The result of this process is
1654   the "Effective Request URI".
1655</t>
1656<t>
1657   If the request-target is an absolute-URI, then the Effective Request URI is
1658   the request-target.
1659</t>
1660<t>
1661   If the request-target uses the path-absolute (plus optional query) syntax
1662   or if it is just the asterisk "*", then the Effective Request URI is
1663   constructed by concatenating
1664</t>
1665<t>
1666  <list style="symbols">
1667    <t>
1668      the scheme name: "http" if the request was received over an insecure
1669      TCP connection, or "https" when received over SSL/TLS-secured TCP
1670      connection,
1671    </t>
1672    <t>
1673      the character sequence "://",
1674    </t>
1675    <t>
1676      the authority component, as specified in the Host header
1677      (<xref target="header.host"/>) and determined by the rules in
1678      <xref target="the.resource.identified.by.a.request"/>,
1679      <cref anchor="effrequri-nohost" source="jre">Do we need to include the handling of missing hosts in HTTP/1.0 messages, as
1680      described in <xref target="the.resource.identified.by.a.request"/>? -- See <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/221"/></cref>
1681      and
1682    </t>
1683    <t>
1684      the request-target obtained from the Request-Line, unless the
1685      request-target is just the asterisk "*".
1686    </t>
1687  </list>
1688</t>
1689<t>
1690   Otherwise, when request-target uses the authority form, the Effective
1691   Request URI is undefined.
1692</t>
1693<figure>
1694<preamble>
1695   Example 1: the Effective Request URI for the message
1696</preamble> 
1697<artwork type="example" x:indent-with="  ">
1698GET /pub/WWW/TheProject.html HTTP/1.1
1699Host: www.example.org:8080
1700</artwork>
1701<postamble>
1702  (received over an insecure TCP connection) is "http", plus "://", plus the
1703  authority component "www.example.org:8080", plus the request-target
1704  "/pub/WWW/TheProject.html", thus
1705  "http://www.example.org:8080/pub/WWW/TheProject.html".
1706</postamble>
1707</figure>
1708<figure>
1709<preamble>
1710   Example 2: the Effective Request URI for the message
1711</preamble> 
1712<artwork type="example" x:indent-with="  ">
1713GET * HTTP/1.1
1714Host: www.example.org
1715</artwork>
1716<postamble>
1717  (received over an SSL/TLS secured TCP connection) is "https", plus "://", plus the
1718  authority component "www.example.org", thus "https://www.example.org".
1719</postamble>
1720</figure>
1721<t>
1722   Effective Request URIs are compared using the rules described in
1723   <xref target="uri.comparison"/>, except that empty path components &MUST-NOT;
1724   be treated as equivalent to an absolute path of "/".
1725</t> 
1726</section>
1727
1728</section>
1729
1730
1731<section title="Response" anchor="response">
1732  <x:anchor-alias value="Response"/>
1733<t>
1734   After receiving and interpreting a request message, a server responds
1735   with an HTTP response message.
1736</t>
1737<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="Response"/>
1738  <x:ref>Response</x:ref>      = <x:ref>Status-Line</x:ref>               ; <xref target="status-line"/>
1739                  *(( <x:ref>general-header</x:ref>        ; <xref target="general.header.fields"/>
1740                   / <x:ref>response-header</x:ref>        ; &response-header-fields;
1741                   / <x:ref>entity-header</x:ref> ) <x:ref>CRLF</x:ref> ) ; &entity-header-fields;
1742                  <x:ref>CRLF</x:ref>
1743                  [ <x:ref>message-body</x:ref> ]          ; <xref target="message.body"/>
1744</artwork></figure>
1745
1746<section title="Status-Line" anchor="status-line">
1747  <x:anchor-alias value="Status-Line"/>
1748<t>
1749   The first line of a Response message is the Status-Line, consisting
1750   of the protocol version followed by a numeric status code and its
1751   associated textual phrase, with each element separated by SP
1752   characters. No CR or LF is allowed except in the final CRLF sequence.
1753</t>
1754<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="Status-Line"/>
1755  <x:ref>Status-Line</x:ref> = <x:ref>HTTP-Version</x:ref> <x:ref>SP</x:ref> <x:ref>Status-Code</x:ref> <x:ref>SP</x:ref> <x:ref>Reason-Phrase</x:ref> <x:ref>CRLF</x:ref>
1756</artwork></figure>
1757
1758<section title="Status Code and Reason Phrase" anchor="status.code.and.reason.phrase">
1759  <x:anchor-alias value="Reason-Phrase"/>
1760  <x:anchor-alias value="Status-Code"/>
1761<t>
1762   The Status-Code element is a 3-digit integer result code of the
1763   attempt to understand and satisfy the request. These codes are fully
1764   defined in &status-codes;.  The Reason Phrase exists for the sole
1765   purpose of providing a textual description associated with the numeric
1766   status code, out of deference to earlier Internet application protocols
1767   that were more frequently used with interactive text clients.
1768   A client &SHOULD; ignore the content of the Reason Phrase.
1769</t>
1770<t>
1771   The first digit of the Status-Code defines the class of response. The
1772   last two digits do not have any categorization role. There are 5
1773   values for the first digit:
1774  <list style="symbols">
1775    <t>
1776      1xx: Informational - Request received, continuing process
1777    </t>
1778    <t>
1779      2xx: Success - The action was successfully received,
1780        understood, and accepted
1781    </t>
1782    <t>
1783      3xx: Redirection - Further action must be taken in order to
1784        complete the request
1785    </t>
1786    <t>
1787      4xx: Client Error - The request contains bad syntax or cannot
1788        be fulfilled
1789    </t>
1790    <t>
1791      5xx: Server Error - The server failed to fulfill an apparently
1792        valid request
1793    </t>
1794  </list>
1795</t>
1796<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="Status-Code"/><iref primary="true" item="Grammar" subitem="extension-code"/><iref primary="true" item="Grammar" subitem="Reason-Phrase"/>
1797  <x:ref>Status-Code</x:ref>    = 3<x:ref>DIGIT</x:ref>
1798  <x:ref>Reason-Phrase</x:ref>  = *( <x:ref>WSP</x:ref> / <x:ref>VCHAR</x:ref> / <x:ref>obs-text</x:ref> )
1799</artwork></figure>
1800</section>
1801</section>
1802
1803</section>
1804
1805
1806<section title="Protocol Parameters" anchor="protocol.parameters">
1807
1808<section title="Date/Time Formats: Full Date" anchor="date.time.formats.full.date">
1809  <x:anchor-alias value="HTTP-date"/>
1810<t>
1811   HTTP applications have historically allowed three different formats
1812   for date/time stamps.
1813   However, the preferred format is
1814   a fixed-length subset of that defined by <xref target="RFC1123"/>:
1815</t>
1816<figure><artwork type="example" x:indent-with="  ">
1817Sun, 06 Nov 1994 08:49:37 GMT  ; RFC 1123
1818</artwork></figure>
1819<t>
1820   The other formats are described here only for compatibility with obsolete
1821   implementations.
1822</t>
1823<figure><artwork type="example" x:indent-with="  ">
1824Sunday, 06-Nov-94 08:49:37 GMT ; obsolete RFC 850 format
1825Sun Nov  6 08:49:37 1994       ; ANSI C's asctime() format
1826</artwork></figure>
1827<t>
1828   HTTP/1.1 clients and servers that parse a date value &MUST; accept
1829   all three formats (for compatibility with HTTP/1.0), though they &MUST;
1830   only generate the RFC 1123 format for representing HTTP-date values
1831   in header fields. See <xref target="tolerant.applications"/> for further information.
1832</t>
1833<t>
1834   All HTTP date/time stamps &MUST; be represented in Greenwich Mean Time
1835   (GMT), without exception. For the purposes of HTTP, GMT is exactly
1836   equal to UTC (Coordinated Universal Time). This is indicated in the
1837   first two formats by the inclusion of "GMT" as the three-letter
1838   abbreviation for time zone, and &MUST; be assumed when reading the
1839   asctime format. HTTP-date is case sensitive and &MUST-NOT; include
1840   additional whitespace beyond that specifically included as SP in the
1841   grammar.
1842</t>
1843<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="HTTP-date"/>
1844  <x:ref>HTTP-date</x:ref>    = <x:ref>rfc1123-date</x:ref> / <x:ref>obs-date</x:ref>
1845</artwork></figure>
1846<t anchor="preferred.date.format">
1847  <x:anchor-alias value="rfc1123-date"/>
1848  <x:anchor-alias value="time-of-day"/>
1849  <x:anchor-alias value="hour"/>
1850  <x:anchor-alias value="minute"/>
1851  <x:anchor-alias value="second"/>
1852  <x:anchor-alias value="day-name"/>
1853  <x:anchor-alias value="day"/>
1854  <x:anchor-alias value="month"/>
1855  <x:anchor-alias value="year"/>
1856  <x:anchor-alias value="GMT"/>
1857  Preferred format:
1858</t>
1859<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="rfc1123-date"/><iref primary="true" item="Grammar" subitem="date1"/><iref primary="true" item="Grammar" subitem="time-of-day"/><iref primary="true" item="Grammar" subitem="hour"/><iref primary="true" item="Grammar" subitem="minute"/><iref primary="true" item="Grammar" subitem="second"/><iref primary="true" item="Grammar" subitem="day-name"/><iref primary="true" item="Grammar" subitem="day-name-l"/><iref primary="true" item="Grammar" subitem="day"/><iref primary="true" item="Grammar" subitem="month"/><iref primary="true" item="Grammar" subitem="year"/><iref primary="true" item="Grammar" subitem="GMT"/>
1860  <x:ref>rfc1123-date</x:ref> = <x:ref>day-name</x:ref> "," <x:ref>SP</x:ref> date1 <x:ref>SP</x:ref> <x:ref>time-of-day</x:ref> <x:ref>SP</x:ref> <x:ref>GMT</x:ref>
1861
1862  <x:ref>day-name</x:ref>     = <x:abnf-char-sequence>"Mon"</x:abnf-char-sequence> ; "Mon", case-sensitive
1863               / <x:abnf-char-sequence>"Tue"</x:abnf-char-sequence> ; "Tue", case-sensitive
1864               / <x:abnf-char-sequence>"Wed"</x:abnf-char-sequence> ; "Wed", case-sensitive
1865               / <x:abnf-char-sequence>"Thu"</x:abnf-char-sequence> ; "Thu", case-sensitive
1866               / <x:abnf-char-sequence>"Fri"</x:abnf-char-sequence> ; "Fri", case-sensitive
1867               / <x:abnf-char-sequence>"Sat"</x:abnf-char-sequence> ; "Sat", case-sensitive
1868               / <x:abnf-char-sequence>"Sun"</x:abnf-char-sequence> ; "Sun", case-sensitive
1869               
1870  <x:ref>date1</x:ref>        = <x:ref>day</x:ref> <x:ref>SP</x:ref> <x:ref>month</x:ref> <x:ref>SP</x:ref> <x:ref>year</x:ref>
1871               ; e.g., 02 Jun 1982
1872
1873  <x:ref>day</x:ref>          = 2<x:ref>DIGIT</x:ref>
1874  <x:ref>month</x:ref>        = <x:abnf-char-sequence>"Jan"</x:abnf-char-sequence> ; "Jan", case-sensitive
1875               / <x:abnf-char-sequence>"Feb"</x:abnf-char-sequence> ; "Feb", case-sensitive
1876               / <x:abnf-char-sequence>"Mar"</x:abnf-char-sequence> ; "Mar", case-sensitive
1877               / <x:abnf-char-sequence>"Apr"</x:abnf-char-sequence> ; "Apr", case-sensitive
1878               / <x:abnf-char-sequence>"May"</x:abnf-char-sequence> ; "May", case-sensitive
1879               / <x:abnf-char-sequence>"Jun"</x:abnf-char-sequence> ; "Jun", case-sensitive
1880               / <x:abnf-char-sequence>"Jul"</x:abnf-char-sequence> ; "Jul", case-sensitive
1881               / <x:abnf-char-sequence>"Aug"</x:abnf-char-sequence> ; "Aug", case-sensitive
1882               / <x:abnf-char-sequence>"Sep"</x:abnf-char-sequence> ; "Sep", case-sensitive
1883               / <x:abnf-char-sequence>"Oct"</x:abnf-char-sequence> ; "Oct", case-sensitive
1884               / <x:abnf-char-sequence>"Nov"</x:abnf-char-sequence> ; "Nov", case-sensitive
1885               / <x:abnf-char-sequence>"Dec"</x:abnf-char-sequence> ; "Dec", case-sensitive
1886  <x:ref>year</x:ref>         = 4<x:ref>DIGIT</x:ref>
1887
1888  <x:ref>GMT</x:ref>   = <x:abnf-char-sequence>"GMT"</x:abnf-char-sequence> ; "GMT", case-sensitive
1889
1890  <x:ref>time-of-day</x:ref>  = <x:ref>hour</x:ref> ":" <x:ref>minute</x:ref> ":" <x:ref>second</x:ref>
1891                 ; 00:00:00 - 23:59:59
1892                 
1893  <x:ref>hour</x:ref>         = 2<x:ref>DIGIT</x:ref>               
1894  <x:ref>minute</x:ref>       = 2<x:ref>DIGIT</x:ref>               
1895  <x:ref>second</x:ref>       = 2<x:ref>DIGIT</x:ref>               
1896</artwork></figure>
1897<t>
1898  The semantics of <x:ref>day-name</x:ref>, <x:ref>day</x:ref>,
1899  <x:ref>month</x:ref>, <x:ref>year</x:ref>, and <x:ref>time-of-day</x:ref> are the
1900  same as those defined for the RFC 5322 constructs
1901  with the corresponding name (<xref target="RFC5322" x:fmt="," x:sec="3.3"/>).
1902</t>
1903<t anchor="obsolete.date.formats">
1904  <x:anchor-alias value="obs-date"/>
1905  <x:anchor-alias value="rfc850-date"/>
1906  <x:anchor-alias value="asctime-date"/>
1907  <x:anchor-alias value="date1"/>
1908  <x:anchor-alias value="date2"/>
1909  <x:anchor-alias value="date3"/>
1910  <x:anchor-alias value="rfc1123-date"/>
1911  <x:anchor-alias value="day-name-l"/>
1912  Obsolete formats:
1913</t>
1914<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="obs-date"/>
1915  <x:ref>obs-date</x:ref>     = <x:ref>rfc850-date</x:ref> / <x:ref>asctime-date</x:ref> 
1916</artwork></figure>
1917<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="rfc850-date"/>
1918  <x:ref>rfc850-date</x:ref>  = <x:ref>day-name-l</x:ref> "," <x:ref>SP</x:ref> <x:ref>date2</x:ref> <x:ref>SP</x:ref> <x:ref>time-of-day</x:ref> <x:ref>SP</x:ref> <x:ref>GMT</x:ref>
1919  <x:ref>date2</x:ref>        = <x:ref>day</x:ref> "-" <x:ref>month</x:ref> "-" 2<x:ref>DIGIT</x:ref>
1920                 ; day-month-year (e.g., 02-Jun-82)
1921
1922  <x:ref>day-name-l</x:ref>   = <x:abnf-char-sequence>"Monday"</x:abnf-char-sequence> ; "Monday", case-sensitive
1923         / <x:abnf-char-sequence>"Tuesday"</x:abnf-char-sequence> ; "Tuesday", case-sensitive
1924         / <x:abnf-char-sequence>"Wednesday"</x:abnf-char-sequence> ; "Wednesday", case-sensitive
1925         / <x:abnf-char-sequence>"Thursday"</x:abnf-char-sequence> ; "Thursday", case-sensitive
1926         / <x:abnf-char-sequence>"Friday"</x:abnf-char-sequence> ; "Friday", case-sensitive
1927         / <x:abnf-char-sequence>"Saturday"</x:abnf-char-sequence> ; "Saturday", case-sensitive
1928         / <x:abnf-char-sequence>"Sunday"</x:abnf-char-sequence> ; "Sunday", case-sensitive
1929</artwork></figure>
1930<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="asctime-date"/>
1931  <x:ref>asctime-date</x:ref> = <x:ref>day-name</x:ref> <x:ref>SP</x:ref> <x:ref>date3</x:ref> <x:ref>SP</x:ref> <x:ref>time-of-day</x:ref> <x:ref>SP</x:ref> <x:ref>year</x:ref>
1932  <x:ref>date3</x:ref>        = <x:ref>month</x:ref> <x:ref>SP</x:ref> ( 2<x:ref>DIGIT</x:ref> / ( <x:ref>SP</x:ref> 1<x:ref>DIGIT</x:ref> ))
1933                 ; month day (e.g., Jun  2)
1934</artwork></figure>
1935<x:note>
1936  <t>
1937    <x:h>Note:</x:h> Recipients of date values are encouraged to be robust in
1938    accepting date values that may have been sent by non-HTTP
1939    applications, as is sometimes the case when retrieving or posting
1940    messages via proxies/gateways to SMTP or NNTP.
1941  </t>
1942</x:note>
1943<x:note>
1944  <t>
1945    <x:h>Note:</x:h> HTTP requirements for the date/time stamp format apply only
1946    to their usage within the protocol stream. Clients and servers are
1947    not required to use these formats for user presentation, request
1948    logging, etc.
1949  </t>
1950</x:note>
1951</section>
1952
1953<section title="Transfer Codings" anchor="transfer.codings">
1954  <x:anchor-alias value="transfer-coding"/>
1955  <x:anchor-alias value="transfer-extension"/>
1956<t>
1957   Transfer-coding values are used to indicate an encoding
1958   transformation that has been, can be, or may need to be applied to a
1959   payload body in order to ensure "safe transport" through the network.
1960   This differs from a content coding in that the transfer-coding is a
1961   property of the message rather than a property of the representation
1962   that is being transferred.
1963</t>
1964<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="transfer-coding"/><iref primary="true" item="Grammar" subitem="transfer-extension"/>
1965  <x:ref>transfer-coding</x:ref>         = "chunked" ; <xref target="chunked.encoding"/>
1966                          / "compress" ; <xref target="compress.coding"/>
1967                          / "deflate" ; <xref target="deflate.coding"/>
1968                          / "gzip" ; <xref target="gzip.coding"/>
1969                          / <x:ref>transfer-extension</x:ref>
1970  <x:ref>transfer-extension</x:ref>      = <x:ref>token</x:ref> *( <x:ref>OWS</x:ref> ";" <x:ref>OWS</x:ref> <x:ref>transfer-parameter</x:ref> )
1971</artwork></figure>
1972<t anchor="rule.parameter">
1973  <x:anchor-alias value="attribute"/>
1974  <x:anchor-alias value="transfer-parameter"/>
1975  <x:anchor-alias value="value"/>
1976   Parameters are in the form of attribute/value pairs.
1977</t>
1978<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="transfer-parameter"/><iref primary="true" item="Grammar" subitem="attribute"/><iref primary="true" item="Grammar" subitem="value"/><iref primary="true" item="Grammar" subitem="date2"/><iref primary="true" item="Grammar" subitem="date3"/>
1979  <x:ref>transfer-parameter</x:ref>      = <x:ref>attribute</x:ref> <x:ref>BWS</x:ref> "=" <x:ref>BWS</x:ref> <x:ref>value</x:ref>
1980  <x:ref>attribute</x:ref>               = <x:ref>token</x:ref>
1981  <x:ref>value</x:ref>                   = <x:ref>word</x:ref>
1982</artwork></figure>
1983<t>
1984   All transfer-coding values are case-insensitive. HTTP/1.1 uses
1985   transfer-coding values in the TE header field (<xref target="header.te"/>) and in
1986   the Transfer-Encoding header field (<xref target="header.transfer-encoding"/>).
1987</t>
1988<t>
1989   Transfer-codings are analogous to the Content-Transfer-Encoding values of
1990   MIME, which were designed to enable safe transport of binary data over a
1991   7-bit transport service (<xref target="RFC2045" x:fmt="," x:sec="6"/>).
1992   However, safe transport
1993   has a different focus for an 8bit-clean transfer protocol. In HTTP,
1994   the only unsafe characteristic of message-bodies is the difficulty in
1995   determining the exact message body length (<xref target="message.body"/>),
1996   or the desire to encrypt data over a shared transport.
1997</t>
1998<t>
1999   A server that receives a request message with a transfer-coding it does
2000   not understand &SHOULD; respond with 501 (Not Implemented) and then
2001   close the connection. A server &MUST-NOT; send transfer-codings to an HTTP/1.0
2002   client.
2003</t>
2004
2005<section title="Chunked Transfer Coding" anchor="chunked.encoding">
2006  <iref item="chunked (Coding Format)"/>
2007  <iref item="Coding Format" subitem="chunked"/>
2008  <x:anchor-alias value="chunk"/>
2009  <x:anchor-alias value="Chunked-Body"/>
2010  <x:anchor-alias value="chunk-data"/>
2011  <x:anchor-alias value="chunk-ext"/>
2012  <x:anchor-alias value="chunk-ext-name"/>
2013  <x:anchor-alias value="chunk-ext-val"/>
2014  <x:anchor-alias value="chunk-size"/>
2015  <x:anchor-alias value="last-chunk"/>
2016  <x:anchor-alias value="trailer-part"/>
2017  <x:anchor-alias value="quoted-str-nf"/>
2018  <x:anchor-alias value="qdtext-nf"/>
2019<t>
2020   The chunked encoding modifies the body of a message in order to
2021   transfer it as a series of chunks, each with its own size indicator,
2022   followed by an &OPTIONAL; trailer containing entity-header fields. This
2023   allows dynamically produced content to be transferred along with the
2024   information necessary for the recipient to verify that it has
2025   received the full message.
2026</t>
2027<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="Chunked-Body"/><iref primary="true" item="Grammar" subitem="chunk"/><iref primary="true" item="Grammar" subitem="chunk-size"/><iref primary="true" item="Grammar" subitem="last-chunk"/><iref primary="true" item="Grammar" subitem="chunk-ext"/><iref primary="true" item="Grammar" subitem="chunk-ext-name"/><iref primary="true" item="Grammar" subitem="chunk-ext-val"/><iref primary="true" item="Grammar" subitem="chunk-data"/><iref primary="true" item="Grammar" subitem="trailer-part"/><iref primary="true" item="Grammar" subitem="quoted-str-nf"/><iref primary="true" item="Grammar" subitem="qdtext-nf"/>
2028  <x:ref>Chunked-Body</x:ref>   = *<x:ref>chunk</x:ref>
2029                   <x:ref>last-chunk</x:ref>
2030                   <x:ref>trailer-part</x:ref>
2031                   <x:ref>CRLF</x:ref>
2032 
2033  <x:ref>chunk</x:ref>          = <x:ref>chunk-size</x:ref> *WSP [ <x:ref>chunk-ext</x:ref> ] <x:ref>CRLF</x:ref>
2034                   <x:ref>chunk-data</x:ref> <x:ref>CRLF</x:ref>
2035  <x:ref>chunk-size</x:ref>     = 1*<x:ref>HEXDIG</x:ref>
2036  <x:ref>last-chunk</x:ref>     = 1*("0") *WSP [ <x:ref>chunk-ext</x:ref> ] <x:ref>CRLF</x:ref>
2037 
2038  <x:ref>chunk-ext</x:ref>      = *( ";" *WSP <x:ref>chunk-ext-name</x:ref>
2039                      [ "=" <x:ref>chunk-ext-val</x:ref> ] *WSP )
2040  <x:ref>chunk-ext-name</x:ref> = <x:ref>token</x:ref>
2041  <x:ref>chunk-ext-val</x:ref>  = <x:ref>token</x:ref> / <x:ref>quoted-str-nf</x:ref>
2042  <x:ref>chunk-data</x:ref>     = 1*<x:ref>OCTET</x:ref> ; a sequence of chunk-size octets
2043  <x:ref>trailer-part</x:ref>   = *( <x:ref>entity-header</x:ref> <x:ref>CRLF</x:ref> )
2044 
2045  <x:ref>quoted-str-nf</x:ref>  = <x:ref>DQUOTE</x:ref> *( <x:ref>qdtext-nf</x:ref> / <x:ref>quoted-pair</x:ref> ) <x:ref>DQUOTE</x:ref>
2046                 ; like <x:ref>quoted-string</x:ref>, but disallowing line folding
2047  <x:ref>qdtext-nf</x:ref>      = <x:ref>WSP</x:ref> / %x21 / %x23-5B / %x5D-7E / <x:ref>obs-text</x:ref>
2048                 ; <x:ref>WSP</x:ref> / &lt;<x:ref>VCHAR</x:ref> except <x:ref>DQUOTE</x:ref> and "\"&gt; / <x:ref>obs-text</x:ref> 
2049</artwork></figure>
2050<t>
2051   The chunk-size field is a string of hex digits indicating the size of
2052   the chunk-data in octets. The chunked encoding is ended by any chunk whose size is
2053   zero, followed by the trailer, which is terminated by an empty line.
2054</t>
2055<t>
2056   The trailer allows the sender to include additional HTTP header
2057   fields at the end of the message. The Trailer header field can be
2058   used to indicate which header fields are included in a trailer (see
2059   <xref target="header.trailer"/>).
2060</t>
2061<t>
2062   A server using chunked transfer-coding in a response &MUST-NOT; use the
2063   trailer for any header fields unless at least one of the following is
2064   true:
2065  <list style="numbers">
2066    <t>the request included a TE header field that indicates "trailers" is
2067     acceptable in the transfer-coding of the  response, as described in
2068     <xref target="header.te"/>; or,</t>
2069
2070    <t>the server is the origin server for the response, the trailer
2071     fields consist entirely of optional metadata, and the recipient
2072     could use the message (in a manner acceptable to the origin server)
2073     without receiving this metadata.  In other words, the origin server
2074     is willing to accept the possibility that the trailer fields might
2075     be silently discarded along the path to the client.</t>
2076  </list>
2077</t>
2078<t>
2079   This requirement prevents an interoperability failure when the
2080   message is being received by an HTTP/1.1 (or later) proxy and
2081   forwarded to an HTTP/1.0 recipient. It avoids a situation where
2082   compliance with the protocol would have necessitated a possibly
2083   infinite buffer on the proxy.
2084</t>
2085<t>
2086   A process for decoding the "chunked" transfer-coding
2087   can be represented in pseudo-code as:
2088</t>
2089<figure><artwork type="code">
2090  length := 0
2091  read chunk-size, chunk-ext (if any) and CRLF
2092  while (chunk-size &gt; 0) {
2093     read chunk-data and CRLF
2094     append chunk-data to decoded-body
2095     length := length + chunk-size
2096     read chunk-size and CRLF
2097  }
2098  read header-field
2099  while (header-field not empty) {
2100     append header-field to existing header fields
2101     read header-field
2102  }
2103  Content-Length := length
2104  Remove "chunked" from Transfer-Encoding
2105</artwork></figure>
2106<t>
2107   All HTTP/1.1 applications &MUST; be able to receive and decode the
2108   "chunked" transfer-coding and &MUST; ignore chunk-ext extensions
2109   they do not understand.
2110</t>
2111<t>
2112   Since "chunked" is the only transfer-coding required to be understood
2113   by HTTP/1.1 recipients, it plays a crucial role in delimiting messages
2114   on a persistent connection.  Whenever a transfer-coding is applied to
2115   a payload body in a request, the final transfer-coding applied &MUST;
2116   be "chunked".  If a transfer-coding is applied to a response payload
2117   body, then either the final transfer-coding applied &MUST; be "chunked"
2118   or the message &MUST; be terminated by closing the connection. When the
2119   "chunked" transfer-coding is used, it &MUST; be the last transfer-coding
2120   applied to form the message-body. The "chunked" transfer-coding &MUST-NOT;
2121   be applied more than once in a message-body.
2122</t>
2123</section>
2124
2125<section title="Compression Codings" anchor="compression.codings">
2126<t>
2127   The codings defined below can be used to compress the payload of a
2128   message.
2129</t>
2130<x:note><t>
2131   <x:h>Note:</x:h> Use of program names for the identification of encoding formats
2132   is not desirable and is discouraged for future encodings. Their
2133   use here is representative of historical practice, not good
2134   design.
2135</t></x:note>
2136<x:note><t>
2137   <x:h>Note:</x:h> For compatibility with previous implementations of HTTP,
2138   applications &SHOULD; consider "x-gzip" and "x-compress" to be
2139   equivalent to "gzip" and "compress" respectively.
2140</t></x:note>
2141
2142<section title="Compress Coding" anchor="compress.coding">
2143<iref item="compress (Coding Format)"/>
2144<iref item="Coding Format" subitem="compress"/>
2145<t>
2146   The "compress" format is produced by the common UNIX file compression
2147   program "compress". This format is an adaptive Lempel-Ziv-Welch
2148   coding (LZW).
2149</t>
2150</section>
2151
2152<section title="Deflate Coding" anchor="deflate.coding">
2153<iref item="deflate (Coding Format)"/>
2154<iref item="Coding Format" subitem="deflate"/>
2155<t>
2156   The "deflate" format is defined as the "deflate" compression mechanism
2157   (described in <xref target="RFC1951"/>) used inside the "zlib"
2158   data format (<xref target="RFC1950"/>).
2159</t>
2160<x:note>
2161  <t>
2162    <x:h>Note:</x:h> Some incorrect implementations send the "deflate"
2163    compressed data without the zlib wrapper.
2164   </t>
2165</x:note>
2166</section>
2167
2168<section title="Gzip Coding" anchor="gzip.coding">
2169<iref item="gzip (Coding Format)"/>
2170<iref item="Coding Format" subitem="gzip"/>
2171<t>
2172   The "gzip" format is produced by the file compression program
2173   "gzip" (GNU zip), as described in <xref target="RFC1952"/>. This format is a
2174   Lempel-Ziv coding (LZ77) with a 32 bit CRC.
2175</t>
2176</section>
2177
2178</section>
2179
2180<section title="Transfer Coding Registry" anchor="transfer.coding.registry">
2181<t>
2182   The HTTP Transfer Coding Registry defines the name space for the transfer
2183   coding names.
2184</t>
2185<t>
2186   Registrations &MUST; include the following fields:
2187   <list style="symbols">
2188     <t>Name</t>
2189     <t>Description</t>
2190     <t>Pointer to specification text</t>
2191   </list>
2192</t>
2193<t>
2194   Names of transfer codings &MUST-NOT; overlap with names of content codings
2195   (&content-codings;), unless the encoding transformation is identical (as it
2196   is the case for the compression codings defined in
2197   <xref target="compression.codings"/>).
2198</t>
2199<t>
2200   Values to be added to this name space require expert review and a specification
2201   (see "Expert Review" and "Specification Required" in
2202   <xref target="RFC5226" x:fmt="of" x:sec="4.1"/>), and &MUST;
2203   conform to the purpose of transfer coding defined in this section.
2204</t>
2205<t>
2206   The registry itself is maintained at
2207   <eref target="http://www.iana.org/assignments/http-parameters"/>.
2208</t>
2209</section>
2210</section>
2211
2212<section title="Product Tokens" anchor="product.tokens">
2213  <x:anchor-alias value="product"/>
2214  <x:anchor-alias value="product-version"/>
2215<t>
2216   Product tokens are used to allow communicating applications to
2217   identify themselves by software name and version. Most fields using
2218   product tokens also allow sub-products which form a significant part
2219   of the application to be listed, separated by whitespace. By
2220   convention, the products are listed in order of their significance
2221   for identifying the application.
2222</t>
2223<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="product"/><iref primary="true" item="Grammar" subitem="product-version"/>
2224  <x:ref>product</x:ref>         = <x:ref>token</x:ref> ["/" <x:ref>product-version</x:ref>]
2225  <x:ref>product-version</x:ref> = <x:ref>token</x:ref>
2226</artwork></figure>
2227<t>
2228   Examples:
2229</t>
2230<figure><artwork type="example">
2231  User-Agent: CERN-LineMode/2.15 libwww/2.17b3
2232  Server: Apache/0.8.4
2233</artwork></figure>
2234<t>
2235   Product tokens &SHOULD; be short and to the point. They &MUST-NOT; be
2236   used for advertising or other non-essential information. Although any
2237   token character &MAY; appear in a product-version, this token &SHOULD;
2238   only be used for a version identifier (i.e., successive versions of
2239   the same product &SHOULD; only differ in the product-version portion of
2240   the product value).
2241</t>
2242</section>
2243
2244<section title="Quality Values" anchor="quality.values">
2245  <x:anchor-alias value="qvalue"/>
2246<t>
2247   Both transfer codings (TE request header, <xref target="header.te"/>)
2248   and content negotiation (&content.negotiation;) use short "floating point"
2249   numbers to indicate the relative importance ("weight") of various
2250   negotiable parameters.  A weight is normalized to a real number in
2251   the range 0 through 1, where 0 is the minimum and 1 the maximum
2252   value. If a parameter has a quality value of 0, then content with
2253   this parameter is "not acceptable" for the client. HTTP/1.1
2254   applications &MUST-NOT; generate more than three digits after the
2255   decimal point. User configuration of these values &SHOULD; also be
2256   limited in this fashion.
2257</t>
2258<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="qvalue"/>
2259  <x:ref>qvalue</x:ref>         = ( "0" [ "." 0*3<x:ref>DIGIT</x:ref> ] )
2260                 / ( "1" [ "." 0*3("0") ] )
2261</artwork></figure>
2262<x:note>
2263  <t>
2264     <x:h>Note:</x:h> "Quality values" is a misnomer, since these values merely represent
2265     relative degradation in desired quality.
2266  </t>
2267</x:note>
2268</section>
2269
2270</section>
2271
2272<section title="Connections" anchor="connections">
2273
2274<section title="Persistent Connections" anchor="persistent.connections">
2275
2276<section title="Purpose" anchor="persistent.purpose">
2277<t>
2278   Prior to persistent connections, a separate TCP connection was
2279   established to fetch each URL, increasing the load on HTTP servers
2280   and causing congestion on the Internet. The use of inline images and
2281   other associated data often requires a client to make multiple
2282   requests of the same server in a short amount of time. Analysis of
2283   these performance problems and results from a prototype
2284   implementation are available <xref target="Pad1995"/> <xref target="Spe"/>. Implementation experience and
2285   measurements of actual HTTP/1.1 implementations show good
2286   results <xref target="Nie1997"/>. Alternatives have also been explored, for example,
2287   T/TCP <xref target="Tou1998"/>.
2288</t>
2289<t>
2290   Persistent HTTP connections have a number of advantages:
2291  <list style="symbols">
2292      <t>
2293        By opening and closing fewer TCP connections, CPU time is saved
2294        in routers and hosts (clients, servers, proxies, gateways,
2295        tunnels, or caches), and memory used for TCP protocol control
2296        blocks can be saved in hosts.
2297      </t>
2298      <t>
2299        HTTP requests and responses can be pipelined on a connection.
2300        Pipelining allows a client to make multiple requests without
2301        waiting for each response, allowing a single TCP connection to
2302        be used much more efficiently, with much lower elapsed time.
2303      </t>
2304      <t>
2305        Network congestion is reduced by reducing the number of packets
2306        caused by TCP opens, and by allowing TCP sufficient time to
2307        determine the congestion state of the network.
2308      </t>
2309      <t>
2310        Latency on subsequent requests is reduced since there is no time
2311        spent in TCP's connection opening handshake.
2312      </t>
2313      <t>
2314        HTTP can evolve more gracefully, since errors can be reported
2315        without the penalty of closing the TCP connection. Clients using
2316        future versions of HTTP might optimistically try a new feature,
2317        but if communicating with an older server, retry with old
2318        semantics after an error is reported.
2319      </t>
2320    </list>
2321</t>
2322<t>
2323   HTTP implementations &SHOULD; implement persistent connections.
2324</t>
2325</section>
2326
2327<section title="Overall Operation" anchor="persistent.overall">
2328<t>
2329   A significant difference between HTTP/1.1 and earlier versions of
2330   HTTP is that persistent connections are the default behavior of any
2331   HTTP connection. That is, unless otherwise indicated, the client
2332   &SHOULD; assume that the server will maintain a persistent connection,
2333   even after error responses from the server.
2334</t>
2335<t>
2336   Persistent connections provide a mechanism by which a client and a
2337   server can signal the close of a TCP connection. This signaling takes
2338   place using the Connection header field (<xref target="header.connection"/>). Once a close
2339   has been signaled, the client &MUST-NOT; send any more requests on that
2340   connection.
2341</t>
2342
2343<section title="Negotiation" anchor="persistent.negotiation">
2344<t>
2345   An HTTP/1.1 server &MAY; assume that a HTTP/1.1 client intends to
2346   maintain a persistent connection unless a Connection header including
2347   the connection-token "close" was sent in the request. If the server
2348   chooses to close the connection immediately after sending the
2349   response, it &SHOULD; send a Connection header including the
2350   connection-token "close".
2351</t>
2352<t>
2353   An HTTP/1.1 client &MAY; expect a connection to remain open, but would
2354   decide to keep it open based on whether the response from a server
2355   contains a Connection header with the connection-token close. In case
2356   the client does not want to maintain a connection for more than that
2357   request, it &SHOULD; send a Connection header including the
2358   connection-token close.
2359</t>
2360<t>
2361   If either the client or the server sends the close token in the
2362   Connection header, that request becomes the last one for the
2363   connection.
2364</t>
2365<t>
2366   Clients and servers &SHOULD-NOT;  assume that a persistent connection is
2367   maintained for HTTP versions less than 1.1 unless it is explicitly
2368   signaled. See <xref target="compatibility.with.http.1.0.persistent.connections"/> for more information on backward
2369   compatibility with HTTP/1.0 clients.
2370</t>
2371<t>
2372   In order to remain persistent, all messages on the connection &MUST;
2373   have a self-defined message length (i.e., one not defined by closure
2374   of the connection), as described in <xref target="message.body"/>.
2375</t>
2376</section>
2377
2378<section title="Pipelining" anchor="pipelining">
2379<t>
2380   A client that supports persistent connections &MAY; "pipeline" its
2381   requests (i.e., send multiple requests without waiting for each
2382   response). A server &MUST; send its responses to those requests in the
2383   same order that the requests were received.
2384</t>
2385<t>
2386   Clients which assume persistent connections and pipeline immediately
2387   after connection establishment &SHOULD; be prepared to retry their
2388   connection if the first pipelined attempt fails. If a client does
2389   such a retry, it &MUST-NOT; pipeline before it knows the connection is
2390   persistent. Clients &MUST; also be prepared to resend their requests if
2391   the server closes the connection before sending all of the
2392   corresponding responses.
2393</t>
2394<t>
2395   Clients &SHOULD-NOT;  pipeline requests using non-idempotent methods or
2396   non-idempotent sequences of methods (see &idempotent-methods;). Otherwise, a
2397   premature termination of the transport connection could lead to
2398   indeterminate results. A client wishing to send a non-idempotent
2399   request &SHOULD; wait to send that request until it has received the
2400   response status for the previous request.
2401</t>
2402</section>
2403</section>
2404
2405<section title="Proxy Servers" anchor="persistent.proxy">
2406<t>
2407   It is especially important that proxies correctly implement the
2408   properties of the Connection header field as specified in <xref target="header.connection"/>.
2409</t>
2410<t>
2411   The proxy server &MUST; signal persistent connections separately with
2412   its clients and the origin servers (or other proxy servers) that it
2413   connects to. Each persistent connection applies to only one transport
2414   link.
2415</t>
2416<t>
2417   A proxy server &MUST-NOT; establish a HTTP/1.1 persistent connection
2418   with an HTTP/1.0 client (but see <xref x:sec="19.7.1" x:fmt="of" target="RFC2068"/>
2419   for information and discussion of the problems with the Keep-Alive header
2420   implemented by many HTTP/1.0 clients).
2421</t>
2422
2423<section title="End-to-end and Hop-by-hop Headers" anchor="end-to-end.and.hop-by-hop.headers">
2424<!--<t>
2425  <cref anchor="TODO-end-to-end" source="jre">
2426    Restored from <eref target="http://tools.ietf.org/html/draft-ietf-httpbis-p6-cache-05#section-7.1"/>.
2427    See also <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/60"/>.
2428  </cref>
2429</t>-->
2430<t>
2431   For the purpose of defining the behavior of caches and non-caching
2432   proxies, we divide HTTP headers into two categories:
2433  <list style="symbols">
2434      <t>End-to-end headers, which are  transmitted to the ultimate
2435        recipient of a request or response. End-to-end headers in
2436        responses MUST be stored as part of a cache entry and &MUST; be
2437        transmitted in any response formed from a cache entry.</t>
2438
2439      <t>Hop-by-hop headers, which are meaningful only for a single
2440        transport-level connection, and are not stored by caches or
2441        forwarded by proxies.</t>
2442  </list>
2443</t>
2444<t>
2445   The following HTTP/1.1 headers are hop-by-hop headers:
2446  <list style="symbols">
2447      <t>Connection</t>
2448      <t>Keep-Alive</t>
2449      <t>Proxy-Authenticate</t>
2450      <t>Proxy-Authorization</t>
2451      <t>TE</t>
2452      <t>Trailer</t>
2453      <t>Transfer-Encoding</t>
2454      <t>Upgrade</t>
2455  </list>
2456</t>
2457<t>
2458   All other headers defined by HTTP/1.1 are end-to-end headers.
2459</t>
2460<t>
2461   Other hop-by-hop headers &MUST; be listed in a Connection header
2462   (<xref target="header.connection"/>).
2463</t>
2464</section>
2465
2466<section title="Non-modifiable Headers" anchor="non-modifiable.headers">
2467<!--<t>
2468  <cref anchor="TODO-non-mod-headers" source="jre">
2469    Restored from <eref target="http://tools.ietf.org/html/draft-ietf-httpbis-p6-cache-05#section-7.2"/>.
2470    See also <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/60"/>.
2471  </cref>
2472</t>-->
2473<t>
2474   Some features of HTTP/1.1, such as Digest Authentication, depend on the
2475   value of certain end-to-end headers. A transparent proxy &SHOULD-NOT;
2476   modify an end-to-end header unless the definition of that header requires
2477   or specifically allows that.
2478</t>
2479<t>
2480   A transparent proxy &MUST-NOT; modify any of the following fields in a
2481   request or response, and it &MUST-NOT; add any of these fields if not
2482   already present:
2483  <list style="symbols">
2484      <t>Content-Location</t>
2485      <t>Content-MD5</t>
2486      <t>ETag</t>
2487      <t>Last-Modified</t>
2488  </list>
2489</t>
2490<t>
2491   A transparent proxy &MUST-NOT; modify any of the following fields in a
2492   response:
2493  <list style="symbols">
2494    <t>Expires</t>
2495  </list>
2496</t>
2497<t>
2498   but it &MAY; add any of these fields if not already present. If an
2499   Expires header is added, it &MUST; be given a field-value identical to
2500   that of the Date header in that response.
2501</t>
2502<t>
2503   A proxy &MUST-NOT; modify or add any of the following fields in a
2504   message that contains the no-transform cache-control directive, or in
2505   any request:
2506  <list style="symbols">
2507    <t>Content-Encoding</t>
2508    <t>Content-Range</t>
2509    <t>Content-Type</t>
2510  </list>
2511</t>
2512<t>
2513   A non-transparent proxy &MAY; modify or add these fields to a message
2514   that does not include no-transform, but if it does so, it &MUST; add a
2515   Warning 214 (Transformation applied) if one does not already appear
2516   in the message (see &header-warning;).
2517</t>
2518<x:note>
2519  <t>
2520    <x:h>Warning:</x:h> Unnecessary modification of end-to-end headers might
2521    cause authentication failures if stronger authentication
2522    mechanisms are introduced in later versions of HTTP. Such
2523    authentication mechanisms &MAY; rely on the values of header fields
2524    not listed here.
2525  </t>
2526</x:note>
2527<t>
2528   A transparent proxy &MUST; preserve the message payload (&payload;),
2529   though it &MAY; change the message-body through application or removal
2530   of a transfer-coding (<xref target="transfer.codings"/>).
2531</t>
2532</section>
2533
2534</section>
2535
2536<section title="Practical Considerations" anchor="persistent.practical">
2537<t>
2538   Servers will usually have some time-out value beyond which they will
2539   no longer maintain an inactive connection. Proxy servers might make
2540   this a higher value since it is likely that the client will be making
2541   more connections through the same server. The use of persistent
2542   connections places no requirements on the length (or existence) of
2543   this time-out for either the client or the server.
2544</t>
2545<t>
2546   When a client or server wishes to time-out it &SHOULD; issue a graceful
2547   close on the transport connection. Clients and servers &SHOULD; both
2548   constantly watch for the other side of the transport close, and
2549   respond to it as appropriate. If a client or server does not detect
2550   the other side's close promptly it could cause unnecessary resource
2551   drain on the network.
2552</t>
2553<t>
2554   A client, server, or proxy &MAY; close the transport connection at any
2555   time. For example, a client might have started to send a new request
2556   at the same time that the server has decided to close the "idle"
2557   connection. From the server's point of view, the connection is being
2558   closed while it was idle, but from the client's point of view, a
2559   request is in progress.
2560</t>
2561<t>
2562   This means that clients, servers, and proxies &MUST; be able to recover
2563   from asynchronous close events. Client software &SHOULD; reopen the
2564   transport connection and retransmit the aborted sequence of requests
2565   without user interaction so long as the request sequence is
2566   idempotent (see &idempotent-methods;). Non-idempotent methods or sequences
2567   &MUST-NOT; be automatically retried, although user agents &MAY; offer a
2568   human operator the choice of retrying the request(s). Confirmation by
2569   user-agent software with semantic understanding of the application
2570   &MAY; substitute for user confirmation. The automatic retry &SHOULD-NOT; 
2571   be repeated if the second sequence of requests fails.
2572</t>
2573<t>
2574   Servers &SHOULD; always respond to at least one request per connection,
2575   if at all possible. Servers &SHOULD-NOT;  close a connection in the
2576   middle of transmitting a response, unless a network or client failure
2577   is suspected.
2578</t>
2579<t>
2580   Clients (including proxies) &SHOULD; limit the number of simultaneous
2581   connections that they maintain to a given server (including proxies).
2582</t>
2583<t>
2584   Previous revisions of HTTP gave a specific number of connections as a
2585   ceiling, but this was found to be impractical for many applications. As a
2586   result, this specification does not mandate a particular maximum number of
2587   connections, but instead encourages clients to be conservative when opening
2588   multiple connections.
2589</t>
2590<t>
2591   In particular, while using multiple connections avoids the "head-of-line
2592   blocking" problem (whereby a request that takes significant server-side
2593   processing and/or has a large payload can block subsequent requests on the
2594   same connection), each connection used consumes server resources (sometimes
2595   significantly), and furthermore using multiple connections can cause
2596   undesirable side effects in congested networks.
2597</t>
2598<t>
2599   Note that servers might reject traffic that they deem abusive, including an
2600   excessive number of connections from a client.
2601</t>
2602</section>
2603</section>
2604
2605<section title="Message Transmission Requirements" anchor="message.transmission.requirements">
2606
2607<section title="Persistent Connections and Flow Control" anchor="persistent.flow">
2608<t>
2609   HTTP/1.1 servers &SHOULD; maintain persistent connections and use TCP's
2610   flow control mechanisms to resolve temporary overloads, rather than
2611   terminating connections with the expectation that clients will retry.
2612   The latter technique can exacerbate network congestion.
2613</t>
2614</section>
2615
2616<section title="Monitoring Connections for Error Status Messages" anchor="persistent.monitor">
2617<t>
2618   An HTTP/1.1 (or later) client sending a message-body &SHOULD; monitor
2619   the network connection for an error status while it is transmitting
2620   the request. If the client sees an error status, it &SHOULD;
2621   immediately cease transmitting the body. If the body is being sent
2622   using a "chunked" encoding (<xref target="transfer.codings"/>), a zero length chunk and
2623   empty trailer &MAY; be used to prematurely mark the end of the message.
2624   If the body was preceded by a Content-Length header, the client &MUST;
2625   close the connection.
2626</t>
2627</section>
2628
2629<section title="Use of the 100 (Continue) Status" anchor="use.of.the.100.status">
2630<t>
2631   The purpose of the 100 (Continue) status (see &status-100;) is to
2632   allow a client that is sending a request message with a request body
2633   to determine if the origin server is willing to accept the request
2634   (based on the request headers) before the client sends the request
2635   body. In some cases, it might either be inappropriate or highly
2636   inefficient for the client to send the body if the server will reject
2637   the message without looking at the body.
2638</t>
2639<t>
2640   Requirements for HTTP/1.1 clients:
2641  <list style="symbols">
2642    <t>
2643        If a client will wait for a 100 (Continue) response before
2644        sending the request body, it &MUST; send an Expect request-header
2645        field (&header-expect;) with the "100-continue" expectation.
2646    </t>
2647    <t>
2648        A client &MUST-NOT; send an Expect request-header field (&header-expect;)
2649        with the "100-continue" expectation if it does not intend
2650        to send a request body.
2651    </t>
2652  </list>
2653</t>
2654<t>
2655   Because of the presence of older implementations, the protocol allows
2656   ambiguous situations in which a client may send "Expect: 100-continue"
2657   without receiving either a 417 (Expectation Failed) status
2658   or a 100 (Continue) status. Therefore, when a client sends this
2659   header field to an origin server (possibly via a proxy) from which it
2660   has never seen a 100 (Continue) status, the client &SHOULD-NOT;  wait
2661   for an indefinite period before sending the request body.
2662</t>
2663<t>
2664   Requirements for HTTP/1.1 origin servers:
2665  <list style="symbols">
2666    <t> Upon receiving a request which includes an Expect request-header
2667        field with the "100-continue" expectation, an origin server &MUST;
2668        either respond with 100 (Continue) status and continue to read
2669        from the input stream, or respond with a final status code. The
2670        origin server &MUST-NOT; wait for the request body before sending
2671        the 100 (Continue) response. If it responds with a final status
2672        code, it &MAY; close the transport connection or it &MAY; continue
2673        to read and discard the rest of the request.  It &MUST-NOT;
2674        perform the requested method if it returns a final status code.
2675    </t>
2676    <t> An origin server &SHOULD-NOT;  send a 100 (Continue) response if
2677        the request message does not include an Expect request-header
2678        field with the "100-continue" expectation, and &MUST-NOT; send a
2679        100 (Continue) response if such a request comes from an HTTP/1.0
2680        (or earlier) client. There is an exception to this rule: for
2681        compatibility with <xref target="RFC2068"/>, a server &MAY; send a 100 (Continue)
2682        status in response to an HTTP/1.1 PUT or POST request that does
2683        not include an Expect request-header field with the "100-continue"
2684        expectation. This exception, the purpose of which is
2685        to minimize any client processing delays associated with an
2686        undeclared wait for 100 (Continue) status, applies only to
2687        HTTP/1.1 requests, and not to requests with any other HTTP-version
2688        value.
2689    </t>
2690    <t> An origin server &MAY; omit a 100 (Continue) response if it has
2691        already received some or all of the request body for the
2692        corresponding request.
2693    </t>
2694    <t> An origin server that sends a 100 (Continue) response &MUST;
2695    ultimately send a final status code, once the request body is
2696        received and processed, unless it terminates the transport
2697        connection prematurely.
2698    </t>
2699    <t> If an origin server receives a request that does not include an
2700        Expect request-header field with the "100-continue" expectation,
2701        the request includes a request body, and the server responds
2702        with a final status code before reading the entire request body
2703        from the transport connection, then the server &SHOULD-NOT;  close
2704        the transport connection until it has read the entire request,
2705        or until the client closes the connection. Otherwise, the client
2706        might not reliably receive the response message. However, this
2707        requirement is not be construed as preventing a server from
2708        defending itself against denial-of-service attacks, or from
2709        badly broken client implementations.
2710      </t>
2711    </list>
2712</t>
2713<t>
2714   Requirements for HTTP/1.1 proxies:
2715  <list style="symbols">
2716    <t> If a proxy receives a request that includes an Expect request-header
2717        field with the "100-continue" expectation, and the proxy
2718        either knows that the next-hop server complies with HTTP/1.1 or
2719        higher, or does not know the HTTP version of the next-hop
2720        server, it &MUST; forward the request, including the Expect header
2721        field.
2722    </t>
2723    <t> If the proxy knows that the version of the next-hop server is
2724        HTTP/1.0 or lower, it &MUST-NOT; forward the request, and it &MUST;
2725        respond with a 417 (Expectation Failed) status.
2726    </t>
2727    <t> Proxies &SHOULD; maintain a cache recording the HTTP version
2728        numbers received from recently-referenced next-hop servers.
2729    </t>
2730    <t> A proxy &MUST-NOT; forward a 100 (Continue) response if the
2731        request message was received from an HTTP/1.0 (or earlier)
2732        client and did not include an Expect request-header field with
2733        the "100-continue" expectation. This requirement overrides the
2734        general rule for forwarding of 1xx responses (see &status-1xx;).
2735    </t>
2736  </list>
2737</t>
2738</section>
2739
2740<section title="Client Behavior if Server Prematurely Closes Connection" anchor="connection.premature">
2741<t>
2742   If an HTTP/1.1 client sends a request which includes a request body,
2743   but which does not include an Expect request-header field with the
2744   "100-continue" expectation, and if the client is not directly
2745   connected to an HTTP/1.1 origin server, and if the client sees the
2746   connection close before receiving any status from the server, the
2747   client &SHOULD; retry the request.  If the client does retry this
2748   request, it &MAY; use the following "binary exponential backoff"
2749   algorithm to be assured of obtaining a reliable response:
2750  <list style="numbers">
2751    <t>
2752      Initiate a new connection to the server
2753    </t>
2754    <t>
2755      Transmit the request-headers
2756    </t>
2757    <t>
2758      Initialize a variable R to the estimated round-trip time to the
2759         server (e.g., based on the time it took to establish the
2760         connection), or to a constant value of 5 seconds if the round-trip
2761         time is not available.
2762    </t>
2763    <t>
2764       Compute T = R * (2**N), where N is the number of previous
2765         retries of this request.
2766    </t>
2767    <t>
2768       Wait either for an error response from the server, or for T
2769         seconds (whichever comes first)
2770    </t>
2771    <t>
2772       If no error response is received, after T seconds transmit the
2773         body of the request.
2774    </t>
2775    <t>
2776       If client sees that the connection is closed prematurely,
2777         repeat from step 1 until the request is accepted, an error
2778         response is received, or the user becomes impatient and
2779         terminates the retry process.
2780    </t>
2781  </list>
2782</t>
2783<t>
2784   If at any point an error status is received, the client
2785  <list style="symbols">
2786      <t>&SHOULD-NOT;  continue and</t>
2787
2788      <t>&SHOULD; close the connection if it has not completed sending the
2789        request message.</t>
2790    </list>
2791</t>
2792</section>
2793</section>
2794</section>
2795
2796
2797<section title="Miscellaneous notes that may disappear" anchor="misc">
2798<section title="Scheme aliases considered harmful" anchor="scheme.aliases">
2799<t>
2800   <cref anchor="TBD-aliases-harmful">describe why aliases like webcal are harmful.</cref>
2801</t>
2802</section>
2803
2804<section title="Use of HTTP for proxy communication" anchor="http.proxy">
2805<t>
2806   <cref anchor="TBD-proxy-other">Configured to use HTTP to proxy HTTP or other protocols.</cref>
2807</t>
2808</section>
2809
2810<section title="Interception of HTTP for access control" anchor="http.intercept">
2811<t>
2812   <cref anchor="TBD-intercept">Interception of HTTP traffic for initiating access control.</cref>
2813</t>
2814</section>
2815
2816<section title="Use of HTTP by other protocols" anchor="http.others">
2817<t>
2818   <cref anchor="TBD-profiles">Profiles of HTTP defined by other protocol.
2819   Extensions of HTTP like WebDAV.</cref>
2820</t>
2821
2822</section>
2823<section title="Use of HTTP by media type specification" anchor="http.media">
2824<t>
2825   <cref anchor="TBD-hypertext">Instructions on composing HTTP requests via hypertext formats.</cref>
2826</t>
2827</section>
2828</section>
2829
2830<section title="Header Field Definitions" anchor="header.field.definitions">
2831<t>
2832   This section defines the syntax and semantics of HTTP/1.1 header fields
2833   related to message framing and transport protocols.
2834</t>
2835<t>
2836   For entity-header fields, both sender and recipient refer to either the
2837   client or the server, depending on who sends and who receives the message.
2838</t>
2839
2840<section title="Connection" anchor="header.connection">
2841  <iref primary="true" item="Connection header" x:for-anchor=""/>
2842  <iref primary="true" item="Headers" subitem="Connection" x:for-anchor=""/>
2843  <x:anchor-alias value="Connection"/>
2844  <x:anchor-alias value="connection-token"/>
2845  <x:anchor-alias value="Connection-v"/>
2846<t>
2847   The "Connection" general-header field allows the sender to specify
2848   options that are desired for that particular connection and &MUST-NOT;
2849   be communicated by proxies over further connections.
2850</t>
2851<t>
2852   The Connection header's value has the following grammar:
2853</t>
2854<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="Connection"/><iref primary="true" item="Grammar" subitem="Connection-v"/><iref primary="true" item="Grammar" subitem="connection-token"/>
2855  <x:ref>Connection</x:ref>       = "Connection" ":" <x:ref>OWS</x:ref> <x:ref>Connection-v</x:ref>
2856  <x:ref>Connection-v</x:ref>     = 1#<x:ref>connection-token</x:ref>
2857  <x:ref>connection-token</x:ref> = <x:ref>token</x:ref>
2858</artwork></figure>
2859<t>
2860   HTTP/1.1 proxies &MUST; parse the Connection header field before a
2861   message is forwarded and, for each connection-token in this field,
2862   remove any header field(s) from the message with the same name as the
2863   connection-token. Connection options are signaled by the presence of
2864   a connection-token in the Connection header field, not by any
2865   corresponding additional header field(s), since the additional header
2866   field may not be sent if there are no parameters associated with that
2867   connection option.
2868</t>
2869<t>
2870   Message headers listed in the Connection header &MUST-NOT; include
2871   end-to-end headers, such as Cache-Control.
2872</t>
2873<t>
2874   HTTP/1.1 defines the "close" connection option for the sender to
2875   signal that the connection will be closed after completion of the
2876   response. For example,
2877</t>
2878<figure><artwork type="example">
2879  Connection: close
2880</artwork></figure>
2881<t>
2882   in either the request or the response header fields indicates that
2883   the connection &SHOULD-NOT;  be considered "persistent" (<xref target="persistent.connections"/>)
2884   after the current request/response is complete.
2885</t>
2886<t>
2887   An HTTP/1.1 client that does not support persistent connections &MUST;
2888   include the "close" connection option in every request message.
2889</t>
2890<t>
2891   An HTTP/1.1 server that does not support persistent connections &MUST;
2892   include the "close" connection option in every response message that
2893   does not have a 1xx (Informational) status code.
2894</t>
2895<t>
2896   A system receiving an HTTP/1.0 (or lower-version) message that
2897   includes a Connection header &MUST;, for each connection-token in this
2898   field, remove and ignore any header field(s) from the message with
2899   the same name as the connection-token. This protects against mistaken
2900   forwarding of such header fields by pre-HTTP/1.1 proxies. See <xref target="compatibility.with.http.1.0.persistent.connections"/>.
2901</t>
2902</section>
2903
2904<section title="Content-Length" anchor="header.content-length">
2905  <iref primary="true" item="Content-Length header" x:for-anchor=""/>
2906  <iref primary="true" item="Headers" subitem="Content-Length" x:for-anchor=""/>
2907  <x:anchor-alias value="Content-Length"/>
2908  <x:anchor-alias value="Content-Length-v"/>
2909<t>
2910   The "Content-Length" header field indicates the size of the
2911   message-body, in decimal number of octets, for any message other than
2912   a response to the HEAD method or a response with a status code of 304.
2913   In the case of responses to the HEAD method, it indicates the size of
2914   the payload body (not including any potential transfer-coding) that
2915   would have been sent had the request been a GET.
2916   In the case of the 304 (Not Modified) response, it indicates the size of
2917   the payload body (not including any potential transfer-coding) that
2918   would have been sent in a 200 (OK) response.
2919</t>
2920<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="Content-Length"/><iref primary="true" item="Grammar" subitem="Content-Length-v"/>
2921  <x:ref>Content-Length</x:ref>   = "Content-Length" ":" <x:ref>OWS</x:ref> 1*<x:ref>Content-Length-v</x:ref>
2922  <x:ref>Content-Length-v</x:ref> = 1*<x:ref>DIGIT</x:ref>
2923</artwork></figure>
2924<t>
2925   An example is
2926</t>
2927<figure><artwork type="example">
2928  Content-Length: 3495
2929</artwork></figure>
2930<t>
2931   Implementations &SHOULD; use this field to indicate the message-body
2932   length when no transfer-coding is being applied and the
2933   payload's body length can be determined prior to being transferred.
2934   <xref target="message.body"/> describes how recipients determine the length
2935   of a message-body.
2936</t>
2937<t>
2938   Any Content-Length greater than or equal to zero is a valid value.
2939</t>
2940<t>
2941   Note that the use of this field in HTTP is significantly different from
2942   the corresponding definition in MIME, where it is an optional field
2943   used within the "message/external-body" content-type.
2944</t>
2945</section>
2946
2947<section title="Date" anchor="header.date">
2948  <iref primary="true" item="Date header" x:for-anchor=""/>
2949  <iref primary="true" item="Headers" subitem="Date" x:for-anchor=""/>
2950  <x:anchor-alias value="Date"/>
2951  <x:anchor-alias value="Date-v"/>
2952<t>
2953   The "Date" general-header field represents the date and time at which
2954   the message was originated, having the same semantics as the Origination
2955   Date Field (orig-date) defined in <xref target="RFC5322" x:fmt="of" x:sec="3.6.1"/>.
2956   The field value is an HTTP-date, as described in <xref target="date.time.formats.full.date"/>;
2957   it &MUST; be sent in rfc1123-date format.
2958</t>
2959<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="Date"/><iref primary="true" item="Grammar" subitem="Date-v"/>
2960  <x:ref>Date</x:ref>   = "Date" ":" <x:ref>OWS</x:ref> <x:ref>Date-v</x:ref>
2961  <x:ref>Date-v</x:ref> = <x:ref>HTTP-date</x:ref>
2962</artwork></figure>
2963<t>
2964   An example is
2965</t>
2966<figure><artwork type="example">
2967  Date: Tue, 15 Nov 1994 08:12:31 GMT
2968</artwork></figure>
2969<t>
2970   Origin servers &MUST; include a Date header field in all responses,
2971   except in these cases:
2972  <list style="numbers">
2973      <t>If the response status code is 100 (Continue) or 101 (Switching
2974         Protocols), the response &MAY; include a Date header field, at
2975         the server's option.</t>
2976
2977      <t>If the response status code conveys a server error, e.g., 500
2978         (Internal Server Error) or 503 (Service Unavailable), and it is
2979         inconvenient or impossible to generate a valid Date.</t>
2980
2981      <t>If the server does not have a clock that can provide a
2982         reasonable approximation of the current time, its responses
2983         &MUST-NOT; include a Date header field. In this case, the rules
2984         in <xref target="clockless.origin.server.operation"/> &MUST; be followed.</t>
2985  </list>
2986</t>
2987<t>
2988   A received message that does not have a Date header field &MUST; be
2989   assigned one by the recipient if the message will be cached by that
2990   recipient or gatewayed via a protocol which requires a Date. An HTTP
2991   implementation without a clock &MUST-NOT; cache responses without
2992   revalidating them on every use. An HTTP cache, especially a shared
2993   cache, &SHOULD; use a mechanism, such as NTP <xref target="RFC1305"/>, to synchronize its
2994   clock with a reliable external standard.
2995</t>
2996<t>
2997   Clients &SHOULD; only send a Date header field in messages that include
2998   a payload, as is usually the case for PUT and POST requests, and even
2999   then it is optional. A client without a clock &MUST-NOT; send a Date
3000   header field in a request.
3001</t>
3002<t>
3003   The HTTP-date sent in a Date header &SHOULD-NOT;  represent a date and
3004   time subsequent to the generation of the message. It &SHOULD; represent
3005   the best available approximation of the date and time of message
3006   generation, unless the implementation has no means of generating a
3007   reasonably accurate date and time. In theory, the date ought to
3008   represent the moment just before the payload is generated. In
3009   practice, the date can be generated at any time during the message
3010   origination without affecting its semantic value.
3011</t>
3012
3013<section title="Clockless Origin Server Operation" anchor="clockless.origin.server.operation">
3014<t>
3015   Some origin server implementations might not have a clock available.
3016   An origin server without a clock &MUST-NOT; assign Expires or Last-Modified
3017   values to a response, unless these values were associated
3018   with the resource by a system or user with a reliable clock. It &MAY;
3019   assign an Expires value that is known, at or before server
3020   configuration time, to be in the past (this allows "pre-expiration"
3021   of responses without storing separate Expires values for each
3022   resource).
3023</t>
3024</section>
3025</section>
3026
3027<section title="Host" anchor="header.host">
3028  <iref primary="true" item="Host header" x:for-anchor=""/>
3029  <iref primary="true" item="Headers" subitem="Host" x:for-anchor=""/>
3030  <x:anchor-alias value="Host"/>
3031  <x:anchor-alias value="Host-v"/>
3032<t>
3033   The "Host" request-header field specifies the Internet host and port
3034   number of the resource being requested, allowing the origin server or
3035   gateway to differentiate between internally-ambiguous URLs, such as the root
3036   "/" URL of a server for multiple host names on a single IP address.
3037</t>
3038<t>   
3039   The Host field value &MUST; represent the naming authority of the origin
3040   server or gateway given by the original URL obtained from the user or
3041   referring resource (generally an http URI, as described in
3042   <xref target="http.uri"/>).
3043</t>
3044<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="Host"/><iref primary="true" item="Grammar" subitem="Host-v"/>
3045  <x:ref>Host</x:ref>   = "Host" ":" <x:ref>OWS</x:ref> <x:ref>Host-v</x:ref>
3046  <x:ref>Host-v</x:ref> = <x:ref>uri-host</x:ref> [ ":" <x:ref>port</x:ref> ] ; <xref target="http.uri"/>
3047</artwork></figure>
3048<t>
3049   A "host" without any trailing port information implies the default
3050   port for the service requested (e.g., "80" for an HTTP URL). For
3051   example, a request on the origin server for
3052   &lt;http://www.example.org/pub/WWW/&gt; would properly include:
3053</t>
3054<figure><artwork type="message/http; msgtype=&#34;request&#34;" x:indent-with="  ">
3055GET /pub/WWW/ HTTP/1.1
3056Host: www.example.org
3057</artwork></figure>
3058<t>
3059   A client &MUST; include a Host header field in all HTTP/1.1 request
3060   messages. If the requested URI does not include an Internet host
3061   name for the service being requested, then the Host header field &MUST;
3062   be given with an empty value. An HTTP/1.1 proxy &MUST; ensure that any
3063   request message it forwards does contain an appropriate Host header
3064   field that identifies the service being requested by the proxy. All
3065   Internet-based HTTP/1.1 servers &MUST; respond with a 400 (Bad Request)
3066   status code to any HTTP/1.1 request message which lacks a Host header
3067   field.
3068</t>
3069<t>
3070   See Sections <xref target="the.resource.identified.by.a.request" format="counter"/>
3071   and <xref target="changes.to.simplify.multi-homed.web.servers.and.conserve.ip.addresses" format="counter"/>
3072   for other requirements relating to Host.
3073</t>
3074</section>
3075
3076<section title="TE" anchor="header.te">
3077  <iref primary="true" item="TE header" x:for-anchor=""/>
3078  <iref primary="true" item="Headers" subitem="TE" x:for-anchor=""/>
3079  <x:anchor-alias value="TE"/>
3080  <x:anchor-alias value="TE-v"/>
3081  <x:anchor-alias value="t-codings"/>
3082  <x:anchor-alias value="te-params"/>
3083  <x:anchor-alias value="te-ext"/>
3084<t>
3085   The "TE" request-header field indicates what extension transfer-codings
3086   it is willing to accept in the response, and whether or not it is
3087   willing to accept trailer fields in a chunked transfer-coding.
3088</t>
3089<t>
3090   Its value may consist of the keyword "trailers" and/or a comma-separated
3091   list of extension transfer-coding names with optional accept
3092   parameters (as described in <xref target="transfer.codings"/>).
3093</t>
3094<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="TE"/><iref primary="true" item="Grammar" subitem="TE-v"/><iref primary="true" item="Grammar" subitem="t-codings"/><iref primary="true" item="Grammar" subitem="te-params"/><iref primary="true" item="Grammar" subitem="te-ext"/>
3095  <x:ref>TE</x:ref>        = "TE" ":" <x:ref>OWS</x:ref> <x:ref>TE-v</x:ref>
3096  <x:ref>TE-v</x:ref>      = #<x:ref>t-codings</x:ref>
3097  <x:ref>t-codings</x:ref> = "trailers" / ( <x:ref>transfer-extension</x:ref> [ <x:ref>te-params</x:ref> ] )
3098  <x:ref>te-params</x:ref> = <x:ref>OWS</x:ref> ";" <x:ref>OWS</x:ref> "q=" <x:ref>qvalue</x:ref> *( <x:ref>te-ext</x:ref> )
3099  <x:ref>te-ext</x:ref>    = <x:ref>OWS</x:ref> ";" <x:ref>OWS</x:ref> <x:ref>token</x:ref> [ "=" <x:ref>word</x:ref> ]
3100</artwork></figure>
3101<t>
3102   The presence of the keyword "trailers" indicates that the client is
3103   willing to accept trailer fields in a chunked transfer-coding, as
3104   defined in <xref target="chunked.encoding"/>. This keyword is reserved for use with
3105   transfer-coding values even though it does not itself represent a
3106   transfer-coding.
3107</t>
3108<t>
3109   Examples of its use are:
3110</t>
3111<figure><artwork type="example">
3112  TE: deflate
3113  TE:
3114  TE: trailers, deflate;q=0.5
3115</artwork></figure>
3116<t>
3117   The TE header field only applies to the immediate connection.
3118   Therefore, the keyword &MUST; be supplied within a Connection header
3119   field (<xref target="header.connection"/>) whenever TE is present in an HTTP/1.1 message.
3120</t>
3121<t>
3122   A server tests whether a transfer-coding is acceptable, according to
3123   a TE field, using these rules:
3124  <list style="numbers">
3125    <x:lt>
3126      <t>The "chunked" transfer-coding is always acceptable. If the
3127         keyword "trailers" is listed, the client indicates that it is
3128         willing to accept trailer fields in the chunked response on
3129         behalf of itself and any downstream clients. The implication is
3130         that, if given, the client is stating that either all
3131         downstream clients are willing to accept trailer fields in the
3132         forwarded response, or that it will attempt to buffer the
3133         response on behalf of downstream recipients.
3134      </t><t>
3135         <x:h>Note:</x:h> HTTP/1.1 does not define any means to limit the size of a
3136         chunked response such that a client can be assured of buffering
3137         the entire response.</t>
3138    </x:lt>
3139    <x:lt>
3140      <t>If the transfer-coding being tested is one of the transfer-codings
3141         listed in the TE field, then it is acceptable unless it
3142         is accompanied by a qvalue of 0. (As defined in <xref target="quality.values"/>, a
3143         qvalue of 0 means "not acceptable.")</t>
3144    </x:lt>
3145    <x:lt>
3146      <t>If multiple transfer-codings are acceptable, then the
3147         acceptable transfer-coding with the highest non-zero qvalue is
3148         preferred.  The "chunked" transfer-coding always has a qvalue
3149         of 1.</t>
3150    </x:lt>
3151  </list>
3152</t>
3153<t>
3154   If the TE field-value is empty or if no TE field is present, the only
3155   transfer-coding is "chunked". A message with no transfer-coding is
3156   always acceptable.
3157</t>
3158</section>
3159
3160<section title="Trailer" anchor="header.trailer">
3161  <iref primary="true" item="Trailer header" x:for-anchor=""/>
3162  <iref primary="true" item="Headers" subitem="Trailer" x:for-anchor=""/>
3163  <x:anchor-alias value="Trailer"/>
3164  <x:anchor-alias value="Trailer-v"/>
3165<t>
3166   The "Trailer" general-header field indicates that the given set of
3167   header fields is present in the trailer of a message encoded with
3168   chunked transfer-coding.
3169</t>
3170<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="Trailer"/><iref primary="true" item="Grammar" subitem="Trailer-v"/>
3171  <x:ref>Trailer</x:ref>   = "Trailer" ":" <x:ref>OWS</x:ref> <x:ref>Trailer-v</x:ref>
3172  <x:ref>Trailer-v</x:ref> = 1#<x:ref>field-name</x:ref>
3173</artwork></figure>
3174<t>
3175   An HTTP/1.1 message &SHOULD; include a Trailer header field in a
3176   message using chunked transfer-coding with a non-empty trailer. Doing
3177   so allows the recipient to know which header fields to expect in the
3178   trailer.
3179</t>
3180<t>
3181   If no Trailer header field is present, the trailer &SHOULD-NOT;  include
3182   any header fields. See <xref target="chunked.encoding"/> for restrictions on the use of
3183   trailer fields in a "chunked" transfer-coding.
3184</t>
3185<t>
3186   Message header fields listed in the Trailer header field &MUST-NOT;
3187   include the following header fields:
3188  <list style="symbols">
3189    <t>Transfer-Encoding</t>
3190    <t>Content-Length</t>
3191    <t>Trailer</t>
3192  </list>
3193</t>
3194</section>
3195
3196<section title="Transfer-Encoding" anchor="header.transfer-encoding">
3197  <iref primary="true" item="Transfer-Encoding header" x:for-anchor=""/>
3198  <iref primary="true" item="Headers" subitem="Transfer-Encoding" x:for-anchor=""/>
3199  <x:anchor-alias value="Transfer-Encoding"/>
3200  <x:anchor-alias value="Transfer-Encoding-v"/>
3201<t>
3202   The "Transfer-Encoding" general-header field indicates what transfer-codings
3203   (if any) have been applied to the message body. It differs from
3204   Content-Encoding (&content-codings;) in that transfer-codings are a property
3205   of the message (and therefore are removed by intermediaries), whereas
3206   content-codings are not.
3207</t>
3208<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="Transfer-Encoding"/><iref primary="true" item="Grammar" subitem="Transfer-Encoding-v"/>
3209  <x:ref>Transfer-Encoding</x:ref>   = "Transfer-Encoding" ":" <x:ref>OWS</x:ref>
3210                        <x:ref>Transfer-Encoding-v</x:ref>
3211  <x:ref>Transfer-Encoding-v</x:ref> = 1#<x:ref>transfer-coding</x:ref>
3212</artwork></figure>
3213<t>
3214   Transfer-codings are defined in <xref target="transfer.codings"/>. An example is:
3215</t>
3216<figure><artwork type="example">
3217  Transfer-Encoding: chunked
3218</artwork></figure>
3219<t>
3220   If multiple encodings have been applied to a representation, the transfer-codings
3221   &MUST; be listed in the order in which they were applied.
3222   Additional information about the encoding parameters &MAY; be provided
3223   by other entity-header fields not defined by this specification.
3224</t>
3225<t>
3226   Many older HTTP/1.0 applications do not understand the Transfer-Encoding
3227   header.
3228</t>
3229</section>
3230
3231<section title="Upgrade" anchor="header.upgrade">
3232  <iref primary="true" item="Upgrade header" x:for-anchor=""/>
3233  <iref primary="true" item="Headers" subitem="Upgrade" x:for-anchor=""/>
3234  <x:anchor-alias value="Upgrade"/>
3235  <x:anchor-alias value="Upgrade-v"/>
3236<t>
3237   The "Upgrade" general-header field allows the client to specify what
3238   additional communication protocols it would like to use, if the server
3239   chooses to switch protocols. Additionally, the server &MUST; use the Upgrade
3240   header field within a 101 (Switching Protocols) response to indicate which
3241   protocol(s) are being switched to.
3242</t>
3243<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="Upgrade"/><iref primary="true" item="Grammar" subitem="Upgrade-v"/>
3244  <x:ref>Upgrade</x:ref>   = "Upgrade" ":" <x:ref>OWS</x:ref> <x:ref>Upgrade-v</x:ref>
3245  <x:ref>Upgrade-v</x:ref> = 1#<x:ref>product</x:ref>
3246</artwork></figure>
3247<t>
3248   For example,
3249</t>
3250<figure><artwork type="example">
3251  Upgrade: HTTP/2.0, SHTTP/1.3, IRC/6.9, RTA/x11
3252</artwork></figure>
3253<t>
3254   The Upgrade header field is intended to provide a simple mechanism
3255   for transition from HTTP/1.1 to some other, incompatible protocol. It
3256   does so by allowing the client to advertise its desire to use another
3257   protocol, such as a later version of HTTP with a higher major version
3258   number, even though the current request has been made using HTTP/1.1.
3259   This eases the difficult transition between incompatible protocols by
3260   allowing the client to initiate a request in the more commonly
3261   supported protocol while indicating to the server that it would like
3262   to use a "better" protocol if available (where "better" is determined
3263   by the server, possibly according to the nature of the method and/or
3264   resource being requested).
3265</t>
3266<t>
3267   The Upgrade header field only applies to switching application-layer
3268   protocols upon the existing transport-layer connection. Upgrade
3269   cannot be used to insist on a protocol change; its acceptance and use
3270   by the server is optional. The capabilities and nature of the
3271   application-layer communication after the protocol change is entirely
3272   dependent upon the new protocol chosen, although the first action
3273   after changing the protocol &MUST; be a response to the initial HTTP
3274   request containing the Upgrade header field.
3275</t>
3276<t>
3277   The Upgrade header field only applies to the immediate connection.
3278   Therefore, the upgrade keyword &MUST; be supplied within a Connection
3279   header field (<xref target="header.connection"/>) whenever Upgrade is present in an
3280   HTTP/1.1 message.
3281</t>
3282<t>
3283   The Upgrade header field cannot be used to indicate a switch to a
3284   protocol on a different connection. For that purpose, it is more
3285   appropriate to use a 301, 302, 303, or 305 redirection response.
3286</t>
3287<t>
3288   This specification only defines the protocol name "HTTP" for use by
3289   the family of Hypertext Transfer Protocols, as defined by the HTTP
3290   version rules of <xref target="http.version"/> and future updates to this
3291   specification. Additional tokens can be registered with IANA using the
3292   registration procedure defined below. 
3293</t>
3294
3295<section title="Upgrade Token Registry" anchor="upgrade.token.registry">
3296<t>
3297   The HTTP Upgrade Token Registry defines the name space for product
3298   tokens used to identify protocols in the Upgrade header field.
3299   Each registered token should be associated with one or a set of
3300   specifications, and with contact information.
3301</t>
3302<t>
3303   Registrations should be allowed on a First Come First Served basis as
3304   described in <xref target="RFC5226" x:sec="4.1" x:fmt="of"/>. These
3305   specifications need not be IETF documents or be subject to IESG review, but
3306   should obey the following rules:
3307  <list style="numbers">
3308    <t>A token, once registered, stays registered forever.</t>
3309    <t>The registration &MUST; name a responsible party for the
3310       registration.</t>
3311    <t>The registration &MUST; name a point of contact.</t>
3312    <t>The registration &MAY; name the documentation required for the
3313       token.</t>
3314    <t>The responsible party &MAY; change the registration at any time.
3315       The IANA will keep a record of all such changes, and make them
3316       available upon request.</t>
3317    <t>The responsible party for the first registration of a "product"
3318       token &MUST; approve later registrations of a "version" token
3319       together with that "product" token before they can be registered.</t>
3320    <t>If absolutely required, the IESG &MAY; reassign the responsibility
3321       for a token. This will normally only be used in the case when a
3322       responsible party cannot be contacted.</t>
3323  </list>
3324</t>
3325<t>
3326   It is not required that specifications for upgrade tokens be made
3327   publicly available, but the contact information for the registration
3328   should be.
3329</t>
3330</section>
3331
3332
3333</section>
3334
3335<section title="Via" anchor="header.via">
3336  <iref primary="true" item="Via header" x:for-anchor=""/>
3337  <iref primary="true" item="Headers" subitem="Via" x:for-anchor=""/>
3338  <x:anchor-alias value="protocol-name"/>
3339  <x:anchor-alias value="protocol-version"/>
3340  <x:anchor-alias value="pseudonym"/>
3341  <x:anchor-alias value="received-by"/>
3342  <x:anchor-alias value="received-protocol"/>
3343  <x:anchor-alias value="Via"/>
3344  <x:anchor-alias value="Via-v"/>
3345<t>
3346   The "Via" general-header field &MUST; be used by gateways and proxies to
3347   indicate the intermediate protocols and recipients between the user
3348   agent and the server on requests, and between the origin server and
3349   the client on responses. It is analogous to the "Received" field defined in
3350   <xref target="RFC5322" x:fmt="of" x:sec="3.6.7"/> and is intended to be used for tracking message forwards,
3351   avoiding request loops, and identifying the protocol capabilities of
3352   all senders along the request/response chain.
3353</t>
3354<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="Via"/><iref primary="true" item="Grammar" subitem="Via-v"/><iref primary="true" item="Grammar" subitem="received-protocol"/><iref primary="true" item="Grammar" subitem="protocol-name"/><iref primary="true" item="Grammar" subitem="protocol-version"/><iref primary="true" item="Grammar" subitem="received-by"/><iref primary="true" item="Grammar" subitem="pseudonym"/>
3355  <x:ref>Via</x:ref>               = "Via" ":" <x:ref>OWS</x:ref> <x:ref>Via-v</x:ref>
3356  <x:ref>Via-v</x:ref>             = 1#( <x:ref>received-protocol</x:ref> <x:ref>RWS</x:ref> <x:ref>received-by</x:ref>
3357                          [ <x:ref>RWS</x:ref> <x:ref>comment</x:ref> ] )
3358  <x:ref>received-protocol</x:ref> = [ <x:ref>protocol-name</x:ref> "/" ] <x:ref>protocol-version</x:ref>
3359  <x:ref>protocol-name</x:ref>     = <x:ref>token</x:ref>
3360  <x:ref>protocol-version</x:ref>  = <x:ref>token</x:ref>
3361  <x:ref>received-by</x:ref>       = ( <x:ref>uri-host</x:ref> [ ":" <x:ref>port</x:ref> ] ) / <x:ref>pseudonym</x:ref>
3362  <x:ref>pseudonym</x:ref>         = <x:ref>token</x:ref>
3363</artwork></figure>
3364<t>
3365   The received-protocol indicates the protocol version of the message
3366   received by the server or client along each segment of the
3367   request/response chain. The received-protocol version is appended to
3368   the Via field value when the message is forwarded so that information
3369   about the protocol capabilities of upstream applications remains
3370   visible to all recipients.
3371</t>
3372<t>
3373   The protocol-name is optional if and only if it would be "HTTP". The
3374   received-by field is normally the host and optional port number of a
3375   recipient server or client that subsequently forwarded the message.
3376   However, if the real host is considered to be sensitive information,
3377   it &MAY; be replaced by a pseudonym. If the port is not given, it &MAY;
3378   be assumed to be the default port of the received-protocol.
3379</t>
3380<t>
3381   Multiple Via field values represent each proxy or gateway that has
3382   forwarded the message. Each recipient &MUST; append its information
3383   such that the end result is ordered according to the sequence of
3384   forwarding applications.
3385</t>
3386<t>
3387   Comments &MAY; be used in the Via header field to identify the software
3388   of the recipient proxy or gateway, analogous to the User-Agent and
3389   Server header fields. However, all comments in the Via field are
3390   optional and &MAY; be removed by any recipient prior to forwarding the
3391   message.
3392</t>
3393<t>
3394   For example, a request message could be sent from an HTTP/1.0 user
3395   agent to an internal proxy code-named "fred", which uses HTTP/1.1 to
3396   forward the request to a public proxy at p.example.net, which completes
3397   the request by forwarding it to the origin server at www.example.com.
3398   The request received by www.example.com would then have the following
3399   Via header field:
3400</t>
3401<figure><artwork type="example">
3402  Via: 1.0 fred, 1.1 p.example.net (Apache/1.1)
3403</artwork></figure>
3404<t>
3405   Proxies and gateways used as a portal through a network firewall
3406   &SHOULD-NOT;, by default, forward the names and ports of hosts within
3407   the firewall region. This information &SHOULD; only be propagated if
3408   explicitly enabled. If not enabled, the received-by host of any host
3409   behind the firewall &SHOULD; be replaced by an appropriate pseudonym
3410   for that host.
3411</t>
3412<t>
3413   For organizations that have strong privacy requirements for hiding
3414   internal structures, a proxy &MAY; combine an ordered subsequence of
3415   Via header field entries with identical received-protocol values into
3416   a single such entry. For example,
3417</t>
3418<figure><artwork type="example">
3419  Via: 1.0 ricky, 1.1 ethel, 1.1 fred, 1.0 lucy
3420</artwork></figure>
3421<t>
3422  could be collapsed to
3423</t>
3424<figure><artwork type="example">
3425  Via: 1.0 ricky, 1.1 mertz, 1.0 lucy
3426</artwork></figure>
3427<t>
3428   Applications &SHOULD-NOT;  combine multiple entries unless they are all
3429   under the same organizational control and the hosts have already been
3430   replaced by pseudonyms. Applications &MUST-NOT; combine entries which
3431   have different received-protocol values.
3432</t>
3433</section>
3434
3435</section>
3436
3437<section title="IANA Considerations" anchor="IANA.considerations">
3438
3439<section title="Message Header Registration" anchor="message.header.registration">
3440<t>
3441   The Message Header Registry located at <eref target="http://www.iana.org/assignments/message-headers/message-header-index.html"/> should be updated
3442   with the permanent registrations below (see <xref target="RFC3864"/>):
3443</t>
3444<?BEGININC p1-messaging.iana-headers ?>
3445<!--AUTOGENERATED FROM extract-header-defs.xslt, do not edit manually-->
3446<texttable align="left" suppress-title="true" anchor="iana.header.registration.table">
3447   <ttcol>Header Field Name</ttcol>
3448   <ttcol>Protocol</ttcol>
3449   <ttcol>Status</ttcol>
3450   <ttcol>Reference</ttcol>
3451
3452   <c>Connection</c>
3453   <c>http</c>
3454   <c>standard</c>
3455   <c>
3456      <xref target="header.connection"/>
3457   </c>
3458   <c>Content-Length</c>
3459   <c>http</c>
3460   <c>standard</c>
3461   <c>
3462      <xref target="header.content-length"/>
3463   </c>
3464   <c>Date</c>
3465   <c>http</c>
3466   <c>standard</c>
3467   <c>
3468      <xref target="header.date"/>
3469   </c>
3470   <c>Host</c>
3471   <c>http</c>
3472   <c>standard</c>
3473   <c>
3474      <xref target="header.host"/>
3475   </c>
3476   <c>TE</c>
3477   <c>http</c>
3478   <c>standard</c>
3479   <c>
3480      <xref target="header.te"/>
3481   </c>
3482   <c>Trailer</c>
3483   <c>http</c>
3484   <c>standard</c>
3485   <c>
3486      <xref target="header.trailer"/>
3487   </c>
3488   <c>Transfer-Encoding</c>
3489   <c>http</c>
3490   <c>standard</c>
3491   <c>
3492      <xref target="header.transfer-encoding"/>
3493   </c>
3494   <c>Upgrade</c>
3495   <c>http</c>
3496   <c>standard</c>
3497   <c>
3498      <xref target="header.upgrade"/>
3499   </c>
3500   <c>Via</c>
3501   <c>http</c>
3502   <c>standard</c>
3503   <c>
3504      <xref target="header.via"/>
3505   </c>
3506</texttable>
3507<!--(END)-->
3508<?ENDINC p1-messaging.iana-headers ?>
3509<t>
3510   The change controller is: "IETF (iesg@ietf.org) - Internet Engineering Task Force".
3511</t>
3512</section>
3513
3514<section title="URI Scheme Registration" anchor="uri.scheme.registration">
3515<t>
3516   The entries for the "http" and "https" URI Schemes in the registry located at
3517   <eref target="http://www.iana.org/assignments/uri-schemes.html"/>
3518   should be updated to point to Sections <xref target="http.uri" format="counter"/>
3519   and <xref target="https.uri" format="counter"/> of this document
3520   (see <xref target="RFC4395"/>).
3521</t>
3522</section>
3523
3524<section title="Internet Media Type Registrations" anchor="internet.media.type.http">
3525<t>
3526   This document serves as the specification for the Internet media types
3527   "message/http" and "application/http". The following is to be registered with
3528   IANA (see <xref target="RFC4288"/>).
3529</t>
3530<section title="Internet Media Type message/http" anchor="internet.media.type.message.http">
3531<iref item="Media Type" subitem="message/http" primary="true"/>
3532<iref item="message/http Media Type" primary="true"/>
3533<t>
3534   The message/http type can be used to enclose a single HTTP request or
3535   response message, provided that it obeys the MIME restrictions for all
3536   "message" types regarding line length and encodings.
3537</t>
3538<t>
3539  <list style="hanging" x:indent="12em">
3540    <t hangText="Type name:">
3541      message
3542    </t>
3543    <t hangText="Subtype name:">
3544      http
3545    </t>
3546    <t hangText="Required parameters:">
3547      none
3548    </t>
3549    <t hangText="Optional parameters:">
3550      version, msgtype
3551      <list style="hanging">
3552        <t hangText="version:">
3553          The HTTP-Version number of the enclosed message
3554          (e.g., "1.1"). If not present, the version can be
3555          determined from the first line of the body.
3556        </t>
3557        <t hangText="msgtype:">
3558          The message type -- "request" or "response". If not
3559          present, the type can be determined from the first
3560          line of the body.
3561        </t>
3562      </list>
3563    </t>
3564    <t hangText="Encoding considerations:">
3565      only "7bit", "8bit", or "binary" are permitted
3566    </t>
3567    <t hangText="Security considerations:">
3568      none
3569    </t>
3570    <t hangText="Interoperability considerations:">
3571      none
3572    </t>
3573    <t hangText="Published specification:">
3574      This specification (see <xref target="internet.media.type.message.http"/>).
3575    </t>
3576    <t hangText="Applications that use this media type:">
3577    </t>
3578    <t hangText="Additional information:">
3579      <list style="hanging">
3580        <t hangText="Magic number(s):">none</t>
3581        <t hangText="File extension(s):">none</t>
3582        <t hangText="Macintosh file type code(s):">none</t>
3583      </list>
3584    </t>
3585    <t hangText="Person and email address to contact for further information:">
3586      See Authors Section.
3587    </t>
3588    <t hangText="Intended usage:">
3589      COMMON
3590    </t>
3591    <t hangText="Restrictions on usage:">
3592      none
3593    </t>
3594    <t hangText="Author/Change controller:">
3595      IESG
3596    </t>
3597  </list>
3598</t>
3599</section>
3600<section title="Internet Media Type application/http" anchor="internet.media.type.application.http">
3601<iref item="Media Type" subitem="application/http" primary="true"/>
3602<iref item="application/http Media Type" primary="true"/>
3603<t>
3604   The application/http type can be used to enclose a pipeline of one or more
3605   HTTP request or response messages (not intermixed).
3606</t>
3607<t>
3608  <list style="hanging" x:indent="12em">
3609    <t hangText="Type name:">
3610      application
3611    </t>
3612    <t hangText="Subtype name:">
3613      http
3614    </t>
3615    <t hangText="Required parameters:">
3616      none
3617    </t>
3618    <t hangText="Optional parameters:">
3619      version, msgtype
3620      <list style="hanging">
3621        <t hangText="version:">
3622          The HTTP-Version number of the enclosed messages
3623          (e.g., "1.1"). If not present, the version can be
3624          determined from the first line of the body.
3625        </t>
3626        <t hangText="msgtype:">
3627          The message type -- "request" or "response". If not
3628          present, the type can be determined from the first
3629          line of the body.
3630        </t>
3631      </list>
3632    </t>
3633    <t hangText="Encoding considerations:">
3634      HTTP messages enclosed by this type
3635      are in "binary" format; use of an appropriate
3636      Content-Transfer-Encoding is required when
3637      transmitted via E-mail.
3638    </t>
3639    <t hangText="Security considerations:">
3640      none
3641    </t>
3642    <t hangText="Interoperability considerations:">
3643      none
3644    </t>
3645    <t hangText="Published specification:">
3646      This specification (see <xref target="internet.media.type.application.http"/>).
3647    </t>
3648    <t hangText="Applications that use this media type:">
3649    </t>
3650    <t hangText="Additional information:">
3651      <list style="hanging">
3652        <t hangText="Magic number(s):">none</t>
3653        <t hangText="File extension(s):">none</t>
3654        <t hangText="Macintosh file type code(s):">none</t>
3655      </list>
3656    </t>
3657    <t hangText="Person and email address to contact for further information:">
3658      See Authors Section.
3659    </t>
3660    <t hangText="Intended usage:">
3661      COMMON
3662    </t>
3663    <t hangText="Restrictions on usage:">
3664      none
3665    </t>
3666    <t hangText="Author/Change controller:">
3667      IESG
3668    </t>
3669  </list>
3670</t>
3671</section>
3672</section>
3673
3674<section title="Transfer Coding Registry" anchor="transfer.coding.registration">
3675<t>
3676   The registration procedure for HTTP Transfer Codings is now defined by
3677   <xref target="transfer.coding.registry"/> of this document.
3678</t>
3679<t>
3680   The HTTP Transfer Codings Registry located at <eref target="http://www.iana.org/assignments/http-parameters"/>
3681   should be updated with the registrations below:
3682</t>
3683<texttable align="left" suppress-title="true" anchor="iana.transfer.coding.registration.table">
3684   <ttcol>Name</ttcol>
3685   <ttcol>Description</ttcol>
3686   <ttcol>Reference</ttcol>
3687   <c>chunked</c>
3688   <c>Transfer in a series of chunks</c>
3689   <c>
3690      <xref target="chunked.encoding"/>
3691   </c>
3692   <c>compress</c>
3693   <c>UNIX "compress" program method</c>
3694   <c>
3695      <xref target="compress.coding"/>
3696   </c>
3697   <c>deflate</c>
3698   <c>"deflate" compression mechanism (<xref target="RFC1951"/>) used inside
3699   the "zlib" data format (<xref target="RFC1950"/>)
3700   </c>
3701   <c>
3702      <xref target="deflate.coding"/>
3703   </c>
3704   <c>gzip</c>
3705   <c>Same as GNU zip <xref target="RFC1952"/></c>
3706   <c>
3707      <xref target="gzip.coding"/>
3708   </c>
3709</texttable>
3710</section>
3711
3712<section title="Upgrade Token Registration" anchor="upgrade.token.registration">
3713<t>
3714   The registration procedure for HTTP Upgrade Tokens -- previously defined
3715   in <xref target="RFC2817" x:fmt="of" x:sec="7.2"/> -- is now defined
3716   by <xref target="upgrade.token.registry"/> of this document.
3717</t>
3718<t>
3719   The HTTP Status Code Registry located at <eref target="http://www.iana.org/assignments/http-upgrade-tokens/"/>
3720   should be updated with the registration below:
3721</t>
3722<texttable align="left" suppress-title="true">
3723   <ttcol>Value</ttcol>
3724   <ttcol>Description</ttcol>
3725   <ttcol>Reference</ttcol>
3726
3727   <c>HTTP</c>
3728   <c>Hypertext Transfer Protocol</c> 
3729   <c><xref target="http.version"/> of this specification</c>
3730<!-- IANA should add this without our instructions; emailed on June 05, 2009
3731   <c>TLS/1.0</c>
3732   <c>Transport Layer Security</c>
3733   <c><xref target="RFC2817"/></c> -->
3734
3735</texttable>
3736</section>
3737
3738</section>
3739
3740<section title="Security Considerations" anchor="security.considerations">
3741<t>
3742   This section is meant to inform application developers, information
3743   providers, and users of the security limitations in HTTP/1.1 as
3744   described by this document. The discussion does not include
3745   definitive solutions to the problems revealed, though it does make
3746   some suggestions for reducing security risks.
3747</t>
3748
3749<section title="Personal Information" anchor="personal.information">
3750<t>
3751   HTTP clients are often privy to large amounts of personal information
3752   (e.g., the user's name, location, mail address, passwords, encryption
3753   keys, etc.), and &SHOULD; be very careful to prevent unintentional
3754   leakage of this information.
3755   We very strongly recommend that a convenient interface be provided
3756   for the user to control dissemination of such information, and that
3757   designers and implementors be particularly careful in this area.
3758   History shows that errors in this area often create serious security
3759   and/or privacy problems and generate highly adverse publicity for the
3760   implementor's company.
3761</t>
3762</section>
3763
3764<section title="Abuse of Server Log Information" anchor="abuse.of.server.log.information">
3765<t>
3766   A server is in the position to save personal data about a user's
3767   requests which might identify their reading patterns or subjects of
3768   interest. This information is clearly confidential in nature and its
3769   handling can be constrained by law in certain countries. People using
3770   HTTP to provide data are responsible for ensuring that
3771   such material is not distributed without the permission of any
3772   individuals that are identifiable by the published results.
3773</t>
3774</section>
3775
3776<section title="Attacks Based On File and Path Names" anchor="attack.pathname">
3777<t>
3778   Implementations of HTTP origin servers &SHOULD; be careful to restrict
3779   the documents returned by HTTP requests to be only those that were
3780   intended by the server administrators. If an HTTP server translates
3781   HTTP URIs directly into file system calls, the server &MUST; take
3782   special care not to serve files that were not intended to be
3783   delivered to HTTP clients. For example, UNIX, Microsoft Windows, and
3784   other operating systems use ".." as a path component to indicate a
3785   directory level above the current one. On such a system, an HTTP
3786   server &MUST; disallow any such construct in the request-target if it
3787   would otherwise allow access to a resource outside those intended to
3788   be accessible via the HTTP server. Similarly, files intended for
3789   reference only internally to the server (such as access control
3790   files, configuration files, and script code) &MUST; be protected from
3791   inappropriate retrieval, since they might contain sensitive
3792   information. Experience has shown that minor bugs in such HTTP server
3793   implementations have turned into security risks.
3794</t>
3795</section>
3796
3797<section title="DNS Spoofing" anchor="dns.spoofing">
3798<t>
3799   Clients using HTTP rely heavily on the Domain Name Service, and are
3800   thus generally prone to security attacks based on the deliberate
3801   mis-association of IP addresses and DNS names. Clients need to be
3802   cautious in assuming the continuing validity of an IP number/DNS name
3803   association.
3804</t>
3805<t>
3806   In particular, HTTP clients &SHOULD; rely on their name resolver for
3807   confirmation of an IP number/DNS name association, rather than
3808   caching the result of previous host name lookups. Many platforms
3809   already can cache host name lookups locally when appropriate, and
3810   they &SHOULD; be configured to do so. It is proper for these lookups to
3811   be cached, however, only when the TTL (Time To Live) information
3812   reported by the name server makes it likely that the cached
3813   information will remain useful.
3814</t>
3815<t>
3816   If HTTP clients cache the results of host name lookups in order to
3817   achieve a performance improvement, they &MUST; observe the TTL
3818   information reported by DNS.
3819</t>
3820<t>
3821   If HTTP clients do not observe this rule, they could be spoofed when
3822   a previously-accessed server's IP address changes. As network
3823   renumbering is expected to become increasingly common <xref target="RFC1900"/>, the
3824   possibility of this form of attack will grow. Observing this
3825   requirement thus reduces this potential security vulnerability.
3826</t>
3827<t>
3828   This requirement also improves the load-balancing behavior of clients
3829   for replicated servers using the same DNS name and reduces the
3830   likelihood of a user's experiencing failure in accessing sites which
3831   use that strategy.
3832</t>
3833</section>
3834
3835<section title="Proxies and Caching" anchor="attack.proxies">
3836<t>
3837   By their very nature, HTTP proxies are men-in-the-middle, and
3838   represent an opportunity for man-in-the-middle attacks. Compromise of
3839   the systems on which the proxies run can result in serious security
3840   and privacy problems. Proxies have access to security-related
3841   information, personal information about individual users and
3842   organizations, and proprietary information belonging to users and
3843   content providers. A compromised proxy, or a proxy implemented or
3844   configured without regard to security and privacy considerations,
3845   might be used in the commission of a wide range of potential attacks.
3846</t>
3847<t>
3848   Proxy operators should protect the systems on which proxies run as
3849   they would protect any system that contains or transports sensitive
3850   information. In particular, log information gathered at proxies often
3851   contains highly sensitive personal information, and/or information
3852   about organizations. Log information should be carefully guarded, and
3853   appropriate guidelines for use should be developed and followed.
3854   (<xref target="abuse.of.server.log.information"/>).
3855</t>
3856<t>
3857   Proxy implementors should consider the privacy and security
3858   implications of their design and coding decisions, and of the
3859   configuration options they provide to proxy operators (especially the
3860   default configuration).
3861</t>
3862<t>
3863   Users of a proxy need to be aware that proxies are no trustworthier than
3864   the people who run them; HTTP itself cannot solve this problem.
3865</t>
3866<t>
3867   The judicious use of cryptography, when appropriate, may suffice to
3868   protect against a broad range of security and privacy attacks. Such
3869   cryptography is beyond the scope of the HTTP/1.1 specification.
3870</t>
3871</section>
3872
3873<section title="Denial of Service Attacks on Proxies" anchor="attack.DoS">
3874<t>
3875   They exist. They are hard to defend against. Research continues.
3876   Beware.
3877</t>
3878</section>
3879</section>
3880
3881<section title="Acknowledgments" anchor="ack">
3882<t>
3883   HTTP has evolved considerably over the years. It has
3884   benefited from a large and active developer community--the many
3885   people who have participated on the www-talk mailing list--and it is
3886   that community which has been most responsible for the success of
3887   HTTP and of the World-Wide Web in general. Marc Andreessen, Robert
3888   Cailliau, Daniel W. Connolly, Bob Denny, John Franks, Jean-Francois
3889   Groff, Phillip M. Hallam-Baker, Hakon W. Lie, Ari Luotonen, Rob
3890   McCool, Lou Montulli, Dave Raggett, Tony Sanders, and Marc
3891   VanHeyningen deserve special recognition for their efforts in
3892   defining early aspects of the protocol.
3893</t>
3894<t>
3895   This document has benefited greatly from the comments of all those
3896   participating in the HTTP-WG. In addition to those already mentioned,
3897   the following individuals have contributed to this specification:
3898</t>
3899<t>
3900   Gary Adams, Harald Tveit Alvestrand, Keith Ball, Brian Behlendorf,
3901   Paul Burchard, Maurizio Codogno, Josh Cohen, Mike Cowlishaw, Roman Czyborra,
3902   Michael A. Dolan, Daniel DuBois, David J. Fiander, Alan Freier, Marc Hedlund, Greg Herlihy,
3903   Koen Holtman, Alex Hopmann, Bob Jernigan, Shel Kaphan, Rohit Khare,
3904   John Klensin, Martijn Koster, Alexei Kosut, David M. Kristol,
3905   Daniel LaLiberte, Ben Laurie, Paul J. Leach, Albert Lunde,
3906   John C. Mallery, Jean-Philippe Martin-Flatin, Mitra, David Morris,
3907   Gavin Nicol, Ross Patterson, Bill Perry, Jeffrey Perry, Scott Powers, Owen Rees,
3908   Luigi Rizzo, David Robinson, Marc Salomon, Rich Salz,
3909   Allan M. Schiffman, Jim Seidman, Chuck Shotton, Eric W. Sink,
3910   Simon E. Spero, Richard N. Taylor, Robert S. Thau,
3911   Bill (BearHeart) Weinman, Francois Yergeau, Mary Ellen Zurko.
3912</t>
3913<t>
3914   Thanks to the "cave men" of Palo Alto. You know who you are.
3915</t>
3916<t>
3917   Jim Gettys (the editor of <xref target="RFC2616"/>) wishes particularly
3918   to thank Roy Fielding, the editor of <xref target="RFC2068"/>, along
3919   with John Klensin, Jeff Mogul, Paul Leach, Dave Kristol, Koen
3920   Holtman, John Franks, Josh Cohen, Alex Hopmann, Scott Lawrence, and
3921   Larry Masinter for their help. And thanks go particularly to Jeff
3922   Mogul and Scott Lawrence for performing the "MUST/MAY/SHOULD" audit.
3923</t>
3924<t>
3925   The Apache Group, Anselm Baird-Smith, author of Jigsaw, and Henrik
3926   Frystyk implemented RFC 2068 early, and we wish to thank them for the
3927   discovery of many of the problems that this document attempts to
3928   rectify.
3929</t>
3930<t>
3931   This specification makes heavy use of the augmented BNF and generic
3932   constructs defined by David H. Crocker for <xref target="RFC5234"/>. Similarly, it
3933   reuses many of the definitions provided by Nathaniel Borenstein and
3934   Ned Freed for MIME <xref target="RFC2045"/>. We hope that their inclusion in this
3935   specification will help reduce past confusion over the relationship
3936   between HTTP and Internet mail message formats.
3937</t>
3938</section>
3939
3940</middle>
3941<back>
3942
3943<references title="Normative References">
3944
3945<reference anchor="ISO-8859-1">
3946  <front>
3947    <title>
3948     Information technology -- 8-bit single-byte coded graphic character sets -- Part 1: Latin alphabet No. 1
3949    </title>
3950    <author>
3951      <organization>International Organization for Standardization</organization>
3952    </author>
3953    <date year="1998"/>
3954  </front>
3955  <seriesInfo name="ISO/IEC" value="8859-1:1998"/>
3956</reference>
3957
3958<reference anchor="Part2">
3959  <front>
3960    <title abbrev="HTTP/1.1">HTTP/1.1, part 2: Message Semantics</title>
3961    <author initials="R." surname="Fielding" fullname="Roy T. Fielding" role="editor">
3962      <organization abbrev="Day Software">Day Software</organization>
3963      <address><email>fielding@gbiv.com</email></address>
3964    </author>
3965    <author initials="J." surname="Gettys" fullname="Jim Gettys">
3966      <organization abbrev="Alcatel-Lucent">Alcatel-Lucent Bell Labs</organization>
3967      <address><email>jg@freedesktop.org</email></address>
3968    </author>
3969    <author initials="J." surname="Mogul" fullname="Jeffrey C. Mogul">
3970      <organization abbrev="HP">Hewlett-Packard Company</organization>
3971      <address><email>JeffMogul@acm.org</email></address>
3972    </author>
3973    <author initials="H." surname="Frystyk" fullname="Henrik Frystyk Nielsen">
3974      <organization abbrev="Microsoft">Microsoft Corporation</organization>
3975      <address><email>henrikn@microsoft.com</email></address>
3976    </author>
3977    <author initials="L." surname="Masinter" fullname="Larry Masinter">
3978      <organization abbrev="Adobe Systems">Adobe Systems, Incorporated</organization>
3979      <address><email>LMM@acm.org</email></address>
3980    </author>
3981    <author initials="P." surname="Leach" fullname="Paul J. Leach">
3982      <organization abbrev="Microsoft">Microsoft Corporation</organization>
3983      <address><email>paulle@microsoft.com</email></address>
3984    </author>
3985    <author initials="T." surname="Berners-Lee" fullname="Tim Berners-Lee">
3986      <organization abbrev="W3C/MIT">World Wide Web Consortium</organization>
3987      <address><email>timbl@w3.org</email></address>
3988    </author>
3989    <author initials="Y." surname="Lafon" fullname="Yves Lafon" role="editor">
3990      <organization abbrev="W3C">World Wide Web Consortium</organization>
3991      <address><email>ylafon@w3.org</email></address>
3992    </author>
3993    <author initials="J. F." surname="Reschke" fullname="Julian F. Reschke" role="editor">
3994      <organization abbrev="greenbytes">greenbytes GmbH</organization>
3995      <address><email>julian.reschke@greenbytes.de</email></address>
3996    </author>
3997    <date month="&ID-MONTH;" year="&ID-YEAR;"/>
3998  </front>
3999  <seriesInfo name="Internet-Draft" value="draft-ietf-httpbis-p2-semantics-&ID-VERSION;"/>
4000  <x:source href="p2-semantics.xml" basename="p2-semantics"/>
4001</reference>
4002
4003<reference anchor="Part3">
4004  <front>
4005    <title abbrev="HTTP/1.1">HTTP/1.1, part 3: Message Payload and Content Negotiation</title>
4006    <author initials="R." surname="Fielding" fullname="Roy T. Fielding" role="editor">
4007      <organization abbrev="Day Software">Day Software</organization>
4008      <address><email>fielding@gbiv.com</email></address>
4009    </author>
4010    <author initials="J." surname="Gettys" fullname="Jim Gettys">
4011      <organization abbrev="Alcatel-Lucent">Alcatel-Lucent Bell Labs</organization>
4012      <address><email>jg@freedesktop.org</email></address>
4013    </author>
4014    <author initials="J." surname="Mogul" fullname="Jeffrey C. Mogul">
4015      <organization abbrev="HP">Hewlett-Packard Company</organization>
4016      <address><email>JeffMogul@acm.org</email></address>
4017    </author>
4018    <author initials="H." surname="Frystyk" fullname="Henrik Frystyk Nielsen">
4019      <organization abbrev="Microsoft">Microsoft Corporation</organization>
4020      <address><email>henrikn@microsoft.com</email></address>
4021    </author>
4022    <author initials="L." surname="Masinter" fullname="Larry Masinter">
4023      <organization abbrev="Adobe Systems">Adobe Systems, Incorporated</organization>
4024      <address><email>LMM@acm.org</email></address>
4025    </author>
4026    <author initials="P." surname="Leach" fullname="Paul J. Leach">
4027      <organization abbrev="Microsoft">Microsoft Corporation</organization>
4028      <address><email>paulle@microsoft.com</email></address>
4029    </author>
4030    <author initials="T." surname="Berners-Lee" fullname="Tim Berners-Lee">
4031      <organization abbrev="W3C/MIT">World Wide Web Consortium</organization>
4032      <address><email>timbl@w3.org</email></address>
4033    </author>
4034    <author initials="Y." surname="Lafon" fullname="Yves Lafon" role="editor">
4035      <organization abbrev="W3C">World Wide Web Consortium</organization>
4036      <address><email>ylafon@w3.org</email></address>
4037    </author>
4038    <author initials="J. F." surname="Reschke" fullname="Julian F. Reschke" role="editor">
4039      <organization abbrev="greenbytes">greenbytes GmbH</organization>
4040      <address><email>julian.reschke@greenbytes.de</email></address>
4041    </author>
4042    <date month="&ID-MONTH;" year="&ID-YEAR;"/>
4043  </front>
4044  <seriesInfo name="Internet-Draft" value="draft-ietf-httpbis-p3-payload-&ID-VERSION;"/>
4045  <x:source href="p3-payload.xml" basename="p3-payload"/>
4046</reference>
4047
4048<reference anchor="Part5">
4049  <front>
4050    <title abbrev="HTTP/1.1">HTTP/1.1, part 5: Range Requests and Partial Responses</title>
4051    <author initials="R." surname="Fielding" fullname="Roy T. Fielding" role="editor">
4052      <organization abbrev="Day Software">Day Software</organization>
4053      <address><email>fielding@gbiv.com</email></address>
4054    </author>
4055    <author initials="J." surname="Gettys" fullname="Jim Gettys">
4056      <organization abbrev="Alcatel-Lucent">Alcatel-Lucent Bell Labs</organization>
4057      <address><email>jg@freedesktop.org</email></address>
4058    </author>
4059    <author initials="J." surname="Mogul" fullname="Jeffrey C. Mogul">
4060      <organization abbrev="HP">Hewlett-Packard Company</organization>
4061      <address><email>JeffMogul@acm.org</email></address>
4062    </author>
4063    <author initials="H." surname="Frystyk" fullname="Henrik Frystyk Nielsen">
4064      <organization abbrev="Microsoft">Microsoft Corporation</organization>
4065      <address><email>henrikn@microsoft.com</email></address>
4066    </author>
4067    <author initials="L." surname="Masinter" fullname="Larry Masinter">
4068      <organization abbrev="Adobe Systems">Adobe Systems, Incorporated</organization>
4069      <address><email>LMM@acm.org</email></address>
4070    </author>
4071    <author initials="P." surname="Leach" fullname="Paul J. Leach">
4072      <organization abbrev="Microsoft">Microsoft Corporation</organization>
4073      <address><email>paulle@microsoft.com</email></address>
4074    </author>
4075    <author initials="T." surname="Berners-Lee" fullname="Tim Berners-Lee">
4076      <organization abbrev="W3C/MIT">World Wide Web Consortium</organization>
4077      <address><email>timbl@w3.org</email></address>
4078    </author>
4079    <author initials="Y." surname="Lafon" fullname="Yves Lafon" role="editor">
4080      <organization abbrev="W3C">World Wide Web Consortium</organization>
4081      <address><email>ylafon@w3.org</email></address>
4082    </author>
4083    <author initials="J. F." surname="Reschke" fullname="Julian F. Reschke" role="editor">
4084      <organization abbrev="greenbytes">greenbytes GmbH</organization>
4085      <address><email>julian.reschke@greenbytes.de</email></address>
4086    </author>
4087    <date month="&ID-MONTH;" year="&ID-YEAR;"/>
4088  </front>
4089  <seriesInfo name="Internet-Draft" value="draft-ietf-httpbis-p5-range-&ID-VERSION;"/>
4090  <x:source href="p5-range.xml" basename="p5-range"/>
4091</reference>
4092
4093<reference anchor="Part6">
4094  <front>
4095    <title abbrev="HTTP/1.1">HTTP/1.1, part 6: Caching</title>
4096    <author initials="R." surname="Fielding" fullname="Roy T. Fielding" role="editor">
4097      <organization abbrev="Day Software">Day Software</organization>
4098      <address><email>fielding@gbiv.com</email></address>
4099    </author>
4100    <author initials="J." surname="Gettys" fullname="Jim Gettys">
4101      <organization abbrev="Alcatel-Lucent">Alcatel-Lucent Bell Labs</organization>
4102      <address><email>jg@freedesktop.org</email></address>
4103    </author>
4104    <author initials="J." surname="Mogul" fullname="Jeffrey C. Mogul">
4105      <organization abbrev="HP">Hewlett-Packard Company</organization>
4106      <address><email>JeffMogul@acm.org</email></address>
4107    </author>
4108    <author initials="H." surname="Frystyk" fullname="Henrik Frystyk Nielsen">
4109      <organization abbrev="Microsoft">Microsoft Corporation</organization>
4110      <address><email>henrikn@microsoft.com</email></address>
4111    </author>
4112    <author initials="L." surname="Masinter" fullname="Larry Masinter">
4113      <organization abbrev="Adobe Systems">Adobe Systems, Incorporated</organization>
4114      <address><email>LMM@acm.org</email></address>
4115    </author>
4116    <author initials="P." surname="Leach" fullname="Paul J. Leach">
4117      <organization abbrev="Microsoft">Microsoft Corporation</organization>
4118      <address><email>paulle@microsoft.com</email></address>
4119    </author>
4120    <author initials="T." surname="Berners-Lee" fullname="Tim Berners-Lee">
4121      <organization abbrev="W3C/MIT">World Wide Web Consortium</organization>
4122      <address><email>timbl@w3.org</email></address>
4123    </author>
4124    <author initials="Y." surname="Lafon" fullname="Yves Lafon" role="editor">
4125      <organization abbrev="W3C">World Wide Web Consortium</organization>
4126      <address><email>ylafon@w3.org</email></address>
4127    </author>
4128    <author initials="M." surname="Nottingham" fullname="Mark Nottingham" role="editor">
4129      <address><email>mnot@mnot.net</email></address>
4130    </author>
4131    <author initials="J. F." surname="Reschke" fullname="Julian F. Reschke" role="editor">
4132      <organization abbrev="greenbytes">greenbytes GmbH</organization>
4133      <address><email>julian.reschke@greenbytes.de</email></address>
4134    </author>
4135    <date month="&ID-MONTH;" year="&ID-YEAR;"/>
4136  </front>
4137  <seriesInfo name="Internet-Draft" value="draft-ietf-httpbis-p6-cache-&ID-VERSION;"/>
4138  <x:source href="p6-cache.xml" basename="p6-cache"/>
4139</reference>
4140
4141<reference anchor="RFC5234">
4142  <front>
4143    <title abbrev="ABNF for Syntax Specifications">Augmented BNF for Syntax Specifications: ABNF</title>
4144    <author initials="D." surname="Crocker" fullname="Dave Crocker" role="editor">
4145      <organization>Brandenburg InternetWorking</organization>
4146      <address>
4147        <email>dcrocker@bbiw.net</email>
4148      </address> 
4149    </author>
4150    <author initials="P." surname="Overell" fullname="Paul Overell">
4151      <organization>THUS plc.</organization>
4152      <address>
4153        <email>paul.overell@thus.net</email>
4154      </address>
4155    </author>
4156    <date month="January" year="2008"/>
4157  </front>
4158  <seriesInfo name="STD" value="68"/>
4159  <seriesInfo name="RFC" value="5234"/>
4160</reference>
4161
4162<reference anchor="RFC2119">
4163  <front>
4164    <title>Key words for use in RFCs to Indicate Requirement Levels</title>
4165    <author initials="S." surname="Bradner" fullname="Scott Bradner">
4166      <organization>Harvard University</organization>
4167      <address><email>sob@harvard.edu</email></address>
4168    </author>
4169    <date month="March" year="1997"/>
4170  </front>
4171  <seriesInfo name="BCP" value="14"/>
4172  <seriesInfo name="RFC" value="2119"/>
4173</reference>
4174
4175<reference anchor="RFC3986">
4176 <front>
4177  <title abbrev='URI Generic Syntax'>Uniform Resource Identifier (URI): Generic Syntax</title>
4178  <author initials='T.' surname='Berners-Lee' fullname='Tim Berners-Lee'>
4179    <organization abbrev="W3C/MIT">World Wide Web Consortium</organization>
4180    <address>
4181       <email>timbl@w3.org</email>
4182       <uri>http://www.w3.org/People/Berners-Lee/</uri>
4183    </address>
4184  </author>
4185  <author initials='R.' surname='Fielding' fullname='Roy T. Fielding'>
4186    <organization abbrev="Day Software">Day Software</organization>
4187    <address>
4188      <email>fielding@gbiv.com</email>
4189      <uri>http://roy.gbiv.com/</uri>
4190    </address>
4191  </author>
4192  <author initials='L.' surname='Masinter' fullname='Larry Masinter'>
4193    <organization abbrev="Adobe Systems">Adobe Systems Incorporated</organization>
4194    <address>
4195      <email>LMM@acm.org</email>
4196      <uri>http://larry.masinter.net/</uri>
4197    </address>
4198  </author>
4199  <date month='January' year='2005'></date>
4200 </front>
4201 <seriesInfo name="RFC" value="3986"/>
4202 <seriesInfo name="STD" value="66"/>
4203</reference>
4204
4205<reference anchor="USASCII">
4206  <front>
4207    <title>Coded Character Set -- 7-bit American Standard Code for Information Interchange</title>
4208    <author>
4209      <organization>American National Standards Institute</organization>
4210    </author>
4211    <date year="1986"/>
4212  </front>
4213  <seriesInfo name="ANSI" value="X3.4"/>
4214</reference>
4215
4216<reference anchor="RFC1950">
4217  <front>
4218    <title>ZLIB Compressed Data Format Specification version 3.3</title>
4219    <author initials="L.P." surname="Deutsch" fullname="L. Peter Deutsch">
4220      <organization>Aladdin Enterprises</organization>
4221      <address><email>ghost@aladdin.com</email></address>
4222    </author>
4223    <author initials="J-L." surname="Gailly" fullname="Jean-Loup Gailly"/>
4224    <date month="May" year="1996"/>
4225  </front>
4226  <seriesInfo name="RFC" value="1950"/>
4227  <annotation>
4228    RFC 1950 is an Informational RFC, thus it may be less stable than
4229    this specification. On the other hand, this downward reference was
4230    present since the publication of RFC 2068 in 1997 (<xref target="RFC2068"/>),
4231    therefore it is unlikely to cause problems in practice. See also
4232    <xref target="BCP97"/>.
4233  </annotation>
4234</reference>
4235
4236<reference anchor="RFC1951">
4237  <front>
4238    <title>DEFLATE Compressed Data Format Specification version 1.3</title>
4239    <author initials="P." surname="Deutsch" fullname="L. Peter Deutsch">
4240      <organization>Aladdin Enterprises</organization>
4241      <address><email>ghost@aladdin.com</email></address>
4242    </author>
4243    <date month="May" year="1996"/>
4244  </front>
4245  <seriesInfo name="RFC" value="1951"/>
4246  <annotation>
4247    RFC 1951 is an Informational RFC, thus it may be less stable than
4248    this specification. On the other hand, this downward reference was
4249    present since the publication of RFC 2068 in 1997 (<xref target="RFC2068"/>),
4250    therefore it is unlikely to cause problems in practice. See also
4251    <xref target="BCP97"/>.
4252  </annotation>
4253</reference>
4254
4255<reference anchor="RFC1952">
4256  <front>
4257    <title>GZIP file format specification version 4.3</title>
4258    <author initials="P." surname="Deutsch" fullname="L. Peter Deutsch">
4259      <organization>Aladdin Enterprises</organization>
4260      <address><email>ghost@aladdin.com</email></address>
4261    </author>
4262    <author initials="J-L." surname="Gailly" fullname="Jean-Loup Gailly">
4263      <address><email>gzip@prep.ai.mit.edu</email></address>
4264    </author>
4265    <author initials="M." surname="Adler" fullname="Mark Adler">
4266      <address><email>madler@alumni.caltech.edu</email></address>
4267    </author>
4268    <author initials="L.P." surname="Deutsch" fullname="L. Peter Deutsch">
4269      <address><email>ghost@aladdin.com</email></address>
4270    </author>
4271    <author initials="G." surname="Randers-Pehrson" fullname="Glenn Randers-Pehrson">
4272      <address><email>randeg@alumni.rpi.edu</email></address>
4273    </author>
4274    <date month="May" year="1996"/>
4275  </front>
4276  <seriesInfo name="RFC" value="1952"/>
4277  <annotation>
4278    RFC 1952 is an Informational RFC, thus it may be less stable than
4279    this specification. On the other hand, this downward reference was
4280    present since the publication of RFC 2068 in 1997 (<xref target="RFC2068"/>),
4281    therefore it is unlikely to cause problems in practice. See also
4282    <xref target="BCP97"/>.
4283  </annotation>
4284</reference>
4285
4286</references>
4287
4288<references title="Informative References">
4289
4290<reference anchor="Nie1997" target="http://doi.acm.org/10.1145/263105.263157">
4291  <front>
4292    <title>Network Performance Effects of HTTP/1.1, CSS1, and PNG</title>
4293    <author initials="H." surname="Frystyk" fullname="Henrik Frystyk Nielsen"/>
4294    <author initials="J." surname="Gettys" fullname="J. Gettys"/>
4295    <author initials="E." surname="Prud'hommeaux" fullname="E. Prud'hommeaux"/>
4296    <author initials="H." surname="Lie" fullname="H. Lie"/>
4297    <author initials="C." surname="Lilley" fullname="C. Lilley"/>
4298    <date year="1997" month="September"/>
4299  </front>
4300  <seriesInfo name="ACM" value="Proceedings of the ACM SIGCOMM '97 conference on Applications, technologies, architectures, and protocols for computer communication SIGCOMM '97"/>
4301</reference>
4302
4303<reference anchor="Pad1995" target="http://portal.acm.org/citation.cfm?id=219094">
4304  <front>
4305    <title>Improving HTTP Latency</title>
4306    <author initials="V.N." surname="Padmanabhan" fullname="Venkata N. Padmanabhan"/>
4307    <author initials="J.C." surname="Mogul" fullname="Jeffrey C. Mogul"/>
4308    <date year="1995" month="December"/>
4309  </front>
4310  <seriesInfo name="Computer Networks and ISDN Systems" value="v. 28, pp. 25-35"/>
4311</reference>
4312
4313<reference anchor="RFC1123">
4314  <front>
4315    <title>Requirements for Internet Hosts - Application and Support</title>
4316    <author initials="R." surname="Braden" fullname="Robert Braden">
4317      <organization>University of Southern California (USC), Information Sciences Institute</organization>
4318      <address><email>Braden@ISI.EDU</email></address>
4319    </author>
4320    <date month="October" year="1989"/>
4321  </front>
4322  <seriesInfo name="STD" value="3"/>
4323  <seriesInfo name="RFC" value="1123"/>
4324</reference>
4325
4326<reference anchor="RFC1305">
4327  <front>
4328    <title>Network Time Protocol (Version 3) Specification, Implementation</title>
4329    <author initials="D." surname="Mills" fullname="David L. Mills">
4330      <organization>University of Delaware, Electrical Engineering Department</organization>
4331      <address><email>mills@udel.edu</email></address>
4332    </author>
4333    <date month="March" year="1992"/>
4334  </front>
4335  <seriesInfo name="RFC" value="1305"/>
4336</reference>
4337
4338<reference anchor="RFC1900">
4339  <front>
4340    <title>Renumbering Needs Work</title>
4341    <author initials="B." surname="Carpenter" fullname="Brian E. Carpenter">
4342      <organization>CERN, Computing and Networks Division</organization>
4343      <address><email>brian@dxcoms.cern.ch</email></address>
4344    </author>
4345    <author initials="Y." surname="Rekhter" fullname="Yakov Rekhter">
4346      <organization>cisco Systems</organization>
4347      <address><email>yakov@cisco.com</email></address>
4348    </author>
4349    <date month="February" year="1996"/>
4350  </front>
4351  <seriesInfo name="RFC" value="1900"/>
4352</reference>
4353
4354<reference anchor="RFC1945">
4355  <front>
4356    <title abbrev="HTTP/1.0">Hypertext Transfer Protocol -- HTTP/1.0</title>
4357    <author initials="T." surname="Berners-Lee" fullname="Tim Berners-Lee">
4358      <organization>MIT, Laboratory for Computer Science</organization>
4359      <address><email>timbl@w3.org</email></address>
4360    </author>
4361    <author initials="R.T." surname="Fielding" fullname="Roy T. Fielding">
4362      <organization>University of California, Irvine, Department of Information and Computer Science</organization>
4363      <address><email>fielding@ics.uci.edu</email></address>
4364    </author>
4365    <author initials="H.F." surname="Nielsen" fullname="Henrik Frystyk Nielsen">
4366      <organization>W3 Consortium, MIT Laboratory for Computer Science</organization>
4367      <address><email>frystyk@w3.org</email></address>
4368    </author>
4369    <date month="May" year="1996"/>
4370  </front>
4371  <seriesInfo name="RFC" value="1945"/>
4372</reference>
4373
4374<reference anchor="RFC2045">
4375  <front>
4376    <title abbrev="Internet Message Bodies">Multipurpose Internet Mail Extensions (MIME) Part One: Format of Internet Message Bodies</title>
4377    <author initials="N." surname="Freed" fullname="Ned Freed">
4378      <organization>Innosoft International, Inc.</organization>
4379      <address><email>ned@innosoft.com</email></address>
4380    </author>
4381    <author initials="N.S." surname="Borenstein" fullname="Nathaniel S. Borenstein">
4382      <organization>First Virtual Holdings</organization>
4383      <address><email>nsb@nsb.fv.com</email></address>
4384    </author>
4385    <date month="November" year="1996"/>
4386  </front>
4387  <seriesInfo name="RFC" value="2045"/>
4388</reference>
4389
4390<reference anchor="RFC2047">
4391  <front>
4392    <title abbrev="Message Header Extensions">MIME (Multipurpose Internet Mail Extensions) Part Three: Message Header Extensions for Non-ASCII Text</title>
4393    <author initials="K." surname="Moore" fullname="Keith Moore">
4394      <organization>University of Tennessee</organization>
4395      <address><email>moore@cs.utk.edu</email></address>
4396    </author>
4397    <date month="November" year="1996"/>
4398  </front>
4399  <seriesInfo name="RFC" value="2047"/>
4400</reference>
4401
4402<reference anchor="RFC2068">
4403  <front>
4404    <title abbrev="HTTP/1.1">Hypertext Transfer Protocol -- HTTP/1.1</title>
4405    <author initials="R." surname="Fielding" fullname="Roy T. Fielding">
4406      <organization>University of California, Irvine, Department of Information and Computer Science</organization>
4407      <address><email>fielding@ics.uci.edu</email></address>
4408    </author>
4409    <author initials="J." surname="Gettys" fullname="Jim Gettys">
4410      <organization>MIT Laboratory for Computer Science</organization>
4411      <address><email>jg@w3.org</email></address>
4412    </author>
4413    <author initials="J." surname="Mogul" fullname="Jeffrey C. Mogul">
4414      <organization>Digital Equipment Corporation, Western Research Laboratory</organization>
4415      <address><email>mogul@wrl.dec.com</email></address>
4416    </author>
4417    <author initials="H." surname="Nielsen" fullname="Henrik Frystyk Nielsen">
4418      <organization>MIT Laboratory for Computer Science</organization>
4419      <address><email>frystyk@w3.org</email></address>
4420    </author>
4421    <author initials="T." surname="Berners-Lee" fullname="Tim Berners-Lee">
4422      <organization>MIT Laboratory for Computer Science</organization>
4423      <address><email>timbl@w3.org</email></address>
4424    </author>
4425    <date month="January" year="1997"/>
4426  </front>
4427  <seriesInfo name="RFC" value="2068"/>
4428</reference>
4429
4430<reference anchor='RFC2109'>
4431  <front>
4432    <title>HTTP State Management Mechanism</title>
4433    <author initials='D.M.' surname='Kristol' fullname='David M. Kristol'>
4434      <organization>Bell Laboratories, Lucent Technologies</organization>
4435      <address><email>dmk@bell-labs.com</email></address>
4436    </author>
4437    <author initials='L.' surname='Montulli' fullname='Lou Montulli'>
4438      <organization>Netscape Communications Corp.</organization>
4439      <address><email>montulli@netscape.com</email></address>
4440    </author>
4441    <date year='1997' month='February' />
4442  </front>
4443  <seriesInfo name='RFC' value='2109' />
4444</reference>
4445
4446<reference anchor="RFC2145">
4447  <front>
4448    <title abbrev="HTTP Version Numbers">Use and Interpretation of HTTP Version Numbers</title>
4449    <author initials="J.C." surname="Mogul" fullname="Jeffrey C. Mogul">
4450      <organization>Western Research Laboratory</organization>
4451      <address><email>mogul@wrl.dec.com</email></address>
4452    </author>
4453    <author initials="R.T." surname="Fielding" fullname="Roy T. Fielding">
4454      <organization>Department of Information and Computer Science</organization>
4455      <address><email>fielding@ics.uci.edu</email></address>
4456    </author>
4457    <author initials="J." surname="Gettys" fullname="Jim Gettys">
4458      <organization>MIT Laboratory for Computer Science</organization>
4459      <address><email>jg@w3.org</email></address>
4460    </author>
4461    <author initials="H.F." surname="Nielsen" fullname="Henrik Frystyk Nielsen">
4462      <organization>W3 Consortium</organization>
4463      <address><email>frystyk@w3.org</email></address>
4464    </author>
4465    <date month="May" year="1997"/>
4466  </front>
4467  <seriesInfo name="RFC" value="2145"/>
4468</reference>
4469
4470<reference anchor="RFC2616">
4471  <front>
4472    <title>Hypertext Transfer Protocol -- HTTP/1.1</title>
4473    <author initials="R." surname="Fielding" fullname="R. Fielding">
4474      <organization>University of California, Irvine</organization>
4475      <address><email>fielding@ics.uci.edu</email></address>
4476    </author>
4477    <author initials="J." surname="Gettys" fullname="J. Gettys">
4478      <organization>W3C</organization>
4479      <address><email>jg@w3.org</email></address>
4480    </author>
4481    <author initials="J." surname="Mogul" fullname="J. Mogul">
4482      <organization>Compaq Computer Corporation</organization>
4483      <address><email>mogul@wrl.dec.com</email></address>
4484    </author>
4485    <author initials="H." surname="Frystyk" fullname="H. Frystyk">
4486      <organization>MIT Laboratory for Computer Science</organization>
4487      <address><email>frystyk@w3.org</email></address>
4488    </author>
4489    <author initials="L." surname="Masinter" fullname="L. Masinter">
4490      <organization>Xerox Corporation</organization>
4491      <address><email>masinter@parc.xerox.com</email></address>
4492    </author>
4493    <author initials="P." surname="Leach" fullname="P. Leach">
4494      <organization>Microsoft Corporation</organization>
4495      <address><email>paulle@microsoft.com</email></address>
4496    </author>
4497    <author initials="T." surname="Berners-Lee" fullname="T. Berners-Lee">
4498      <organization>W3C</organization>
4499      <address><email>timbl@w3.org</email></address>
4500    </author>
4501    <date month="June" year="1999"/>
4502  </front>
4503  <seriesInfo name="RFC" value="2616"/>
4504</reference>
4505
4506<reference anchor='RFC2817'>
4507  <front>
4508    <title>Upgrading to TLS Within HTTP/1.1</title>
4509    <author initials='R.' surname='Khare' fullname='R. Khare'>
4510      <organization>4K Associates / UC Irvine</organization>
4511      <address><email>rohit@4K-associates.com</email></address>
4512    </author>
4513    <author initials='S.' surname='Lawrence' fullname='S. Lawrence'>
4514      <organization>Agranat Systems, Inc.</organization>
4515      <address><email>lawrence@agranat.com</email></address>
4516    </author>
4517    <date year='2000' month='May' />
4518  </front>
4519  <seriesInfo name='RFC' value='2817' />
4520</reference>
4521
4522<reference anchor='RFC2818'>
4523  <front>
4524    <title>HTTP Over TLS</title>
4525    <author initials='E.' surname='Rescorla' fullname='Eric Rescorla'>
4526      <organization>RTFM, Inc.</organization>
4527      <address><email>ekr@rtfm.com</email></address>
4528    </author>
4529    <date year='2000' month='May' />
4530  </front>
4531  <seriesInfo name='RFC' value='2818' />
4532</reference>
4533
4534<reference anchor='RFC2965'>
4535  <front>
4536    <title>HTTP State Management Mechanism</title>
4537    <author initials='D. M.' surname='Kristol' fullname='David M. Kristol'>
4538      <organization>Bell Laboratories, Lucent Technologies</organization>
4539      <address><email>dmk@bell-labs.com</email></address>
4540    </author>
4541    <author initials='L.' surname='Montulli' fullname='Lou Montulli'>
4542      <organization>Epinions.com, Inc.</organization>
4543      <address><email>lou@montulli.org</email></address>
4544    </author>
4545    <date year='2000' month='October' />
4546  </front>
4547  <seriesInfo name='RFC' value='2965' />
4548</reference>
4549
4550<reference anchor='RFC3864'>
4551  <front>
4552    <title>Registration Procedures for Message Header Fields</title>
4553    <author initials='G.' surname='Klyne' fullname='G. Klyne'>
4554      <organization>Nine by Nine</organization>
4555      <address><email>GK-IETF@ninebynine.org</email></address>
4556    </author>
4557    <author initials='M.' surname='Nottingham' fullname='M. Nottingham'>
4558      <organization>BEA Systems</organization>
4559      <address><email>mnot@pobox.com</email></address>
4560    </author>
4561    <author initials='J.' surname='Mogul' fullname='J. Mogul'>
4562      <organization>HP Labs</organization>
4563      <address><email>JeffMogul@acm.org</email></address>
4564    </author>
4565    <date year='2004' month='September' />
4566  </front>
4567  <seriesInfo name='BCP' value='90' />
4568  <seriesInfo name='RFC' value='3864' />
4569</reference>
4570
4571<reference anchor="RFC4288">
4572  <front>
4573    <title>Media Type Specifications and Registration Procedures</title>
4574    <author initials="N." surname="Freed" fullname="N. Freed">
4575      <organization>Sun Microsystems</organization>
4576      <address>
4577        <email>ned.freed@mrochek.com</email>
4578      </address>
4579    </author>
4580    <author initials="J." surname="Klensin" fullname="J. Klensin">
4581      <address>
4582        <email>klensin+ietf@jck.com</email>
4583      </address>
4584    </author>
4585    <date year="2005" month="December"/>
4586  </front>
4587  <seriesInfo name="BCP" value="13"/>
4588  <seriesInfo name="RFC" value="4288"/>
4589</reference>
4590
4591<reference anchor='RFC4395'>
4592  <front>
4593    <title>Guidelines and Registration Procedures for New URI Schemes</title>
4594    <author initials='T.' surname='Hansen' fullname='T. Hansen'>
4595      <organization>AT&amp;T Laboratories</organization>
4596      <address>
4597        <email>tony+urireg@maillennium.att.com</email>
4598      </address>
4599    </author>
4600    <author initials='T.' surname='Hardie' fullname='T. Hardie'>
4601      <organization>Qualcomm, Inc.</organization>
4602      <address>
4603        <email>hardie@qualcomm.com</email>
4604      </address>
4605    </author>
4606    <author initials='L.' surname='Masinter' fullname='L. Masinter'>
4607      <organization>Adobe Systems</organization>
4608      <address>
4609        <email>LMM@acm.org</email>
4610      </address>
4611    </author>
4612    <date year='2006' month='February' />
4613  </front>
4614  <seriesInfo name='BCP' value='115' />
4615  <seriesInfo name='RFC' value='4395' />
4616</reference>
4617
4618<reference anchor='RFC5226'>
4619  <front>
4620    <title>Guidelines for Writing an IANA Considerations Section in RFCs</title>
4621    <author initials='T.' surname='Narten' fullname='T. Narten'>
4622      <organization>IBM</organization>
4623      <address><email>narten@us.ibm.com</email></address>
4624    </author>
4625    <author initials='H.' surname='Alvestrand' fullname='H. Alvestrand'>
4626      <organization>Google</organization>
4627      <address><email>Harald@Alvestrand.no</email></address>
4628    </author>
4629    <date year='2008' month='May' />
4630  </front>
4631  <seriesInfo name='BCP' value='26' />
4632  <seriesInfo name='RFC' value='5226' />
4633</reference>
4634
4635<reference anchor="RFC5322">
4636  <front>
4637    <title>Internet Message Format</title>
4638    <author initials="P." surname="Resnick" fullname="P. Resnick">
4639      <organization>Qualcomm Incorporated</organization>
4640    </author>
4641    <date year="2008" month="October"/>
4642  </front> 
4643  <seriesInfo name="RFC" value="5322"/>
4644</reference>
4645
4646<reference anchor='BCP97'>
4647  <front>
4648    <title>Handling Normative References to Standards-Track Documents</title>
4649    <author initials='J.' surname='Klensin' fullname='J. Klensin'>
4650      <address>
4651        <email>klensin+ietf@jck.com</email>
4652      </address>
4653    </author>
4654    <author initials='S.' surname='Hartman' fullname='S. Hartman'>
4655      <organization>MIT</organization>
4656      <address>
4657        <email>hartmans-ietf@mit.edu</email>
4658      </address>
4659    </author>
4660    <date year='2007' month='June' />
4661  </front>
4662  <seriesInfo name='BCP' value='97' />
4663  <seriesInfo name='RFC' value='4897' />
4664</reference>
4665
4666<reference anchor="Kri2001" target="http://arxiv.org/abs/cs.SE/0105018">
4667  <front>
4668    <title>HTTP Cookies: Standards, Privacy, and Politics</title>
4669    <author initials="D." surname="Kristol" fullname="David M. Kristol"/>
4670    <date year="2001" month="November"/>
4671  </front>
4672  <seriesInfo name="ACM Transactions on Internet Technology" value="Vol. 1, #2"/>
4673</reference>
4674
4675<reference anchor="Spe" target="http://sunsite.unc.edu/mdma-release/http-prob.html">
4676  <front>
4677    <title>Analysis of HTTP Performance Problems</title>
4678    <author initials="S." surname="Spero" fullname="Simon E. Spero"/>
4679    <date/>
4680  </front>
4681</reference>
4682
4683<reference anchor="Tou1998" target="http://www.isi.edu/touch/pubs/http-perf96/">
4684  <front>
4685  <title>Analysis of HTTP Performance</title>
4686  <author initials="J." surname="Touch" fullname="Joe Touch">
4687    <organization>USC/Information Sciences Institute</organization>
4688    <address><email>touch@isi.edu</email></address>
4689  </author>
4690  <author initials="J." surname="Heidemann" fullname="John Heidemann">
4691    <organization>USC/Information Sciences Institute</organization>
4692    <address><email>johnh@isi.edu</email></address>
4693  </author>
4694  <author initials="K." surname="Obraczka" fullname="Katia Obraczka">
4695    <organization>USC/Information Sciences Institute</organization>
4696    <address><email>katia@isi.edu</email></address>
4697  </author>
4698  <date year="1998" month="Aug"/>
4699  </front>
4700  <seriesInfo name="ISI Research Report" value="ISI/RR-98-463"/>
4701  <annotation>(original report dated Aug. 1996)</annotation>
4702</reference>
4703
4704</references>
4705
4706
4707<section title="Tolerant Applications" anchor="tolerant.applications">
4708<t>
4709   Although this document specifies the requirements for the generation
4710   of HTTP/1.1 messages, not all applications will be correct in their
4711   implementation. We therefore recommend that operational applications
4712   be tolerant of deviations whenever those deviations can be
4713   interpreted unambiguously.
4714</t>
4715<t>
4716   Clients &SHOULD; be tolerant in parsing the Status-Line and servers
4717   &SHOULD; be tolerant when parsing the Request-Line. In particular, they
4718   &SHOULD; accept any amount of WSP characters between fields, even though
4719   only a single SP is required.
4720</t>
4721<t>
4722   The line terminator for header fields is the sequence CRLF.
4723   However, we recommend that applications, when parsing such headers,
4724   recognize a single LF as a line terminator and ignore the leading CR.
4725</t>
4726<t>
4727   The character set of a representation &SHOULD; be labeled as the lowest
4728   common denominator of the character codes used within that representation, with
4729   the exception that not labeling the representation is preferred over labeling
4730   the representation with the labels US-ASCII or ISO-8859-1. See &payload;.
4731</t>
4732<t>
4733   Additional rules for requirements on parsing and encoding of dates
4734   and other potential problems with date encodings include:
4735</t>
4736<t>
4737  <list style="symbols">
4738     <t>HTTP/1.1 clients and caches &SHOULD; assume that an RFC-850 date
4739        which appears to be more than 50 years in the future is in fact
4740        in the past (this helps solve the "year 2000" problem).</t>
4741
4742     <t>Although all date formats are specified to be case-sensitive,
4743        recipients &SHOULD; match day, week and timezone names
4744        case-insensitively.</t>
4745             
4746     <t>An HTTP/1.1 implementation &MAY; internally represent a parsed
4747        Expires date as earlier than the proper value, but &MUST-NOT;
4748        internally represent a parsed Expires date as later than the
4749        proper value.</t>
4750
4751     <t>All expiration-related calculations &MUST; be done in GMT. The
4752        local time zone &MUST-NOT; influence the calculation or comparison
4753        of an age or expiration time.</t>
4754
4755     <t>If an HTTP header incorrectly carries a date value with a time
4756        zone other than GMT, it &MUST; be converted into GMT using the
4757        most conservative possible conversion.</t>
4758  </list>
4759</t>
4760</section>
4761
4762<section title="Compatibility with Previous Versions" anchor="compatibility">
4763<t>
4764   HTTP has been in use by the World-Wide Web global information initiative
4765   since 1990. The first version of HTTP, later referred to as HTTP/0.9,
4766   was a simple protocol for hypertext data transfer across the Internet
4767   with only a single method and no metadata.
4768   HTTP/1.0, as defined by <xref target="RFC1945"/>, added a range of request
4769   methods and MIME-like messaging that could include metadata about the data
4770   transferred and modifiers on the request/response semantics. However,
4771   HTTP/1.0 did not sufficiently take into consideration the effects of
4772   hierarchical proxies, caching, the need for persistent connections, or
4773   name-based virtual hosts. The proliferation of incompletely-implemented
4774   applications calling themselves "HTTP/1.0" further necessitated a
4775   protocol version change in order for two communicating applications
4776   to determine each other's true capabilities.
4777</t>
4778<t>
4779   HTTP/1.1 remains compatible with HTTP/1.0 by including more stringent
4780   requirements that enable reliable implementations, adding only
4781   those new features that will either be safely ignored by an HTTP/1.0
4782   recipient or only sent when communicating with a party advertising
4783   compliance with HTTP/1.1.
4784</t>
4785<t>
4786   It is beyond the scope of a protocol specification to mandate
4787   compliance with previous versions. HTTP/1.1 was deliberately
4788   designed, however, to make supporting previous versions easy. It is
4789   worth noting that, at the time of composing this specification, we would
4790   expect general-purpose HTTP/1.1 servers to:
4791  <list style="symbols">
4792     <t>understand any valid request in the format of HTTP/1.0 and
4793        1.1;</t>
4794
4795     <t>respond appropriately with a message in the same major version
4796        used by the client.</t>
4797  </list>
4798</t>
4799<t>
4800   And we would expect HTTP/1.1 clients to:
4801  <list style="symbols">
4802     <t>understand any valid response in the format of HTTP/1.0 or
4803        1.1.</t>
4804  </list>
4805</t>
4806<t>
4807   For most implementations of HTTP/1.0, each connection is established
4808   by the client prior to the request and closed by the server after
4809   sending the response. Some implementations implement the Keep-Alive
4810   version of persistent connections described in <xref x:sec="19.7.1" x:fmt="of" target="RFC2068"/>.
4811</t>
4812
4813<section title="Changes from HTTP/1.0" anchor="changes.from.1.0">
4814<t>
4815   This section summarizes major differences between versions HTTP/1.0
4816   and HTTP/1.1.
4817</t>
4818
4819<section title="Changes to Simplify Multi-homed Web Servers and Conserve IP Addresses" anchor="changes.to.simplify.multi-homed.web.servers.and.conserve.ip.addresses">
4820<t>
4821   The requirements that clients and servers support the Host request-header,
4822   report an error if the Host request-header (<xref target="header.host"/>) is
4823   missing from an HTTP/1.1 request, and accept absolute URIs (<xref target="request-target"/>)
4824   are among the most important changes defined by this
4825   specification.
4826</t>
4827<t>
4828   Older HTTP/1.0 clients assumed a one-to-one relationship of IP
4829   addresses and servers; there was no other established mechanism for
4830   distinguishing the intended server of a request than the IP address
4831   to which that request was directed. The changes outlined above will
4832   allow the Internet, once older HTTP clients are no longer common, to
4833   support multiple Web sites from a single IP address, greatly
4834   simplifying large operational Web servers, where allocation of many
4835   IP addresses to a single host has created serious problems. The
4836   Internet will also be able to recover the IP addresses that have been
4837   allocated for the sole purpose of allowing special-purpose domain
4838   names to be used in root-level HTTP URLs. Given the rate of growth of
4839   the Web, and the number of servers already deployed, it is extremely
4840   important that all implementations of HTTP (including updates to
4841   existing HTTP/1.0 applications) correctly implement these
4842   requirements:
4843  <list style="symbols">
4844     <t>Both clients and servers &MUST; support the Host request-header.</t>
4845
4846     <t>A client that sends an HTTP/1.1 request &MUST; send a Host header.</t>
4847
4848     <t>Servers &MUST; report a 400 (Bad Request) error if an HTTP/1.1
4849        request does not include a Host request-header.</t>
4850
4851     <t>Servers &MUST; accept absolute URIs.</t>
4852  </list>
4853</t>
4854</section>
4855</section>
4856
4857<section title="Compatibility with HTTP/1.0 Persistent Connections" anchor="compatibility.with.http.1.0.persistent.connections">
4858<t>
4859   Some clients and servers might wish to be compatible with some
4860   previous implementations of persistent connections in HTTP/1.0
4861   clients and servers. Persistent connections in HTTP/1.0 are
4862   explicitly negotiated as they are not the default behavior. HTTP/1.0
4863   experimental implementations of persistent connections are faulty,
4864   and the new facilities in HTTP/1.1 are designed to rectify these
4865   problems. The problem was that some existing HTTP/1.0 clients may be
4866   sending Keep-Alive to a proxy server that doesn't understand
4867   Connection, which would then erroneously forward it to the next
4868   inbound server, which would establish the Keep-Alive connection and
4869   result in a hung HTTP/1.0 proxy waiting for the close on the
4870   response. The result is that HTTP/1.0 clients must be prevented from
4871   using Keep-Alive when talking to proxies.
4872</t>
4873<t>
4874   However, talking to proxies is the most important use of persistent
4875   connections, so that prohibition is clearly unacceptable. Therefore,
4876   we need some other mechanism for indicating a persistent connection
4877   is desired, which is safe to use even when talking to an old proxy
4878   that ignores Connection. Persistent connections are the default for
4879   HTTP/1.1 messages; we introduce a new keyword (Connection: close) for
4880   declaring non-persistence. See <xref target="header.connection"/>.
4881</t>
4882<t>
4883   The original HTTP/1.0 form of persistent connections (the Connection:
4884   Keep-Alive and Keep-Alive header) is documented in <xref x:sec="19.7.1" x:fmt="of" target="RFC2068"/>.
4885</t>
4886</section>
4887
4888<section title="Changes from RFC 2068" anchor="changes.from.rfc.2068">
4889<t>
4890   This specification has been carefully audited to correct and
4891   disambiguate key word usage; RFC 2068 had many problems in respect to
4892   the conventions laid out in <xref target="RFC2119"/>.
4893</t>
4894<t>
4895   Transfer-coding and message lengths all interact in ways that
4896   required fixing exactly when chunked encoding is used (to allow for
4897   transfer encoding that may not be self delimiting); it was important
4898   to straighten out exactly how message lengths are computed. (Sections
4899   <xref target="transfer.codings" format="counter"/>, <xref target="message.body" format="counter"/>,
4900   <xref target="header.content-length" format="counter"/>,
4901   see also <xref target="Part5"/>)
4902</t>
4903<t>
4904   The use and interpretation of HTTP version numbers has been clarified
4905   by <xref target="RFC2145"/>. Require proxies to upgrade requests to highest protocol
4906   version they support to deal with problems discovered in HTTP/1.0
4907   implementations (<xref target="http.version"/>)
4908</t>
4909<t>
4910   Quality Values of zero should indicate that "I don't want something"
4911   to allow clients to refuse a representation. (<xref target="quality.values"/>)
4912</t>
4913<t>
4914   Transfer-coding had significant problems, particularly with
4915   interactions with chunked encoding. The solution is that transfer-codings
4916   become as full fledged as content-codings. This involves
4917   adding an IANA registry for transfer-codings (separate from content
4918   codings), a new header field (TE) and enabling trailer headers in the
4919   future. Transfer encoding is a major performance benefit, so it was
4920   worth fixing <xref target="Nie1997"/>. TE also solves another, obscure, downward
4921   interoperability problem that could have occurred due to interactions
4922   between authentication trailers, chunked encoding and HTTP/1.0
4923   clients.(Section
4924   <xref target="transfer.codings" format="counter"/>,
4925   <xref target="chunked.encoding" format="counter"/>,
4926   <xref target="non-modifiable.headers" format="counter"/>,
4927   and <xref target="header.te" format="counter"/>)
4928</t>
4929<t>
4930  Proxies should be able to add Content-Length when appropriate.
4931  (<xref target="non-modifiable.headers"/>)
4932</t>
4933</section>
4934
4935<section title="Changes from RFC 2616" anchor="changes.from.rfc.2616">
4936<t>
4937  Empty list elements in list productions have been deprecated.
4938  (<xref target="notation.abnf"/>)
4939</t>
4940<t>
4941  Rules about implicit linear whitespace between certain grammar productions
4942  have been removed; now it's only allowed when specifically pointed out
4943  in the ABNF. The NUL character is no longer allowed in comment and quoted-string
4944  text. The quoted-pair rule no longer allows escaping control characters other than HTAB.
4945  Non-ASCII content in header fields and reason phrase has been obsoleted and
4946  made opaque (the TEXT rule was removed)
4947  (<xref target="basic.rules"/>)
4948</t>
4949<t>
4950  Clarify that HTTP-Version is case sensitive.
4951  (<xref target="http.version"/>)
4952</t>
4953<t>
4954  Remove reference to non-existent identity transfer-coding value tokens.
4955  (Sections <xref format="counter" target="transfer.codings"/> and
4956  <xref format="counter" target="message.body"/>)
4957</t>
4958<t>
4959  Require that invalid whitespace around field-names be rejected.
4960  (<xref target="header.fields"/>)
4961</t>
4962<t>
4963  Update use of abs_path production from RFC1808 to the path-absolute + query
4964  components of RFC3986.
4965  (<xref target="request-target"/>)
4966</t>
4967<t>
4968  Clarification that the chunk length does not include the count of the octets
4969  in the chunk header and trailer. Furthermore disallowed line folding
4970  in chunk extensions.
4971  (<xref target="chunked.encoding"/>)
4972</t>
4973<t>
4974  Remove hard limit of two connections per server.
4975  (<xref target="persistent.practical"/>)
4976</t>
4977<t>
4978  Clarify exactly when close connection options must be sent.
4979  (<xref target="header.connection"/>)
4980</t>
4981</section>
4982</section>
4983
4984<?BEGININC p1-messaging.abnf-appendix ?>
4985<section xmlns:x="http://purl.org/net/xml2rfc/ext" title="Collected ABNF" anchor="collected.abnf">
4986<figure>
4987<artwork type="abnf" name="p1-messaging.parsed-abnf">
4988<x:ref>BWS</x:ref> = OWS
4989
4990<x:ref>Cache-Control</x:ref> = &lt;Cache-Control, defined in [Part6], Section 3.4&gt;
4991<x:ref>Chunked-Body</x:ref> = *chunk last-chunk trailer-part CRLF
4992<x:ref>Connection</x:ref> = "Connection:" OWS Connection-v
4993<x:ref>Connection-v</x:ref> = *( "," OWS ) connection-token *( OWS "," [ OWS
4994 connection-token ] )
4995<x:ref>Content-Length</x:ref> = "Content-Length:" OWS 1*Content-Length-v
4996<x:ref>Content-Length-v</x:ref> = 1*DIGIT
4997
4998<x:ref>Date</x:ref> = "Date:" OWS Date-v
4999<x:ref>Date-v</x:ref> = HTTP-date
5000
5001<x:ref>GMT</x:ref> = %x47.4D.54 ; GMT
5002
5003<x:ref>HTTP-Prot-Name</x:ref> = %x48.54.54.50 ; HTTP
5004<x:ref>HTTP-Version</x:ref> = HTTP-Prot-Name "/" 1*DIGIT "." 1*DIGIT
5005<x:ref>HTTP-date</x:ref> = rfc1123-date / obs-date
5006<x:ref>HTTP-message</x:ref> = start-line *( header-field CRLF ) CRLF [ message-body
5007 ]
5008<x:ref>Host</x:ref> = "Host:" OWS Host-v
5009<x:ref>Host-v</x:ref> = uri-host [ ":" port ]
5010
5011<x:ref>Method</x:ref> = token
5012
5013<x:ref>OWS</x:ref> = *( [ obs-fold ] WSP )
5014
5015<x:ref>Pragma</x:ref> = &lt;Pragma, defined in [Part6], Section 3.4&gt;
5016
5017<x:ref>RWS</x:ref> = 1*( [ obs-fold ] WSP )
5018<x:ref>Reason-Phrase</x:ref> = *( WSP / VCHAR / obs-text )
5019<x:ref>Request</x:ref> = Request-Line *( ( general-header / request-header /
5020 entity-header ) CRLF ) CRLF [ message-body ]
5021<x:ref>Request-Line</x:ref> = Method SP request-target SP HTTP-Version CRLF
5022<x:ref>Response</x:ref> = Status-Line *( ( general-header / response-header /
5023 entity-header ) CRLF ) CRLF [ message-body ]
5024
5025<x:ref>Status-Code</x:ref> = 3DIGIT
5026<x:ref>Status-Line</x:ref> = HTTP-Version SP Status-Code SP Reason-Phrase CRLF
5027
5028<x:ref>TE</x:ref> = "TE:" OWS TE-v
5029<x:ref>TE-v</x:ref> = [ ( "," / t-codings ) *( OWS "," [ OWS t-codings ] ) ]
5030<x:ref>Trailer</x:ref> = "Trailer:" OWS Trailer-v
5031<x:ref>Trailer-v</x:ref> = *( "," OWS ) field-name *( OWS "," [ OWS field-name ] )
5032<x:ref>Transfer-Encoding</x:ref> = "Transfer-Encoding:" OWS Transfer-Encoding-v
5033<x:ref>Transfer-Encoding-v</x:ref> = *( "," OWS ) transfer-coding *( OWS "," [ OWS
5034 transfer-coding ] )
5035
5036<x:ref>URI-reference</x:ref> = &lt;URI-reference, defined in [RFC3986], Section 4.1&gt;
5037<x:ref>Upgrade</x:ref> = "Upgrade:" OWS Upgrade-v
5038<x:ref>Upgrade-v</x:ref> = *( "," OWS ) product *( OWS "," [ OWS product ] )
5039
5040<x:ref>Via</x:ref> = "Via:" OWS Via-v
5041<x:ref>Via-v</x:ref> = *( "," OWS ) received-protocol RWS received-by [ RWS comment
5042 ] *( OWS "," [ OWS received-protocol RWS received-by [ RWS comment ]
5043 ] )
5044
5045<x:ref>Warning</x:ref> = &lt;Warning, defined in [Part6], Section 3.6&gt;
5046
5047<x:ref>absolute-URI</x:ref> = &lt;absolute-URI, defined in [RFC3986], Section 4.3&gt;
5048<x:ref>asctime-date</x:ref> = day-name SP date3 SP time-of-day SP year
5049<x:ref>attribute</x:ref> = token
5050<x:ref>authority</x:ref> = &lt;authority, defined in [RFC3986], Section 3.2&gt;
5051
5052<x:ref>chunk</x:ref> = chunk-size *WSP [ chunk-ext ] CRLF chunk-data CRLF
5053<x:ref>chunk-data</x:ref> = 1*OCTET
5054<x:ref>chunk-ext</x:ref> = *( ";" *WSP chunk-ext-name [ "=" chunk-ext-val ] *WSP )
5055<x:ref>chunk-ext-name</x:ref> = token
5056<x:ref>chunk-ext-val</x:ref> = token / quoted-str-nf
5057<x:ref>chunk-size</x:ref> = 1*HEXDIG
5058<x:ref>comment</x:ref> = "(" *( ctext / quoted-cpair / comment ) ")"
5059<x:ref>connection-token</x:ref> = token
5060<x:ref>ctext</x:ref> = OWS / %x21-27 ; '!'-'''
5061 / %x2A-5B ; '*'-'['
5062 / %x5D-7E ; ']'-'~'
5063 / obs-text
5064
5065<x:ref>date1</x:ref> = day SP month SP year
5066<x:ref>date2</x:ref> = day "-" month "-" 2DIGIT
5067<x:ref>date3</x:ref> = month SP ( 2DIGIT / ( SP DIGIT ) )
5068<x:ref>day</x:ref> = 2DIGIT
5069<x:ref>day-name</x:ref> = %x4D.6F.6E ; Mon
5070 / %x54.75.65 ; Tue
5071 / %x57.65.64 ; Wed
5072 / %x54.68.75 ; Thu
5073 / %x46.72.69 ; Fri
5074 / %x53.61.74 ; Sat
5075 / %x53.75.6E ; Sun
5076<x:ref>day-name-l</x:ref> = %x4D.6F.6E.64.61.79 ; Monday
5077 / %x54.75.65.73.64.61.79 ; Tuesday
5078 / %x57.65.64.6E.65.73.64.61.79 ; Wednesday
5079 / %x54.68.75.72.73.64.61.79 ; Thursday
5080 / %x46.72.69.64.61.79 ; Friday
5081 / %x53.61.74.75.72.64.61.79 ; Saturday
5082 / %x53.75.6E.64.61.79 ; Sunday
5083
5084<x:ref>entity-header</x:ref> = &lt;entity-header, defined in [Part3], Section 3.1&gt;
5085
5086<x:ref>field-content</x:ref> = *( WSP / VCHAR / obs-text )
5087<x:ref>field-name</x:ref> = token
5088<x:ref>field-value</x:ref> = *( field-content / OWS )
5089
5090<x:ref>general-header</x:ref> = Cache-Control / Connection / Date / Pragma / Trailer
5091 / Transfer-Encoding / Upgrade / Via / Warning
5092
5093<x:ref>header-field</x:ref> = field-name ":" OWS [ field-value ] OWS
5094<x:ref>hour</x:ref> = 2DIGIT
5095<x:ref>http-URI</x:ref> = "http://" authority path-abempty [ "?" query ]
5096<x:ref>https-URI</x:ref> = "https://" authority path-abempty [ "?" query ]
5097
5098<x:ref>last-chunk</x:ref> = 1*"0" *WSP [ chunk-ext ] CRLF
5099
5100<x:ref>message-body</x:ref> = *OCTET
5101<x:ref>minute</x:ref> = 2DIGIT
5102<x:ref>month</x:ref> = %x4A.61.6E ; Jan
5103 / %x46.65.62 ; Feb
5104 / %x4D.61.72 ; Mar
5105 / %x41.70.72 ; Apr
5106 / %x4D.61.79 ; May
5107 / %x4A.75.6E ; Jun
5108 / %x4A.75.6C ; Jul
5109 / %x41.75.67 ; Aug
5110 / %x53.65.70 ; Sep
5111 / %x4F.63.74 ; Oct
5112 / %x4E.6F.76 ; Nov
5113 / %x44.65.63 ; Dec
5114
5115<x:ref>obs-date</x:ref> = rfc850-date / asctime-date
5116<x:ref>obs-fold</x:ref> = CRLF
5117<x:ref>obs-text</x:ref> = %x80-FF
5118
5119<x:ref>partial-URI</x:ref> = relative-part [ "?" query ]
5120<x:ref>path-abempty</x:ref> = &lt;path-abempty, defined in [RFC3986], Section 3.3&gt;
5121<x:ref>path-absolute</x:ref> = &lt;path-absolute, defined in [RFC3986], Section 3.3&gt;
5122<x:ref>port</x:ref> = &lt;port, defined in [RFC3986], Section 3.2.3&gt;
5123<x:ref>product</x:ref> = token [ "/" product-version ]
5124<x:ref>product-version</x:ref> = token
5125<x:ref>protocol-name</x:ref> = token
5126<x:ref>protocol-version</x:ref> = token
5127<x:ref>pseudonym</x:ref> = token
5128
5129<x:ref>qdtext</x:ref> = OWS / "!" / %x23-5B ; '#'-'['
5130 / %x5D-7E ; ']'-'~'
5131 / obs-text
5132<x:ref>qdtext-nf</x:ref> = WSP / "!" / %x23-5B ; '#'-'['
5133 / %x5D-7E ; ']'-'~'
5134 / obs-text
5135<x:ref>query</x:ref> = &lt;query, defined in [RFC3986], Section 3.4&gt;
5136<x:ref>quoted-cpair</x:ref> = "\" ( WSP / VCHAR / obs-text )
5137<x:ref>quoted-pair</x:ref> = "\" ( WSP / VCHAR / obs-text )
5138<x:ref>quoted-str-nf</x:ref> = DQUOTE *( qdtext-nf / quoted-pair ) DQUOTE
5139<x:ref>quoted-string</x:ref> = DQUOTE *( qdtext / quoted-pair ) DQUOTE
5140<x:ref>qvalue</x:ref> = ( "0" [ "." *3DIGIT ] ) / ( "1" [ "." *3"0" ] )
5141
5142<x:ref>received-by</x:ref> = ( uri-host [ ":" port ] ) / pseudonym
5143<x:ref>received-protocol</x:ref> = [ protocol-name "/" ] protocol-version
5144<x:ref>relative-part</x:ref> = &lt;relative-part, defined in [RFC3986], Section 4.2&gt;
5145<x:ref>request-header</x:ref> = &lt;request-header, defined in [Part2], Section 3&gt;
5146<x:ref>request-target</x:ref> = "*" / absolute-URI / ( path-absolute [ "?" query ] )
5147 / authority
5148<x:ref>response-header</x:ref> = &lt;response-header, defined in [Part2], Section 5&gt;
5149<x:ref>rfc1123-date</x:ref> = day-name "," SP date1 SP time-of-day SP GMT
5150<x:ref>rfc850-date</x:ref> = day-name-l "," SP date2 SP time-of-day SP GMT
5151
5152<x:ref>second</x:ref> = 2DIGIT
5153<x:ref>special</x:ref> = "(" / ")" / "&lt;" / "&gt;" / "@" / "," / ";" / ":" / "\" /
5154 DQUOTE / "/" / "[" / "]" / "?" / "=" / "{" / "}"
5155<x:ref>start-line</x:ref> = Request-Line / Status-Line
5156
5157<x:ref>t-codings</x:ref> = "trailers" / ( transfer-extension [ te-params ] )
5158<x:ref>tchar</x:ref> = "!" / "#" / "$" / "%" / "&amp;" / "'" / "*" / "+" / "-" / "." /
5159 "^" / "_" / "`" / "|" / "~" / DIGIT / ALPHA
5160<x:ref>te-ext</x:ref> = OWS ";" OWS token [ "=" word ]
5161<x:ref>te-params</x:ref> = OWS ";" OWS "q=" qvalue *te-ext
5162<x:ref>time-of-day</x:ref> = hour ":" minute ":" second
5163<x:ref>token</x:ref> = 1*tchar
5164<x:ref>trailer-part</x:ref> = *( entity-header CRLF )
5165<x:ref>transfer-coding</x:ref> = "chunked" / "compress" / "deflate" / "gzip" /
5166 transfer-extension
5167<x:ref>transfer-extension</x:ref> = token *( OWS ";" OWS transfer-parameter )
5168<x:ref>transfer-parameter</x:ref> = attribute BWS "=" BWS value
5169
5170<x:ref>uri-host</x:ref> = &lt;host, defined in [RFC3986], Section 3.2.2&gt;
5171
5172<x:ref>value</x:ref> = word
5173
5174<x:ref>word</x:ref> = token / quoted-string
5175
5176<x:ref>year</x:ref> = 4DIGIT
5177</artwork>
5178</figure>
5179<figure><preamble>ABNF diagnostics:</preamble><artwork type="inline">
5180; Chunked-Body defined but not used
5181; Content-Length defined but not used
5182; HTTP-message defined but not used
5183; Host defined but not used
5184; Request defined but not used
5185; Response defined but not used
5186; TE defined but not used
5187; URI-reference defined but not used
5188; http-URI defined but not used
5189; https-URI defined but not used
5190; partial-URI defined but not used
5191; special defined but not used
5192</artwork></figure></section>
5193<?ENDINC p1-messaging.abnf-appendix ?>
5194
5195<section title="Change Log (to be removed by RFC Editor before publication)" anchor="change.log">
5196
5197<section title="Since RFC2616">
5198<t>
5199  Extracted relevant partitions from <xref target="RFC2616"/>.
5200</t>
5201</section>
5202
5203<section title="Since draft-ietf-httpbis-p1-messaging-00">
5204<t>
5205  Closed issues:
5206  <list style="symbols"> 
5207    <t>
5208      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/1"/>:
5209      "HTTP Version should be case sensitive"
5210      (<eref target="http://purl.org/NET/http-errata#verscase"/>)
5211    </t>
5212    <t>
5213      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/2"/>:
5214      "'unsafe' characters"
5215      (<eref target="http://purl.org/NET/http-errata#unsafe-uri"/>)
5216    </t>
5217    <t>
5218      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/3"/>:
5219      "Chunk Size Definition"
5220      (<eref target="http://purl.org/NET/http-errata#chunk-size"/>)
5221    </t>
5222    <t>
5223      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/4"/>:
5224      "Message Length"
5225      (<eref target="http://purl.org/NET/http-errata#msg-len-chars"/>)
5226    </t>
5227    <t>
5228      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/8"/>:
5229      "Media Type Registrations"
5230      (<eref target="http://purl.org/NET/http-errata#media-reg"/>)
5231    </t>
5232    <t>
5233      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/11"/>:
5234      "URI includes query"
5235      (<eref target="http://purl.org/NET/http-errata#uriquery"/>)
5236    </t>
5237    <t>
5238      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/15"/>:
5239      "No close on 1xx responses"
5240      (<eref target="http://purl.org/NET/http-errata#noclose1xx"/>)
5241    </t>
5242    <t>
5243      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/16"/>:
5244      "Remove 'identity' token references"
5245      (<eref target="http://purl.org/NET/http-errata#identity"/>)
5246    </t>
5247    <t>
5248      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/26"/>:
5249      "Import query BNF"
5250    </t>
5251    <t>
5252      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/31"/>:
5253      "qdtext BNF"
5254    </t>
5255    <t>
5256      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/35"/>:
5257      "Normative and Informative references"
5258    </t>
5259    <t>
5260      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/42"/>:
5261      "RFC2606 Compliance"
5262    </t>
5263    <t>
5264      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/45"/>:
5265      "RFC977 reference"
5266    </t>
5267    <t>
5268      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/46"/>:
5269      "RFC1700 references"
5270    </t>
5271    <t>
5272      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/47"/>:
5273      "inconsistency in date format explanation"
5274    </t>
5275    <t>
5276      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/48"/>:
5277      "Date reference typo"
5278    </t>
5279    <t>
5280      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/65"/>:
5281      "Informative references"
5282    </t>
5283    <t>
5284      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/66"/>:
5285      "ISO-8859-1 Reference"
5286    </t>
5287    <t>
5288      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/86"/>:
5289      "Normative up-to-date references"
5290    </t>
5291  </list>
5292</t>
5293<t>
5294  Other changes:
5295  <list style="symbols"> 
5296    <t>
5297      Update media type registrations to use RFC4288 template.
5298    </t>
5299    <t>
5300      Use names of RFC4234 core rules DQUOTE and WSP,
5301      fix broken ABNF for chunk-data
5302      (work in progress on <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/36"/>)
5303    </t>
5304  </list>
5305</t>
5306</section>
5307
5308<section title="Since draft-ietf-httpbis-p1-messaging-01">
5309<t>
5310  Closed issues:
5311  <list style="symbols"> 
5312    <t>
5313      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/19"/>:
5314      "Bodies on GET (and other) requests"
5315    </t>
5316    <t>
5317      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/55"/>:
5318      "Updating to RFC4288"
5319    </t>
5320    <t>
5321      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/57"/>:
5322      "Status Code and Reason Phrase"
5323    </t>
5324    <t>
5325      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/82"/>:
5326      "rel_path not used"
5327    </t>
5328  </list>
5329</t>
5330<t>
5331  Ongoing work on ABNF conversion (<eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/36"/>):
5332  <list style="symbols"> 
5333    <t>
5334      Get rid of duplicate BNF rule names ("host" -> "uri-host", "trailer" ->
5335      "trailer-part").
5336    </t>
5337    <t>
5338      Avoid underscore character in rule names ("http_URL" ->
5339      "http-URL", "abs_path" -> "path-absolute").
5340    </t>
5341    <t>
5342      Add rules for terms imported from URI spec ("absoluteURI", "authority",
5343      "path-absolute", "port", "query", "relativeURI", "host) -- these will
5344      have to be updated when switching over to RFC3986.
5345    </t>
5346    <t>
5347      Synchronize core rules with RFC5234.
5348    </t>
5349    <t>
5350      Get rid of prose rules that span multiple lines.
5351    </t>
5352    <t>
5353      Get rid of unused rules LOALPHA and UPALPHA.
5354    </t>
5355    <t>
5356      Move "Product Tokens" section (back) into Part 1, as "token" is used
5357      in the definition of the Upgrade header.
5358    </t>
5359    <t>
5360      Add explicit references to BNF syntax and rules imported from other parts of the specification.
5361    </t>
5362    <t>
5363      Rewrite prose rule "token" in terms of "tchar", rewrite prose rule "TEXT".
5364    </t>
5365  </list>
5366</t>
5367</section>
5368
5369<section title="Since draft-ietf-httpbis-p1-messaging-02" anchor="changes.since.02">
5370<t>
5371  Closed issues:
5372  <list style="symbols"> 
5373    <t>
5374      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/51"/>:
5375      "HTTP-date vs. rfc1123-date"
5376    </t>
5377    <t>
5378      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/64"/>:
5379      "WS in quoted-pair"
5380    </t>
5381  </list>
5382</t>
5383<t>
5384  Ongoing work on IANA Message Header Registration (<eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/40"/>):
5385  <list style="symbols"> 
5386    <t>
5387      Reference RFC 3984, and update header registrations for headers defined
5388      in this document.
5389    </t>
5390  </list>
5391</t>
5392<t>
5393  Ongoing work on ABNF conversion (<eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/36"/>):
5394  <list style="symbols"> 
5395    <t>
5396      Replace string literals when the string really is case-sensitive (HTTP-Version).
5397    </t>
5398  </list>
5399</t>
5400</section>
5401
5402<section title="Since draft-ietf-httpbis-p1-messaging-03" anchor="changes.since.03">
5403<t>
5404  Closed issues:
5405  <list style="symbols"> 
5406    <t>
5407      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/28"/>:
5408      "Connection closing"
5409    </t>
5410    <t>
5411      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/97"/>:
5412      "Move registrations and registry information to IANA Considerations"
5413    </t>
5414    <t>
5415      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/120"/>:
5416      "need new URL for PAD1995 reference"
5417    </t>
5418    <t>
5419      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/127"/>:
5420      "IANA Considerations: update HTTP URI scheme registration"
5421    </t>
5422    <t>
5423      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/128"/>:
5424      "Cite HTTPS URI scheme definition"
5425    </t>
5426    <t>
5427      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/129"/>:
5428      "List-type headers vs Set-Cookie"
5429    </t>
5430  </list>
5431</t>
5432<t>
5433  Ongoing work on ABNF conversion (<eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/36"/>):
5434  <list style="symbols"> 
5435    <t>
5436      Replace string literals when the string really is case-sensitive (HTTP-Date).
5437    </t>
5438    <t>
5439      Replace HEX by HEXDIG for future consistence with RFC 5234's core rules.
5440    </t>
5441  </list>
5442</t>
5443</section>
5444
5445<section title="Since draft-ietf-httpbis-p1-messaging-04" anchor="changes.since.04">
5446<t>
5447  Closed issues:
5448  <list style="symbols"> 
5449    <t>
5450      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/34"/>:
5451      "Out-of-date reference for URIs"
5452    </t>
5453    <t>
5454      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/132"/>:
5455      "RFC 2822 is updated by RFC 5322"
5456    </t>
5457  </list>
5458</t>
5459<t>
5460  Ongoing work on ABNF conversion (<eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/36"/>):
5461  <list style="symbols"> 
5462    <t>
5463      Use "/" instead of "|" for alternatives.
5464    </t>
5465    <t>
5466      Get rid of RFC822 dependency; use RFC5234 plus extensions instead.
5467    </t>
5468    <t>
5469      Only reference RFC 5234's core rules.
5470    </t>
5471    <t>
5472      Introduce new ABNF rules for "bad" whitespace ("BWS"), optional
5473      whitespace ("OWS") and required whitespace ("RWS").
5474    </t>
5475    <t>
5476      Rewrite ABNFs to spell out whitespace rules, factor out
5477      header value format definitions.
5478    </t>
5479  </list>
5480</t>
5481</section>
5482
5483<section title="Since draft-ietf-httpbis-p1-messaging-05" anchor="changes.since.05">
5484<t>
5485  Closed issues:
5486  <list style="symbols"> 
5487    <t>
5488      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/30"/>:
5489      "Header LWS"
5490    </t>
5491    <t>
5492      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/52"/>:
5493      "Sort 1.3 Terminology"
5494    </t>
5495    <t>
5496      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/63"/>:
5497      "RFC2047 encoded words"
5498    </t>
5499    <t>
5500      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/74"/>:
5501      "Character Encodings in TEXT"
5502    </t>
5503    <t>
5504      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/77"/>:
5505      "Line Folding"
5506    </t>
5507    <t>
5508      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/83"/>:
5509      "OPTIONS * and proxies"
5510    </t>
5511    <t>
5512      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/94"/>:
5513      "Reason-Phrase BNF"
5514    </t>
5515    <t>
5516      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/111"/>:
5517      "Use of TEXT"
5518    </t>
5519    <t>
5520      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/118"/>:
5521      "Join "Differences Between HTTP Entities and RFC 2045 Entities"?"
5522    </t>
5523    <t>
5524      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/134"/>:
5525      "RFC822 reference left in discussion of date formats"
5526    </t>
5527  </list>
5528</t>
5529<t>
5530  Final work on ABNF conversion (<eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/36"/>):
5531  <list style="symbols"> 
5532    <t>
5533      Rewrite definition of list rules, deprecate empty list elements.
5534    </t>
5535    <t>
5536      Add appendix containing collected and expanded ABNF.
5537    </t>
5538  </list>
5539</t>
5540<t>
5541  Other changes:
5542  <list style="symbols"> 
5543    <t>
5544      Rewrite introduction; add mostly new Architecture Section.
5545    </t>
5546    <t>
5547      Move definition of quality values from Part 3 into Part 1;
5548      make TE request header grammar independent of accept-params (defined in Part 3).
5549    </t>
5550  </list>
5551</t>
5552</section>
5553
5554<section title="Since draft-ietf-httpbis-p1-messaging-06" anchor="changes.since.06">
5555<t>
5556  Closed issues:
5557  <list style="symbols"> 
5558    <t>
5559      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/161"/>:
5560      "base for numeric protocol elements"
5561    </t>
5562    <t>
5563      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/162"/>:
5564      "comment ABNF"
5565    </t>
5566  </list>
5567</t>
5568<t>
5569  Partly resolved issues:
5570  <list style="symbols"> 
5571    <t>
5572      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/88"/>:
5573      "205 Bodies" (took out language that implied that there may be
5574      methods for which a request body MUST NOT be included)
5575    </t>
5576    <t>
5577      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/163"/>:
5578      "editorial improvements around HTTP-date"
5579    </t>
5580  </list>
5581</t>
5582</section>
5583
5584<section title="Since draft-ietf-httpbis-p1-messaging-07" anchor="changes.since.07">
5585<t>
5586  Closed issues:
5587  <list style="symbols"> 
5588    <t>
5589      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/93"/>:
5590      "Repeating single-value headers"
5591    </t>
5592    <t>
5593      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/131"/>:
5594      "increase connection limit"
5595    </t>
5596    <t>
5597      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/157"/>:
5598      "IP addresses in URLs"
5599    </t>
5600    <t>
5601      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/172"/>:
5602      "take over HTTP Upgrade Token Registry"
5603    </t>
5604    <t>
5605      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/173"/>:
5606      "CR and LF in chunk extension values"
5607    </t>
5608    <t>
5609      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/184"/>:
5610      "HTTP/0.9 support"
5611    </t>
5612    <t>
5613      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/188"/>:
5614      "pick IANA policy (RFC5226) for Transfer Coding / Content Coding"
5615    </t>
5616    <t>
5617      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/189"/>:
5618      "move definitions of gzip/deflate/compress to part 1"
5619    </t>
5620    <t>
5621      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/194"/>:
5622      "disallow control characters in quoted-pair"
5623    </t>
5624  </list>
5625</t>
5626<t>
5627  Partly resolved issues:
5628  <list style="symbols"> 
5629    <t>
5630      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/148"/>:
5631      "update IANA requirements wrt Transfer-Coding values" (add the
5632      IANA Considerations subsection)
5633    </t>
5634  </list>
5635</t>
5636</section>
5637
5638<section title="Since draft-ietf-httpbis-p1-messaging-08" anchor="changes.since.08">
5639<t>
5640  Closed issues:
5641  <list style="symbols"> 
5642    <t>
5643      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/201"/>:
5644      "header parsing, treatment of leading and trailing OWS"
5645    </t>
5646  </list>
5647</t>
5648<t>
5649  Partly resolved issues:
5650  <list style="symbols"> 
5651    <t>
5652      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/60"/>:
5653      "Placement of 13.5.1 and 13.5.2"
5654    </t>
5655    <t>
5656      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/200"/>:
5657      "use of term "word" when talking about header structure"
5658    </t>
5659  </list>
5660</t>
5661</section>
5662
5663<section title="Since draft-ietf-httpbis-p1-messaging-09" anchor="changes.since.09">
5664<t>
5665  Closed issues:
5666  <list style="symbols"> 
5667    <t>
5668      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/73"/>:
5669      "Clarification of the term 'deflate'"
5670    </t>
5671    <t>
5672      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/83"/>:
5673      "OPTIONS * and proxies"
5674    </t>
5675    <t>
5676      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/143"/>:
5677      "IANA registry for content/transfer encodings"
5678    </t>
5679    <t>
5680      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/165"/>:
5681      "Case-sensitivity of HTTP-date"
5682    </t>
5683    <t>
5684      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/200"/>:
5685      "use of term "word" when talking about header structure"
5686    </t>
5687  </list>
5688</t>
5689<t>
5690  Partly resolved issues:
5691  <list style="symbols"> 
5692    <t>
5693      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/196"/>:
5694      "Term for the requested resource's URI"
5695    </t>
5696  </list>
5697</t>
5698</section>
5699
5700<section title="Since draft-ietf-httpbis-p1-messaging-10" anchor="changes.since.10">
5701<t>
5702  Closed issues:
5703  <list style="symbols">
5704    <t>
5705      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/28"/>:
5706      "Connection Closing"
5707    </t>
5708    <t>
5709      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/90"/>:
5710      "Delimiting messages with multipart/byteranges"
5711    </t>
5712    <t>
5713      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/95"/>:
5714      "Handling multiple Content-Length headers"
5715    </t>
5716  </list>
5717</t>
5718</section>
5719
5720</section>
5721
5722</back>
5723</rfc>
Note: See TracBrowser for help on using the repository browser.