[Technical Errata Reported] RFC9111 (7695)

RFC Errata System <rfc-editor@rfc-editor.org> Tue, 07 November 2023 17:45 UTC

Return-Path: <ietf-http-wg-request+bounce-httpbisa-archive-bis2juki=ietf.org@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 F2A01C1524BC for <ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com>; Tue, 7 Nov 2023 09:45:21 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -7.657
X-Spam-Level:
X-Spam-Status: No, score=-7.657 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, HEADER_FROM_DIFFERENT_DOMAINS=0.249, MAILING_LIST_MULTI=-1, RCVD_IN_DNSWL_HI=-5, RCVD_IN_MSPIKE_H5=0.001, RCVD_IN_MSPIKE_WL=0.001, RCVD_IN_ZEN_BLOCKED_OPENDNS=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01, URIBL_DBL_BLOCKED_OPENDNS=0.001, URIBL_ZEN_BLOCKED_OPENDNS=0.001] autolearn=unavailable autolearn_force=no
Received: from mail.ietf.org ([50.223.129.194]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id R-joX-v2Gfwl for <ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com>; Tue, 7 Nov 2023 09:45:18 -0800 (PST)
Received: from lyra.w3.org (lyra.w3.org [128.30.52.18]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 34D56C14CE36 for <httpbisa-archive-bis2Juki@ietf.org>; Tue, 7 Nov 2023 09:45:17 -0800 (PST)
Received: from lists by lyra.w3.org with local (Exim 4.94.2) (envelope-from <ietf-http-wg-request@listhub.w3.org>) id 1r0Q5x-00GkSp-Km for ietf-http-wg-dist@listhub.w3.org; Tue, 07 Nov 2023 17:42:33 +0000
Resent-Date: Tue, 07 Nov 2023 17:42:33 +0000
Resent-Message-Id: <E1r0Q5x-00GkSp-Km@lyra.w3.org>
Received: from titan.w3.org ([128.30.52.76]) by lyra.w3.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from <wwwrun@rfcpa.amsl.com>) id 1r0Q5v-00GkRi-HR for ietf-http-wg@listhub.w3.org; Tue, 07 Nov 2023 17:42:31 +0000
Received: from [50.223.129.200] (helo=rfcpa.amsl.com) by titan.w3.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from <wwwrun@rfcpa.amsl.com>) id 1r0Q5t-00CMJY-AH for ietf-http-wg@w3.org; Tue, 07 Nov 2023 17:42:31 +0000
Received: by rfcpa.amsl.com (Postfix, from userid 499) id 2692D55E6C; Tue, 7 Nov 2023 09:42:21 -0800 (PST)
To: fielding@gbiv.com, mnot@mnot.net, julian.reschke@greenbytes.de, superuser@gmail.com, francesca.palombini@ericsson.com, mnot@mnot.net, tpauly@apple.com
From: RFC Errata System <rfc-editor@rfc-editor.org>
Cc: dron.rathore@gmail.com, ietf-http-wg@w3.org, rfc-editor@rfc-editor.org
Content-Type: text/plain; charset="UTF-8"
Message-Id: <20231107174221.2692D55E6C@rfcpa.amsl.com>
Date: Tue, 07 Nov 2023 09:42:21 -0800
Received-SPF: softfail client-ip=50.223.129.200; envelope-from=wwwrun@rfcpa.amsl.com; helo=rfcpa.amsl.com
X-W3C-Hub-Spam-Status: No, score=-2.5
X-W3C-Hub-Spam-Report: BAYES_00=-1.9, HEADER_FROM_DIFFERENT_DOMAINS=0.25, RCVD_IN_DNSWL_NONE=-0.0001, RDNS_NONE=0.793, SPF_HELO_SOFTFAIL=0.732, SPF_SOFTFAIL=0.665, T_SCC_BODY_TEXT_LINE=-0.01, W3C_AA=-1, W3C_IRA=-1, W3C_WL=-1
X-W3C-Scan-Sig: titan.w3.org 1r0Q5t-00CMJY-AH c550adc0281cf5a71feba4b3e8840f33
X-Original-To: ietf-http-wg@w3.org
Subject: [Technical Errata Reported] RFC9111 (7695)
Archived-At: <https://www.w3.org/mid/20231107174221.2692D55E6C@rfcpa.amsl.com>
Resent-From: ietf-http-wg@w3.org
X-Mailing-List: <ietf-http-wg@w3.org> archive/latest/51575
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: <https://www.w3.org/email/>
List-Post: <mailto:ietf-http-wg@w3.org>
List-Unsubscribe: <mailto:ietf-http-wg-request@w3.org?subject=unsubscribe>

The following errata report has been submitted for RFC9111,
"HTTP Caching".

--------------------------------------
You may review the report below and at:
https://www.rfc-editor.org/errata/eid7695

--------------------------------------
Type: Technical
Reported by: Dron Rathore <dron.rathore@gmail.com>

Section: 4.3.2-4

Original Text
-------------
   The proper evaluation of conditional requests by a cache depends on
   the received precondition header fields and their precedence.  In
   summary, the If-Match and If-Unmodified-Since conditional header
   fields are not applicable to a cache, and If-None-Match takes
   precedence over If-Modified-Since.  See Section 13.2.2 of [HTTP] for
   a complete specification of precondition precedence.

