Re: [hybi] workability (or otherwise) of HTTP upgrade

Bjoern Hoehrmann <derhoermi@gmx.net> Thu, 09 December 2010 03:44 UTC

Return-Path: <derhoermi@gmx.net>
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 AF7723A6892 for <hybi@core3.amsl.com>; Wed, 8 Dec 2010 19:44:12 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -3.839
X-Spam-Level:
X-Spam-Status: No, score=-3.839 tagged_above=-999 required=5 tests=[AWL=-1.240, 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 Ar7yP1ub7Ejz for <hybi@core3.amsl.com>; Wed, 8 Dec 2010 19:44:11 -0800 (PST)
Received: from mail.gmx.net (mailout-de.gmx.net [213.165.64.22]) by core3.amsl.com (Postfix) with SMTP id 37A723A682B for <hybi@ietf.org>; Wed, 8 Dec 2010 19:44:10 -0800 (PST)
Received: (qmail invoked by alias); 09 Dec 2010 03:45:38 -0000
Received: from dslb-094-222-156-080.pools.arcor-ip.net (EHLO xn--bjrn-6qa.xn--hhrmann-90a.de) [94.222.156.80] by mail.gmx.net (mp058) with SMTP; 09 Dec 2010 04:45:38 +0100
X-Authenticated: #723575
X-Provags-ID: V01U2FsdGVkX1/9pTIpqU/90d3nxo4mclFlsOGU8UfheJaX5N7OnH 99vpsvdtvKG4ed
From: Bjoern Hoehrmann <derhoermi@gmx.net>
To: Mark Nottingham <mnot@mnot.net>
Date: Thu, 09 Dec 2010 04:45:29 +0100
Message-ID: <mgj0g6hseqb6j92au80f8d1ook058nb33m@hive.bjoern.hoehrmann.de>
References: <F4D1B715-3606-4E9A-BFB2-8B7BC11BE331@mnot.net> <57D4B885-B1D8-482F-8747-6460C0FFF166@apple.com> <37A00E8D-B55C-49AD-A85C-A299C80FFF17@mnot.net> <4F2580A7-79C2-4B0A-BCE5-7FB6D9AA0ED7@apple.com> <BB31C4AB95A70042A256109D461991260583956C@XCH117CNC.rim.net> <EA41A6C7-971C-4EC8-AA6F-96363B7FDC4C@gmail.com> <73E53F19-E0E7-4ADB-B765-ABAF0B4A6736@mnot.net> <r2f0g6d7bj770kg0db5ptr027ninmckns8@hive.bjoern.hoehrmann.de> <20C2FBB9-901F-4235-AF23-EC8262585905@mnot.net>
In-Reply-To: <20C2FBB9-901F-4235-AF23-EC8262585905@mnot.net>
X-Mailer: Forte Agent 3.3/32.846
MIME-Version: 1.0
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: 8bit
X-Y-GMX-Trusted: 0
Cc: hybi HTTP <hybi@ietf.org>, HTTP Working Group <ietf-http-wg@w3.org>
Subject: Re: [hybi] workability (or otherwise) of HTTP upgrade
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: Thu, 09 Dec 2010 03:44:12 -0000

* Mark Nottingham wrote:
>I still haven't seen anyone explain why CONNECT is better than, say, WEBSOCKET_PLEASE.

As I understand it, some people hope that the HTTP framing implied by
"CONNECT" (essentially, anything the client sends after the server does
send it's HTTP response is not interpreted as HTTP traffic) is very
widely implemented, while a WEBSOCKET-specific method might follow a
different code path in deployed implementations, whatever that might
entail (it's common for servers to close the connection if they see a
method they do not recognize, but who knows what the odd server does.)

>Also, from a quick read of the archive, it appears that encoding the
>stream (e.g., XOR, removing newlines, etc.) was shot down very quickly
>because people couldn't do sendfile().

I think there is a rough consensus to do some XOR obfuscation if that
is necessary or helpful, even though some would rather be able to do
the easy sendfile() call instead, but the benefits are not very clear
(if the attacker learns or can predict the XOR key, you've not gained
much, in some scenarios anyway.)

>That makes me wonder: what are the use cases for using sendfile() with
>WebSockets that can't be addressed by HTTP (more reliably, by everything
>I've seen here)?

(I think the question would be more aptly put as an issue of "you can
do this using simple commands to the hardware" versus "you have to
pump everything through the main processor"; while static files would
be a good example, you could also imagine, say, a camera that offers a
"WebM" stream you'd like to direct directly at the network equipment.)
-- 
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/