Re: Robert Wilton's No Objection on draft-ietf-httpbis-header-structure-18: (with COMMENT)

Mark Nottingham <mnot@mnot.net> Thu, 21 May 2020 02:37 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 2365D3A09C3 for <ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com>; Wed, 20 May 2020 19:37:56 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.749
X-Spam-Level:
X-Spam-Status: No, score=-2.749 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HEADER_FROM_DIFFERENT_DOMAINS=0.249, MAILING_LIST_MULTI=-1, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=unavailable autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=mnot.net header.b=YnOcztdW; dkim=pass (2048-bit key) header.d=messagingengine.com header.b=F7mXqjZq
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 XSwLgCY1s6G0 for <ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com>; Wed, 20 May 2020 19:37:54 -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 52FBE3A09C1 for <httpbisa-archive-bis2Juki@lists.ietf.org>; Wed, 20 May 2020 19:37:53 -0700 (PDT)
Received: from lists by lyra.w3.org with local (Exim 4.92) (envelope-from <ietf-http-wg-request@listhub.w3.org>) id 1jbb2q-0004BM-PE for ietf-http-wg-dist@listhub.w3.org; Thu, 21 May 2020 02:34:52 +0000
Resent-Date: Thu, 21 May 2020 02:34:52 +0000
Resent-Message-Id: <E1jbb2q-0004BM-PE@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 <mnot@mnot.net>) id 1jbb2p-0004AV-Mz for ietf-http-wg@listhub.w3.org; Thu, 21 May 2020 02:34:51 +0000
Received: from wout2-smtp.messagingengine.com ([64.147.123.25]) by mimas.w3.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from <mnot@mnot.net>) id 1jbb2m-0006Rz-L8 for ietf-http-wg@w3.org; Thu, 21 May 2020 02:34:51 +0000
Received: from compute4.internal (compute4.nyi.internal [10.202.2.44]) by mailout.west.internal (Postfix) with ESMTP id 3EC881A9D; Wed, 20 May 2020 22:34:33 -0400 (EDT)
Received: from mailfrontend2 ([10.202.2.163]) by compute4.internal (MEProxy); Wed, 20 May 2020 22:34:33 -0400
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mnot.net; h= content-type:mime-version:subject:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; s=fm2; bh=l ABB0Nhcbp6qyC1HhsXFkcP/aGWRBcXLijkrlbsxCXI=; b=YnOcztdW92vb+Q/mW 4RJqrg0CpsliOUePLhtukK5Qp0iDrTeyCJ7OjWXnammgfZUYPas7b/KaHeaRTCIG lngbrekcF6U0uGx54yrfi5hy13oqSASQPNkHI5r23s1HFd4efFxVDQrgG6fES7u/ 5Xkv1fe1VttiGY42CYzghDL6npP6MczsHgiq9vN1gxeulP0o/WYtK9C3pfsmtx4W u8tSIE9/GeXRerrUEzN8EU9ElazDb/4Nc1a7bY0u/nxPapbdF/6BJ3JqPJevE2I4 rfIp9cFWd08zJ0Xw+Nnx+qTnviFp7CxGrXoTeP4ZkPJFnEMoSnSDk+DgNnXrjq0o Scgkw==
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm2; bh=lABB0Nhcbp6qyC1HhsXFkcP/aGWRBcXLijkrlbsxC XI=; b=F7mXqjZqUd4ke1+bO4Jvu/nbQjO9V8Ckr677nxGdxIVhRWIHtjq3A55gs LOKSufZ3W4ypl6pTqAR5DhQwZprVZy0INkjBoHMdqAkFy3zBXOH3ngZrr5sOtz0g PxcJJeK++JatSatvt0uRutnvauDLmFJxQt/HZV19uza0qyAC8rAPdBFN4AIHWVhz nmbVaBCP17rAUXYbR36FqmMcXSVnFEHgABaSlBwBmds/h+2ep8Rzi3Y+JU7ZVNb0 JsyO7pQIQ4x/MR+qosGNRR0D+Xpa7OBksnPBN4pshf5+5lRAITvfmIyjZQ0xcesS +k6UnYcBaLmGyk0U4u4NlLjfT8Byg==
X-ME-Sender: <xms:t-jFXkYtV6qUI5futVAQHKlyZRmSFHSHid91uyVv_IYz4FXM4YBhsw>
X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduhedruddutddgheekucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurheptggguffhjgffgffkfhfvofesthhqmhdthhdtvdenucfhrhhomhepofgrrhhk ucfpohhtthhinhhghhgrmhcuoehmnhhothesmhhnohhtrdhnvghtqeenucggtffrrghtth gvrhhnpedvgfevudetieeuieefteeulefglefhteehlefhjefgkeefleehhfffheektdff tdenucffohhmrghinhepghhithhhuhgsrdgtohhmpdhhthhtphhfihgvlhgushhinhhthh hoshgvthgvrhhmshhmohhrvggtohhmfhhorhhtrggslhgvrdgrshdpmhhnohhtrdhnvght necukfhppeduudelrddujedrudehkedrvdehudenucevlhhushhtvghrufhiiigvpedtne curfgrrhgrmhepmhgrihhlfhhrohhmpehmnhhothesmhhnohhtrdhnvght
X-ME-Proxy: <xmx:t-jFXvZGSZK2J_i0jBGnHxgAaRQQfnWc6inci9MgDidsilXlqkTAEw> <xmx:t-jFXu-SHNWvj9sbZIC4fomXZn7Ykg6UjOPI7jY9JkIsBuMq6Drjfw> <xmx:t-jFXuq1ZGTyWOkLCe4Q0EeoU7QqRCdsC3NWaZ1d4PAY1B0BWo6b7Q> <xmx:uOjFXgBj3P-a7MaQPHpLGNzpOiNbRbvfGlZbcZYwfiRQwhkHro9UYA>
Received: from macbook-air.mnot.net (119-17-158-251.77119e.mel.static.aussiebb.net [119.17.158.251]) by mail.messagingengine.com (Postfix) with ESMTPA id B73333066461; Wed, 20 May 2020 22:34:29 -0400 (EDT)
Content-Type: text/plain; charset="us-ascii"
Mime-Version: 1.0 (Mac OS X Mail 13.4 \(3608.80.23.2.2\))
From: Mark Nottingham <mnot@mnot.net>
In-Reply-To: <158998416528.29748.5730867215913093544@ietfa.amsl.com>
Date: Thu, 21 May 2020 12:34:26 +1000
Cc: The IESG <iesg@ietf.org>, draft-ietf-httpbis-header-structure@ietf.org, httpbis-chairs@ietf.org, ietf-http-wg@w3.org, Tommy Pauly <tpauly@apple.com>
Content-Transfer-Encoding: quoted-printable
Message-Id: <4C766CCA-1F19-4088-9138-A9387580C4F2@mnot.net>
References: <158998416528.29748.5730867215913093544@ietfa.amsl.com>
To: Robert Wilton <rwilton@cisco.com>
X-Mailer: Apple Mail (2.3608.80.23.2.2)
Received-SPF: pass client-ip=64.147.123.25; envelope-from=mnot@mnot.net; helo=wout2-smtp.messagingengine.com
X-W3C-Hub-Spam-Status: No, score=-9.8
X-W3C-Hub-Spam-Report: BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001, W3C_AA=-1, W3C_DB=-1, W3C_IRA=-1, W3C_IRR=-3, W3C_WL=-1
X-W3C-Scan-Sig: mimas.w3.org 1jbb2m-0006Rz-L8 f2e6afd8fbd3a914395c8b0c735ce27c
X-Original-To: ietf-http-wg@w3.org
Subject: Re: Robert Wilton's No Objection on draft-ietf-httpbis-header-structure-18: (with COMMENT)
Archived-At: <https://www.w3.org/mid/4C766CCA-1F19-4088-9138-A9387580C4F2@mnot.net>
Resent-From: ietf-http-wg@w3.org
X-Mailing-List: <ietf-http-wg@w3.org> archive/latest/37689
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 Rob,

