Re: [hybi] Different server semantics of CONNECT

John Tamplin <jat@google.com> Tue, 07 December 2010 00:46 UTC

Return-Path: <jat@google.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 7D6A328C0F5 for <hybi@core3.amsl.com>; Mon, 6 Dec 2010 16:46:57 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -109.588
X-Spam-Level:
X-Spam-Status: No, score=-109.588 tagged_above=-999 required=5 tests=[AWL=-0.211, BAYES_00=-2.599, FM_FORGED_GMAIL=0.622, J_CHICKENPOX_37=0.6, RCVD_IN_DNSWL_HI=-8, 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 Xi3NIiVMDqNJ for <hybi@core3.amsl.com>; Mon, 6 Dec 2010 16:46:56 -0800 (PST)
Received: from smtp-out.google.com (smtp-out.google.com [74.125.121.35]) by core3.amsl.com (Postfix) with ESMTP id 656F728C0D0 for <hybi@ietf.org>; Mon, 6 Dec 2010 16:46:55 -0800 (PST)
Received: from wpaz33.hot.corp.google.com (wpaz33.hot.corp.google.com [172.24.198.97]) by smtp-out.google.com with ESMTP id oB70mIT0018028 for <hybi@ietf.org>; Mon, 6 Dec 2010 16:48:18 -0800
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d=google.com; s=beta; t=1291682898; bh=ZWxZlSx49S1C0Ftx+9JKlmhQqvQ=; h=MIME-Version:In-Reply-To:References:From:Date:Message-ID:Subject: To:Cc:Content-Type; b=R4wDX6v5H6SJYwQpavRXkZUSKYbZ3TxYe9qmy+pS4hhMsplFVsRRbgNVXTOoLu/jg lMtr7NM/gN9Yr+VbM1gYQ==
Received: from yxl31 (yxl31.prod.google.com [10.190.3.223]) by wpaz33.hot.corp.google.com with ESMTP id oB70lAnq010002 for <hybi@ietf.org>; Mon, 6 Dec 2010 16:48:17 -0800
Received: by yxl31 with SMTP id 31so6676989yxl.32 for <hybi@ietf.org>; Mon, 06 Dec 2010 16:48:17 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=beta; h=domainkey-signature:received:mime-version:received:in-reply-to :references:from:date:message-id:subject:to:cc:content-type; bh=awAaoUwIEHm5g5bQlYEkZ7HuiPZiG0cUbcxfdJk0Q/I=; b=XiILVzYs/ds12J3Vl4xLUgU1uZRNQ316u+Fcyf9lXbd/j9tPZXRZznkhBM0umpcAxB UjegALzFNc4thbBOZ4Vw==
DomainKey-Signature: a=rsa-sha1; c=nofws; d=google.com; s=beta; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type; b=ndc+vRK/1cBY4q8sPkBZnAoXHejrbTyT0/XBwuWN4s1uTy1y4DbTVJQwNUOEtPhxwR Gx2/1bVqPxZd8nr4xmiQ==
Received: by 10.150.192.9 with SMTP id p9mr611466ybf.320.1291682897012; Mon, 06 Dec 2010 16:48:17 -0800 (PST)
MIME-Version: 1.0
Received: by 10.150.217.12 with HTTP; Mon, 6 Dec 2010 16:47:56 -0800 (PST)
In-Reply-To: <F1D6C4CA564CA347B3B9EB54BEA5AD7C0C942729@TK5EX14MBXC212.redmond.corp.microsoft.com>
References: <AANLkTi=5Z+PhCSmgNAd5_JcLYxR1rBQX=sbTT3qEwW-W@mail.gmail.com> <49B71D64-9B5D-40DB-B823-1552C56D19E5@gbiv.com> <F1D6C4CA564CA347B3B9EB54BEA5AD7C0C942729@TK5EX14MBXC212.redmond.corp.microsoft.com>
From: John Tamplin <jat@google.com>
Date: Mon, 06 Dec 2010 19:47:56 -0500
Message-ID: <AANLkTikw+RUNrJQoE13Jm6zkesf8AZ1JZmQdMC7wZDqQ@mail.gmail.com>
To: Henrik Frystyk Nielsen <henrikn@microsoft.com>
Content-Type: text/plain; charset="UTF-8"
X-System-Of-Record: true
Cc: "Roy T. Fielding" <fielding@gbiv.com>, Hybi <hybi@ietf.org>, Greg Wilkins <gregw@intalio.com>
Subject: Re: [hybi] Different server semantics of CONNECT
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, 07 Dec 2010 00:46:57 -0000

On Mon, Dec 6, 2010 at 7:19 PM, Henrik Frystyk Nielsen
<henrikn@microsoft.com> wrote:
> I would like to second Roy's observation that redefining HTTP semantics is a non-starter.
> The main goal should be to settle on a handshake that works and has a high probability of
> surviving the IETF process which basically means that it has to follow HTTP semantics. I
> haven't seen any persuading arguments that would justify this WG to go beyond its
> charter and attempt to change HTTP directly. Traditionally, arguments citing interop
> problems with particular existing implementations is not sufficient for a spec to change,
> especially not when it is as widespread as HTTP. I don't think this in any way precludes the
> WG from coming up with a reasonable, lightweight yet robust handshake so I would
> encourage the discussion to continue but also to constrain itself to the boundaries put
> forward.

First, I am not sure that the CONNECT method is well-enough specified
that anything could be considered changing it.  RFC2616 only has this
to say:

> 9.9 CONNECT
>
> This specification reserves the method name CONNECT for use with a proxy that can
> dynamically switch to being a tunnel (e.g. SSL tunneling [44]).

It doesn't even talk at all about what is acceptable in the request
line, headers, responses, etc.  The only draft which ever made any
attempt to specify it (as far as I am aware) -
http://tools.ietf.org/id/draft-luotonen-web-proxy-tunneling-01.txt -
expired in 1999 (!), so it seems to be stretching the facts to call
that an active spec.

Second, I think it is arguing over semantics to say that the proposed
use of CONNECT does not fit this definition.  The 14 mentions of
"proxy" in the HTTP spec don't really shed any light on whether an
HTTP server acting as a gateway to WebSocket applications could be
considered a proxy, but certainly seems reasonable to consider it so.
Even if not, I would argue that refining the terminology in 9.9 to
clarify "proxy" should not be considered changing the HTTP spec, when
it is so woefully underspecified at present.  Clearly, the intent of
WebSocket is to setup a message-oriented tunnel between the client and
the server, so it seems that part fits.

It seems that those so fundamentally opposed to using CONNECT are
setting up a no-win situation.  If we can't use GET+Upgrade because
real-world implementations never bothered to implement it because it
wasn't actually used, and we can't use CONNECT because it is deemed to
be in violation of the HTTP spec, then where does that leave us?  We
can use a dedicated port, in which case WebSockets will not be usable
in the near future for anyone behind a configured proxy (ie, most
corporate environments and some home ones), or we can use some other
hack which has its own problems like POST with chunked encoding in
both directions.

Do you just want to kill WebSockets so we can stick with Comet/etc?
Is that any less abusive of existing HTTP infrastructure?

-- 
John A. Tamplin
Software Engineer (GWT), Google