Ignore:
Timestamp:
Jul 12, 2012, 3:14:44 AM (7 years ago)
Author:
julian.reschke@…
Message:

Refactor If-*Match header fields to separately define the condition (see #372)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • draft-ietf-httpbis/latest/p4-conditional.xml

    r1758 r1761  
    758758</artwork></figure>
    759759<t>
    760    If any of the entity-tags listed in the If-Match field value match
    761    (as per <xref target="entity.tag.comparison"/>) the entity-tag of the
    762    selected representation for the target resource,
    763    or if "*" is given and any current representation exists for the
    764    target resource, then the server &MAY; perform the request method
    765    as if the If-Match header field was not present.
    766 </t>
    767 <t>
    768    Origin servers &MUST-NOT; perform the requested method if none of the
    769    entity-tags match, or if "*" is given and no current representation
    770    exists; instead they &MUST; respond with the <x:ref>412 (Precondition Failed)</x:ref>
    771    status code.
     760   The If-Match condition is met if and only if any of the entity-tags listed
     761   in the If-Match field value match the entity-tag of the selected
     762   representation for the target resource (as per <xref
     763   target="entity.tag.comparison"/>), or if "*" is given and any current
     764   representation exists for the target resource.
     765</t>
     766<t>
     767   If the condition is met, the server &MAY; perform the request method as if
     768   the If-Match header field was not present.
     769</t>
     770<t>
     771   Origin servers &MUST-NOT; perform the requested method if the condition is
     772   not met; instead they &MUST; respond with the <x:ref>412 (Precondition
     773   Failed)</x:ref> status code.
    772774</t>
    773775<t>
    774776   Proxy servers using a cached response as the selected representation
    775    &MUST-NOT; perform the requested method if none of the entity-tags match,
    776    or if "*" is given and no current representation exists; instead, they
    777    &MUST; forward the request towards the origin server.
     777   &MUST-NOT; perform the requested method if the condition is not met;
     778   instead, they &MUST; forward the request towards the origin server.
    778779</t>
    779780<t>
     
    827828</artwork></figure>
    828829<t>
    829    If any of the entity-tags listed in the If-None-Match field-value match
    830    (as per <xref target="entity.tag.comparison"/>) the entity-tag of the
    831    selected representation, or if "*" is
    832    given and any current representation exists for that resource, then the
    833    server &MUST-NOT; perform the requested method.
    834    Instead, if the request method was GET or HEAD, the server &SHOULD;
    835    respond with a <x:ref>304 (Not Modified)</x:ref> status code, including the cache-related
    836    header fields (particularly <x:ref>ETag</x:ref>) of the selected representation that has
    837    a matching entity-tag.  For all other request methods, the server &MUST;
    838    respond with a <x:ref>412 (Precondition Failed)</x:ref> status code.
    839 </t>
    840 <t>
    841    If none of the entity-tags match, then the server &MAY; perform the
    842    requested method as if the If-None-Match header field did not exist,
    843    but &MUST; also ignore any <x:ref>If-Modified-Since</x:ref> header field(s)
    844    in the request. That is, if no entity-tags match, then the server &MUST-NOT;
    845    return a <x:ref>304 (Not Modified)</x:ref> response.
     830   The If-None-Match condition is met if and only if none of the entity-tags
     831   listed in the If-None-Match field value match the entity-tag of the selected
     832   representation for the target resource (as per <xref
     833   target="entity.tag.comparison"/>), or if "*" is given and no current
     834   representation exists for that resource.
     835</t>
     836<t>
     837   If the condition is not met, the server &MUST-NOT; perform the requested
     838   method. Instead, if the request method was GET or HEAD, the server &SHOULD;
     839   respond with a <x:ref>304 (Not Modified)</x:ref> status code, including the
     840   cache-related header fields (particularly <x:ref>ETag</x:ref>) of the
     841   selected representation that has a matching entity-tag. For all other
     842   request methods, the server &MUST; respond with a <x:ref>412 (Precondition
     843   Failed)</x:ref> status code.
     844</t>
     845<t>
     846   If the condition is met, the server &MAY; perform the requested method
     847   as if the If-None-Match header field did not exist, but &MUST; also ignore
     848   any <x:ref>If-Modified-Since</x:ref> header field(s) in the request. That
     849   is, if no entity-tags match, then the server &MUST-NOT; return a <x:ref>304
     850   (Not Modified)</x:ref> response.
    846851</t>
    847852<t>
     
    14621467      "Rare cases"
    14631468    </t>
     1469    <t>
     1470      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/372"/>:
     1471      "refactor conditional header field descriptions"
     1472    </t>
    14641473  </list>
    14651474</t>
Note: See TracChangeset for help on using the changeset viewer.