Re: [hybi] Redesigning the Web Socket handshake
Maciej Stachowiak <mjs@apple.com> Tue, 02 February 2010 03:50 UTC
Return-Path: <mjs@apple.com>
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 A1EA43A68C1 for <hybi@core3.amsl.com>; Mon, 1 Feb 2010 19:50:00 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -106.599
X-Spam-Level:
X-Spam-Status: No, score=-106.599 tagged_above=-999 required=5 tests=[AWL=0.000, BAYES_00=-2.599, RCVD_IN_DNSWL_MED=-4, USER_IN_WHITELIST=-100]
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 GkKVmQdNGa1k for <hybi@core3.amsl.com>; Mon, 1 Feb 2010 19:49:59 -0800 (PST)
Received: from mail-out4.apple.com (mail-out4.apple.com [17.254.13.23]) by core3.amsl.com (Postfix) with ESMTP id C5AB83A6882 for <hybi@ietf.org>; Mon, 1 Feb 2010 19:49:59 -0800 (PST)
Received: from relay13.apple.com (relay13.apple.com [17.128.113.29]) by mail-out4.apple.com (Postfix) with ESMTP id AB4B489B7031 for <hybi@ietf.org>; Mon, 1 Feb 2010 19:50:36 -0800 (PST)
X-AuditID: 1180711d-b7b18ae000001001-e6-4b67a10c63d6
Received: from et.apple.com (et.apple.com [17.151.62.12]) by relay13.apple.com (Apple SCV relay) with SMTP id 5C.AB.04097.C01A76B4; Mon, 1 Feb 2010 19:50:36 -0800 (PST)
MIME-version: 1.0
Content-transfer-encoding: 7bit
Content-type: text/plain; charset="us-ascii"
Received: from [17.246.17.218] by et.apple.com (Sun Java(tm) System Messaging Server 6.3-7.04 (built Sep 26 2008; 32bit)) with ESMTPSA id <0KX700CSR40C8540@et.apple.com> for hybi@ietf.org; Mon, 01 Feb 2010 19:50:36 -0800 (PST)
From: Maciej Stachowiak <mjs@apple.com>
In-reply-to: <4B679E2C.2080502@webtide.com>
Date: Mon, 01 Feb 2010 19:50:35 -0800
Message-id: <FD440FEA-9F53-4F4C-8AA5-98B23318F0F7@apple.com>
References: <Pine.LNX.4.64.1002012305000.21600@ps20323.dreamhostps.com> <4B676E8C.70804@webtide.com> <Pine.LNX.4.64.1002020311030.3846@ps20323.dreamhostps.com> <4B679E2C.2080502@webtide.com>
To: Greg Wilkins <gregw@webtide.com>
X-Mailer: Apple Mail (2.1077)
X-Brightmail-Tracker: AAAAAQAAAZE=
Cc: hybi@ietf.org
Subject: Re: [hybi] Redesigning the Web Socket handshake
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 03:50:00 -0000
On Feb 1, 2010, at 7:38 PM, Greg Wilkins wrote: > Ian, > > you are not listening to the server side developers. It looks to me like Ian just made a bunch of changes to the draft in response to comments from server side developers. On top of the fact that the WebSocket protocol was essentially designed by server-side developers. Could we please stick to substantive points instead of debating who is listening to whom? > > Apache is telling you that they can't share port 80 Did anyone really say that? Isn't mod_pywebsocket a proof that it is in fact possible: <http://code.google.com/p/pywebsocket/>? > with websocket and you're giving them nothing back! > > For many of us, we are already "near the HTTP spec" and > it's full rules and we've already dealt with the complications. > It is your attempt to simplify HTTP that is causing the > complications. > > We've already parsed the HTTP request by the time that > we know it is a websocket upgrade. We're deep inside > our containers... potentially not even on the same > machine that terminated the HTTP request. As far as I can tell, the WebSocket spec does not require special hardcoded handling of the request handshake. It's totally allowed to run it through a normal HTTP stack. In fact, it's totally allowed for servers to do no checking of the client request handshake at all, but that creates a security hole (possibility of violating integrity of a WebSocket service with XDomainRequest, cross-site XHR or cross-site form submission), one of the security holes we are trying to fix. > > Nobody is saying that a compliant websocket server has > to also be a fully compliant HTTP server. > > We are simply saying don't impose additional constraints > on the format of the HTTP request/response. Allow > them to be order and case insensitive and you're more > or less done. FWIW I think my nonce proposal would allow doing this for the response at no cost in security - getting your victim to echo back a hash of an unpredictable nonce is so unlikely that there's no need to count on newlines in the handshake. I wish you could consider the nonce handshake proposal and report whether it addresses your concerns. Instead, you are just repeating your own suggestion. I listened to you and gave you feedback. I even made a proposal that tries to address the requirements you have identified. Can you please do me the same courtesy? Would it be helpful if I spelled out the nonce proposal in more detail and explained how it fixes security vulnerabilities in the current handshake, while also making it easier to integrate with existing servers? I admit both my explanation and Ian's later summary were somewhat roughly sketched out. Regards, Maciej
- Re: [hybi] Redesigning the Web Socket handshake Greg Wilkins
- Re: [hybi] Redesigning the Web Socket handshake Justin Erenkrantz
- [hybi] Redesigning the Web Socket handshake Ian Hickson
- Re: [hybi] Redesigning the Web Socket handshake Greg Wilkins
- Re: [hybi] Redesigning the Web Socket handshake Ian Hickson
- Re: [hybi] Redesigning the Web Socket handshake Maciej Stachowiak
- Re: [hybi] Redesigning the Web Socket handshake Greg Wilkins
- Re: [hybi] Redesigning the Web Socket handshake Maciej Stachowiak
- Re: [hybi] Redesigning the Web Socket handshake Vladimir Katardjiev
- Re: [hybi] Redesigning the Web Socket handshake Francis Brosnan Blázquez
- Re: [hybi] Redesigning the Web Socket handshake Justin Erenkrantz
- Re: [hybi] Redesigning the Web Socket handshake Justin Erenkrantz
- Re: [hybi] Redesigning the Web Socket handshake Jamie Lokier
- Re: [hybi] Redesigning the Web Socket handshake Jamie Lokier
- Re: [hybi] Redesigning the Web Socket handshake Jamie Lokier
- Re: [hybi] Redesigning the Web Socket handshake Jamie Lokier
- Re: [hybi] Redesigning the Web Socket handshake Maciej Stachowiak
- Re: [hybi] Redesigning the Web Socket handshake Greg Wilkins
- Re: [hybi] Redesigning the Web Socket handshake Maciej Stachowiak
- Re: [hybi] Redesigning the Web Socket handshake Justin Erenkrantz
- Re: [hybi] Redesigning the Web Socket handshake Maciej Stachowiak
- Re: [hybi] Redesigning the Web Socket handshake Maciej Stachowiak
- Re: [hybi] Redesigning the Web Socket handshake Roberto Peon
- Re: [hybi] Redesigning the Web Socket handshake Justin Erenkrantz
- Re: [hybi] Redesigning the Web Socket handshake Maciej Stachowiak
- Re: [hybi] Redesigning the Web Socket handshake Justin Erenkrantz
- Re: [hybi] Redesigning the Web Socket handshake Maciej Stachowiak
- Re: [hybi] Redesigning the Web Socket handshake Jamie Lokier
- Re: [hybi] Redesigning the Web Socket handshake Maciej Stachowiak
- Re: [hybi] Redesigning the Web Socket handshake Jamie Lokier
- Re: [hybi] Redesigning the Web Socket handshake Martin J. Dürst
- Re: [hybi] Redesigning the Web Socket handshake Lars Eggert
- Re: [hybi] Redesigning the Web Socket handshake Maciej Stachowiak
- Re: [hybi] Redesigning the Web Socket handshake Martin J. Dürst