Re: HTTP/2 Header Encoding Status Update

James M Snell <jasnell@gmail.com> Wed, 27 February 2013 23:02 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 7D89C21F8860 for <ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com>; Wed, 27 Feb 2013 15:02:11 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -10.507
X-Spam-Level:
X-Spam-Status: No, score=-10.507 tagged_above=-999 required=5 tests=[AWL=0.092, BAYES_00=-2.599, RCVD_IN_DNSWL_HI=-8]
Received: from mail.ietf.org ([64.170.98.30]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id Ge0vLI11vtpQ for <ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com>; Wed, 27 Feb 2013 15:02:11 -0800 (PST)
Received: from frink.w3.org (frink.w3.org [128.30.52.56]) by ietfa.amsl.com (Postfix) with ESMTP id F22FA21F877B for <httpbisa-archive-bis2Juki@lists.ietf.org>; Wed, 27 Feb 2013 15:02:10 -0800 (PST)
Received: from lists by frink.w3.org with local (Exim 4.72) (envelope-from <ietf-http-wg-request@listhub.w3.org>) id 1UApzq-0002pa-Sc for ietf-http-wg-dist@listhub.w3.org; Wed, 27 Feb 2013 23:01:10 +0000
Resent-Date: Wed, 27 Feb 2013 23:01:10 +0000
Resent-Message-Id: <E1UApzq-0002pa-Sc@frink.w3.org>
Received: from lisa.w3.org ([128.30.52.41]) by frink.w3.org with esmtp (Exim 4.72) (envelope-from <jasnell@gmail.com>) id 1UApze-0002mn-I2 for ietf-http-wg@listhub.w3.org; Wed, 27 Feb 2013 23:00:58 +0000
Received: from mail-oa0-f52.google.com ([209.85.219.52]) by lisa.w3.org with esmtps (TLS1.0:RSA_ARCFOUR_SHA1:16) (Exim 4.72) (envelope-from <jasnell@gmail.com>) id 1UApza-0003CS-Bv for ietf-http-wg@w3.org; Wed, 27 Feb 2013 23:00:58 +0000
Received: by mail-oa0-f52.google.com with SMTP id k14so2376713oag.39 for <ietf-http-wg@w3.org>; Wed, 27 Feb 2013 15:00:28 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:mime-version:in-reply-to:references:from:date:message-id :subject:to:cc:content-type:content-transfer-encoding; bh=q3iuoDzZruJaLVs//TPcSmGdUps5NJZq0ZFxQKt5e4A=; b=bXOOCIgRPg03zGF1c00KLuuQo5DKXGJCePCOwldnYd4HFsL8/HmMrKl6647U0QiIIW DuJJpHYQG3XXr8qByGNRGqhHLJPxHv6fosJKO/cGshJUZT29VMRasxbEDgKGBOez1swk AoxUuAvi0h8XKqZ4C5xoqMLVLoyvUDY4jbgH08EkueUYh9HtWdl7jG4QQp5LAclMArUW vP0L0xiXtwsL/aqZEwM6wCk6PvL76wjCp/wUNhu0vfDMlJaYRoQI1OoBMYGTsbzarkf2 yNEEAyeAIWrSarN0fnk9IGAE4Xy4HnCR1VsKinG5AMX0fUASmGF45JdehsT+9qUhsEsS 8zYg==
X-Received: by 10.60.14.71 with SMTP id n7mr3944423oec.135.1362006028255; Wed, 27 Feb 2013 15:00:28 -0800 (PST)
MIME-Version: 1.0
Received: by 10.60.23.193 with HTTP; Wed, 27 Feb 2013 15:00:08 -0800 (PST)
In-Reply-To: <0DE7FB38-9484-4FED-84C7-A034AFBFA8E6@mnot.net>
References: <CABP7RbfK9jT=-wXqv8wo6fJr8Wg0g9SYTZ3FeXHC=4yhihdsug@mail.gmail.com> <0DE7FB38-9484-4FED-84C7-A034AFBFA8E6@mnot.net>
From: James M Snell <jasnell@gmail.com>
Date: Wed, 27 Feb 2013 15:00:08 -0800
Message-ID: <CABP7RbfaSLUCw+sns8Av2i2EDOioRxSx0RxuaSozKNJtO9YeBQ@mail.gmail.com>
To: Mark Nottingham <mnot@mnot.net>
Cc: "ietf-http-wg@w3.org" <ietf-http-wg@w3.org>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
Received-SPF: pass client-ip=209.85.219.52; envelope-from=jasnell@gmail.com; helo=mail-oa0-f52.google.com
X-W3C-Hub-Spam-Status: No, score=-3.5
X-W3C-Hub-Spam-Report: AWL=-2.659, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_LOW=-0.7, SPF_PASS=-0.001
X-W3C-Scan-Sig: lisa.w3.org 1UApza-0003CS-Bv 5db6b6ec119348566584cbd1ee65e124
X-Original-To: ietf-http-wg@w3.org
Subject: Re: HTTP/2 Header Encoding Status Update
Archived-At: <http://www.w3.org/mid/CABP7RbfaSLUCw+sns8Av2i2EDOioRxSx0RxuaSozKNJtO9YeBQ@mail.gmail.com>
Resent-From: ietf-http-wg@w3.org
X-Mailing-List: <ietf-http-wg@w3.org> archive/latest/16913
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>

On Wed, Feb 27, 2013 at 2:45 PM, Mark Nottingham <mnot@mnot.net> wrote:
> Hi James,
>
>[snip]
> So, the biggest concern here, I think, is that the conversion of a UTF-8 value to ASCII/Latin-1 -- to be able to forward the header on a HTTP/1.x hop -- requires knowledge of the header.
>
> Would you want to define a standard way to encode UTF-8 in Latin-1 (e.g., percent-encoding) for headers that use this? It would constrain the headers (and likely rule out any existing headers from using UTF-8), but I don't see how this is going to be viable otherwise.
>

Yes, I think that is reasonable. One key thing is that existing
headers would need to be explicitly redefined to take advantage of the
new encoding options so it would be technically invalid to take any of
the existing headers and encode them as UTF-8 unless their definition
has been changed in spec. That said, a standard mapping like you
suggest would be good in the cases we do have to drop down from http/2
to /1. Percent-encoding seems to be perfectly reasonable.

>[snip]
>>
>>  For example, the byte sequence 01 02 03 is encoded as:
>>    20 03 01 02 03
>
> Similar problem as with UTF-8, unless you define a single transformation between binary and ASCII (base64?).
>

Yes, I had imagined that the transform here would be base64.

- James