W3C home > Mailing lists > Public > ietf-http-wg@w3.org > April to June 2013

Re: p1: BWS

From: Mark Nottingham <mnot@mnot.net>
Date: Tue, 23 Apr 2013 17:32:01 +1000
Cc: Roberto Peon <grmocg@gmail.com>, Willy Tarreau <w@1wt.eu>, Amos Jeffries <squid3@treenet.co.nz>, HTTP Working Group <ietf-http-wg@w3.org>
Message-Id: <EA013249-27A2-40EE-AA5E-A0126E71D47D@mnot.net>
To: Julian Reschke <julian.reschke@gmx.de>
OK, marking both of the below for incorporation in -23.

On 19/04/2013, at 9:47 PM, Julian Reschke <julian.reschke@gmx.de> wrote:

> On 2013-04-19 13:39, Mark Nottingham wrote:
>> 
>> On 19/04/2013, at 7:34 PM, Julian Reschke <julian.reschke@gmx.de> wrote:
>> 
>>> On 2013-04-19 00:27, Mark Nottingham wrote:
>>>> We can either:
>>>> 
>>>> - make it a MUST
>>>> - document what the exceptional circumstances are that cause the SHOULD (but I don't think it's that kind of SHOULD)
>>>> - downgrade it to an "ought to"
>>>> 
>>>> I do note that we say "generate" there (which I missed before, sorry); in our terminology, that means you DON'T need to fix it up when forwarding it; it's only when you're actually creating the element that this applies.
>>>> 
>>>> So, I'd suggest we make it a MUST, and change the language slightly to clarify:
>>>> 
>>>> "...but it MUST NOT be generated in messages..."
>>> 
>>> I have no problem with *that* change.
>>> 
>>> What concerns we much more is the "MUST accept such bad optional whitespace and remove it before interpreting the field value or forwarding the message downstream" -- that part is fine for parsing the message itself (everybody needs to be able to do that), but *not* ok for individual field values. We need a distinction here.
>> 
>> Ah, yes, that was the part that sparked my original concern.
>> 
>> The text in the latest draft is:
>> 
>> """
>> BWS is used where the grammar allows optional whitespace, for historical reasons, but senders SHOULD NOT generate it in messages; recipients MUST accept such bad optional whitespace and remove it before interpreting the field value or forwarding the message downstream.
>> """
>> 
>> I'd suggest:
>> 
>> """
>> BWS is used where the grammar allows optional whitespace, for historical reasons, but it MUST NOT be generated in messages; recipients MUST accept such bad optional whitespace and remove it before interpreting the field value.
>> """
>> 
>> 
>>>> Also, in p2, I'd note that we do NOT allow BWS inside of media type parameters:
>>>>   https://svn.tools.ietf.org/svn/wg/httpbis/draft-ietf-httpbis/latest/p2-semantics.html#media.type
>>>> 
>>>> AIUI (thanks, Julian), this is because many implementations don't accept whitespace there at all. It might be worth noting in the text that this parameter construct is different in that aspect.
>>> 
>>> I don't know whether it's because of implementations following the spec, or the spec following implementations.
>>> 
>>> Somewhat outdated tests are over here: <http://greenbytes.de/tech/tc/httpcontenttype/>
>>> 
>>> I'm more than happy to require recipients to handle BWS here for consistency with other header fields, as long as we tell generators to never ever use it.
>> 
>> That would make current implementations non-conformant, where we already have interop. While consistency is good, that may be going too far for it.
>> 
>> I was thinking of something along the lines of
>> 
>> """
>> Note that unlike some similar constructs in other headers, media type parameters do not allow whitespace (even "bad" whitespace) around the "=" character.
>> """
>> 
>> Would that work for you?
>> ...
> 
> 
> +1 on both.
> 
> Best regards, Julian
> 
> 

--
Mark Nottingham   http://www.mnot.net/
Received on Tuesday, 23 April 2013 07:32:29 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 1 March 2016 11:11:12 UTC