WebSocket over HTTP/2.0
draft-hirano-httpbis-websocket-over-http2-00

The information below is for an old version of the document
Document Type Active Internet-Draft (individual)
Last updated 2014-02-14
Stream (None)
Intended RFC status (None)
Formats plain text pdf html bibtex
Stream Stream state (No stream defined)
Consensus Boilerplate Unknown
RFC Editor Note (None)
IESG IESG state I-D Exists
Telechat date
Responsible AD (None)
Send notices to (None)
HTTPbis Working Group                                          Y. Hirano
Internet-Draft                                              Google, Inc.
Intended status: Standards Track                       February 14, 2014
Expires: August 18, 2014

                        WebSocket over HTTP/2.0
              draft-hirano-httpbis-websocket-over-http2-00

Abstract

   The WebSocket protocol enables two-way communication between a client
   running untrusted code in a controlled environment to a remote host
   that has opted-in to communications from that code.  Since it
   requires one TCP connection for every WebSocket connection, having
   multiple WebSocket connections between the same client and the same
   server is inefficient.  On the other hand, HTTP/2.0 specifies a fast,
   secure, multiplexed framing protocol.  This document provides bi-
   directional multiplexed communication by layering WebSocket on top of
   HTTP/2.0.

   Please send feedback to the ietf-http-wg@w3.org mailing list.

Status of this Memo

   This Internet-Draft is submitted in full conformance with the
   provisions of BCP 78 and BCP 79.

   Internet-Drafts are working documents of the Internet Engineering
   Task Force (IETF).  Note that other groups may also distribute
   working documents as Internet-Drafts.  The list of current Internet-
   Drafts is at http://datatracker.ietf.org/drafts/current/.

   Internet-Drafts are draft documents valid for a maximum of six months
   and may be updated, replaced, or obsoleted by other documents at any
   time.  It is inappropriate to use Internet-Drafts as reference
   material or to cite them other than as "work in progress."

   This Internet-Draft will expire on August 18, 2014.

Copyright Notice

   Copyright (c) 2014 IETF Trust and the persons identified as the
   document authors.  All rights reserved.

   This document is subject to BCP 78 and the IETF Trust's Legal
   Provisions Relating to IETF Documents
   (http://trustee.ietf.org/license-info) in effect on the date of

Hirano                   Expires August 18, 2014                [Page 1]
Internet-Draft           WebSocket over HTTP/2.0           February 2014

   publication of this document.  Please review these documents
   carefully, as they describe your rights and restrictions with respect
   to this document.  Code Components extracted from this document must
   include Simplified BSD License text as described in Section 4.e of
   the Trust Legal Provisions and are provided without warranty as
   described in the Simplified BSD License.

Table of Contents

   1.  Introduction . . . . . . . . . . . . . . . . . . . . . . . . .  3
     1.1.  Document Organization  . . . . . . . . . . . . . . . . . .  3
   2.  Conformance Requirements and Terminology . . . . . . . . . . .  4
   3.  Cross Protocol Negotiation . . . . . . . . . . . . . . . . . .  5
     3.1.  Supported scheme negotiation using SETTINGS frame  . . . .  6
   4.  Opening Handshake  . . . . . . . . . . . . . . . . . . . . . .  8
     4.1.  Handshake Request  . . . . . . . . . . . . . . . . . . . .  8
     4.2.  Handshake Response . . . . . . . . . . . . . . . . . . . .  8
   5.  Data Framing . . . . . . . . . . . . . . . . . . . . . . . . . 10
     5.1.  Overview . . . . . . . . . . . . . . . . . . . . . . . . . 10
     5.2.  Frame representation . . . . . . . . . . . . . . . . . . . 10
       5.2.1.  Tunneling RFC6455 framing (Plan D) . . . . . . . . . . 10
       5.2.2.  Tunneling RFC6455 framing with END_SEGMENT mark
               (Plan A) . . . . . . . . . . . . . . . . . . . . . . . 10
       5.2.3.  HEADERS + DATAs (Plan C) . . . . . . . . . . . . . . . 10
     5.3.  Masking  . . . . . . . . . . . . . . . . . . . . . . . . . 11
   6.  Closing the Connection . . . . . . . . . . . . . . . . . . . . 12
     6.1.  Definitions  . . . . . . . . . . . . . . . . . . . . . . . 12
       6.1.1.  Close the WebSocket Connection . . . . . . . . . . . . 12
       6.1.2.  Start the WebSocket Closing Handshake  . . . . . . . . 12
       6.1.3.  The WebSocket Closing Handshake is Started . . . . . . 12
       6.1.4.  The WebSocket Connection is Closed . . . . . . . . . . 12
       6.1.5.  The WebSocket Connection Close Code  . . . . . . . . . 12
       6.1.6.  The WebSocket Connection Close Reason  . . . . . . . . 12
       6.1.7.  Fail the WebSocket Connection  . . . . . . . . . . . . 13
     6.2.  Abnormal Closures  . . . . . . . . . . . . . . . . . . . . 13
       6.2.1.  Client-Initiated Closure . . . . . . . . . . . . . . . 13
       6.2.2.  Server-initiated closure . . . . . . . . . . . . . . . 13
       6.2.3.  Recovering from Abnormal Closure . . . . . . . . . . . 13
     6.3.  Normal Closure of Connections  . . . . . . . . . . . . . . 13
     6.4.  Status Codes . . . . . . . . . . . . . . . . . . . . . . . 13
Show full document text