A JSON Meta Application Protocol (JMAP) Subprotocol for WebSocket
draft-ietf-jmap-websocket-00

Document Type Active Internet-Draft (jmap WG)
Last updated 2018-12-05
Stream IETF
Intended RFC status (None)
Formats plain text xml pdf html bibtex
Stream WG state WG Document
Document shepherd No shepherd assigned
IESG IESG state I-D Exists
Consensus Boilerplate Unknown
Telechat date
Responsible AD (None)
Send notices to (None)
JMAP                                                        K. Murchison
Internet-Draft                                                  FastMail
Intended status: Standards Track                        December 5, 2018
Expires: June 8, 2019

   A JSON Meta Application Protocol (JMAP) Subprotocol for WebSocket
                      draft-ietf-jmap-websocket-00

Abstract

   This document defines a binding for the JSON Meta Application
   Protocol (JMAP) over a WebSocket transport layer.  A WebSocket
   binding for JMAP provides higher performance than the current HTTP
   binding for JMAP.

Open Issues

   o  What mechanism should be used to allow the client to choose what
      types of objects for which is wishes to receive push notifications
      over the WS connection?  Shoul this be done via a new method type
      or can it be done with header fields and/or query parameters on
      the WS handshake?

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 https://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 June 8, 2019.

Copyright Notice

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

Murchison                 Expires June 8, 2019                  [Page 1]
Internet-Draft             JMAP Over WebSocket             December 2018

   (https://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.

Table of Contents

   1.  Introduction  . . . . . . . . . . . . . . . . . . . . . . . .   2
   2.  Conventions Used in This Document . . . . . . . . . . . . . .   3
   3.  Discovering Support for JMAP over WebSocket . . . . . . . . .   3
   4.  JMAP Subprotocol  . . . . . . . . . . . . . . . . . . . . . .   3
     4.1.  Handshake . . . . . . . . . . . . . . . . . . . . . . . .   3
     4.2.  WebSocket Messages  . . . . . . . . . . . . . . . . . . .   4
     4.3.  Examples  . . . . . . . . . . . . . . . . . . . . . . . .   5
   5.  Security Considerations . . . . . . . . . . . . . . . . . . .   9
   6.  IANA Considerations . . . . . . . . . . . . . . . . . . . . .   9
     6.1.  Registration of the WebSocket JMAP Subprotocol  . . . . .   9
   7.  Acknowledgments . . . . . . . . . . . . . . . . . . . . . . .   9
   8.  References  . . . . . . . . . . . . . . . . . . . . . . . . .   9
     8.1.  Normative References  . . . . . . . . . . . . . . . . . .   9
     8.2.  Informative References  . . . . . . . . . . . . . . . . .  10
     8.3.  URIs  . . . . . . . . . . . . . . . . . . . . . . . . . .  10
   Appendix A.  Change History (To be removed by RFC Editor before
                publication) . . . . . . . . . . . . . . . . . . . .  10
   Author's Address  . . . . . . . . . . . . . . . . . . . . . . . .  11

1.  Introduction

   JMAP over HTTP requires that every JMAP API request be authenticated.
   Depending on the type of authentication used by the JMAP client and
   the configuration of the JMAP server, authentication could be an
   expensive operation both in time and resources.  In such
   circumstances, authenticating every JMAP API request may harm
   performance.

   The WebSocket binding for JMAP eliminates this performance hit by
   authenticating just the WebSocket handshake request and having those
   credentials remain in effect for the duration of the WebSocket
   connection.

   Furthermore, the WebSocket binding for JMAP can optionally compress
   [RFC7692] JMAP API requests.  Although compression of HTTP responses
   is ubiquitous, compression of HTTP requests has very low, if any
   deployment, and therefore isn't a viable option for JMAP API requests
   over HTTP.

Murchison                 Expires June 8, 2019                  [Page 2]
Internet-Draft             JMAP Over WebSocket             December 2018

2.  Conventions Used in This Document

   The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
   "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and
Show full document text