#434: mention in header field considerations that leading/trailing WS is lossy

Julian Reschke <julian.reschke@gmx.de> Tue, 19 February 2013 13:01 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 F16D321F8949 for <ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com>; Tue, 19 Feb 2013 05:01:54 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -8.726
X-Spam-Level:
X-Spam-Status: No, score=-8.726 tagged_above=-999 required=5 tests=[AWL=1.873, 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 oUqtMhxiM0dR for <ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com>; Tue, 19 Feb 2013 05:01:53 -0800 (PST)
Received: from frink.w3.org (frink.w3.org [128.30.52.56]) by ietfa.amsl.com (Postfix) with ESMTP id B2F9F21F8930 for <httpbisa-archive-bis2Juki@lists.ietf.org>; Tue, 19 Feb 2013 05:01:53 -0800 (PST)
Received: from lists by frink.w3.org with local (Exim 4.72) (envelope-from <ietf-http-wg-request@listhub.w3.org>) id 1U7mnj-0004Gl-BQ for ietf-http-wg-dist@listhub.w3.org; Tue, 19 Feb 2013 13:00:03 +0000
Resent-Date: Tue, 19 Feb 2013 13:00:03 +0000
Resent-Message-Id: <E1U7mnj-0004Gl-BQ@frink.w3.org>
Received: from lisa.w3.org ([128.30.52.41]) by frink.w3.org with esmtp (Exim 4.72) (envelope-from <julian.reschke@gmx.de>) id 1U7mnW-0003QT-J3 for ietf-http-wg@listhub.w3.org; Tue, 19 Feb 2013 12:59:50 +0000
Received: from mout.gmx.net ([212.227.17.20]) by lisa.w3.org with esmtp (Exim 4.72) (envelope-from <julian.reschke@gmx.de>) id 1U7mnQ-00010t-H8 for ietf-http-wg@w3.org; Tue, 19 Feb 2013 12:59:50 +0000
Received: from mailout-de.gmx.net ([10.1.76.4]) by mrigmx.server.lan (mrigmx002) with ESMTP (Nemesis) id 0Lse5X-1Urkb60lHF-012JGp for <ietf-http-wg@w3.org>; Tue, 19 Feb 2013 13:59:17 +0100
Received: (qmail invoked by alias); 19 Feb 2013 12:59:17 -0000
Received: from mail.greenbytes.de (EHLO [192.168.1.102]) [217.91.35.233] by mail.gmx.net (mp004) with SMTP; 19 Feb 2013 13:59:17 +0100
X-Authenticated: #1915285
X-Provags-ID: V01U2FsdGVkX1+n+VFgCJGnvQw9LqcT3jiYGQvya4XDBIzIMM1izK ++MPv283HDxVtZ
Message-ID: <51237724.3070005@gmx.de>
Date: Tue, 19 Feb 2013 13:59:16 +0100
From: Julian Reschke <julian.reschke@gmx.de>
User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:17.0) Gecko/20130107 Thunderbird/17.0.2
MIME-Version: 1.0
To: HTTP Working Group <ietf-http-wg@w3.org>
Content-Type: text/plain; charset="UTF-8"; format="flowed"
Content-Transfer-Encoding: 8bit
X-Y-GMX-Trusted: 0
Received-SPF: pass client-ip=212.227.17.20; envelope-from=julian.reschke@gmx.de; helo=mout.gmx.net
X-W3C-Hub-Spam-Status: No, score=-4.4
X-W3C-Hub-Spam-Report: AWL=-2.500, BAYES_00=-1.9, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_PASS=-0.001
X-W3C-Scan-Sig: lisa.w3.org 1U7mnQ-00010t-H8 9372d401be5bd1379a3e351e4c4722ab
X-Original-To: ietf-http-wg@w3.org
Subject: #434: mention in header field considerations that leading/trailing WS is lossy
Archived-At: <http://www.w3.org/mid/51237724.3070005@gmx.de>
Resent-From: ietf-http-wg@w3.org
X-Mailing-List: <ietf-http-wg@w3.org> archive/latest/16683
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>

...thus this needs to be considered when defining new header fields (-> 
quoted-string).

See <​ 
http://stackoverflow.com/questions/14910794/value-starting-with-a-space-in-httpurlconnection-add-request-property>

Proposed patch (see 
<http://trac.tools.ietf.org/wg/httpbis/trac/attachment/ticket/434/>): 
add the paragraph:

 >  Leading and trailing whitespace in field values is removed upon field
 >  parsing (Section 3.2.4 of [Part1]).  Field definitions where leading
 >  or trailing whitespace in values is significant will have to use a
 >  syntax such as in the quoted-string ABNF production.

Best regards, Julian