W3C home > Mailing lists > Public > ietf-http-wg@w3.org > April to June 2012

Re: WGLC issue: P4 - ETags & conditional requests

From: Roy T. Fielding <fielding@gbiv.com>
Date: Mon, 23 Apr 2012 12:12:03 -0700
Cc: "ietf-http-wg@w3.org Group" <ietf-http-wg@w3.org>, John Sullivan <jsullivan@velocix.com>
Message-Id: <1BC5B798-1594-46A2-B4CA-2CBC038F0FAA@gbiv.com>
To: Ben Niven-Jenkins <ben@niven-jenkins.co.uk>
On Apr 23, 2012, at 10:47 AM, Ben Niven-Jenkins wrote:

> Hi,
> Apologies that this mail misses the WG LC deadline, in Velocix we're reviewing all the HTTPBIS documents but we're a little behind, hence the late comments, sorry. (we're still reviewing so might have more comments as we work through the documents)
> On page 14 of P4 it states:
>   If none of the entity-tags match, or if "*" is given and no current
>   representation exists, the server MUST NOT perform the requested
>   method.  Instead, the server MUST respond with the 412 (Precondition
>   Failed) status code.
> This appears to apply to intermediates, but If-Match has a problem
> here that If-Unmodified-Since does not. If a proxy has a cached
> entity which has a newer Last-Modified timestamp it *knows* that
> the conditional has failed and can generate the required
> 412 Precondition Failed response itself. Otherwise it can satisfy
> the request from cache. Or relay if there is no current cached
> version.
> But because multiple responses with different ETags may exist then a cache receiving If-Match with one etag, when it has a different etag cached, can not know for sure that the request etag does not exist. If it were to respond with a 412 status it would effectively be preventing the use of that conditional.
> It would appear that the only two options available to an intermediate are to satisfy the request in the case of a known match, and relay upstream in all other cases (which would be in conflict with the spec as quoted above).
> Thanks
> Ben

Thanks for your comments (there is plenty of time left, so keep them coming).

Yes, that appears to be a bug in the spec.  Only an origin server can respond 412.

Received on Monday, 23 April 2012 19:12:31 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 1 March 2016 11:11:02 UTC