Re: [hybi] Review of draft-ietf-hybi-thewebsocketprotocol-13

"Richard L. Barnes" <rbarnes@bbn.com> Tue, 06 September 2011 16:53 UTC

Return-Path: <rbarnes@bbn.com>
X-Original-To: hybi@ietfa.amsl.com
Delivered-To: hybi@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 6DD0F21F8C30; Tue, 6 Sep 2011 09:53:24 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -106.553
X-Spam-Level:
X-Spam-Status: No, score=-106.553 tagged_above=-999 required=5 tests=[AWL=0.046, BAYES_00=-2.599, RCVD_IN_DNSWL_MED=-4, USER_IN_WHITELIST=-100]
Received: from mail.ietf.org ([12.22.58.30]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id tDsIRwb1H3cM; Tue, 6 Sep 2011 09:53:23 -0700 (PDT)
Received: from smtp.bbn.com (smtp.bbn.com [128.33.1.81]) by ietfa.amsl.com (Postfix) with ESMTP id ABC1E21F8B2B; Tue, 6 Sep 2011 09:53:23 -0700 (PDT)
Received: from ros-dhcp192-1-51-76.bbn.com ([192.1.51.76]:61397) by smtp.bbn.com with esmtps (TLSv1:AES128-SHA:128) (Exim 4.74 (FreeBSD)) (envelope-from <rbarnes@bbn.com>) id 1R0yvV-000Kp8-6d; Tue, 06 Sep 2011 12:55:10 -0400
Mime-Version: 1.0 (Apple Message framework v1084)
Content-Type: text/plain; charset="iso-8859-1"
From: "Richard L. Barnes" <rbarnes@bbn.com>
In-Reply-To: <c8ic67por9b7638k4cuoqr4blvneo2hlh3@hive.bjoern.hoehrmann.de>
Date: Tue, 06 Sep 2011 12:55:08 -0400
Content-Transfer-Encoding: quoted-printable
Message-Id: <8BF29F54-2E7D-489E-9A2F-322BE69DE5BA@bbn.com>
References: <942CCA6B-B784-441B-96CA-3506FFC439E1@bbn.com> <CALiegfmyQ5h4S2FgBnrh2VLr8+q-h0sLiGsww7T+1VwYNRo4wQ@mail.gmail.com> <72E40A0F-C923-472F-9534-538B89F7A444@bbn.com> <634914A010D0B943A035D226786325D422C0EB8D18@EXVMBX020-12.exch020.serverdata.net> <365A444D-CF7D-41A0-A446-7306DE4CDBBC@bbn.com> <c8ic67por9b7638k4cuoqr4blvneo2hlh3@hive.bjoern.hoehrmann.de>
To: Bjoern Hoehrmann <derhoermi@gmx.net>
X-Mailer: Apple Mail (2.1084)
Cc: General Area Review Team <gen-art@ietf.org>, "hybi@ietf.org" <hybi@ietf.org>
Subject: Re: [hybi] Review of draft-ietf-hybi-thewebsocketprotocol-13
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.12
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/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, 06 Sep 2011 16:53:24 -0000

Well, ok.  No state related to UTF-8.  Any intermediary that deals with fragmentation will have to remember the opcode/extensions.

--Richard


On Sep 6, 2011, at 12:38 PM, Bjoern Hoehrmann wrote:

> * Richard L. Barnes wrote:
>> If frames are valid utf-8, then you don't need to keep any state (on
>> either end of the connection).
> 
> That's somewhat misleading. If you accept for instance both binary and
> text frames, you have to maintain the type of the first frame so you can
> reject continuation frames of the wrong type. You may also have to main-
> tain state coming from extension data or your protocol may require other
> state to be maintained. A minimal byte-oriented UTF-8 validator has nine
> states http://bjoern.hoehrmann.de/utf-8/decoder/dfa/ and that seems less
> onerous to maintain than having fragmenting senders and forwarders to
> find where character and byte boundaries coincide (you need to have the
> encoded text available and re-sychronize to character boundaries, or
> have the character stream available with analyze the encoded widths, or
> you have to include padding within the text, to start sending).
> -- 
> Björn Höhrmann · mailto:bjoern@hoehrmann.de · http://bjoern.hoehrmann.de
> Am Badedeich 7 · Telefon: +49(0)160/4415681 · http://www.bjoernsworld.de
> 25899 Dagebüll · PGP Pub. KeyID: 0xA4357E78 · http://www.websitedev.de/