Re: [hybi] Serf support for BWTP

Ian Hickson <ian@hixie.ch> Tue, 02 February 2010 02:31 UTC

Return-Path: <ian@hixie.ch>
X-Original-To: hybi@core3.amsl.com
Delivered-To: hybi@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id 37A0D3A6991 for <hybi@core3.amsl.com>; Mon, 1 Feb 2010 18:31:26 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.413
X-Spam-Level:
X-Spam-Status: No, score=-2.413 tagged_above=-999 required=5 tests=[AWL=0.186, BAYES_00=-2.599]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id JyByjvyDD76A for <hybi@core3.amsl.com>; Mon, 1 Feb 2010 18:31:25 -0800 (PST)
Received: from looneymail-a4.g.dreamhost.com (caibbdcaaaaf.dreamhost.com [208.113.200.5]) by core3.amsl.com (Postfix) with ESMTP id 514933A6870 for <hybi@ietf.org>; Mon, 1 Feb 2010 18:31:25 -0800 (PST)
Received: from ps20323.dreamhostps.com (ps20323.dreamhost.com [69.163.222.251]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by looneymail-a4.g.dreamhost.com (Postfix) with ESMTP id C21A283CF; Mon, 1 Feb 2010 18:32:01 -0800 (PST)
Date: Tue, 02 Feb 2010 02:32:01 +0000
From: Ian Hickson <ian@hixie.ch>
To: Justin Erenkrantz <justin@erenkrantz.com>
In-Reply-To: <5c902b9e1001312123r1051a8dbpc8eb106c245c425a@mail.gmail.com>
Message-ID: <Pine.LNX.4.64.1002020229020.3846@ps20323.dreamhostps.com>
References: <5c902b9e0912180032o33d58da5hf3411baeb1fc5f7f@mail.gmail.com> <Pine.LNX.4.64.1001310829370.3846@ps20323.dreamhostps.com> <5c902b9e1001312123r1051a8dbpc8eb106c245c425a@mail.gmail.com>
Content-Language: en-GB-hixie
Content-Style-Type: text/css
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; charset="US-ASCII"
Cc: hybi@ietf.org
Subject: Re: [hybi] Serf support for BWTP
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hybi>
List-Post: <mailto:hybi@ietf.org>
List-Help: <mailto:hybi-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=subscribe>
X-List-Received-Date: Tue, 02 Feb 2010 02:31:26 -0000

On Sun, 31 Jan 2010, Justin Erenkrantz wrote:
> 
> There is simply no way that I could translate the current draft to an 
> implementation without introducing serious bugs, flaws, or 
> interoperability issues.

Seriously?

> As a concrete example, let's look at Section 5.3:
> 
> ---
> 5.3.  Data framing
> 
>    The server must run through the following steps to process the bytes
>    sent by the client:
> 
>    1.  _Frame_: Read a byte from the client.  Let /type/ be that byte.
> 
>    2.  If /type/ is not a 0x00 byte, then the server may disconnect from
>        the client.
> 
>    3.  If the most significant bit of /type/ is not set, then run the
>        following steps:
> 
>    ....
> --
> 
> If I read this, what is the rationale behind the if clause of step 3? 
> We're guaranteed that /type/ is 0x00 at this point because the server 
> has just been told it's okay to disconnect in step 2.

It may disconnect, but it doesn't have to (there's no "must", it's a "may" 
-- the spec uses RFC2119 terminology). So there's no guarantee that the 
type is 0x00 at step 3.


> But, if I step back and think, I think that it is step 2 that is bogus 
> because, in other parts of the draft, you mention other frame types.

Neither step is bogus.


> In fact, the data framing rules for the client are different than the 
> server.
>
> Oops.

Why "oops"? The requirements are different on both sides. It's an 
asymetric protocol, like most.


> The confusion that was attempted to be prevented by this radically 
> different editorial style is exactly what was created.

With all due respect, don't try to read between the lines, and it'll be 
easier. In specs that don't use this explicit style, you have to read 
between the lines precisely because the information isn't there. But 
that's exactly the problem that this style solves. You just code up what 
it says, and you'll be interoperable.

-- 
Ian Hickson               U+1047E                )\._.,--....,'``.    fL
http://ln.hixie.ch/       U+263A                /,   _.. \   _\  ;`._ ,.
Things that are impossible just take longer.   `._.-(,_..'--(,_..'`-.;.'