Thanks for the feedback. The commit mentioned below is <https://github.com/httpwg/http-extensions/commit/5eb50dafa>.

> On 21 May 2020, at 12:16 am, Robert Wilton via Datatracker <noreply@ietf.org> wrote:
> 
> However, my main comment (which possibly could have been a discuss) questions
> how this is specified.  In my experience other specifications of encodings
> define exactly what the format the encoding must take, but leave it up to
> implementation to decide how to perform that encoding.  Whereas this document
> specifies the format in 3 ways: (i) as a prose description of the format, (ii)
> as an ABNF description of the format, (iii) as a pair of algorithms that
> construct or parse the format.  I would prefer for the ANBF to be definitive
> along with prose to describe/refine the ANBF as required.  For the algorithms,
> I would have preferred that they are held in the appendix as non-normative text
> that provides a description of one possible method of writing the serialization
> or parsing code.  The corner cases that the algorithm cover could be in the
> normative prose/ABNF description.  I appreciate that this would be a
> significant change to the document and hence will leave it to
> authors/responsible AD to decide whether to process or ignore this comment.

There's a fair bit of history here. HTTP headers have typically been defined using ABNF as you suggest. That has led to a number of interoperability (and often security) problems, because the vast majority people don't write ABNF-based parsers or serialisers; they manually interpret the ABNF, prose and examples and write a bespoke parser and serialiser. These issues are exacerbated by the relatively diffuse pool of new field authors (people mint HTTP headers outside the IETF on a regular basis, for a large variety of reasons), and by the even more diffuse pool of people who actually send headers (people writing .htaccess files in Apache, people writing PHP and CGI scripts, people sending a header in XmlHttpRequest or Fetch, etc.). 

