source: draft-ietf-httpbis/06/draft-ietf-httpbis-p4-conditional-06.xml @ 558

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

Draft 06 (as recorded by www.ietf.org)

  • Property svn:eol-style set to native
File size: 58.5 KB
Line 
1<?xml version="1.0" encoding="UTF-8"?>
2<!--
3    This XML document is the output of clean-for-DTD.xslt; a tool that strips
4    extensions to RFC2629(bis) from documents for processing with xml2rfc.
5-->
6<?xml-stylesheet type='text/xsl' href='../myxml2rfc.xslt'?>
7<?rfc toc="yes" ?>
8<?rfc symrefs="yes" ?>
9<?rfc sortrefs="yes" ?>
10<?rfc compact="yes"?>
11<?rfc subcompact="no" ?>
12<?rfc linkmailto="no" ?>
13<?rfc editing="no" ?>
14<?rfc comments="yes"?>
15<?rfc inline="yes"?>
16<!DOCTYPE rfc
17  PUBLIC "" "rfc2629.dtd">
18<rfc obsoletes="2616" category="std" ipr="pre5378Trust200902" docName="draft-ietf-httpbis-p4-conditional-06">
19<front>
20
21  <title abbrev="HTTP/1.1, Part 4">HTTP/1.1, part 4: Conditional Requests</title>
22
23  <author initials="R." surname="Fielding" fullname="Roy T. Fielding" role="editor">
24    <organization abbrev="Day Software">Day Software</organization>
25    <address>
26      <postal>
27        <street>23 Corporate Plaza DR, Suite 280</street>
28        <city>Newport Beach</city>
29        <region>CA</region>
30        <code>92660</code>
31        <country>USA</country>
32      </postal>
33      <phone>+1-949-706-5300</phone>
34      <facsimile>+1-949-706-5305</facsimile>
35      <email>fielding@gbiv.com</email>
36      <uri>http://roy.gbiv.com/</uri>
37    </address>
38  </author>
39
40  <author initials="J." surname="Gettys" fullname="Jim Gettys">
41    <organization>One Laptop per Child</organization>
42    <address>
43      <postal>
44        <street>21 Oak Knoll Road</street>
45        <city>Carlisle</city>
46        <region>MA</region>
47        <code>01741</code>
48        <country>USA</country>
49      </postal>
50      <email>jg@laptop.org</email>
51      <uri>http://www.laptop.org/</uri>
52    </address>
53  </author>
54 
55  <author initials="J." surname="Mogul" fullname="Jeffrey C. Mogul">
56    <organization abbrev="HP">Hewlett-Packard Company</organization>
57    <address>
58      <postal>
59        <street>HP Labs, Large Scale Systems Group</street>
60        <street>1501 Page Mill Road, MS 1177</street>
61        <city>Palo Alto</city>
62        <region>CA</region>
63        <code>94304</code>
64        <country>USA</country>
65      </postal>
66      <email>JeffMogul@acm.org</email>
67    </address>
68  </author>
69
70  <author initials="H." surname="Frystyk" fullname="Henrik Frystyk Nielsen">
71    <organization abbrev="Microsoft">Microsoft Corporation</organization>
72    <address>
73      <postal>
74        <street>1 Microsoft Way</street>
75        <city>Redmond</city>
76        <region>WA</region>
77        <code>98052</code>
78        <country>USA</country>
79      </postal>
80      <email>henrikn@microsoft.com</email>
81    </address>
82  </author>
83
84  <author initials="L." surname="Masinter" fullname="Larry Masinter">
85    <organization abbrev="Adobe Systems">Adobe Systems, Incorporated</organization>
86    <address>
87      <postal>
88        <street>345 Park Ave</street>
89        <city>San Jose</city>
90        <region>CA</region>
91        <code>95110</code>
92        <country>USA</country>
93      </postal>
94      <email>LMM@acm.org</email>
95      <uri>http://larry.masinter.net/</uri>
96    </address>
97  </author>
98 
99  <author initials="P." surname="Leach" fullname="Paul J. Leach">
100    <organization abbrev="Microsoft">Microsoft Corporation</organization>
101    <address>
102      <postal>
103        <street>1 Microsoft Way</street>
104        <city>Redmond</city>
105        <region>WA</region>
106        <code>98052</code>
107      </postal>
108      <email>paulle@microsoft.com</email>
109    </address>
110  </author>
111   
112  <author initials="T." surname="Berners-Lee" fullname="Tim Berners-Lee">
113    <organization abbrev="W3C/MIT">World Wide Web Consortium</organization>
114    <address>
115      <postal>
116        <street>MIT Computer Science and Artificial Intelligence Laboratory</street>
117        <street>The Stata Center, Building 32</street>
118        <street>32 Vassar Street</street>
119        <city>Cambridge</city>
120        <region>MA</region>
121        <code>02139</code>
122        <country>USA</country>
123      </postal>
124      <email>timbl@w3.org</email>
125      <uri>http://www.w3.org/People/Berners-Lee/</uri>
126    </address>
127  </author>
128
129  <author initials="Y." surname="Lafon" fullname="Yves Lafon" role="editor">
130    <organization abbrev="W3C">World Wide Web Consortium</organization>
131    <address>
132      <postal>
133        <street>W3C / ERCIM</street>
134        <street>2004, rte des Lucioles</street>
135        <city>Sophia-Antipolis</city>
136        <region>AM</region>
137        <code>06902</code>
138        <country>France</country>
139      </postal>
140      <email>ylafon@w3.org</email>
141      <uri>http://www.raubacapeu.net/people/yves/</uri>
142    </address>
143  </author>
144
145  <author initials="J. F." surname="Reschke" fullname="Julian F. Reschke" role="editor">
146    <organization abbrev="greenbytes">greenbytes GmbH</organization>
147    <address>
148      <postal>
149        <street>Hafenweg 16</street>
150        <city>Muenster</city><region>NW</region><code>48155</code>
151        <country>Germany</country>
152      </postal>
153      <phone>+49 251 2807760</phone>   
154      <facsimile>+49 251 2807761</facsimile>   
155      <email>julian.reschke@greenbytes.de</email>       
156      <uri>http://greenbytes.de/tech/webdav/</uri>     
157    </address>
158  </author>
159
160  <date month="March" year="2009" day="9"/>
161  <workgroup>HTTPbis Working Group</workgroup>
162
163<abstract>
164<t>
165   The Hypertext Transfer Protocol (HTTP) is an application-level
166   protocol for distributed, collaborative, hypermedia information
167   systems. HTTP has been in use by the World Wide Web global information
168   initiative since 1990. This document is Part 4 of the seven-part specification
169   that defines the protocol referred to as "HTTP/1.1" and, taken together,
170   obsoletes RFC 2616.  Part 4 defines request header fields for
171   indicating conditional requests and the rules for constructing responses
172   to those requests.
173</t>
174</abstract>
175
176<note title="Editorial Note (To be removed by RFC Editor)">
177  <t>
178    Discussion of this draft should take place on the HTTPBIS working group
179    mailing list (ietf-http-wg@w3.org). The current issues list is
180    at <eref target="http://tools.ietf.org/wg/httpbis/trac/report/11"/>
181    and related documents (including fancy diffs) can be found at
182    <eref target="http://tools.ietf.org/wg/httpbis/"/>.
183  </t>
184  <t>
185    The changes in this draft are summarized in <xref target="changes.since.05"/>.
186  </t>
187</note>
188</front>
189<middle>
190<section title="Introduction" anchor="introduction">
191<t>
192   This document defines HTTP/1.1 response metadata for indicating potential
193   changes to payload content, including modification time stamps and opaque
194   entity-tags, and the HTTP conditional request mechanisms that allow
195   preconditions to be placed on a request method.  Conditional GET requests
196   allow for efficient cache updates.  Other conditional request methods are
197   used to protect against overwriting or misunderstanding the state of a
198   resource that has been changed unbeknownst to the requesting client.
199</t>
200<t>
201   This document is currently disorganized in order to minimize the changes
202   between drafts and enable reviewers to see the smaller errata changes.
203   The next draft will reorganize the sections to better reflect the content.
204   In particular, the sections on resource metadata will be discussed first
205   and then followed by each conditional request-header, concluding with a
206   definition of precedence and the expectation of ordering strong validator
207   checks before weak validator checks.  It is likely that more content from
208   <xref target="Part6"/> will migrate to this part, where appropriate.
209   The current mess reflects how widely dispersed these topics and associated
210   requirements had become in <xref target="RFC2616"/>.
211</t>
212
213<section title="Requirements" anchor="intro.requirements">
214<t>
215   The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
216   "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this
217   document are to be interpreted as described in <xref target="RFC2119"/>.
218</t>
219<t>
220   An implementation is not compliant if it fails to satisfy one or more
221   of the MUST or REQUIRED level requirements for the protocols it
222   implements. An implementation that satisfies all the MUST or REQUIRED
223   level and all the SHOULD level requirements for its protocols is said
224   to be "unconditionally compliant"; one that satisfies all the MUST
225   level requirements but not all the SHOULD level requirements for its
226   protocols is said to be "conditionally compliant."
227</t>
228</section>
229
230<section title="Syntax Notation" anchor="notation">
231 
232 
233 
234 
235 
236 
237 
238<t>
239  This specification uses the ABNF syntax defined in Section 1.2 of <xref target="Part1"/> (which
240  extends the syntax defined in <xref target="RFC5234"/> with a list rule).
241  <xref target="collected.abnf"/> shows the collected ABNF, with the list
242  rule expanded.
243</t>
244<t>
245  The following core rules are included by
246  reference, as defined in <xref target="RFC5234"/>, Appendix B.1:
247  ALPHA (letters), CR (carriage return), CRLF (CR LF), CTL (controls),
248  DIGIT (decimal 0-9), DQUOTE (double quote),
249  HEXDIG (hexadecimal 0-9/A-F/a-f), LF (line feed),
250  OCTET (any 8-bit sequence of data), SP (space),
251  VCHAR (any visible USASCII character),
252  and WSP (whitespace).
253</t>
254
255<section title="Core Rules" anchor="core.rules">
256 
257 
258<t>
259  The core rules below are defined in Section 1.2.2 of <xref target="Part1"/>:
260</t>
261<figure><artwork type="abnf2616"><![CDATA[
262  quoted-string = <quoted-string, defined in [Part1], Section 1.2.2>
263  OWS           = <OWS, defined in [Part1], Section 1.2.2>
264]]></artwork></figure>
265</section>
266
267<section title="ABNF Rules defined in other Parts of the Specification" anchor="abnf.dependencies">
268 
269<t>
270  The ABNF rules below are defined in other parts:
271</t>
272<figure><!--Part1--><artwork type="abnf2616"><![CDATA[
273  HTTP-date     = <HTTP-date, defined in [Part1], Section 3.2.1>
274]]></artwork></figure>
275</section>
276
277</section>
278
279</section>
280
281<section title="Entity Tags" anchor="entity.tags">
282 
283 
284 
285<t>
286   Entity tags are used for comparing two or more entities from the same
287   requested resource. HTTP/1.1 uses entity tags in the ETag (<xref target="header.etag"/>),
288   If-Match (<xref target="header.if-match"/>), If-None-Match (<xref target="header.if-none-match"/>), and
289   If-Range (Section 5.3 of <xref target="Part5"/>) header fields. The definition of how they
290   are used and compared as cache validators is in <xref target="weak.and.strong.validators"/>. An
291   entity tag consists of an opaque quoted string, possibly prefixed by
292   a weakness indicator.
293</t>
294<figure><iref primary="true" item="Grammar" subitem="entity-tag"/><iref primary="true" item="Grammar" subitem="weak"/><iref primary="true" item="Grammar" subitem="opaque-tag"/><artwork type="abnf2616"><![CDATA[
295  entity-tag = [ weak ] opaque-tag
296  weak       = "W/"
297  opaque-tag = quoted-string
298]]></artwork></figure>
299<t>
300   A "strong entity tag" MAY be shared by two entities of a resource
301   only if they are equivalent by octet equality.
302</t>
303<t>
304   A "weak entity tag," indicated by the "W/" prefix, MAY be shared by
305   two entities of a resource only if the entities are equivalent and
306   could be substituted for each other with no significant change in
307   semantics. A weak entity tag can only be used for weak comparison.
308</t>
309<t>
310   An entity tag MUST be unique across all versions of all entities
311   associated with a particular resource. A given entity tag value MAY
312   be used for entities obtained by requests on different URIs. The use
313   of the same entity tag value in conjunction with entities obtained by
314   requests on different URIs does not imply the equivalence of those
315   entities.
316</t>
317</section>
318
319<section title="Status Code Definitions">
320<section title="304 Not Modified" anchor="status.304">
321  <iref primary="true" item="304 Not Modified (status code)"/>
322  <iref primary="true" item="Status Codes" subitem="304 Not Modified"/>
323<t>
324   If the client has performed a conditional GET request and access is
325   allowed, but the document has not been modified, the server SHOULD
326   respond with this status code. The 304 response MUST NOT contain a
327   message-body, and thus is always terminated by the first empty line
328   after the header fields.
329</t>
330<t>
331   The response MUST include the following header fields:
332  <list style="symbols">
333    <t>Date, unless its omission is required by Section 8.3.1 of <xref target="Part1"/>.<vspace blankLines="1"/>
334         If a clockless origin server obeys these rules, and proxies and
335         clients add their own Date to any response received without one (as
336         already specified by Section 8.3 of <xref target="Part1"/>, caches will operate
337         correctly.</t>
338    <t>ETag and/or Content-Location, if the header would have been sent
339         in a 200 response to the same request.</t>
340    <t>Expires, Cache-Control, and/or Vary, if the field-value might
341         differ from that sent in any previous response for the same
342         variant.</t>
343  </list>
344</t>
345<t>
346   If the conditional GET used a strong cache validator (see <xref target="weak.and.strong.validators"/>),
347   the response SHOULD NOT  include other entity-headers.
348   Otherwise (i.e., the conditional GET used a weak validator), the
349   response MUST NOT include other entity-headers; this prevents
350   inconsistencies between cached entity-bodies and updated headers.
351</t>
352<t>
353   If a 304 response indicates an entity not currently cached, then the
354   cache MUST disregard the response and repeat the request without the
355   conditional.
356</t>
357<t>
358   If a cache uses a received 304 response to update a cache entry, the
359   cache MUST update the entry to reflect any new field values given in
360   the response.
361</t>
362</section>
363
364<section title="412 Precondition Failed" anchor="status.412">
365  <iref primary="true" item="412 Precondition Failed (status code)"/>
366  <iref primary="true" item="Status Codes" subitem="412 Precondition Failed"/>
367<t>
368   The precondition given in one or more of the request-header fields
369   evaluated to false when it was tested on the server. This response
370   code allows the client to place preconditions on the current resource
371   metainformation (header field data) and thus prevent the requested
372   method from being applied to a resource other than the one intended.
373</t>
374</section>
375</section>
376
377<section title="Weak and Strong Validators" anchor="weak.and.strong.validators">
378<t>
379   Since both origin servers and caches will compare two validators to
380   decide if they represent the same or different entities, one normally
381   would expect that if the entity (the entity-body or any entity-headers)
382   changes in any way, then the associated validator would
383   change as well. If this is true, then we call this validator a
384   "strong validator."
385</t>
386<t>
387   However, there might be cases when a server prefers to change the
388   validator only on semantically significant changes, and not when
389   insignificant aspects of the entity change. A validator that does not
390   always change when the resource changes is a "weak validator."
391</t>
392<t>
393   Entity tags are normally "strong validators," but the protocol
394   provides a mechanism to tag an entity tag as "weak." One can think of
395   a strong validator as one that changes whenever the bits of an entity
396   changes, while a weak value changes whenever the meaning of an entity
397   changes. Alternatively, one can think of a strong validator as part
398   of an identifier for a specific entity, while a weak validator is
399   part of an identifier for a set of semantically equivalent entities.
400  <list><t>
401      Note: One example of a strong validator is an integer that is
402      incremented in stable storage every time an entity is changed.
403    </t><t>
404      An entity's modification time, if represented with one-second
405      resolution, could be a weak validator, since it is possible that
406      the resource might be modified twice during a single second.
407    </t><t>
408      Support for weak validators is optional. However, weak validators
409      allow for more efficient caching of equivalent objects; for
410      example, a hit counter on a site is probably good enough if it is
411      updated every few days or weeks, and any value during that period
412      is likely "good enough" to be equivalent.
413    </t></list>
414</t>
415<t>
416   A "use" of a validator is either when a client generates a request
417   and includes the validator in a validating header field, or when a
418   server compares two validators.
419</t>
420<t>
421   Strong validators are usable in any context. Weak validators are only
422   usable in contexts that do not depend on exact equality of an entity.
423   For example, either kind is usable for a conditional GET of a full
424   entity. However, only a strong validator is usable for a sub-range
425   retrieval, since otherwise the client might end up with an internally
426   inconsistent entity.
427</t>
428<t>
429   Clients MUST NOT use weak validators in range requests (<xref target="Part5"/>).
430</t>
431<t>
432   The only function that HTTP/1.1 defines on validators is
433   comparison. There are two validator comparison functions, depending
434   on whether the comparison context allows the use of weak validators
435   or not:
436  <list style="symbols">
437     <t>The strong comparison function: in order to be considered equal,
438        both opaque-tags MUST be identical character-by-character, and both
439        MUST NOT be weak.</t>
440     <t>The weak comparison function: in order to be considered equal, both
441        opaque-tags MUST be identical character-by-character.</t>
442  </list>
443</t>
444<t>
445   The example below shows the results for a set of entity tag pairs,
446   and both the weak and strong comparison function results:
447</t>
448<texttable align="left">
449  <ttcol>ETag 1</ttcol>
450  <ttcol>ETag 2</ttcol>
451  <ttcol>Strong Comparison</ttcol>
452  <ttcol>Weak Comparison</ttcol>
453
454  <c>W/"1"</c>
455  <c>W/"1"</c>
456  <c>no match</c>
457  <c>match</c>
458 
459  <c>W/"1"</c>
460  <c>W/"2"</c>
461  <c>no match</c>
462  <c>no match</c>
463
464  <c>W/"1"</c>
465  <c>"1"</c>
466  <c>no match</c>
467  <c>match</c>
468
469  <c>"1"</c>
470  <c>"1"</c>
471  <c>match</c>
472  <c>match</c>
473</texttable>
474<t>
475   An entity tag is strong unless it is explicitly tagged as weak.
476   <xref target="entity.tags"/> gives the syntax for entity tags.
477</t>
478<t>
479   A Last-Modified time, when used as a validator in a request, is
480   implicitly weak unless it is possible to deduce that it is strong,
481   using the following rules:
482  <list style="symbols">
483     <t>The validator is being compared by an origin server to the
484        actual current validator for the entity and,</t>
485     <t>That origin server reliably knows that the associated entity did
486        not change twice during the second covered by the presented
487        validator.</t>
488  </list>
489</t>
490<t>
491   or
492  <list style="symbols">
493     <t>The validator is about to be used by a client in an If-Modified-Since
494        or If-Unmodified-Since header, because the client
495        has a cache entry for the associated entity, and</t>
496     <t>That cache entry includes a Date value, which gives the time
497        when the origin server sent the original response, and</t>
498     <t>The presented Last-Modified time is at least 60 seconds before
499        the Date value.</t>
500  </list>
501</t>
502<t>
503   or
504  <list style="symbols">
505     <t>The validator is being compared by an intermediate cache to the
506        validator stored in its cache entry for the entity, and</t>
507     <t>That cache entry includes a Date value, which gives the time
508        when the origin server sent the original response, and</t>
509     <t>The presented Last-Modified time is at least 60 seconds before
510        the Date value.</t>
511  </list>
512</t>
513<t>
514   This method relies on the fact that if two different responses were
515   sent by the origin server during the same second, but both had the
516   same Last-Modified time, then at least one of those responses would
517   have a Date value equal to its Last-Modified time. The arbitrary 60-second
518   limit guards against the possibility that the Date and Last-Modified
519   values are generated from different clocks, or at somewhat
520   different times during the preparation of the response. An
521   implementation MAY use a value larger than 60 seconds, if it is
522   believed that 60 seconds is too short.
523</t>
524<t>
525   If a client wishes to perform a sub-range retrieval on a value for
526   which it has only a Last-Modified time and no opaque validator, it
527   MAY do this only if the Last-Modified time is strong in the sense
528   described here.
529</t>
530<t>
531   A cache or origin server receiving a conditional range request
532   (<xref target="Part5"/>) MUST use the strong comparison function to
533   evaluate the condition.
534</t>
535<t>
536   These rules allow HTTP/1.1 caches and clients to safely perform sub-range
537   retrievals on values that have been obtained from HTTP/1.0
538   servers.
539</t>
540</section>
541
542<section title="Rules for When to Use Entity Tags and Last-Modified Dates" anchor="rules.for.when.to.use.entity.tags.and.last-modified.dates">
543<t>
544   We adopt a set of rules and recommendations for origin servers,
545   clients, and caches regarding when various validator types ought to
546   be used, and for what purposes.
547</t>
548<t>
549   HTTP/1.1 origin servers:
550  <list style="symbols">
551     <t>SHOULD send an entity tag validator unless it is not feasible to
552        generate one.</t>
553
554     <t>MAY send a weak entity tag instead of a strong entity tag, if
555        performance considerations support the use of weak entity tags,
556        or if it is unfeasible to send a strong entity tag.</t>
557
558     <t>SHOULD send a Last-Modified value if it is feasible to send one,
559        unless the risk of a breakdown in semantic transparency that
560        could result from using this date in an If-Modified-Since header
561        would lead to serious problems.</t>
562  </list>
563</t>
564<t>
565   In other words, the preferred behavior for an HTTP/1.1 origin server
566   is to send both a strong entity tag and a Last-Modified value.
567</t>
568<t>
569   In order to be legal, a strong entity tag MUST change whenever the
570   associated entity changes in any way. A weak entity tag SHOULD
571   change whenever the associated entity changes in a semantically
572   significant way.
573  <list><t>
574      Note: in order to provide semantically transparent caching, an
575      origin server must avoid reusing a specific strong entity tag
576      value for two different entities, or reusing a specific weak
577      entity tag value for two semantically different entities. Cache
578      entries might persist for arbitrarily long periods, regardless of
579      expiration times, so it might be inappropriate to expect that a
580      cache will never again attempt to validate an entry using a
581      validator that it obtained at some point in the past.
582  </t></list>
583</t>
584<t>
585   HTTP/1.1 clients:
586  <list style="symbols">
587     <t>If an entity tag has been provided by the origin server, MUST
588        use that entity tag in any cache-conditional request (using If-Match
589        or If-None-Match).</t>
590
591     <t>If only a Last-Modified value has been provided by the origin
592        server, SHOULD use that value in non-subrange cache-conditional
593        requests (using If-Modified-Since).</t>
594
595     <t>If only a Last-Modified value has been provided by an HTTP/1.0
596        origin server, MAY use that value in subrange cache-conditional
597        requests (using If-Unmodified-Since:). The user agent SHOULD
598        provide a way to disable this, in case of difficulty.</t>
599
600     <t>If both an entity tag and a Last-Modified value have been
601        provided by the origin server, SHOULD use both validators in
602        cache-conditional requests. This allows both HTTP/1.0 and
603        HTTP/1.1 caches to respond appropriately.</t>
604  </list>
605</t>
606<t>
607   An HTTP/1.1 origin server, upon receiving a conditional request that
608   includes both a Last-Modified date (e.g., in an If-Modified-Since or
609   If-Unmodified-Since header field) and one or more entity tags (e.g.,
610   in an If-Match, If-None-Match, or If-Range header field) as cache
611   validators, MUST NOT return a response status of 304 (Not Modified)
612   unless doing so is consistent with all of the conditional header
613   fields in the request.
614</t>
615<t>
616   An HTTP/1.1 caching proxy, upon receiving a conditional request that
617   includes both a Last-Modified date and one or more entity tags as
618   cache validators, MUST NOT return a locally cached response to the
619   client unless that cached response is consistent with all of the
620   conditional header fields in the request.
621  <list><t>
622      Note: The general principle behind these rules is that HTTP/1.1
623      servers and clients should transmit as much non-redundant
624      information as is available in their responses and requests.
625      HTTP/1.1 systems receiving this information will make the most
626      conservative assumptions about the validators they receive.
627  </t><t>
628      HTTP/1.0 clients and caches will ignore entity tags. Generally,
629      last-modified values received or used by these systems will
630      support transparent and efficient caching, and so HTTP/1.1 origin
631      servers should provide Last-Modified values. In those rare cases
632      where the use of a Last-Modified value as a validator by an
633      HTTP/1.0 system could result in a serious problem, then HTTP/1.1
634      origin servers should not provide one.
635  </t></list>
636</t>
637</section>
638
639<section title="Header Field Definitions" anchor="header.fields">
640<t>
641   This section defines the syntax and semantics of HTTP/1.1 header fields
642   related to conditional requests.
643</t>
644<t>
645   For entity-header fields, both sender and recipient refer to either the
646   client or the server, depending on who sends and who receives the entity.
647</t>
648
649<section title="ETag" anchor="header.etag">
650  <iref primary="true" item="ETag header"/>
651  <iref primary="true" item="Headers" subitem="ETag"/>
652 
653 
654<t>
655   The response-header field "ETag" provides the current value of the
656   entity tag (see <xref target="entity.tags"/>) for the requested variant.
657   The headers used with entity
658   tags are described in Sections <xref target="header.if-match" format="counter"/>
659   and <xref target="header.if-none-match" format="counter"/> of this document,
660   and in Section 5.3 of <xref target="Part5"/>. The entity tag
661   MAY be used for comparison with other entities from the same resource
662   (see <xref target="weak.and.strong.validators"/>).
663</t>
664<figure><iref primary="true" item="Grammar" subitem="ETag"/><iref primary="true" item="Grammar" subitem="ETag-v"/><artwork type="abnf2616"><![CDATA[
665  ETag   = "ETag" ":" OWS ETag-v
666  ETag-v = entity-tag
667]]></artwork></figure>
668<figure><preamble>
669  Examples:
670</preamble>
671<artwork type="example"><![CDATA[
672  ETag: "xyzzy"
673  ETag: W/"xyzzy"
674  ETag: ""
675]]></artwork></figure>
676<t>
677   The ETag response-header field value, an entity tag, provides for an
678   "opaque" cache validator. This might allow more reliable validation
679   in situations where it is inconvenient to store modification dates,
680   where the one-second resolution of HTTP date values is not
681   sufficient, or where the origin server wishes to avoid certain
682   paradoxes that might arise from the use of modification dates.
683</t>
684<t>
685   The principle behind entity tags is that only the service author
686   knows the semantics of a resource well enough to select an
687   appropriate cache validation mechanism, and the specification of any
688   validator comparison function more complex than byte-equality would
689   open up a can of worms. Thus, comparisons of any other headers
690   (except Last-Modified, for compatibility with HTTP/1.0) are never
691   used for purposes of validating a cache entry.
692</t>
693</section>
694
695<section title="If-Match" anchor="header.if-match">
696  <iref primary="true" item="If-Match header"/>
697  <iref primary="true" item="Headers" subitem="If-Match"/>
698 
699 
700<t>
701   The request-header field "If-Match" is used with a method to make it
702   conditional. A client that has one or more entities previously
703   obtained from the resource can verify that one of those entities is
704   current by including a list of their associated entity tags in the
705   If-Match header field. Entity tags are defined in <xref target="entity.tags"/>. The
706   purpose of this feature is to allow efficient updates of cached
707   information with a minimum amount of transaction overhead. It is also
708   used, on updating requests, to prevent inadvertent modification of
709   the wrong version of a resource. As a special case, the value "*"
710   matches any current entity of the resource.
711</t>
712<figure><iref primary="true" item="Grammar" subitem="If-Match"/><iref primary="true" item="Grammar" subitem="If-Match-v"/><artwork type="abnf2616"><![CDATA[
713  If-Match   = "If-Match" ":" OWS If-Match-v
714  If-Match-v = "*" / 1#entity-tag
715]]></artwork></figure>
716<t>
717   If any of the entity tags match the entity tag of the entity that
718   would have been returned in the response to a similar GET request
719   (without the If-Match header) on that resource, or if "*" is given
720   and any current entity exists for that resource, then the server MAY
721   perform the requested method as if the If-Match header field did not
722   exist.
723</t>
724<t>
725   A server MUST use the strong comparison function (see <xref target="weak.and.strong.validators"/>)
726   to compare the entity tags in If-Match.
727</t>
728<t>
729   If none of the entity tags match, or if "*" is given and no current
730   entity exists, the server MUST NOT perform the requested method, and
731   MUST return a 412 (Precondition Failed) response. This behavior is
732   most useful when the client wants to prevent an updating method, such
733   as PUT, from modifying a resource that has changed since the client
734   last retrieved it.
735</t>
736<t>
737   If the request would, without the If-Match header field, result in
738   anything other than a 2xx or 412 status, then the If-Match header
739   MUST be ignored.
740</t>
741<t>
742   The meaning of "If-Match: *" is that the method SHOULD be performed
743   if the representation selected by the origin server (or by a cache,
744   possibly using the Vary mechanism, see Section 3.5 of <xref target="Part6"/>) exists, and
745   MUST NOT be performed if the representation does not exist.
746</t>
747<t>
748   A request intended to update a resource (e.g., a PUT) MAY include an
749   If-Match header field to signal that the request method MUST NOT be
750   applied if the entity corresponding to the If-Match value (a single
751   entity tag) is no longer a representation of that resource. This
752   allows the user to indicate that they do not wish the request to be
753   successful if the resource has been changed without their knowledge.
754   Examples:
755</t>
756<figure><artwork type="example"><![CDATA[
757  If-Match: "xyzzy"
758  If-Match: "xyzzy", "r2d2xxxx", "c3piozzzz"
759  If-Match: *
760]]></artwork></figure>
761<t>
762   The result of a request having both an If-Match header field and
763   either an If-None-Match or an If-Modified-Since header fields is
764   undefined by this specification.
765</t>
766</section>
767
768<section title="If-Modified-Since" anchor="header.if-modified-since">
769  <iref primary="true" item="If-Modified-Since header"/>
770  <iref primary="true" item="Headers" subitem="If-Modified-Since"/>
771 
772 
773<t>
774   The request-header field "If-Modified-Since" is used with a method to
775   make it conditional: if the requested variant has not been modified
776   since the time specified in this field, an entity will not be
777   returned from the server; instead, a 304 (Not Modified) response will
778   be returned without any message-body.
779</t>
780<figure><iref primary="true" item="Grammar" subitem="If-Modified-Since"/><iref primary="true" item="Grammar" subitem="If-Modified-Since-v"/><artwork type="abnf2616"><![CDATA[
781  If-Modified-Since   = "If-Modified-Since" ":" OWS
782                        If-Modified-Since-v
783  If-Modified-Since-v = HTTP-date
784]]></artwork></figure>
785<t>
786   An example of the field is:
787</t>
788<figure><artwork type="example"><![CDATA[
789  If-Modified-Since: Sat, 29 Oct 1994 19:43:31 GMT
790]]></artwork></figure>
791<t>
792   A GET method with an If-Modified-Since header and no Range header
793   requests that the identified entity be transferred only if it has
794   been modified since the date given by the If-Modified-Since header.
795   The algorithm for determining this includes the following cases:
796  <list style="numbers">
797      <t>If the request would normally result in anything other than a
798         200 (OK) status, or if the passed If-Modified-Since date is
799         invalid, the response is exactly the same as for a normal GET.
800         A date which is later than the server's current time is
801         invalid.</t>
802
803      <t>If the variant has been modified since the If-Modified-Since
804         date, the response is exactly the same as for a normal GET.</t>
805
806      <t>If the variant has not been modified since a valid If-Modified-Since
807         date, the server SHOULD return a 304 (Not
808         Modified) response.</t>
809  </list>
810</t>
811<t>
812   The purpose of this feature is to allow efficient updates of cached
813   information with a minimum amount of transaction overhead.
814  <list><t>
815      Note: The Range request-header field modifies the meaning of If-Modified-Since;
816      see Section 5.4 of <xref target="Part5"/> for full details.
817    </t><t>
818      Note: If-Modified-Since times are interpreted by the server, whose
819      clock might not be synchronized with the client.
820    </t><t>
821      Note: When handling an If-Modified-Since header field, some
822      servers will use an exact date comparison function, rather than a
823      less-than function, for deciding whether to send a 304 (Not
824      Modified) response. To get best results when sending an If-Modified-Since
825      header field for cache validation, clients are
826      advised to use the exact date string received in a previous Last-Modified
827      header field whenever possible.
828    </t><t>
829      Note: If a client uses an arbitrary date in the If-Modified-Since
830      header instead of a date taken from the Last-Modified header for
831      the same request, the client should be aware of the fact that this
832      date is interpreted in the server's understanding of time. The
833      client should consider unsynchronized clocks and rounding problems
834      due to the different encodings of time between the client and
835      server. This includes the possibility of race conditions if the
836      document has changed between the time it was first requested and
837      the If-Modified-Since date of a subsequent request, and the
838      possibility of clock-skew-related problems if the If-Modified-Since
839      date is derived from the client's clock without correction
840      to the server's clock. Corrections for different time bases
841      between client and server are at best approximate due to network
842      latency.
843    </t>
844  </list>
845</t>
846<t>
847   The result of a request having both an If-Modified-Since header field
848   and either an If-Match or an If-Unmodified-Since header fields is
849   undefined by this specification.
850</t>
851</section>
852
853<section title="If-None-Match" anchor="header.if-none-match">
854  <iref primary="true" item="If-None-Match header"/>
855  <iref primary="true" item="Headers" subitem="If-None-Match"/>
856 
857 
858<t>
859   The request-header field "If-None-Match" is used with a method to make
860   it conditional. A client that has one or more entities previously
861   obtained from the resource can verify that none of those entities is
862   current by including a list of their associated entity tags in the
863   If-None-Match header field. The purpose of this feature is to allow
864   efficient updates of cached information with a minimum amount of
865   transaction overhead. It is also used to prevent a method (e.g. PUT)
866   from inadvertently modifying an existing resource when the client
867   believes that the resource does not exist.
868</t>
869<t>
870   As a special case, the value "*" matches any current entity of the
871   resource.
872</t>
873<figure><iref primary="true" item="Grammar" subitem="If-None-Match"/><iref primary="true" item="Grammar" subitem="If-None-Match-v"/><artwork type="abnf2616"><![CDATA[
874  If-None-Match   = "If-None-Match" ":" OWS If-None-Match-v
875  If-None-Match-v = "*" / 1#entity-tag
876]]></artwork></figure>
877<t>
878   If any of the entity tags match the entity tag of the entity that
879   would have been returned in the response to a similar GET request
880   (without the If-None-Match header) on that resource, or if "*" is
881   given and any current entity exists for that resource, then the
882   server MUST NOT perform the requested method, unless required to do
883   so because the resource's modification date fails to match that
884   supplied in an If-Modified-Since header field in the request.
885   Instead, if the request method was GET or HEAD, the server SHOULD
886   respond with a 304 (Not Modified) response, including the cache-related
887   header fields (particularly ETag) of one of the entities that
888   matched. For all other request methods, the server MUST respond with
889   a status of 412 (Precondition Failed).
890</t>
891<t>
892   See <xref target="weak.and.strong.validators"/> for rules on how to
893   determine if two entity tags match.
894</t>
895<t>
896   If none of the entity tags match, then the server MAY perform the
897   requested method as if the If-None-Match header field did not exist,
898   but MUST also ignore any If-Modified-Since header field(s) in the
899   request. That is, if no entity tags match, then the server MUST NOT
900   return a 304 (Not Modified) response.
901</t>
902<t>
903   If the request would, without the If-None-Match header field, result
904   in anything other than a 2xx or 304 status, then the If-None-Match
905   header MUST be ignored. (See <xref target="rules.for.when.to.use.entity.tags.and.last-modified.dates"/> for a discussion of
906   server behavior when both If-Modified-Since and If-None-Match appear
907   in the same request.)
908</t>
909<t>
910   The meaning of "If-None-Match: *" is that the method MUST NOT be
911   performed if the representation selected by the origin server (or by
912   a cache, possibly using the Vary mechanism, see Section 3.5 of <xref target="Part6"/>)
913   exists, and SHOULD be performed if the representation does not exist.
914   This feature is intended to be useful in preventing races between PUT
915   operations.
916</t>
917<t>
918   Examples:
919</t>
920<figure><artwork type="example"><![CDATA[
921  If-None-Match: "xyzzy"
922  If-None-Match: W/"xyzzy"
923  If-None-Match: "xyzzy", "r2d2xxxx", "c3piozzzz"
924  If-None-Match: W/"xyzzy", W/"r2d2xxxx", W/"c3piozzzz"
925  If-None-Match: *
926]]></artwork></figure>
927<t>
928   The result of a request having both an If-None-Match header field and
929   either an If-Match or an If-Unmodified-Since header fields is
930   undefined by this specification.
931</t>
932</section>
933
934<section title="If-Unmodified-Since" anchor="header.if-unmodified-since">
935  <iref primary="true" item="If-Unmodified-Since header"/>
936  <iref primary="true" item="Headers" subitem="If-Unmodified-Since"/>
937 
938 
939<t>
940   The request-header field "If-Unmodified-Since" is used with a method to
941   make it conditional. If the requested resource has not been modified
942   since the time specified in this field, the server SHOULD perform the
943   requested operation as if the If-Unmodified-Since header were not
944   present.
945</t>
946<t>
947   If the requested variant has been modified since the specified time,
948   the server MUST NOT perform the requested operation, and MUST return
949   a 412 (Precondition Failed).
950</t>
951<figure><iref primary="true" item="Grammar" subitem="If-Unmodified-Since"/><iref primary="true" item="Grammar" subitem="If-Unmodified-Since-v"/><artwork type="abnf2616"><![CDATA[
952  If-Unmodified-Since   = "If-Unmodified-Since" ":" OWS
953                          If-Unmodified-Since-v
954  If-Unmodified-Since-v = HTTP-date
955]]></artwork></figure>
956<t>
957   An example of the field is:
958</t>
959<figure><artwork type="example"><![CDATA[
960  If-Unmodified-Since: Sat, 29 Oct 1994 19:43:31 GMT
961]]></artwork></figure>
962<t>
963   If the request normally (i.e., without the If-Unmodified-Since
964   header) would result in anything other than a 2xx or 412 status, the
965   If-Unmodified-Since header SHOULD be ignored.
966</t>
967<t>
968   If the specified date is invalid, the header is ignored.
969</t>
970<t>
971   The result of a request having both an If-Unmodified-Since header
972   field and either an If-None-Match or an If-Modified-Since header
973   fields is undefined by this specification.
974</t>
975</section>
976
977<section title="Last-Modified" anchor="header.last-modified">
978  <iref primary="true" item="Last-Modified header"/>
979  <iref primary="true" item="Headers" subitem="Last-Modified"/>
980 
981 
982<t>
983   The entity-header field "Last-Modified" indicates the date and time at
984   which the origin server believes the variant was last modified.
985</t>
986<figure><iref primary="true" item="Grammar" subitem="Last-Modified"/><iref primary="true" item="Grammar" subitem="Last-Modified-v"/><artwork type="abnf2616"><![CDATA[
987  Last-Modified   = "Last-Modified" ":" OWS Last-Modified-v
988  Last-Modified-v = HTTP-date
989]]></artwork></figure>
990<t>
991   An example of its use is
992</t>
993<figure><artwork type="example"><![CDATA[
994  Last-Modified: Tue, 15 Nov 1994 12:45:26 GMT
995]]></artwork></figure>
996<t>
997   The exact meaning of this header field depends on the implementation
998   of the origin server and the nature of the original resource. For
999   files, it may be just the file system last-modified time. For
1000   entities with dynamically included parts, it may be the most recent
1001   of the set of last-modify times for its component parts. For database
1002   gateways, it may be the last-update time stamp of the record. For
1003   virtual objects, it may be the last time the internal state changed.
1004</t>
1005<t>
1006   An origin server MUST NOT send a Last-Modified date which is later
1007   than the server's time of message origination. In such cases, where
1008   the resource's last modification would indicate some time in the
1009   future, the server MUST replace that date with the message
1010   origination date.
1011</t>
1012<t>
1013   An origin server SHOULD obtain the Last-Modified value of the entity
1014   as close as possible to the time that it generates the Date value of
1015   its response. This allows a recipient to make an accurate assessment
1016   of the entity's modification time, especially if the entity changes
1017   near the time that the response is generated.
1018</t>
1019<t>
1020   HTTP/1.1 servers SHOULD send Last-Modified whenever feasible.
1021</t>
1022<t>
1023   The Last-Modified entity-header field value is often used as a cache
1024   validator. In simple terms, a cache entry is considered to be valid
1025   if the entity has not been modified since the Last-Modified value.
1026</t>
1027</section>
1028
1029</section>
1030
1031<section title="IANA Considerations" anchor="IANA.considerations">
1032<section title="Message Header Registration" anchor="message.header.registration">
1033<t>
1034   The Message Header Registry located at <eref target="http://www.iana.org/assignments/message-headers/message-header-index.html"/> should be updated
1035   with the permanent registrations below (see <xref target="RFC3864"/>):
1036</t>
1037<!--AUTOGENERATED FROM extract-header-defs.xslt, do not edit manually-->
1038<texttable align="left" suppress-title="true" anchor="iana.header.registration.table">
1039   <ttcol>Header Field Name</ttcol>
1040   <ttcol>Protocol</ttcol>
1041   <ttcol>Status</ttcol>
1042   <ttcol>Reference</ttcol>
1043
1044   <c>ETag</c>
1045   <c>http</c>
1046   <c>standard</c>
1047   <c>
1048      <xref target="header.etag"/>
1049   </c>
1050   <c>If-Match</c>
1051   <c>http</c>
1052   <c>standard</c>
1053   <c>
1054      <xref target="header.if-match"/>
1055   </c>
1056   <c>If-Modified-Since</c>
1057   <c>http</c>
1058   <c>standard</c>
1059   <c>
1060      <xref target="header.if-modified-since"/>
1061   </c>
1062   <c>If-None-Match</c>
1063   <c>http</c>
1064   <c>standard</c>
1065   <c>
1066      <xref target="header.if-none-match"/>
1067   </c>
1068   <c>If-Unmodified-Since</c>
1069   <c>http</c>
1070   <c>standard</c>
1071   <c>
1072      <xref target="header.if-unmodified-since"/>
1073   </c>
1074   <c>Last-Modified</c>
1075   <c>http</c>
1076   <c>standard</c>
1077   <c>
1078      <xref target="header.last-modified"/>
1079   </c>
1080</texttable>
1081<!--(END)-->
1082<t>
1083   The change controller is: "IETF (iesg@ietf.org) - Internet Engineering Task Force".
1084</t>
1085</section>
1086</section>
1087
1088<section title="Security Considerations" anchor="security.considerations">
1089<t>
1090   No additional security considerations have been identified beyond
1091   those applicable to HTTP in general <xref target="Part1"/>.
1092</t>
1093</section>
1094
1095<section title="Acknowledgments" anchor="ack">
1096</section>
1097</middle>
1098<back>
1099
1100<references title="Normative References">
1101
1102<reference anchor="Part1">
1103  <front>
1104    <title abbrev="HTTP/1.1">HTTP/1.1, part 1: URIs, Connections, and Message Parsing</title>
1105    <author initials="R." surname="Fielding" fullname="Roy T. Fielding" role="editor">
1106      <organization abbrev="Day Software">Day Software</organization>
1107      <address><email>fielding@gbiv.com</email></address>
1108    </author>
1109    <author initials="J." surname="Gettys" fullname="Jim Gettys">
1110      <organization>One Laptop per Child</organization>
1111      <address><email>jg@laptop.org</email></address>
1112    </author>
1113    <author initials="J." surname="Mogul" fullname="Jeffrey C. Mogul">
1114      <organization abbrev="HP">Hewlett-Packard Company</organization>
1115      <address><email>JeffMogul@acm.org</email></address>
1116    </author>
1117    <author initials="H." surname="Frystyk" fullname="Henrik Frystyk Nielsen">
1118      <organization abbrev="Microsoft">Microsoft Corporation</organization>
1119      <address><email>henrikn@microsoft.com</email></address>
1120    </author>
1121    <author initials="L." surname="Masinter" fullname="Larry Masinter">
1122      <organization abbrev="Adobe Systems">Adobe Systems, Incorporated</organization>
1123      <address><email>LMM@acm.org</email></address>
1124    </author>
1125    <author initials="P." surname="Leach" fullname="Paul J. Leach">
1126      <organization abbrev="Microsoft">Microsoft Corporation</organization>
1127      <address><email>paulle@microsoft.com</email></address>
1128    </author>
1129    <author initials="T." surname="Berners-Lee" fullname="Tim Berners-Lee">
1130      <organization abbrev="W3C/MIT">World Wide Web Consortium</organization>
1131      <address><email>timbl@w3.org</email></address>
1132    </author>
1133    <author initials="Y." surname="Lafon" fullname="Yves Lafon" role="editor">
1134      <organization abbrev="W3C">World Wide Web Consortium</organization>
1135      <address><email>ylafon@w3.org</email></address>
1136    </author>
1137    <author initials="J. F." surname="Reschke" fullname="Julian F. Reschke" role="editor">
1138      <organization abbrev="greenbytes">greenbytes GmbH</organization>
1139      <address><email>julian.reschke@greenbytes.de</email></address>
1140    </author>
1141    <date month="March" year="2009"/>
1142  </front>
1143  <seriesInfo name="Internet-Draft" value="draft-ietf-httpbis-p1-messaging-06"/>
1144 
1145</reference>
1146
1147<reference anchor="Part5">
1148  <front>
1149    <title abbrev="HTTP/1.1">HTTP/1.1, part 5: Range Requests and Partial Responses</title>
1150    <author initials="R." surname="Fielding" fullname="Roy T. Fielding" role="editor">
1151      <organization abbrev="Day Software">Day Software</organization>
1152      <address><email>fielding@gbiv.com</email></address>
1153    </author>
1154    <author initials="J." surname="Gettys" fullname="Jim Gettys">
1155      <organization>One Laptop per Child</organization>
1156      <address><email>jg@laptop.org</email></address>
1157    </author>
1158    <author initials="J." surname="Mogul" fullname="Jeffrey C. Mogul">
1159      <organization abbrev="HP">Hewlett-Packard Company</organization>
1160      <address><email>JeffMogul@acm.org</email></address>
1161    </author>
1162    <author initials="H." surname="Frystyk" fullname="Henrik Frystyk Nielsen">
1163      <organization abbrev="Microsoft">Microsoft Corporation</organization>
1164      <address><email>henrikn@microsoft.com</email></address>
1165    </author>
1166    <author initials="L." surname="Masinter" fullname="Larry Masinter">
1167      <organization abbrev="Adobe Systems">Adobe Systems, Incorporated</organization>
1168      <address><email>LMM@acm.org</email></address>
1169    </author>
1170    <author initials="P." surname="Leach" fullname="Paul J. Leach">
1171      <organization abbrev="Microsoft">Microsoft Corporation</organization>
1172      <address><email>paulle@microsoft.com</email></address>
1173    </author>
1174    <author initials="T." surname="Berners-Lee" fullname="Tim Berners-Lee">
1175      <organization abbrev="W3C/MIT">World Wide Web Consortium</organization>
1176      <address><email>timbl@w3.org</email></address>
1177    </author>
1178    <author initials="Y." surname="Lafon" fullname="Yves Lafon" role="editor">
1179      <organization abbrev="W3C">World Wide Web Consortium</organization>
1180      <address><email>ylafon@w3.org</email></address>
1181    </author>
1182    <author initials="J. F." surname="Reschke" fullname="Julian F. Reschke" role="editor">
1183      <organization abbrev="greenbytes">greenbytes GmbH</organization>
1184      <address><email>julian.reschke@greenbytes.de</email></address>
1185    </author>
1186    <date month="March" year="2009"/>
1187  </front>
1188  <seriesInfo name="Internet-Draft" value="draft-ietf-httpbis-p5-range-06"/>
1189 
1190</reference>
1191
1192<reference anchor="Part6">
1193  <front>
1194    <title abbrev="HTTP/1.1">HTTP/1.1, part 6: Caching</title>
1195    <author initials="R." surname="Fielding" fullname="Roy T. Fielding" role="editor">
1196      <organization abbrev="Day Software">Day Software</organization>
1197      <address><email>fielding@gbiv.com</email></address>
1198    </author>
1199    <author initials="J." surname="Gettys" fullname="Jim Gettys">
1200      <organization>One Laptop per Child</organization>
1201      <address><email>jg@laptop.org</email></address>
1202    </author>
1203    <author initials="J." surname="Mogul" fullname="Jeffrey C. Mogul">
1204      <organization abbrev="HP">Hewlett-Packard Company</organization>
1205      <address><email>JeffMogul@acm.org</email></address>
1206    </author>
1207    <author initials="H." surname="Frystyk" fullname="Henrik Frystyk Nielsen">
1208      <organization abbrev="Microsoft">Microsoft Corporation</organization>
1209      <address><email>henrikn@microsoft.com</email></address>
1210    </author>
1211    <author initials="L." surname="Masinter" fullname="Larry Masinter">
1212      <organization abbrev="Adobe Systems">Adobe Systems, Incorporated</organization>
1213      <address><email>LMM@acm.org</email></address>
1214    </author>
1215    <author initials="P." surname="Leach" fullname="Paul J. Leach">
1216      <organization abbrev="Microsoft">Microsoft Corporation</organization>
1217      <address><email>paulle@microsoft.com</email></address>
1218    </author>
1219    <author initials="T." surname="Berners-Lee" fullname="Tim Berners-Lee">
1220      <organization abbrev="W3C/MIT">World Wide Web Consortium</organization>
1221      <address><email>timbl@w3.org</email></address>
1222    </author>
1223    <author initials="Y." surname="Lafon" fullname="Yves Lafon" role="editor">
1224      <organization abbrev="W3C">World Wide Web Consortium</organization>
1225      <address><email>ylafon@w3.org</email></address>
1226    </author>
1227    <author initials="J. F." surname="Reschke" fullname="Julian F. Reschke" role="editor">
1228      <organization abbrev="greenbytes">greenbytes GmbH</organization>
1229      <address><email>julian.reschke@greenbytes.de</email></address>
1230    </author>
1231    <date month="March" year="2009"/>
1232  </front>
1233  <seriesInfo name="Internet-Draft" value="draft-ietf-httpbis-p6-cache-06"/>
1234 
1235</reference>
1236
1237<reference anchor="RFC2119">
1238  <front>
1239    <title>Key words for use in RFCs to Indicate Requirement Levels</title>
1240    <author initials="S." surname="Bradner" fullname="Scott Bradner">
1241      <organization>Harvard University</organization>
1242      <address><email>sob@harvard.edu</email></address>
1243    </author>
1244    <date month="March" year="1997"/>
1245  </front>
1246  <seriesInfo name="BCP" value="14"/>
1247  <seriesInfo name="RFC" value="2119"/>
1248</reference>
1249
1250<reference anchor="RFC5234">
1251  <front>
1252    <title abbrev="ABNF for Syntax Specifications">Augmented BNF for Syntax Specifications: ABNF</title>
1253    <author initials="D." surname="Crocker" fullname="Dave Crocker" role="editor">
1254      <organization>Brandenburg InternetWorking</organization>
1255      <address>
1256      <postal>
1257      <street>675 Spruce Dr.</street>
1258      <city>Sunnyvale</city>
1259      <region>CA</region>
1260      <code>94086</code>
1261      <country>US</country></postal>
1262      <phone>+1.408.246.8253</phone>
1263      <email>dcrocker@bbiw.net</email></address> 
1264    </author>
1265    <author initials="P." surname="Overell" fullname="Paul Overell">
1266      <organization>THUS plc.</organization>
1267      <address>
1268      <postal>
1269      <street>1/2 Berkeley Square</street>
1270      <street>99 Berkely Street</street>
1271      <city>Glasgow</city>
1272      <code>G3 7HR</code>
1273      <country>UK</country></postal>
1274      <email>paul.overell@thus.net</email></address>
1275    </author>
1276    <date month="January" year="2008"/>
1277  </front>
1278  <seriesInfo name="STD" value="68"/>
1279  <seriesInfo name="RFC" value="5234"/>
1280</reference>
1281
1282</references>
1283
1284<references title="Informative References">
1285
1286<reference anchor="RFC2616">
1287  <front>
1288    <title>Hypertext Transfer Protocol -- HTTP/1.1</title>
1289    <author initials="R." surname="Fielding" fullname="R. Fielding">
1290      <organization>University of California, Irvine</organization>
1291      <address><email>fielding@ics.uci.edu</email></address>
1292    </author>
1293    <author initials="J." surname="Gettys" fullname="J. Gettys">
1294      <organization>W3C</organization>
1295      <address><email>jg@w3.org</email></address>
1296    </author>
1297    <author initials="J." surname="Mogul" fullname="J. Mogul">
1298      <organization>Compaq Computer Corporation</organization>
1299      <address><email>mogul@wrl.dec.com</email></address>
1300    </author>
1301    <author initials="H." surname="Frystyk" fullname="H. Frystyk">
1302      <organization>MIT Laboratory for Computer Science</organization>
1303      <address><email>frystyk@w3.org</email></address>
1304    </author>
1305    <author initials="L." surname="Masinter" fullname="L. Masinter">
1306      <organization>Xerox Corporation</organization>
1307      <address><email>masinter@parc.xerox.com</email></address>
1308    </author>
1309    <author initials="P." surname="Leach" fullname="P. Leach">
1310      <organization>Microsoft Corporation</organization>
1311      <address><email>paulle@microsoft.com</email></address>
1312    </author>
1313    <author initials="T." surname="Berners-Lee" fullname="T. Berners-Lee">
1314      <organization>W3C</organization>
1315      <address><email>timbl@w3.org</email></address>
1316    </author>
1317    <date month="June" year="1999"/>
1318  </front>
1319  <seriesInfo name="RFC" value="2616"/>
1320</reference>
1321
1322<reference anchor="RFC3864">
1323  <front>
1324    <title>Registration Procedures for Message Header Fields</title>
1325    <author initials="G." surname="Klyne" fullname="G. Klyne">
1326      <organization>Nine by Nine</organization>
1327      <address><email>GK-IETF@ninebynine.org</email></address>
1328    </author>
1329    <author initials="M." surname="Nottingham" fullname="M. Nottingham">
1330      <organization>BEA Systems</organization>
1331      <address><email>mnot@pobox.com</email></address>
1332    </author>
1333    <author initials="J." surname="Mogul" fullname="J. Mogul">
1334      <organization>HP Labs</organization>
1335      <address><email>JeffMogul@acm.org</email></address>
1336    </author>
1337    <date year="2004" month="September"/>
1338  </front>
1339  <seriesInfo name="BCP" value="90"/>
1340  <seriesInfo name="RFC" value="3864"/>
1341</reference>
1342
1343</references>
1344
1345<section title="Compatibility with Previous Versions" anchor="compatibility">
1346
1347<section title="Changes from RFC 2616" anchor="changes.from.rfc.2616">
1348<t>
1349  Allow weak entity tags in all requests except range requests (Sections
1350  <xref target="weak.and.strong.validators" format="counter"/> and
1351  <xref target="header.if-none-match" format="counter"/>).
1352</t>
1353</section>
1354
1355</section>
1356
1357<section title="Collected ABNF" anchor="collected.abnf">
1358<figure>
1359<artwork type="abnf" name="p4-conditional.parsed-abnf"><![CDATA[
1360ETag = "ETag:" OWS ETag-v
1361ETag-v = entity-tag
1362
1363HTTP-date = <HTTP-date, defined in [Part1], Section 3.2.1>
1364
1365If-Match = "If-Match:" OWS If-Match-v
1366If-Match-v = "*" / ( *( "," OWS ) entity-tag *( OWS "," [ OWS
1367 entity-tag ] ) )
1368If-Modified-Since = "If-Modified-Since:" OWS If-Modified-Since-v
1369If-Modified-Since-v = HTTP-date
1370If-None-Match = "If-None-Match:" OWS If-None-Match-v
1371If-None-Match-v = "*" / ( *( "," OWS ) entity-tag *( OWS "," [ OWS
1372 entity-tag ] ) )
1373If-Unmodified-Since = "If-Unmodified-Since:" OWS
1374 If-Unmodified-Since-v
1375If-Unmodified-Since-v = HTTP-date
1376
1377Last-Modified = "Last-Modified:" OWS Last-Modified-v
1378Last-Modified-v = HTTP-date
1379
1380OWS = <OWS, defined in [Part1], Section 1.2.2>
1381
1382entity-tag = [ weak ] opaque-tag
1383
1384opaque-tag = quoted-string
1385
1386quoted-string = <quoted-string, defined in [Part1], Section 1.2.2>
1387
1388weak = "W/"
1389
1390
1391]]></artwork>
1392</figure>
1393<figure><preamble>ABNF diagnostics:</preamble><artwork type="inline"><![CDATA[
1394; ETag defined but not used
1395; If-Match defined but not used
1396; If-Modified-Since defined but not used
1397; If-None-Match defined but not used
1398; If-Unmodified-Since defined but not used
1399; Last-Modified defined but not used
1400]]></artwork></figure></section>
1401
1402<section title="Change Log (to be removed by RFC Editor before publication)" anchor="change.log">
1403
1404<section title="Since RFC2616">
1405<t>
1406  Extracted relevant partitions from <xref target="RFC2616"/>.
1407</t>
1408</section>
1409
1410<section title="Since draft-ietf-httpbis-p4-conditional-00">
1411<t>
1412  Closed issues:
1413  <list style="symbols"> 
1414    <t>
1415      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/35"/>:
1416      "Normative and Informative references"
1417    </t>
1418  </list>
1419</t>
1420<t>
1421  Other changes:
1422  <list style="symbols"> 
1423    <t>
1424      Move definitions of 304 and 412 condition codes from Part2.
1425    </t>
1426  </list>
1427</t>
1428</section>
1429
1430<section title="Since draft-ietf-httpbis-p4-conditional-01">
1431<t>
1432  Ongoing work on ABNF conversion (<eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/36"/>):
1433  <list style="symbols"> 
1434    <t>
1435      Add explicit references to BNF syntax and rules imported from other parts of the specification.
1436    </t>
1437  </list>
1438</t>
1439</section>
1440
1441<section title="Since draft-ietf-httpbis-p4-conditional-02" anchor="changes.since.02">
1442<t>
1443  Closed issues:
1444  <list style="symbols"> 
1445    <t>
1446      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/116"/>:
1447      "Weak ETags on non-GET requests"
1448    </t>
1449  </list>
1450</t>
1451<t>
1452  Ongoing work on IANA Message Header Registration (<eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/40"/>):
1453  <list style="symbols"> 
1454    <t>
1455      Reference RFC 3984, and update header registrations for headers defined
1456      in this document.
1457    </t>
1458  </list>
1459</t>
1460</section>
1461
1462<section title="Since draft-ietf-httpbis-p4-conditional-03" anchor="changes.since.03">
1463<t>
1464  Closed issues:
1465  <list style="symbols"> 
1466    <t>
1467      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/71"/>:
1468      "Examples for ETag matching"
1469    </t>
1470    <t>
1471      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/124"/>:
1472      "'entity value' undefined"
1473    </t>
1474    <t>
1475      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/126"/>:
1476      "bogus 2068 Date header reference"
1477    </t>
1478  </list>
1479</t>
1480</section>
1481
1482<section title="Since draft-ietf-httpbis-p4-conditional-04" anchor="changes.since.04">
1483<t>
1484  Ongoing work on ABNF conversion (<eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/36"/>):
1485  <list style="symbols"> 
1486    <t>
1487      Use "/" instead of "|" for alternatives.
1488    </t>
1489    <t>
1490      Introduce new ABNF rules for "bad" whitespace ("BWS"), optional
1491      whitespace ("OWS") and required whitespace ("RWS").
1492    </t>
1493    <t>
1494      Rewrite ABNFs to spell out whitespace rules, factor out
1495      header value format definitions.
1496    </t>
1497  </list>
1498</t>
1499</section>
1500
1501<section title="Since draft-ietf-httpbis-p4-conditional-05" anchor="changes.since.05">
1502<t>
1503  Final work on ABNF conversion (<eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/36"/>):
1504  <list style="symbols"> 
1505    <t>
1506      Add appendix containing collected and expanded ABNF, reorganize ABNF introduction.
1507    </t>
1508  </list>
1509</t>
1510</section>
1511
1512</section>
1513
1514</back>
1515</rfc>
Note: See TracBrowser for help on using the repository browser.