Corrected Text
--------------
   The proper evaluation of conditional requests by a cache depends on
   the received precondition header fields and their precedence.  In
   summary, the If-Match and If-Unmodified-Since conditional header
   fields are not applicable to a cache and hence such requests MUST
   be forwarded to the origin, and If-None-Match takes precedence
   over If-Modified-Since.  See Section 13.2.2 of [HTTP] for a complete
   specification of precondition precedence.

Notes
-----
Correction:
"the If-Match and If-Unmodified-Since conditional header fields are not applicable
 to a cache [and hence such requests MUST be forwarded to the origin]"

This is based upon the reading of RFC 9111#section-4.3.2-3[1]:
 
   A cache MUST NOT evaluate conditional header fields that only apply
   to an origin server, occur in a request with semantics that cannot be
   satisfied with a cached response, or occur in a request with a target
   resource for which it has no stored responses; such preconditions are
   likely intended for some other (inbound) server.


Current RFC 9110#section-13.1.1-13[2], RFC 9110#section-13.2.2[3] and RFC 
9111#section-4.3.2-4[4] does not explicitly provide clear direction to cache servers as to 
how to deal with If-Match and If-Unmodified-Since conditional headers[5].

The correction intends to provide more clarity for If-Match and If-Unmodified-Since
header as to how a cache server should handle conditional header which are meant
for origin server based on the reading of above produced section of 
the RFC 9111#section-4.3.2-3.

If cache nodes have to ignore If-Match and If-Unmodified-Since header as per 
RFC 9110#section-13.1.1-13 then in scenarios where they have a cached non-expired
content representation which can be satisfied sans If-Match and If-Unmodified-Since
headers the same will be returned back by cache and intermediary servers. 

Caching layers with multiple content representation cached in the network may 
return invalid response back causing higher requests errors when dealing with origin 
applicable conditional headers that are sent to intermediary cache nodes from 
edge cache nodes for cache hydration. 

Consider the below scenario:

1. A caching system consisting of 2 cache layers with 3 servers each,
Server nodes "A" representing Edge cache nodes(A1, A2, A3),
Server nodes "B" representing intermediary cache nodes(B1, B2, B3), and an 
origin server

2. All cache servers (A and B) make use of If-Match and If-Unmodified-Since to 
hydrate their own cached content representation as per RFC 9110#section-13.1.1-12 [6]

3. All cache servers make use of 5MiB chunk ranges for cache hydration of large 
files 

4. Origin server contains a file foo with size 20MiB, with content 
representation Etag E1 

5. A client C1 who sends a range request for file foo with range 10-20MiB to edge node A1

6. For initial set of requests sent by edge node A1 the representation E1 gets 
cached on 2 of the intermediary nodes B1 and B2 (because of 2 requests for 
5MiB chunk each) 

6. Content representation for file foo changes to Etag E2 on origin 

7. A client C2 who sends a range request for file foo with range 10-20MiB to edge node A2

8. Requests to edge node A2 which does not have a cached representation causes it 
to send 2 range requests for 5MiB each, in this case lets assume it is sent to 
intermediary cache nodes B1(range:10-15MiB) and B3(range:15-20MiB), 
B3 node faces cache-miss and hydrates its own cache from Range 15Mib-20MiB
with content representation E2. B1 node already has a cached representation E1
for requested range so it returns it back. A2 node which has now cached 10-15MiB E1
representation received from B1 has to returns error and performs a cache reset for
itself because of mixed representation for the whole user requested range.

In such a case where intermediary cache severs/nodes may end up with multiple 
content representation an edge node who is trying to hydrate its own cache 
will find it hard to do so, i.e. the first 5MiB 
chunk may end up being served by intermediary cache nodes with representation 
E1 and the other half of the chunk by nodes who have a content representation 
E2. The error rates will be higher whenever content representation changes at
the origin server for such range requests.


[1]: https://www.rfc-editor.org/rfc/rfc9111#section-4.3.2-3
[2]: https://www.rfc-editor.org/rfc/rfc9110#section-13.1.1-13
[3]: https://www.rfc-editor.org/rfc/rfc9110#section-13.2.2
[4]: https://www.rfc-editor.org/rfc/rfc9111#section-4.3.2-4
[5]: https://github.com/httpwg/http-core/issues/1111
[6]: https://www.rfc-editor.org/rfc/rfc9110#section-13.1.1-12

Instructions:
-------------
This erratum is currently posted as "Reported". (If it is spam, it 
will be removed shortly by the RFC Production Center.) Please
use "Reply All" to discuss whether it should be verified or
rejected. When a decision is reached, the verifying party  
will log in to change the status and edit the report, if necessary.

--------------------------------------
RFC9111 (draft-ietf-httpbis-cache-19)
--------------------------------------
Title               : HTTP Caching
Publication Date    : June 2022
Author(s)           : R. Fielding, Ed., M. Nottingham, Ed., J. Reschke, Ed.
Category            : INTERNET STANDARD
Source              : HTTP
Area                : Applications and Real-Time
Stream              : IETF
Verifying Party     : IESG