All of this led us to try a different approach - specifying parsing and serialisation via pseudo-code. This is the way that the WHATWG writes their specifications (including HTML and Fetch), and it's arguably improved interoperability for Web developers -- which is also our audience -- considerably.

The ABNF is included mostly to make folks who are used to thinking of HTTP fields in those terms more comfortable. As we've seen during the IESG evaluation, that's led to some confusion, so the most recent changes have attempted to make the status of the ABNF more clear.

> A few other comments on particular sections that I noted:
> 
> 1.2.  Notational Conventions
> 
>   When parsing from HTTP fields, implementations MUST follow the
>   algorithms, but MAY vary in implementation so as the behaviors are
>   indistinguishable from specified behavior.
> 
> I find that sentence slightly strange in that the first part of the sentence
> states that your MUST follow the algorithm, and the second part states that you
> don't have to follow the algorithm.  It might be more clear if this was worded
> differently.  E.g. MUST have behavior that is indistinguishable from that
> produced by the algorithm.

Thank you, that's good wording. See the commit.

> 3.1  Lists:
> 
>   An empty List is denoted by not serializing the field at all.
> 
> This was slightly unclear to me.  Does this mean that it isn't possible to
> distinguish between not providing the header and providing an empty list? 
> Possibly it might be worth clarifying this here, although I note that it does
> become clear what the expected behavior is later in the document.

This has been clarified as a result of other comments.

> 3.2.  Dictionaries
> 
>   Dictionaries are ordered maps of name-value pairs, where the names
>   are short, textual strings
> 
> "short, textual" => short textual"
> 
> It might also be helpful to explicitly state what the ordering is (i.e. I
> presume that it is the order that they are listed in the request)

In the commit.

> 3.3.1 Integers
> Are "00" "01" "-0", "-01" all allowed?

They're all allowed in the serialisation, but aren't necessarily distinct in the data model. Do you (and others) think it's worth mentioning here?

> 3.3.6.  Booleans
> Should this cover the fact that if the boolean value is not present it is
> interpreted as true in a parameter or dictionary?  E.g. as per the description
> in the parameter and dictionaries sections?

That's a good clarification; in the commit.


Cheers,

--
Mark Nottingham   https://www.mnot.net/