Re: WGLC issue: P4 - ETags & conditional requests

"Roy T. Fielding" <fielding@gbiv.com> Mon, 23 April 2012 19:13 UTC

Return-Path: <ietf-http-wg-request@listhub.w3.org>
X-Original-To: ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com
Delivered-To: ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 6E5D121F859F for <ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com>; Mon, 23 Apr 2012 12:13:52 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -9.419
X-Spam-Level:
X-Spam-Status: No, score=-9.419 tagged_above=-999 required=5 tests=[AWL=1.180, BAYES_00=-2.599, RCVD_IN_DNSWL_HI=-8]
Received: from mail.ietf.org ([12.22.58.30]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id pEnqr+VM3QuJ for <ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com>; Mon, 23 Apr 2012 12:13:51 -0700 (PDT)
Received: from frink.w3.org (frink.w3.org [128.30.52.56]) by ietfa.amsl.com (Postfix) with ESMTP id A7A3621F858D for <httpbisa-archive-bis2Juki@lists.ietf.org>; Mon, 23 Apr 2012 12:13:51 -0700 (PDT)
Received: from lists by frink.w3.org with local (Exim 4.69) (envelope-from <ietf-http-wg-request@listhub.w3.org>) id 1SMOgk-0007Qc-DL for ietf-http-wg-dist@listhub.w3.org; Mon, 23 Apr 2012 19:12:42 +0000
Received: from lisa.w3.org ([128.30.52.41]) by frink.w3.org with esmtp (Exim 4.69) (envelope-from <fielding@gbiv.com>) id 1SMOgZ-0007Pl-Hs for ietf-http-wg@listhub.w3.org; Mon, 23 Apr 2012 19:12:31 +0000
Received: from caiajhbdcaid.dreamhost.com ([208.97.132.83] helo=homiemail-a96.g.dreamhost.com) by lisa.w3.org with esmtp (Exim 4.72) (envelope-from <fielding@gbiv.com>) id 1SMOgT-0007Rk-3B for ietf-http-wg@w3.org; Mon, 23 Apr 2012 19:12:29 +0000
Received: from homiemail-a96.g.dreamhost.com (localhost [127.0.0.1]) by homiemail-a96.g.dreamhost.com (Postfix) with ESMTP id 6C19A3B8078; Mon, 23 Apr 2012 12:12:04 -0700 (PDT)
DomainKey-Signature: a=rsa-sha1; c=nofws; d=gbiv.com; h=subject:mime-version :content-type:from:in-reply-to:date:cc:content-transfer-encoding :message-id:references:to; q=dns; s=gbiv.com; b=fIZLxC8QVNw/rgja 8lOm4wzcX0WyamR8+WaZpsttVT/U8uU6vBf8vi5Y2pNaQIisCC+xgq7AQVMZiiMa zzX+NfIaQcji92G/FXxUjMUNe3su5l8BefSvjSM9Km9bzJ348FSWBuUl+zFvDyte j2wOjyXdrjWZTEhckNbOLFlcm4o=
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=gbiv.com; h=subject :mime-version:content-type:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; s=gbiv.com; bh=MSPZUzBpiXoYqjTx3E+GxHBaT5k=; b=YK9XO0Bzk6EzEX2OzUKSx/sTf6Re hQUt8Y+k0cBohGortw1bLkSzsp30S3YJZx5YhSoJuLZki68VeJbS/1kfVlnA12yJ 28AAeWJOSmGWOE3BOhLx5/tGpjSGKyg2eqGh4Zznjhk2ZfvtcUTMkmCLCGzg++66 TEbp7wFZ0VR4H6g=
Received: from [192.168.1.84] (99-21-208-82.lightspeed.irvnca.sbcglobal.net [99.21.208.82]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (No client certificate requested) (Authenticated sender: fielding@gbiv.com) by homiemail-a96.g.dreamhost.com (Postfix) with ESMTPSA id F2EB53B800C; Mon, 23 Apr 2012 12:12:03 -0700 (PDT)
Mime-Version: 1.0 (Apple Message framework v1257)
Content-Type: text/plain; charset=us-ascii
From: "Roy T. Fielding" <fielding@gbiv.com>
In-Reply-To: <B5E63193-2450-41AD-A3AA-047755F2189D@niven-jenkins.co.uk>
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>
Content-Transfer-Encoding: quoted-printable
Message-Id: <1BC5B798-1594-46A2-B4CA-2CBC038F0FAA@gbiv.com>
References: <B5E63193-2450-41AD-A3AA-047755F2189D@niven-jenkins.co.uk>
To: Ben Niven-Jenkins <ben@niven-jenkins.co.uk>
X-Mailer: Apple Mail (2.1257)
Received-SPF: none client-ip=208.97.132.83; envelope-from=fielding@gbiv.com; helo=homiemail-a96.g.dreamhost.com
X-W3C-Hub-Spam-Status: No, score=-2.0
X-W3C-Hub-Spam-Report: BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, RCVD_IN_DNSWL_NONE=-0.0001
X-W3C-Scan-Sig: lisa.w3.org 1SMOgT-0007Rk-3B 660a849b30f18ba2ff6005ce4819ec5d
X-Original-To: ietf-http-wg@w3.org
Subject: Re: WGLC issue: P4 - ETags & conditional requests
Archived-At: <http://www.w3.org/mid/1BC5B798-1594-46A2-B4CA-2CBC038F0FAA@gbiv.com>
Resent-From: ietf-http-wg@w3.org
X-Mailing-List: <ietf-http-wg@w3.org> archive/latest/13465
X-Loop: ietf-http-wg@w3.org
Resent-Sender: ietf-http-wg-request@w3.org
Precedence: list
List-Id: <ietf-http-wg.w3.org>
List-Help: <http://www.w3.org/Mail/>
List-Post: <mailto:ietf-http-wg@w3.org>
List-Unsubscribe: <mailto:ietf-http-wg-request@w3.org?subject=unsubscribe>
Resent-Message-Id: <E1SMOgk-0007Qc-DL@frink.w3.org>
Resent-Date: Mon, 23 Apr 2012 19:12:42 +0000

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.

....Roy