datatracker.ietf.org
Sign In
Version 4.50, 2013-05-15
Report a bug

An XMPP Sub-protocol for WebSocket
draft-moffitt-xmpp-over-websocket-03

Active Internet-Draft (None)
Document Stream: No stream defined
Last updated: 2013-05-18
Intended RFC status: (None)
Other versions: plain text, xml, pdf, html

Document shepherd:(None)
Shepherd writeup

IESG State: I-D Exists
Responsible AD: (None)
Send notices to: No addresses provided

HyBi Working Group                                         L. Stout, Ed.
Internet-Draft                                                      &yet
Intended status: Standards Track                              J. Moffitt
Expires: November 19, 2013                                    E. Cestari
                                                        cstar industries
                                                            May 18, 2013

                   An XMPP Sub-protocol for WebSocket
                  draft-moffitt-xmpp-over-websocket-03

Abstract

   This document defines a binding for the XMPP protocol over a
   WebSocket transport layer.  A WebSocket binding for XMPP provides
   higher performance than the current HTTP binding for XMPP.

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 November 19, 2013.

Copyright Notice

   Copyright (c) 2013 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
   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.

Stout, et al.          Expires November 19, 2013                [Page 1]
Internet-Draft            XMPP over WebSocket                   May 2013

Table of Contents

   1.  Introduction  . . . . . . . . . . . . . . . . . . . . . . . .   2
   2.  Terminology . . . . . . . . . . . . . . . . . . . . . . . . .   3
   3.  XMPP Sub-Protocol . . . . . . . . . . . . . . . . . . . . . .   3
     3.1.  Handshake . . . . . . . . . . . . . . . . . . . . . . . .   3
     3.2.  Messages  . . . . . . . . . . . . . . . . . . . . . . . .   4
     3.3.  XMPP Stream Setup . . . . . . . . . . . . . . . . . . . .   4
     3.4.  Stream Errors . . . . . . . . . . . . . . . . . . . . . .   4
     3.5.  Closing the Connection  . . . . . . . . . . . . . . . . .   5
     3.6.  Stanzas . . . . . . . . . . . . . . . . . . . . . . . . .   6
     3.7.  Stream Restarts . . . . . . . . . . . . . . . . . . . . .   6
     3.8.  Pings and Keepalives  . . . . . . . . . . . . . . . . . .   6
     3.9.  Use of TLS  . . . . . . . . . . . . . . . . . . . . . . .   6
     3.10. Stream Management . . . . . . . . . . . . . . . . . . . .   7
   4.  Discovering Connection Method . . . . . . . . . . . . . . . .   7
   5.  Security Considerations . . . . . . . . . . . . . . . . . . .   7
   6.  IANA Considerations . . . . . . . . . . . . . . . . . . . . .   8
   7.  Informative References  . . . . . . . . . . . . . . . . . . .   8
   Authors' Addresses  . . . . . . . . . . . . . . . . . . . . . . .   9

1.  Introduction

   Applications using XMPP (see [RFC6120] and [RFC6121]) on the Web
   currently make use of BOSH (see [XEP-0124] and [XEP-0206]), an XMPP
   binding to HTTP.  BOSH is based on the HTTP long polling technique,
   and it suffers from high transport overhead compared to XMPP's native
   binding to TCP.  In addition, there are a number of other known
   issues with long polling [RFC6202], which have an impact on BOSH-
   based systems.

   It would be much better in most circumstances to avoid tunneling XMPP
   over HTTP long polled connections and instead use the XMPP protocol
   directly.  However, the APIs and sandbox that browsers have provided
   do not allow this.  The WebSocket protocol [RFC6455] now exists to
   solve these kinds of problems.  The WebSocket protocol is a bi-
   directional protocol that provides a simple message-based framing
   layer over raw sockets and allows for more robust and efficient
   communication in web applications.

   The WebSocket protocol enables two-way communication between a client
   and a server, effectively emulating TCP at the application layer and
   therefore overcoming many of the problems with existing long-polling