Changeset 2406 for draft-ietf-httpbis


Ignore:
Timestamp:
17/09/13 06:50:58 (7 years ago)
Author:
fielding@…
Message:

un-deprecate chunk extensions and explain them in a new section; addresses #343

Location:
draft-ietf-httpbis/latest
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • draft-ietf-httpbis/latest/p1-messaging.html

    r2405 r2406  
    446446  }
    447447  @bottom-center {
    448        content: "Expires March 21, 2014";
     448       content: "Expires March 20, 2014";
    449449  }
    450450  @bottom-right {
     
    488488      <meta name="dct.creator" content="Reschke, J. F.">
    489489      <meta name="dct.identifier" content="urn:ietf:id:draft-ietf-httpbis-p1-messaging-latest">
    490       <meta name="dct.issued" scheme="ISO8601" content="2013-09-17">
     490      <meta name="dct.issued" scheme="ISO8601" content="2013-09-16">
    491491      <meta name="dct.replaces" content="urn:ietf:rfc:2145">
    492492      <meta name="dct.replaces" content="urn:ietf:rfc:2616">
     
    517517            <tr>
    518518               <td class="left">Intended status: Standards Track</td>
    519                <td class="right">September 17, 2013</td>
     519               <td class="right">September 16, 2013</td>
    520520            </tr>
    521521            <tr>
    522                <td class="left">Expires: March 21, 2014</td>
     522               <td class="left">Expires: March 20, 2014</td>
    523523               <td class="right"></td>
    524524            </tr>
     
    548548         in progress”.
    549549      </p>
    550       <p>This Internet-Draft will expire on March 21, 2014.</p>
     550      <p>This Internet-Draft will expire on March 20, 2014.</p>
    551551      <h1><a id="rfc.copyrightnotice" href="#rfc.copyrightnotice">Copyright Notice</a></h1>
    552552      <p>Copyright © 2013 IETF Trust and the persons identified as the document authors. All rights reserved.</p>
     
    613613         <li><a href="#rfc.section.4">4.</a>&nbsp;&nbsp;&nbsp;<a href="#transfer.codings">Transfer Codings</a><ul>
    614614               <li><a href="#rfc.section.4.1">4.1</a>&nbsp;&nbsp;&nbsp;<a href="#chunked.encoding">Chunked Transfer Coding</a><ul>
    615                      <li><a href="#rfc.section.4.1.1">4.1.1</a>&nbsp;&nbsp;&nbsp;<a href="#chunked.trailer.part">Chunked Trailer Part</a></li>
    616                      <li><a href="#rfc.section.4.1.2">4.1.2</a>&nbsp;&nbsp;&nbsp;<a href="#decoding.chunked">Decoding Chunked</a></li>
     615                     <li><a href="#rfc.section.4.1.1">4.1.1</a>&nbsp;&nbsp;&nbsp;<a href="#chunked.extension">Chunk Extensions</a></li>
     616                     <li><a href="#rfc.section.4.1.2">4.1.2</a>&nbsp;&nbsp;&nbsp;<a href="#chunked.trailer.part">Chunked Trailer Part</a></li>
     617                     <li><a href="#rfc.section.4.1.3">4.1.3</a>&nbsp;&nbsp;&nbsp;<a href="#decoding.chunked">Decoding Chunked</a></li>
    617618                  </ul>
    618619               </li>
     
    15911592      <div id="rfc.iref.c.9"></div>
    15921593      <h2 id="rfc.section.4.1"><a href="#rfc.section.4.1">4.1</a>&nbsp;<a id="chunked.encoding" href="#chunked.encoding">Chunked Transfer Coding</a></h2>
    1593       <p id="rfc.section.4.1.p.1">The chunked transfer coding modifies the body of a message in order to transfer it as a series of chunks, each with its own
    1594          size indicator, followed by an <em class="bcp14">OPTIONAL</em> trailer containing header fields. This allows dynamically generated content to be transferred along with the information necessary
    1595          for the recipient to verify that it has received the full message.
     1594      <p id="rfc.section.4.1.p.1">The chunked transfer coding wraps the payload body in order to transfer it as a series of chunks, each with its own size indicator,
     1595         followed by an <em class="bcp14">OPTIONAL</em> trailer containing header fields. Chunked enables content streams of unknown size to be transferred as a sequence of length-delimited
     1596         buffers, which enables the sender to retain connection persistence and the recipient to know when it has received the entire
     1597         message.
    15961598      </p>
    15971599      <div id="rfc.figure.u.32"></div><pre class="inline"><span id="rfc.iref.g.64"></span><span id="rfc.iref.g.65"></span><span id="rfc.iref.g.66"></span><span id="rfc.iref.g.67"></span><span id="rfc.iref.g.68"></span><span id="rfc.iref.g.69"></span><span id="rfc.iref.g.70"></span><span id="rfc.iref.g.71"></span><span id="rfc.iref.g.72"></span><span id="rfc.iref.g.73"></span><span id="rfc.iref.g.74"></span>  <a href="#chunked.encoding" class="smpl">chunked-body</a>   = *<a href="#chunked.encoding" class="smpl">chunk</a>
     
    16001602                   <a href="#core.rules" class="smpl">CRLF</a>
    16011603 
    1602   <a href="#chunked.encoding" class="smpl">chunk</a>          = <a href="#chunked.encoding" class="smpl">chunk-size</a> [ <a href="#chunked.encoding" class="smpl">chunk-ext</a> ] <a href="#core.rules" class="smpl">CRLF</a>
     1604  <a href="#chunked.encoding" class="smpl">chunk</a>          = <a href="#chunked.encoding" class="smpl">chunk-size</a> [ <a href="#chunked.extension" class="smpl">chunk-ext</a> ] <a href="#core.rules" class="smpl">CRLF</a>
    16031605                   <a href="#chunked.encoding" class="smpl">chunk-data</a> <a href="#core.rules" class="smpl">CRLF</a>
    16041606  <a href="#chunked.encoding" class="smpl">chunk-size</a>     = 1*<a href="#core.rules" class="smpl">HEXDIG</a>
    1605   <a href="#chunked.encoding" class="smpl">last-chunk</a>     = 1*("0") [ <a href="#chunked.encoding" class="smpl">chunk-ext</a> ] <a href="#core.rules" class="smpl">CRLF</a>
     1607  <a href="#chunked.encoding" class="smpl">last-chunk</a>     = 1*("0") [ <a href="#chunked.extension" class="smpl">chunk-ext</a> ] <a href="#core.rules" class="smpl">CRLF</a>
    16061608 
    1607   <a href="#chunked.encoding" class="smpl">chunk-ext</a>      = *( ";" <a href="#chunked.encoding" class="smpl">chunk-ext-name</a> [ "=" <a href="#chunked.encoding" class="smpl">chunk-ext-val</a> ] )
    1608   <a href="#chunked.encoding" class="smpl">chunk-ext-name</a> = <a href="#rule.token.separators" class="smpl">token</a>
    1609   <a href="#chunked.encoding" class="smpl">chunk-ext-val</a>  = <a href="#rule.token.separators" class="smpl">token</a> / <a href="#chunked.encoding" class="smpl">quoted-str-nf</a>
    16101609  <a href="#chunked.encoding" class="smpl">chunk-data</a>     = 1*<a href="#core.rules" class="smpl">OCTET</a> ; a sequence of chunk-size octets
    1611  
    1612   <a href="#chunked.encoding" class="smpl">quoted-str-nf</a>  = <a href="#core.rules" class="smpl">DQUOTE</a> *( <a href="#chunked.encoding" class="smpl">qdtext-nf</a> / <a href="#rule.quoted-pair" class="smpl">quoted-pair</a> ) <a href="#core.rules" class="smpl">DQUOTE</a>
    1613                  ; like <a href="#rule.quoted-string" class="smpl">quoted-string</a>, but disallowing line folding
    1614   <a href="#chunked.encoding" class="smpl">qdtext-nf</a>      = <a href="#core.rules" class="smpl">HTAB</a> / <a href="#core.rules" class="smpl">SP</a> / %x21 / %x23-5B / %x5D-7E / <a href="#rule.quoted-string" class="smpl">obs-text</a>
    1615 </pre><p id="rfc.section.4.1.p.3">Chunk extensions need to be used carefully because use of chunking does not have any semantics related to the message; it
    1616          is by definition hop-by-hop and thus can be removed/reformatted by any intermediary. Furthermore, few implementations expose
    1617          information about their contents.
    1618       </p>
    1619       <p id="rfc.section.4.1.p.4">The chunk-size field is a string of hex digits indicating the size of the chunk-data in octets. The chunked transfer coding
     1610</pre><p id="rfc.section.4.1.p.3">The chunk-size field is a string of hex digits indicating the size of the chunk-data in octets. The chunked transfer coding
    16201611         is complete when a chunk with a chunk-size of zero is received, possibly followed by a trailer, and finally terminated by
    16211612         an empty line.
    16221613      </p>
    1623       <h3 id="rfc.section.4.1.1"><a href="#rfc.section.4.1.1">4.1.1</a>&nbsp;<a id="chunked.trailer.part" href="#chunked.trailer.part">Chunked Trailer Part</a></h3>
    1624       <p id="rfc.section.4.1.1.p.1">A trailer allows the sender to include additional fields at the end of a chunked message in order to supply metadata that
     1614      <p id="rfc.section.4.1.p.4">A recipient <em class="bcp14">MUST</em> be able to parse and decode the chunked transfer coding.
     1615      </p>
     1616      <h3 id="rfc.section.4.1.1"><a href="#rfc.section.4.1.1">4.1.1</a>&nbsp;<a id="chunked.extension" href="#chunked.extension">Chunk Extensions</a></h3>
     1617      <p id="rfc.section.4.1.1.p.1">The chunked encoding allows each chunk to include zero or more chunk extensions, immediately following the <a href="#chunked.encoding" class="smpl">chunk-size</a>, for the sake of supplying per-chunk metadata (such as a signature or hash), mid-message control information, or randomization
     1618         of message body size.
     1619      </p>
     1620      <div id="rfc.figure.u.33"></div><pre class="inline"><span id="rfc.iref.g.75"></span><span id="rfc.iref.g.76"></span><span id="rfc.iref.g.77"></span><span id="rfc.iref.g.78"></span><span id="rfc.iref.g.79"></span><span id="rfc.iref.g.80"></span><span id="rfc.iref.g.81"></span><span id="rfc.iref.g.82"></span><span id="rfc.iref.g.83"></span><span id="rfc.iref.g.84"></span><span id="rfc.iref.g.85"></span>  <a href="#chunked.extension" class="smpl">chunk-ext</a>      = *( ";" <a href="#chunked.extension" class="smpl">chunk-ext-name</a> [ "=" <a href="#chunked.extension" class="smpl">chunk-ext-val</a> ] )
     1621
     1622  <a href="#chunked.extension" class="smpl">chunk-ext-name</a> = <a href="#rule.token.separators" class="smpl">token</a>
     1623  <a href="#chunked.extension" class="smpl">chunk-ext-val</a>  = <a href="#rule.token.separators" class="smpl">token</a> / <a href="#chunked.extension" class="smpl">quoted-str-nf</a>
     1624 
     1625  <a href="#chunked.extension" class="smpl">quoted-str-nf</a>  = <a href="#core.rules" class="smpl">DQUOTE</a> *( <a href="#chunked.extension" class="smpl">qdtext-nf</a> / <a href="#rule.quoted-pair" class="smpl">quoted-pair</a> ) <a href="#core.rules" class="smpl">DQUOTE</a>
     1626                 ; like <a href="#rule.quoted-string" class="smpl">quoted-string</a>, but disallowing line folding
     1627  <a href="#chunked.extension" class="smpl">qdtext-nf</a>      = <a href="#core.rules" class="smpl">HTAB</a> / <a href="#core.rules" class="smpl">SP</a> / %x21 / %x23-5B / %x5D-7E / <a href="#rule.quoted-string" class="smpl">obs-text</a>
     1628</pre><p id="rfc.section.4.1.1.p.3">The chunked encoding is specific to each connection and is likely to be removed or recoded by each recipient (including intermediaries)
     1629         before any higher-level application would have a chance to inspect the extensions. Hence, use of chunk extensions is generally
     1630         limited to specialized HTTP services such as "long polling" (where client and server can have shared expectations regarding
     1631         the use of chunk extensions) or for padding within an end-to-end secured connection.
     1632      </p>
     1633      <p id="rfc.section.4.1.1.p.4">A recipient <em class="bcp14">MUST</em> ignore unrecognized chunk extensions. A server ought to limit the total length of chunk extensions received in a request to
     1634         an amount reasonable for the services provided, in the same way that it applies length limitations and timeouts for other
     1635         parts of a message, and generate an appropriate <a href="p2-semantics.html#status.4xx" class="smpl">4xx (Client Error)</a> response if that amount is exceeded.
     1636      </p>
     1637      <h3 id="rfc.section.4.1.2"><a href="#rfc.section.4.1.2">4.1.2</a>&nbsp;<a id="chunked.trailer.part" href="#chunked.trailer.part">Chunked Trailer Part</a></h3>
     1638      <p id="rfc.section.4.1.2.p.1">A trailer allows the sender to include additional fields at the end of a chunked message in order to supply metadata that
    16251639         might be dynamically generated while the message body is sent, such as a message integrity check, digital signature, or post-processing
    16261640         status. The trailer fields are identical to header fields, except they are sent in a chunked trailer instead of the message's
    16271641         header section.
    16281642      </p>
    1629       <div id="rfc.figure.u.33"></div><pre class="inline"><span id="rfc.iref.g.75"></span>  <a href="#chunked.trailer.part" class="smpl">trailer-part</a>   = *( <a href="#header.fields" class="smpl">header-field</a> <a href="#core.rules" class="smpl">CRLF</a> )
    1630 </pre><p id="rfc.section.4.1.1.p.3">A sender <em class="bcp14">MUST NOT</em> generate a trailer that contains a field which needs to be known by the recipient before it can begin processing the message
     1643      <div id="rfc.figure.u.34"></div><pre class="inline"><span id="rfc.iref.g.86"></span>  <a href="#chunked.trailer.part" class="smpl">trailer-part</a>   = *( <a href="#header.fields" class="smpl">header-field</a> <a href="#core.rules" class="smpl">CRLF</a> )
     1644</pre><p id="rfc.section.4.1.2.p.3">A sender <em class="bcp14">MUST NOT</em> generate a trailer that contains a field which needs to be known by the recipient before it can begin processing the message
    16311645         body. For example, most recipients need to know the values of <a href="p2-semantics.html#header.content-encoding" class="smpl">Content-Encoding</a> and <a href="p2-semantics.html#header.content-type" class="smpl">Content-Type</a> in order to select a content handler, so placing those fields in a trailer would force the recipient to buffer the entire
    16321646         body before it could begin, greatly increasing user-perceived latency and defeating one of the main advantages of using chunked
    16331647         to send data streams of unknown length. A sender <em class="bcp14">MUST NOT</em> generate a trailer containing a <a href="#header.transfer-encoding" class="smpl">Transfer-Encoding</a>, <a href="#header.content-length" class="smpl">Content-Length</a>, or <a href="#header.trailer" class="smpl">Trailer</a> field.
    16341648      </p>
    1635       <p id="rfc.section.4.1.1.p.4">A server <em class="bcp14">MUST</em> generate an empty trailer with the chunked transfer coding unless at least one of the following is true:
     1649      <p id="rfc.section.4.1.2.p.4">A server <em class="bcp14">MUST</em> generate an empty trailer with the chunked transfer coding unless at least one of the following is true:
    16361650      </p>
    16371651      <ol>
     
    16431657         </li>
    16441658      </ol>
    1645       <p id="rfc.section.4.1.1.p.5">The above requirement prevents the need for an infinite buffer when a message is being received by an HTTP/1.1 (or later)
     1659      <p id="rfc.section.4.1.2.p.5">The above requirement prevents the need for an infinite buffer when a message is being received by an HTTP/1.1 (or later)
    16461660         proxy and forwarded to an HTTP/1.0 recipient.
    16471661      </p>
    1648       <h3 id="rfc.section.4.1.2"><a href="#rfc.section.4.1.2">4.1.2</a>&nbsp;<a id="decoding.chunked" href="#decoding.chunked">Decoding Chunked</a></h3>
    1649       <p id="rfc.section.4.1.2.p.1">A process for decoding the chunked transfer coding can be represented in pseudo-code as:</p>
    1650       <div id="rfc.figure.u.34"></div><pre class="text">  length := 0
     1662      <h3 id="rfc.section.4.1.3"><a href="#rfc.section.4.1.3">4.1.3</a>&nbsp;<a id="decoding.chunked" href="#decoding.chunked">Decoding Chunked</a></h3>
     1663      <p id="rfc.section.4.1.3.p.1">A process for decoding the chunked transfer coding can be represented in pseudo-code as:</p>
     1664      <div id="rfc.figure.u.35"></div><pre class="text">  length := 0
    16511665  read chunk-size, chunk-ext (if any), and CRLF
    16521666  while (chunk-size &gt; 0) {
     
    16641678  Remove "chunked" from Transfer-Encoding
    16651679  Remove Trailer from existing header fields
    1666 </pre><p id="rfc.section.4.1.2.p.3">A recipient <em class="bcp14">MUST</em> be able to parse and decode the chunked transfer coding and <em class="bcp14">MUST</em> ignore chunk-ext extensions they do not understand.
    1667       </p>
    1668       <h2 id="rfc.section.4.2"><a href="#rfc.section.4.2">4.2</a>&nbsp;<a id="compression.codings" href="#compression.codings">Compression Codings</a></h2>
     1680</pre><h2 id="rfc.section.4.2"><a href="#rfc.section.4.2">4.2</a>&nbsp;<a id="compression.codings" href="#compression.codings">Compression Codings</a></h2>
    16691681      <p id="rfc.section.4.2.p.1">The codings defined below can be used to compress the payload of a message.</p>
    16701682      <div id="rfc.iref.c.10"></div>
     
    16801692         </p>
    16811693      </div>
    1682       <div id="rfc.iref.g.76"></div>
     1694      <div id="rfc.iref.g.87"></div>
    16831695      <h3 id="rfc.section.4.2.3"><a href="#rfc.section.4.2.3">4.2.3</a>&nbsp;<a id="gzip.coding" href="#gzip.coding">Gzip Coding</a></h3>
    16841696      <p id="rfc.section.4.2.3.p.1">The "gzip" coding is an LZ77 coding with a 32 bit CRC that is commonly produced by the gzip file compression program <a href="#RFC1952" id="rfc.xref.RFC1952.1"><cite title="GZIP file format specification version 4.3">[RFC1952]</cite></a>. A recipient <em class="bcp14">SHOULD</em> consider "x-gzip" to be equivalent to "gzip".
     
    16921704         described in <a href="#transfer.codings" title="Transfer Codings">Section&nbsp;4</a>), and/or the keyword "trailers". A client <em class="bcp14">MUST NOT</em> send the chunked transfer coding name in TE; chunked is always acceptable for HTTP/1.1 recipients.
    16931705      </p>
    1694       <div id="rfc.figure.u.35"></div><pre class="inline"><span id="rfc.iref.g.77"></span><span id="rfc.iref.g.78"></span><span id="rfc.iref.g.79"></span><span id="rfc.iref.g.80"></span>  <a href="#header.te" class="smpl">TE</a>        = #<a href="#header.te" class="smpl">t-codings</a>
     1706      <div id="rfc.figure.u.36"></div><pre class="inline"><span id="rfc.iref.g.88"></span><span id="rfc.iref.g.89"></span><span id="rfc.iref.g.90"></span><span id="rfc.iref.g.91"></span>  <a href="#header.te" class="smpl">TE</a>        = #<a href="#header.te" class="smpl">t-codings</a>
    16951707  <a href="#header.te" class="smpl">t-codings</a> = "trailers" / ( <a href="#transfer.codings" class="smpl">transfer-coding</a> [ <a href="#header.te" class="smpl">t-ranking</a> ] )
    16961708  <a href="#header.te" class="smpl">t-ranking</a> = <a href="#rule.whitespace" class="smpl">OWS</a> ";" <a href="#rule.whitespace" class="smpl">OWS</a> "q=" <a href="#header.te" class="smpl">rank</a>
     
    16981710             / ( "1" [ "." 0*3("0") ] )
    16991711</pre><p id="rfc.section.4.3.p.4">Three examples of TE use are below.</p>
    1700       <div id="rfc.figure.u.36"></div><pre class="text">  TE: deflate
     1712      <div id="rfc.figure.u.37"></div><pre class="text">  TE: deflate
    17011713  TE:
    17021714  TE: trailers, deflate;q=0.5
    17031715</pre><p id="rfc.section.4.3.p.6">The presence of the keyword "trailers" indicates that the client is willing to accept trailer fields in a chunked transfer
    1704          coding, as defined in <a href="#chunked.trailer.part" title="Chunked Trailer Part">Section&nbsp;4.1.1</a>, on behalf of itself and any downstream clients. For requests from an intermediary, this implies that either: (a) all downstream
     1716         coding, as defined in <a href="#chunked.trailer.part" title="Chunked Trailer Part">Section&nbsp;4.1.2</a>, on behalf of itself and any downstream clients. For requests from an intermediary, this implies that either: (a) all downstream
    17051717         clients are willing to accept trailer fields in the forwarded response; or, (b) the intermediary will attempt to buffer the
    17061718         response on behalf of downstream recipients. Note that HTTP/1.1 does not define any means to limit the size of a chunked response
     
    17231735         and the recipient wishes to confirm an integrity check on the fly.
    17241736      </p>
    1725       <div id="rfc.figure.u.37"></div><pre class="inline"><span id="rfc.iref.g.81"></span>  <a href="#header.trailer" class="smpl">Trailer</a> = 1#<a href="#header.fields" class="smpl">field-name</a>
     1737      <div id="rfc.figure.u.38"></div><pre class="inline"><span id="rfc.iref.g.92"></span>  <a href="#header.trailer" class="smpl">Trailer</a> = 1#<a href="#header.fields" class="smpl">field-name</a>
    17261738</pre><h1 id="rfc.section.5"><a href="#rfc.section.5">5.</a>&nbsp;<a id="message.routing" href="#message.routing">Message Routing</a></h1>
    17271739      <p id="rfc.section.5.p.1">HTTP request message routing is determined by each client based on the target resource, the client's proxy configuration,
     
    17621774         both the method being requested and whether the request is to a proxy.
    17631775      </p>
    1764       <div id="rfc.figure.u.38"></div><pre class="inline"><span id="rfc.iref.g.82"></span><span id="rfc.iref.g.83"></span><span id="rfc.iref.g.84"></span><span id="rfc.iref.g.85"></span><span id="rfc.iref.g.86"></span>  <a href="#request-target" class="smpl">request-target</a> = <a href="#origin-form" class="smpl">origin-form</a>
     1776      <div id="rfc.figure.u.39"></div><pre class="inline"><span id="rfc.iref.g.93"></span><span id="rfc.iref.g.94"></span><span id="rfc.iref.g.95"></span><span id="rfc.iref.g.96"></span><span id="rfc.iref.g.97"></span>  <a href="#request-target" class="smpl">request-target</a> = <a href="#origin-form" class="smpl">origin-form</a>
    17651777                 / <a href="#absolute-form" class="smpl">absolute-form</a>
    17661778                 / <a href="#authority-form" class="smpl">authority-form</a>
     
    17801792      </p>
    17811793      <p id="rfc.section.5.3.p.5">For example, a client wishing to retrieve a representation of the resource identified as</p>
    1782       <div id="rfc.figure.u.39"></div><pre class="text">http://www.example.org/where?q=now
     1794      <div id="rfc.figure.u.40"></div><pre class="text">http://www.example.org/where?q=now
    17831795</pre><p id="rfc.section.5.3.p.7">directly from the origin server would open (or reuse) a TCP connection to port 80 of the host "www.example.org" and send the
    17841796         lines:
    17851797      </p>
    1786       <div id="rfc.figure.u.40"></div><pre class="text2">GET /where?q=now HTTP/1.1
     1798      <div id="rfc.figure.u.41"></div><pre class="text2">GET /where?q=now HTTP/1.1
    17871799Host: www.example.org
    17881800</pre><p id="rfc.section.5.3.p.9">followed by the remainder of the request message.</p>
     
    17961808      </p>
    17971809      <p id="rfc.section.5.3.p.12">An example absolute-form of request-line would be:</p>
    1798       <div id="rfc.figure.u.41"></div><pre class="text2">GET http://www.example.org/pub/WWW/TheProject.html HTTP/1.1
     1810      <div id="rfc.figure.u.42"></div><pre class="text2">GET http://www.example.org/pub/WWW/TheProject.html HTTP/1.1
    17991811</pre><p id="rfc.section.5.3.p.14">To allow for transition to the absolute-form for all requests in some future version of HTTP, a server <em class="bcp14">MUST</em> accept the absolute-form in requests, even though HTTP/1.1 clients will only send them in requests to proxies.
    18001812      </p>
     
    18051817      <p id="rfc.section.5.3.p.16">The <dfn>authority-form</dfn> of request-target is only used for CONNECT requests (<a href="p2-semantics.html#CONNECT" title="CONNECT">Section 4.3.6</a> of <a href="#Part2" id="rfc.xref.Part2.20"><cite title="Hypertext Transfer Protocol (HTTP/1.1): Semantics and Content">[Part2]</cite></a>). When making a CONNECT request to establish a tunnel through one or more proxies, a client <em class="bcp14">MUST</em> send only the target URI's authority component (excluding any userinfo and its "@" delimiter) as the request-target. For example,
    18061818      </p>
    1807       <div id="rfc.figure.u.42"></div><pre class="text2">CONNECT www.example.com:80 HTTP/1.1
     1819      <div id="rfc.figure.u.43"></div><pre class="text2">CONNECT www.example.com:80 HTTP/1.1
    18081820</pre><div id="asterisk-form">
    18091821         <p id="rfc.section.5.3.p.18"><span id="rfc.iref.a.4"></span> <b>asterisk-form</b>
     
    18131825         the client <em class="bcp14">MUST</em> send only "*" (%x2A) as the request-target. For example,
    18141826      </p>
    1815       <div id="rfc.figure.u.43"></div><pre class="text2">OPTIONS * HTTP/1.1
     1827      <div id="rfc.figure.u.44"></div><pre class="text2">OPTIONS * HTTP/1.1
    18161828</pre><p id="rfc.section.5.3.p.21">If a proxy receives an OPTIONS request with an absolute-form of request-target in which the URI has an empty path and no query
    18171829         component, then the last proxy on the request chain <em class="bcp14">MUST</em> send a request-target of "*" when it forwards the request to the indicated origin server.
    18181830      </p>
    1819       <div id="rfc.figure.u.44"></div>
     1831      <div id="rfc.figure.u.45"></div>
    18201832      <p>For example, the request</p><pre class="text2">OPTIONS http://www.example.org:8001 HTTP/1.1
    1821 </pre><div id="rfc.figure.u.45"></div>
     1833</pre><div id="rfc.figure.u.46"></div>
    18221834      <p>would be forwarded by the final proxy as</p><pre class="text2">OPTIONS * HTTP/1.1
    18231835Host: www.example.org:8001
     
    18281840         to distinguish among resources while servicing requests for multiple host names on a single IP address.
    18291841      </p>
    1830       <div id="rfc.figure.u.46"></div><pre class="inline"><span id="rfc.iref.g.87"></span>  <a href="#header.host" class="smpl">Host</a> = <a href="#uri" class="smpl">uri-host</a> [ ":" <a href="#uri" class="smpl">port</a> ] ; <a href="#http.uri" title="http URI scheme">Section&nbsp;2.7.1</a>
     1842      <div id="rfc.figure.u.47"></div><pre class="inline"><span id="rfc.iref.g.98"></span>  <a href="#header.host" class="smpl">Host</a> = <a href="#uri" class="smpl">uri-host</a> [ ":" <a href="#uri" class="smpl">port</a> ] ; <a href="#http.uri" title="http URI scheme">Section&nbsp;2.7.1</a>
    18311843</pre><p id="rfc.section.5.4.p.3">A client <em class="bcp14">MUST</em> send a Host header field in all HTTP/1.1 request messages. If the target URI includes an authority component, then a client <em class="bcp14">MUST</em> send a field-value for Host that is identical to that authority component, excluding any userinfo subcomponent and its "@"
    18321844         delimiter (<a href="#http.uri" title="http URI scheme">Section&nbsp;2.7.1</a>). If the authority component is missing or undefined for the target URI, then a client <em class="bcp14">MUST</em> send a Host header field with an empty field-value.
     
    18351847      </p>
    18361848      <p id="rfc.section.5.4.p.5">For example, a GET request to the origin server for &lt;http://www.example.org/pub/WWW/&gt; would begin with:</p>
    1837       <div id="rfc.figure.u.47"></div><pre class="text2">GET /pub/WWW/ HTTP/1.1
     1849      <div id="rfc.figure.u.48"></div><pre class="text2">GET /pub/WWW/ HTTP/1.1
    18381850Host: www.example.org
    18391851</pre><p id="rfc.section.5.4.p.7">A client <em class="bcp14">MUST</em> send a Host header field in an HTTP/1.1 request even if the request-target is in the absolute-form, since this allows the
     
    18741886         the scheme, "://", authority, and combined path and query component.
    18751887      </p>
    1876       <div id="rfc.figure.u.48"></div>
     1888      <div id="rfc.figure.u.49"></div>
    18771889      <p>Example 1: the following message received over an insecure TCP connection</p><pre class="text">GET /pub/WWW/TheProject.html HTTP/1.1
    18781890Host: www.example.org:8080
    1879 </pre><div id="rfc.figure.u.49"></div>
     1891</pre><div id="rfc.figure.u.50"></div>
    18801892      <p>has an effective request URI of</p><pre class="text">http://www.example.org:8080/pub/WWW/TheProject.html
    1881 </pre><div id="rfc.figure.u.50"></div>
     1893</pre><div id="rfc.figure.u.51"></div>
    18821894      <p>Example 2: the following message received over a TLS-secured TCP connection</p><pre class="text">OPTIONS * HTTP/1.1
    18831895Host: www.example.org
    1884 </pre><div id="rfc.figure.u.51"></div>
     1896</pre><div id="rfc.figure.u.52"></div>
    18851897      <p>has an effective request URI of</p><pre class="text">https://www.example.org
    18861898</pre><p id="rfc.section.5.5.p.12">An origin server that does not allow resources to differ by requested host <em class="bcp14">MAY</em> ignore the <a href="#header.host" class="smpl">Host</a> field-value and instead replace it with a configured server name when constructing the effective request URI.
     
    19151927         along the request/response chain.
    19161928      </p>
    1917       <div id="rfc.figure.u.52"></div><pre class="inline"><span id="rfc.iref.g.88"></span><span id="rfc.iref.g.89"></span><span id="rfc.iref.g.90"></span><span id="rfc.iref.g.91"></span><span id="rfc.iref.g.92"></span><span id="rfc.iref.g.93"></span>  <a href="#header.via" class="smpl">Via</a> = 1#( <a href="#header.via" class="smpl">received-protocol</a> <a href="#rule.whitespace" class="smpl">RWS</a> <a href="#header.via" class="smpl">received-by</a> [ <a href="#rule.whitespace" class="smpl">RWS</a> <a href="#rule.comment" class="smpl">comment</a> ] )
     1929      <div id="rfc.figure.u.53"></div><pre class="inline"><span id="rfc.iref.g.99"></span><span id="rfc.iref.g.100"></span><span id="rfc.iref.g.101"></span><span id="rfc.iref.g.102"></span><span id="rfc.iref.g.103"></span><span id="rfc.iref.g.104"></span>  <a href="#header.via" class="smpl">Via</a> = 1#( <a href="#header.via" class="smpl">received-protocol</a> <a href="#rule.whitespace" class="smpl">RWS</a> <a href="#header.via" class="smpl">received-by</a> [ <a href="#rule.whitespace" class="smpl">RWS</a> <a href="#rule.comment" class="smpl">comment</a> ] )
    19181930
    19191931  <a href="#header.via" class="smpl">received-protocol</a> = [ <a href="#header.upgrade" class="smpl">protocol-name</a> "/" ] <a href="#header.upgrade" class="smpl">protocol-version</a>
     
    19411953         server at www.example.com. The request received by www.example.com would then have the following Via header field:
    19421954      </p>
    1943       <div id="rfc.figure.u.53"></div><pre class="text">  Via: 1.0 fred, 1.1 p.example.net
     1955      <div id="rfc.figure.u.54"></div><pre class="text">  Via: 1.0 fred, 1.1 p.example.net
    19441956</pre><p id="rfc.section.5.7.1.p.10">An intermediary used as a portal through a network firewall <em class="bcp14">SHOULD NOT</em> forward the names and ports of hosts within the firewall region unless it is explicitly enabled to do so. If not enabled,
    19451957         such an intermediary <em class="bcp14">SHOULD</em> replace each received-by host of any host behind the firewall by an appropriate pseudonym for that host.
     
    19481960         values. For example,
    19491961      </p>
    1950       <div id="rfc.figure.u.54"></div><pre class="text">  Via: 1.0 ricky, 1.1 ethel, 1.1 fred, 1.0 lucy
     1962      <div id="rfc.figure.u.55"></div><pre class="text">  Via: 1.0 ricky, 1.1 ethel, 1.1 fred, 1.0 lucy
    19511963</pre><p id="rfc.section.5.7.1.p.13">could be collapsed to</p>
    1952       <div id="rfc.figure.u.55"></div><pre class="text">  Via: 1.0 ricky, 1.1 mertz, 1.0 lucy
     1964      <div id="rfc.figure.u.56"></div><pre class="text">  Via: 1.0 ricky, 1.1 mertz, 1.0 lucy
    19531965</pre><p id="rfc.section.5.7.1.p.15">A sender <em class="bcp14">SHOULD NOT</em> combine multiple entries unless they are all under the same organizational control and the hosts have already been replaced
    19541966         by pseudonyms. A sender <em class="bcp14">MUST NOT</em> combine entries that have different received-protocol values.
     
    20062018      </p>
    20072019      <p id="rfc.section.6.1.p.4">The Connection header field's value has the following grammar:</p>
    2008       <div id="rfc.figure.u.56"></div><pre class="inline"><span id="rfc.iref.g.94"></span><span id="rfc.iref.g.95"></span>  <a href="#header.connection" class="smpl">Connection</a>        = 1#<a href="#header.connection" class="smpl">connection-option</a>
     2020      <div id="rfc.figure.u.57"></div><pre class="inline"><span id="rfc.iref.g.105"></span><span id="rfc.iref.g.106"></span>  <a href="#header.connection" class="smpl">Connection</a>        = 1#<a href="#header.connection" class="smpl">connection-option</a>
    20092021  <a href="#header.connection" class="smpl">connection-option</a> = <a href="#rule.token.separators" class="smpl">token</a>
    20102022</pre><p id="rfc.section.6.1.p.6">Connection options are case-insensitive.</p>
     
    20262038         For example,
    20272039      </p>
    2028       <div id="rfc.figure.u.57"></div><pre class="text">  Connection: close
     2040      <div id="rfc.figure.u.58"></div><pre class="text">  Connection: close
    20292041</pre><p id="rfc.section.6.1.p.12">in either the request or the response header fields indicates that the sender is going to close the connection after the current
    20302042         request/response is complete (<a href="#persistent.tear-down" id="rfc.xref.persistent.tear-down.1" title="Tear-down">Section&nbsp;6.6</a>).
     
    21612173         in order of descending preference, before sending the final response. A server <em class="bcp14">MAY</em> ignore a received Upgrade header field if it wishes to continue using the current protocol on that connection.
    21622174      </p>
    2163       <div id="rfc.figure.u.58"></div><pre class="inline"><span id="rfc.iref.g.96"></span>  <a href="#header.upgrade" class="smpl">Upgrade</a>          = 1#<a href="#header.upgrade" class="smpl">protocol</a>
     2175      <div id="rfc.figure.u.59"></div><pre class="inline"><span id="rfc.iref.g.107"></span>  <a href="#header.upgrade" class="smpl">Upgrade</a>          = 1#<a href="#header.upgrade" class="smpl">protocol</a>
    21642176
    21652177  <a href="#header.upgrade" class="smpl">protocol</a>         = <a href="#header.upgrade" class="smpl">protocol-name</a> ["/" <a href="#header.upgrade" class="smpl">protocol-version</a>]
     
    21752187         in order of descending preference, when appropriate for a future request.
    21762188      </p>
    2177       <div id="rfc.figure.u.59"></div>
     2189      <div id="rfc.figure.u.60"></div>
    21782190      <p>The following is a hypothetical example sent by a client:</p><pre class="text2">GET /hello.txt HTTP/1.1
    21792191Host: www.example.com
     
    21932205         by any protocol.
    21942206      </p>
    2195       <div id="rfc.figure.u.60"></div>
     2207      <div id="rfc.figure.u.61"></div>
    21962208      <p>The following is an example response to the above hypothetical request:</p><pre class="text">HTTP/1.1 101 Switching Protocols
    21972209Connection: upgrade
     
    22172229         indicating at least &lt;n&gt; and at most &lt;m&gt; elements, each separated by a single comma (",") and optional whitespace (OWS).
    22182230      </p>
    2219       <div id="rfc.figure.u.61"></div>
     2231      <div id="rfc.figure.u.62"></div>
    22202232      <p>Thus, a sender <em class="bcp14">MUST</em> expand the list construct as follows:
    22212233      </p><pre class="text">  1#element =&gt; element *( OWS "," OWS element )
    2222 </pre><div id="rfc.figure.u.62"></div>
     2234</pre><div id="rfc.figure.u.63"></div>
    22232235      <p>and:</p><pre class="text">  #element =&gt; [ 1#element ]
    2224 </pre><div id="rfc.figure.u.63"></div>
     2236</pre><div id="rfc.figure.u.64"></div>
    22252237      <p>and for n &gt;= 1 and m &gt; 1:</p><pre class="text">  &lt;n&gt;#&lt;m&gt;element =&gt; element &lt;n-1&gt;*&lt;m-1&gt;( OWS "," OWS element )
    22262238</pre><p id="rfc.section.7.p.6">For compatibility with legacy list rules, a recipient <em class="bcp14">MUST</em> parse and ignore a reasonable number of empty list elements: enough to handle common mistakes by senders that merge values,
    22272239         but not so much that they could be used as a denial of service mechanism. In other words, a recipient <em class="bcp14">MUST</em> expand the list construct as follows:
    22282240      </p>
    2229       <div id="rfc.figure.u.64"></div><pre class="text">  #element =&gt; [ ( "," / element ) *( OWS "," [ OWS element ] ) ]
     2241      <div id="rfc.figure.u.65"></div><pre class="text">  #element =&gt; [ ( "," / element ) *( OWS "," [ OWS element ] ) ]
    22302242 
    22312243  1#element =&gt; *( "," OWS ) element *( OWS "," [ OWS element ] )
    22322244</pre><p id="rfc.section.7.p.8">Empty elements do not contribute to the count of elements present. For example, given these ABNF productions:</p>
    2233       <div id="rfc.figure.u.65"></div><pre class="text">  example-list      = 1#example-list-elmt
     2245      <div id="rfc.figure.u.66"></div><pre class="text">  example-list      = 1#example-list-elmt
    22342246  example-list-elmt = token ; see <a href="#field.components" title="Field value components">Section&nbsp;3.2.6</a>
    22352247</pre><p id="rfc.section.7.p.10">Then the following are valid values for example-list (not including the double quotes, which are present for delimitation
    22362248         only):
    22372249      </p>
    2238       <div id="rfc.figure.u.66"></div><pre class="text">  "foo,bar"
     2250      <div id="rfc.figure.u.67"></div><pre class="text">  "foo,bar"
    22392251  "foo ,bar,"
    22402252  "foo , ,bar,charlie   "
    22412253</pre><p id="rfc.section.7.p.12">In contrast, the following values would be invalid, since at least one non-empty element is required by the example-list production:</p>
    2242       <div id="rfc.figure.u.67"></div><pre class="text">  ""
     2254      <div id="rfc.figure.u.68"></div><pre class="text">  ""
    22432255  ","
    22442256  ",   ,"
     
    30463058      </p>
    30473059      <h1 id="rfc.section.B"><a href="#rfc.section.B">B.</a>&nbsp;<a id="collected.abnf" href="#collected.abnf">Collected ABNF</a></h1>
    3048       <div id="rfc.figure.u.68"></div><pre class="inline"><a href="#rule.whitespace" class="smpl">BWS</a> = OWS
     3060      <div id="rfc.figure.u.69"></div><pre class="inline"><a href="#rule.whitespace" class="smpl">BWS</a> = OWS
    30493061
    30503062<a href="#header.connection" class="smpl">Connection</a> = *( "," OWS ) connection-option *( OWS "," [ OWS
     
    30843096<a href="#chunked.encoding" class="smpl">chunk</a> = chunk-size [ chunk-ext ] CRLF chunk-data CRLF
    30853097<a href="#chunked.encoding" class="smpl">chunk-data</a> = 1*OCTET
    3086 <a href="#chunked.encoding" class="smpl">chunk-ext</a> = *( ";" chunk-ext-name [ "=" chunk-ext-val ] )
    3087 <a href="#chunked.encoding" class="smpl">chunk-ext-name</a> = token
    3088 <a href="#chunked.encoding" class="smpl">chunk-ext-val</a> = token / quoted-str-nf
     3098<a href="#chunked.extension" class="smpl">chunk-ext</a> = *( ";" chunk-ext-name [ "=" chunk-ext-val ] )
     3099<a href="#chunked.extension" class="smpl">chunk-ext-name</a> = token
     3100<a href="#chunked.extension" class="smpl">chunk-ext-val</a> = token / quoted-str-nf
    30893101<a href="#chunked.encoding" class="smpl">chunk-size</a> = 1*HEXDIG
    30903102<a href="#chunked.encoding" class="smpl">chunked-body</a> = *chunk last-chunk trailer-part CRLF
     
    31273139 / %x5D-7E ; ']'-'~'
    31283140 / obs-text
    3129 <a href="#chunked.encoding" class="smpl">qdtext-nf</a> = HTAB / SP / "!" / %x23-5B ; '#'-'['
     3141<a href="#chunked.extension" class="smpl">qdtext-nf</a> = HTAB / SP / "!" / %x23-5B ; '#'-'['
    31303142 / %x5D-7E ; ']'-'~'
    31313143 / obs-text
     
    31333145<a href="#rule.quoted-cpair" class="smpl">quoted-cpair</a> = "\" ( HTAB / SP / VCHAR / obs-text )
    31343146<a href="#rule.quoted-pair" class="smpl">quoted-pair</a> = "\" ( HTAB / SP / VCHAR / obs-text )
    3135 <a href="#chunked.encoding" class="smpl">quoted-str-nf</a> = DQUOTE *( qdtext-nf / quoted-pair ) DQUOTE
     3147<a href="#chunked.extension" class="smpl">quoted-str-nf</a> = DQUOTE *( qdtext-nf / quoted-pair ) DQUOTE
    31363148<a href="#rule.quoted-string" class="smpl">quoted-string</a> = DQUOTE *( qdtext / quoted-pair ) DQUOTE
    31373149
     
    32563268      <p id="rfc.section.C.4.p.1">Closed issues: </p>
    32573269      <ul>
    3258          <li>&lt;<a href="http://tools.ietf.org/wg/httpbis/trac/ticket/343">http://tools.ietf.org/wg/httpbis/trac/ticket/343</a>&gt;: "chunk-extensions" (removed the earlier deprecation)
     3270         <li>&lt;<a href="http://tools.ietf.org/wg/httpbis/trac/ticket/343">http://tools.ietf.org/wg/httpbis/trac/ticket/343</a>&gt;: "chunk-extensions" (un-deprecated and explained)
    32593271         </li>
    32603272         <li>&lt;<a href="http://tools.ietf.org/wg/httpbis/trac/ticket/483">http://tools.ietf.org/wg/httpbis/trac/ticket/483</a>&gt;: "MUST fix Content-Length?"
     
    33093321                  <li><tt>Grammar</tt>&nbsp;&nbsp;
    33103322                     <ul>
    3311                         <li><tt>absolute-form</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.84"><b>5.3</b></a></li>
     3323                        <li><tt>absolute-form</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.95"><b>5.3</b></a></li>
    33123324                        <li><tt>absolute-path</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.19"><b>2.7</b></a></li>
    33133325                        <li><tt>absolute-URI</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.17"><b>2.7</b></a></li>
    33143326                        <li>ALPHA&nbsp;&nbsp;<a href="#rfc.iref.g.1"><b>1.2</b></a></li>
    3315                         <li><tt>asterisk-form</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.86"><b>5.3</b></a></li>
     3327                        <li><tt>asterisk-form</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.97"><b>5.3</b></a></li>
    33163328                        <li><tt>attribute</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.60"><b>4</b></a></li>
    33173329                        <li><tt>authority</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.18"><b>2.7</b></a></li>
    3318                         <li><tt>authority-form</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.85"><b>5.3</b></a></li>
     3330                        <li><tt>authority-form</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.96"><b>5.3</b></a></li>
    33193331                        <li><tt>BWS</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.42"><b>3.2.3</b></a></li>
    3320                         <li><tt>chunk</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.65"><b>4.1</b></a></li>
    3321                         <li><tt>chunk-data</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.71"><b>4.1</b></a></li>
    3322                         <li><tt>chunk-ext</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.68"><b>4.1</b></a></li>
    3323                         <li><tt>chunk-ext-name</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.69"><b>4.1</b></a></li>
    3324                         <li><tt>chunk-ext-val</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.70"><b>4.1</b></a></li>
    3325                         <li><tt>chunk-size</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.66"><b>4.1</b></a></li>
    3326                         <li><tt>chunked-body</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.64"><b>4.1</b></a></li>
     3332                        <li><tt>chunk</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.65"><b>4.1</b></a>, <a href="#rfc.iref.g.76"><b>4.1.1</b></a></li>
     3333                        <li><tt>chunk-data</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.71"><b>4.1</b></a>, <a href="#rfc.iref.g.82"><b>4.1.1</b></a></li>
     3334                        <li><tt>chunk-ext</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.68"><b>4.1</b></a>, <a href="#rfc.iref.g.79"><b>4.1.1</b></a></li>
     3335                        <li><tt>chunk-ext-name</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.69"><b>4.1</b></a>, <a href="#rfc.iref.g.80"><b>4.1.1</b></a></li>
     3336                        <li><tt>chunk-ext-val</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.70"><b>4.1</b></a>, <a href="#rfc.iref.g.81"><b>4.1.1</b></a></li>
     3337                        <li><tt>chunk-size</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.66"><b>4.1</b></a>, <a href="#rfc.iref.g.77"><b>4.1.1</b></a></li>
     3338                        <li><tt>chunked-body</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.64"><b>4.1</b></a>, <a href="#rfc.iref.g.75"><b>4.1.1</b></a></li>
    33273339                        <li><tt>comment</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.51"><b>3.2.6</b></a></li>
    3328                         <li><tt>Connection</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.94"><b>6.1</b></a></li>
    3329                         <li><tt>connection-option</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.95"><b>6.1</b></a></li>
     3340                        <li><tt>Connection</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.105"><b>6.1</b></a></li>
     3341                        <li><tt>connection-option</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.106"><b>6.1</b></a></li>
    33303342                        <li><tt>Content-Length</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.56"><b>3.3.2</b></a></li>
    33313343                        <li>CR&nbsp;&nbsp;<a href="#rfc.iref.g.2"><b>1.2</b></a></li>
     
    33433355                        <li><tt>header-field</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.35"><b>3.2</b></a></li>
    33443356                        <li>HEXDIG&nbsp;&nbsp;<a href="#rfc.iref.g.7"><b>1.2</b></a></li>
    3345                         <li><tt>Host</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.87"><b>5.4</b></a></li>
     3357                        <li><tt>Host</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.98"><b>5.4</b></a></li>
    33463358                        <li>HTAB&nbsp;&nbsp;<a href="#rfc.iref.g.8"><b>1.2</b></a></li>
    33473359                        <li><tt>HTTP-message</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.28"><b>3</b></a></li>
     
    33503362                        <li><tt>HTTP-version</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.14"><b>2.6</b></a></li>
    33513363                        <li><tt>https-URI</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.27"><b>2.7.2</b></a></li>
    3352                         <li><tt>last-chunk</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.67"><b>4.1</b></a></li>
     3364                        <li><tt>last-chunk</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.67"><b>4.1</b></a>, <a href="#rfc.iref.g.78"><b>4.1.1</b></a></li>
    33533365                        <li>LF&nbsp;&nbsp;<a href="#rfc.iref.g.9"><b>1.2</b></a></li>
    33543366                        <li><tt>message-body</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.54"><b>3.3</b></a></li>
     
    33573369                        <li><tt>obs-text</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.49"><b>3.2.6</b></a></li>
    33583370                        <li>OCTET&nbsp;&nbsp;<a href="#rfc.iref.g.10"><b>1.2</b></a></li>
    3359                         <li><tt>origin-form</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.83"><b>5.3</b></a></li>
     3371                        <li><tt>origin-form</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.94"><b>5.3</b></a></li>
    33603372                        <li><tt>OWS</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.40"><b>3.2.3</b></a></li>
    33613373                        <li><tt>partial-URI</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.25"><b>2.7</b></a></li>
    33623374                        <li><tt>port</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.20"><b>2.7</b></a></li>
    3363                         <li><tt>protocol-name</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.90"><b>5.7.1</b></a></li>
    3364                         <li><tt>protocol-version</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.91"><b>5.7.1</b></a></li>
    3365                         <li><tt>pseudonym</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.93"><b>5.7.1</b></a></li>
     3375                        <li><tt>protocol-name</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.101"><b>5.7.1</b></a></li>
     3376                        <li><tt>protocol-version</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.102"><b>5.7.1</b></a></li>
     3377                        <li><tt>pseudonym</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.104"><b>5.7.1</b></a></li>
    33663378                        <li><tt>qdtext</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.48"><b>3.2.6</b></a></li>
    3367                         <li><tt>qdtext-nf</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.74"><b>4.1</b></a></li>
     3379                        <li><tt>qdtext-nf</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.74"><b>4.1</b></a>, <a href="#rfc.iref.g.85"><b>4.1.1</b></a></li>
    33683380                        <li><tt>query</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.21"><b>2.7</b></a></li>
    33693381                        <li><tt>quoted-cpair</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.53"><b>3.2.6</b></a></li>
    33703382                        <li><tt>quoted-pair</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.50"><b>3.2.6</b></a></li>
    3371                         <li><tt>quoted-str-nf</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.73"><b>4.1</b></a></li>
     3383                        <li><tt>quoted-str-nf</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.73"><b>4.1</b></a>, <a href="#rfc.iref.g.84"><b>4.1.1</b></a></li>
    33723384                        <li><tt>quoted-string</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.47"><b>3.2.6</b></a></li>
    3373                         <li><tt>rank</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.80"><b>4.3</b></a></li>
     3385                        <li><tt>rank</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.91"><b>4.3</b></a></li>
    33743386                        <li><tt>reason-phrase</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.34"><b>3.1.2</b></a></li>
    3375                         <li><tt>received-by</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.92"><b>5.7.1</b></a></li>
    3376                         <li><tt>received-protocol</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.89"><b>5.7.1</b></a></li>
     3387                        <li><tt>received-by</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.103"><b>5.7.1</b></a></li>
     3388                        <li><tt>received-protocol</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.100"><b>5.7.1</b></a></li>
    33773389                        <li><tt>request-line</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.30"><b>3.1.1</b></a></li>
    3378                         <li><tt>request-target</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.82"><b>5.3</b></a></li>
     3390                        <li><tt>request-target</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.93"><b>5.3</b></a></li>
    33793391                        <li><tt>RWS</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.41"><b>3.2.3</b></a></li>
    33803392                        <li><tt>segment</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.23"><b>2.7</b></a></li>
     
    33843396                        <li><tt>status-code</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.33"><b>3.1.2</b></a></li>
    33853397                        <li><tt>status-line</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.32"><b>3.1.2</b></a></li>
    3386                         <li><tt>t-codings</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.78"><b>4.3</b></a></li>
    3387                         <li><tt>t-ranking</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.79"><b>4.3</b></a></li>
     3398                        <li><tt>t-codings</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.89"><b>4.3</b></a></li>
     3399                        <li><tt>t-ranking</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.90"><b>4.3</b></a></li>
    33883400                        <li><tt>tchar</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.45"><b>3.2.6</b></a></li>
    3389                         <li><tt>TE</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.77"><b>4.3</b></a></li>
     3401                        <li><tt>TE</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.88"><b>4.3</b></a></li>
    33903402                        <li><tt>token</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.44"><b>3.2.6</b></a></li>
    3391                         <li><tt>Trailer</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.81"><b>4.4</b></a></li>
    3392                         <li><tt>trailer-part</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.72">4.1</a>, <a href="#rfc.iref.g.75"><b>4.1.1</b></a></li>
     3403                        <li><tt>Trailer</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.92"><b>4.4</b></a></li>
     3404                        <li><tt>trailer-part</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.72">4.1</a>, <a href="#rfc.iref.g.83">4.1.1</a>, <a href="#rfc.iref.g.86"><b>4.1.2</b></a></li>
    33933405                        <li><tt>transfer-coding</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.57"><b>4</b></a></li>
    33943406                        <li><tt>Transfer-Encoding</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.55"><b>3.3.1</b></a></li>
    33953407                        <li><tt>transfer-extension</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.58"><b>4</b></a></li>
    33963408                        <li><tt>transfer-parameter</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.59"><b>4</b></a></li>
    3397                         <li><tt>Upgrade</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.96"><b>6.7</b></a></li>
     3409                        <li><tt>Upgrade</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.107"><b>6.7</b></a></li>
    33983410                        <li><tt>uri-host</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.24"><b>2.7</b></a></li>
    33993411                        <li><tt>URI-reference</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.16"><b>2.7</b></a></li>
    34003412                        <li><tt>value</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.61"><b>4</b></a></li>
    34013413                        <li>VCHAR&nbsp;&nbsp;<a href="#rfc.iref.g.12"><b>1.2</b></a></li>
    3402                         <li><tt>Via</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.88"><b>5.7.1</b></a></li>
     3414                        <li><tt>Via</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.99"><b>5.7.1</b></a></li>
    34033415                        <li><tt>word</tt>&nbsp;&nbsp;<a href="#rfc.iref.g.43"><b>3.2.6</b></a></li>
    34043416                     </ul>
    34053417                  </li>
    3406                   <li>gzip (Coding Format)&nbsp;&nbsp;<a href="#rfc.iref.g.76">4.2.3</a></li>
     3418                  <li>gzip (Coding Format)&nbsp;&nbsp;<a href="#rfc.iref.g.87">4.2.3</a></li>
    34073419               </ul>
    34083420            </li>
     
    35693581                  <li>target resource&nbsp;&nbsp;<a href="#rfc.iref.t.7"><b>5.1</b></a></li>
    35703582                  <li>target URI&nbsp;&nbsp;<a href="#rfc.iref.t.8"><b>5.1</b></a></li>
    3571                   <li>TE header field&nbsp;&nbsp;<a href="#rfc.xref.header.te.1">4</a>, <a href="#rfc.xref.header.te.2">4.1.1</a>, <a href="#rfc.iref.t.5"><b>4.3</b></a>, <a href="#rfc.xref.header.te.3">8.1</a></li>
     3583                  <li>TE header field&nbsp;&nbsp;<a href="#rfc.xref.header.te.1">4</a>, <a href="#rfc.xref.header.te.2">4.1.2</a>, <a href="#rfc.iref.t.5"><b>4.3</b></a>, <a href="#rfc.xref.header.te.3">8.1</a></li>
    35723584                  <li>Trailer header field&nbsp;&nbsp;<a href="#rfc.iref.t.6"><b>4.4</b></a>, <a href="#rfc.xref.header.trailer.1">8.1</a></li>
    35733585                  <li>Transfer-Encoding header field&nbsp;&nbsp;<a href="#rfc.xref.header.transfer-encoding.1">3.3</a>, <a href="#rfc.iref.t.4"><b>3.3.1</b></a>, <a href="#rfc.xref.header.transfer-encoding.2">4</a>, <a href="#rfc.xref.header.transfer-encoding.3">8.1</a>, <a href="#rfc.xref.header.transfer-encoding.4">A.1.3</a></li>
  • draft-ietf-httpbis/latest/p1-messaging.xml

    r2405 r2406  
    19781978  <x:anchor-alias value="chunked-body"/>
    19791979  <x:anchor-alias value="chunk-data"/>
    1980   <x:anchor-alias value="chunk-ext"/>
    1981   <x:anchor-alias value="chunk-ext-name"/>
    1982   <x:anchor-alias value="chunk-ext-val"/>
    19831980  <x:anchor-alias value="chunk-size"/>
    19841981  <x:anchor-alias value="last-chunk"/>
    1985   <x:anchor-alias value="quoted-str-nf"/>
    1986   <x:anchor-alias value="qdtext-nf"/>
    1987 <t>
    1988    The chunked transfer coding modifies the body of a message in order to
    1989    transfer it as a series of chunks, each with its own size indicator,
    1990    followed by an &OPTIONAL; trailer containing header fields. This
    1991    allows dynamically generated content to be transferred along with the
    1992    information necessary for the recipient to verify that it has
    1993    received the full message.
     1982<t>
     1983   The chunked transfer coding wraps the payload body in order to transfer it
     1984   as a series of chunks, each with its own size indicator, followed by an
     1985   &OPTIONAL; trailer containing header fields. Chunked enables content
     1986   streams of unknown size to be transferred as a sequence of length-delimited
     1987   buffers, which enables the sender to retain connection persistence and the
     1988   recipient to know when it has received the entire message.
    19941989</t>
    19951990<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="chunked-body"><!--terminal production--></iref><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="false" item="Grammar" subitem="trailer-part"/><iref primary="true" item="Grammar" subitem="quoted-str-nf"/><iref primary="true" item="Grammar" subitem="qdtext-nf"/>
     
    20041999  <x:ref>last-chunk</x:ref>     = 1*("0") [ <x:ref>chunk-ext</x:ref> ] <x:ref>CRLF</x:ref>
    20052000 
     2001  <x:ref>chunk-data</x:ref>     = 1*<x:ref>OCTET</x:ref> ; a sequence of chunk-size octets
     2002</artwork></figure>
     2003<t>
     2004   The chunk-size field is a string of hex digits indicating the size of
     2005   the chunk-data in octets. The chunked transfer coding is complete when a
     2006   chunk with a chunk-size of zero is received, possibly followed by a
     2007   trailer, and finally terminated by an empty line.
     2008</t>
     2009<t>
     2010   A recipient &MUST; be able to parse and decode the chunked transfer coding.
     2011</t>
     2012
     2013<section title="Chunk Extensions" anchor="chunked.extension">
     2014  <x:anchor-alias value="chunk-ext"/>
     2015  <x:anchor-alias value="chunk-ext-name"/>
     2016  <x:anchor-alias value="chunk-ext-val"/>
     2017  <x:anchor-alias value="quoted-str-nf"/>
     2018  <x:anchor-alias value="qdtext-nf"/>
     2019<t>
     2020   The chunked encoding allows each chunk to include zero or more chunk
     2021   extensions, immediately following the <x:ref>chunk-size</x:ref>, for the
     2022   sake of supplying per-chunk metadata (such as a signature or hash),
     2023   mid-message control information, or randomization of message body size.
     2024</t>
     2025<figure><artwork type="abnf2616"><iref primary="true" item="Grammar" subitem="chunked-body"><!--terminal production--></iref><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="false" item="Grammar" subitem="trailer-part"/><iref primary="true" item="Grammar" subitem="quoted-str-nf"/><iref primary="true" item="Grammar" subitem="qdtext-nf"/>
    20062026  <x:ref>chunk-ext</x:ref>      = *( ";" <x:ref>chunk-ext-name</x:ref> [ "=" <x:ref>chunk-ext-val</x:ref> ] )
     2027
    20072028  <x:ref>chunk-ext-name</x:ref> = <x:ref>token</x:ref>
    20082029  <x:ref>chunk-ext-val</x:ref>  = <x:ref>token</x:ref> / <x:ref>quoted-str-nf</x:ref>
    2009   <x:ref>chunk-data</x:ref>     = 1*<x:ref>OCTET</x:ref> ; a sequence of chunk-size octets
    20102030 
    20112031  <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>
     
    20142034</artwork></figure>
    20152035<t>
    2016    Chunk extensions need to be used carefully because use of chunking does not
    2017    have any semantics related to the message; it is by definition hop-by-hop
    2018    and thus can be removed/reformatted by any intermediary.
    2019    Furthermore, few implementations expose information about their contents.
    2020 </t>
    2021 <t>
    2022    The chunk-size field is a string of hex digits indicating the size of
    2023    the chunk-data in octets. The chunked transfer coding is complete when a
    2024    chunk with a chunk-size of zero is received, possibly followed by a
    2025    trailer, and finally terminated by an empty line.
    2026 </t>
     2036   The chunked encoding is specific to each connection and is likely to be
     2037   removed or recoded by each recipient (including intermediaries) before any
     2038   higher-level application would have a chance to inspect the extensions.
     2039   Hence, use of chunk extensions is generally limited to specialized HTTP
     2040   services such as "long polling" (where client and server can have shared
     2041   expectations regarding the use of chunk extensions) or for padding within
     2042   an end-to-end secured connection.
     2043</t>
     2044<t>
     2045   A recipient &MUST; ignore unrecognized chunk extensions.
     2046   A server ought to limit the total length of chunk extensions received in a
     2047   request to an amount reasonable for the services provided, in the same way
     2048   that it applies length limitations and timeouts for other parts of a
     2049   message, and generate an appropriate <x:ref>4xx (Client Error)</x:ref>
     2050   response if that amount is exceeded.
     2051</t>
     2052</section>
    20272053
    20282054<section title="Chunked Trailer Part" anchor="chunked.trailer.part">
     
    20982124  Remove Trailer from existing header fields
    20992125</artwork></figure>
    2100 <t>
    2101    A recipient &MUST; be able to parse and decode the
    2102    chunked transfer coding and &MUST; ignore chunk-ext extensions
    2103    they do not understand.
    2104 </t>
    21052126</section>
    21062127</section>
     
    54935514    <t>
    54945515      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/343"/>:
    5495       "chunk-extensions" (removed the earlier deprecation)
     5516      "chunk-extensions" (un-deprecated and explained)
    54965517    </t>
    54975518    <t>
Note: See TracChangeset for help on using the changeset viewer.