draft-ietf-httpbis-header-structure: handling multiple field values

Julian Reschke <julian.reschke@gmx.de> Tue, 12 May 2020 17:02 UTC

Return-Path: <ietf-http-wg-request+bounce-httpbisa-archive-bis2juki=lists.ie@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 DC5BF3A0791 for <ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com>; Tue, 12 May 2020 10:02:09 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.649
X-Spam-Level:
X-Spam-Status: No, score=-2.649 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, HEADER_FROM_DIFFERENT_DOMAINS=0.25, MAILING_LIST_MULTI=-1, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_PASS=-0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (1024-bit key) header.d=gmx.net
Received: from mail.ietf.org ([4.31.198.44]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id EmsQC7KwzNDy for <ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com>; Tue, 12 May 2020 10:02:08 -0700 (PDT)
Received: from lyra.w3.org (lyra.w3.org [128.30.52.18]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 0C3203A0781 for <httpbisa-archive-bis2Juki@lists.ietf.org>; Tue, 12 May 2020 10:02:07 -0700 (PDT)
Received: from lists by lyra.w3.org with local (Exim 4.92) (envelope-from <ietf-http-wg-request@listhub.w3.org>) id 1jYYFl-0001GG-OA for ietf-http-wg-dist@listhub.w3.org; Tue, 12 May 2020 16:59:38 +0000
Resent-Date: Tue, 12 May 2020 16:59:37 +0000
Resent-Message-Id: <E1jYYFl-0001GG-OA@lyra.w3.org>
Received: from mimas.w3.org ([128.30.52.79]) by lyra.w3.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from <julian.reschke@gmx.de>) id 1jYYFk-0001FV-8V for ietf-http-wg@listhub.w3.org; Tue, 12 May 2020 16:59:36 +0000
Received: from mout.gmx.net ([212.227.17.21]) by mimas.w3.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from <julian.reschke@gmx.de>) id 1jYYFh-0004pn-Td for ietf-http-wg@w3.org; Tue, 12 May 2020 16:59:36 +0000
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1589302761; bh=GHz32dyjEB9rlTlVECH2OnMoMCe3l08fU6axWtXt3z8=; h=X-UI-Sender-Class:To:From:Subject:Date; b=K1rwily6kZSg5f92hCojsMb1O/FJqISrHt8pC+68HopbBsKizjYrA8FDYqFHY2K2p 6s/x6RppM8YicHH17VdjZTZwGvdy2ARCHINJoGW0Vn1Qyn5MPxW8or2uAuKM47qStQ isVnDTLkNwSPddo3iH/3sxWqmn0v7mfvlAdA9phc=
X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c
Received: from [192.168.178.182] ([84.171.146.181]) by mail.gmx.com (mrgmx105 [212.227.17.168]) with ESMTPSA (Nemesis) id 1Msq6C-1jEYMq0Qky-00t9aR; Tue, 12 May 2020 18:53:44 +0200
To: HTTP Working Group <ietf-http-wg@w3.org>
From: Julian Reschke <julian.reschke@gmx.de>
Message-ID: <f55521dd-e1d3-d925-688c-c472ad67bfb4@gmx.de>
Date: Tue, 12 May 2020 18:53:40 +0200
User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:68.0) Gecko/20100101 Thunderbird/68.8.0
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Language: en-US
Content-Transfer-Encoding: quoted-printable
X-Provags-ID: V03:K1:Pqyd8e1lSqD7ufUNVYva0u0RYpxpuQt7Xs6VB64l2pVc6D7knv/ 7NoS5x9XzPhhnN7HG5hYeb0E8WVjxyvg0XgLnE1BqYGErbV7tX0ip3B8eHPVoUpeQla5cbB zTUrPd6U26/GKRSibx2nwqxgLkPFFhrgwI7tKQBmseSNFVpi8R3gSk7VUfamQbn9GFIFMNy JASN/tUxpe4BTTXptZf1w==
X-UI-Out-Filterresults: notjunk:1;V03:K0:hJkqdRu5pts=:L5kgGbWHwWKfAas/cqnOTp 4du6iTFbjLdzoNaOtlGMEXwS4kpq4w3HzfPosQemzXXuYUfdWzZvBG4EFX74QugWuL12ynS4K YTaOu5BTPVwfpiksrfy5usgAwhBtfYP21IuyBRj5soG8ENRpReaQ5++cBDtPKq1tme3CHvJWC o/z8kW6aTycwj/NT1GcyXX6jjFmRjUsfSSgGPnYxYcCEh3EJSkF29IPecuEsOVQdwqGovEKqp 3+O+/wNt5hRAUfFN1hpUeU26j1mkv1Qd2Kqrwe2OImwPVr0dNuLw+uoFRnAFKZOc3e/9JF7Ad klLE2+HvGSJM078LorqPtfb3sbTE6nHx2lVmU8NdLRc0S2U5Jo9dSYp05WeCiVdk822RCSais v75MSZJ73q/EMh4Qhigu21SBafDdpCMEj9EaRVr9EEus7N0DY05uvN4NQ8Gm7TesqWsAcYQMd /WkGSGfWFRrkmSLLa7+nr5OaGIvtflwEGFOFX+pMLlNhM69pgQ91lqmqM7sxuSkAG3Ak8kS61 0qtdpfqXcgc5/pdV/4lWuyKFbAjVF6c+fHObadnNkBS4lrCbO/Y/ixs3yka/CuAPin5L8+cXO OZKtUt4Z7QSw+mbYHSdUKSU8keDINTMgSQ8oNCEGnBQxvIgm5JMFHrJqb+oG5MEPbtjyfRQu4 6EpXUUEeYzanmr2Wq/eXj9OB1H+aIWjInUc15jPPgPpUViDjO9W0XCEpeM6Z4qu4MQVcslFG+ kCaqF9ojhHa19fwhcNUyWouKxjFNMkhXCUWpYJa57qDmOm8+FyvdOTWwRGF3RgfnxFunL5Clb vsNTEVHKglup8OZvg9mEPQgyMpClWLsTfzvnbCpzJOpXm3Bxx0vDEjZ1E9da/yXa23JXwEAvN O2dKrbs+e+9gB5+KRUTol+6FWaznQvnN5Ws8JMQ8GDhQCA4W2Q0jpytGDEcnz5ZoGFKRUswX7 dhjEyF2eSEjUu8J+A0vIM80Ovxk90su5ZnbpzNEI0y+5M9PSn8JWtsu/+kNBEgd9dlPeqPaSH nmHa6T8PxMbIQWkyF9ZUxfhXEimJZWS7zgi0RWMPMb4IcD9PPa7Azm6aKpZx/djlWNfiuJ/YQ A3gHh64GoWeW9fvfef/95qqx3SdbQhYLLz86xPcqtUgFAk+fgxf+WLsW+D4W9yXuP1TTh2QKK 9JadMim1wFhNKJTcaRMS9GsQznZWSFDhyOlHbg3rnERFnp8/Q2qaTvTXuWUh4qDbiJGNc6SLa bXRkZijz8/p7vQTqe
Received-SPF: pass client-ip=212.227.17.21; envelope-from=julian.reschke@gmx.de; helo=mout.gmx.net
X-W3C-Hub-Spam-Status: No, score=-5.6
X-W3C-Hub-Spam-Report: BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, W3C_AA=-1, W3C_IRA=-1, W3C_WL=-1
X-W3C-Scan-Sig: mimas.w3.org 1jYYFh-0004pn-Td 635bf33177dbdfe1ab7dcf46cbedd028
X-Original-To: ietf-http-wg@w3.org
Subject: draft-ietf-httpbis-header-structure: handling multiple field values
Archived-At: <https://www.w3.org/mid/f55521dd-e1d3-d925-688c-c472ad67bfb4@gmx.de>
Resent-From: ietf-http-wg@w3.org
X-Mailing-List: <ietf-http-wg@w3.org> archive/latest/37599
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/Mail/>
List-Post: <mailto:ietf-http-wg@w3.org>
List-Unsubscribe: <mailto:ietf-http-wg-request@w3.org?subject=unsubscribe>

Hi there,

while working on an implementation I encountered the following question.

Consider something defined as "sh-list". If a value is received spread
over multiple field instances, recipients *can* recombine the value
before processing. So for

   Foo: "1
   Foo: 2"

...the parser would see the string "1,2" (or maybe "1, 2").

What's not totally clear to me is whether recipients are *allowed* to
process the field values separately, in which case parsing would fail.

If this is allowed, I would expect tests in
<https://github.com/httpwg/structured-header-tests> where "can_fail" is
set to true, but I couldn't find any.

FWIW; one reason for processing them separately would be to catch syntax
errors; another one performance, as it would avoid concatenating things
that can be parsed separately.

Best regards, Julian