XEP-0177: Jingle Raw UDP Transport

This document defines a Jingle transport method that results in sending data over a raw User Datagram Protocol (UDP) connection.

NOTICE: This document is currently within Last Call or under consideration by the XMPP Council for advancement to the next stage in the JSF standards process.

XEP Information

Status: Proposed
Type: Standards Track
Number: 0177
Version: 0.2
Last Updated: 2006-07-12
Publishing Organization: Jabber Software Foundation
Approving Body: XMPP Council
Dependencies: XMPP Core, XEP-0166
Supersedes: None
Superseded By: None
Short Name: raw-udp
Wiki Page: <http://wiki.jabber.org/index.php/Jingle Raw UDP Transport (XEP-0177)>

Author Information

Joe Beda

Email: jbeda@google.com
JID: jbeda@google.com

Peter Saint-Andre

Email: stpeter@jabber.org
JID: stpeter@jabber.org

Scott Ludwig

Email: scottlu@google.com
JID: scottlu@google.com

Joe Hildebrand

Email: jhildebrand@jabber.com
JID: hildjj@jabber.org

Sean Egan

Email: seanegan@google.com
JID: seanegan@google.com

Legal Notice

This XMPP Extension Protocol is copyright 1999 - 2006 by the Jabber Software Foundation (JSF) and is in full conformance with the JSF's Intellectual Property Rights Policy <http://www.xmpp.org/extensions/ipr-policy.shtml>. This material may be distributed only subject to the terms and conditions set forth in the Creative Commons Attribution License (<http://creativecommons.org/licenses/by/2.5/>).

Discussion Venue

The preferred venue for discussion of this document is the Standards-JIG discussion list: <http://mail.jabber.org/mailman/listinfo/standards-jig>.

Relation to XMPP

The Extensible Messaging and Presence Protocol (XMPP) is defined in the XMPP Core (RFC 3920) and XMPP IM (RFC 3921) specifications contributed by the Jabber Software Foundation to the Internet Standards Process, which is managed by the Internet Engineering Task Force in accordance with RFC 2026. Any protocol defined in this document has been developed outside the Internet Standards Process and is to be understood as an extension to XMPP rather than as an evolution, development, or modification of XMPP itself.

Conformance Terms

The following keywords as used in this document are to be interpreted as described in RFC 2119: "MUST", "SHALL", "REQUIRED"; "MUST NOT", "SHALL NOT"; "SHOULD", "RECOMMENDED"; "SHOULD NOT", "NOT RECOMMENDED"; "MAY", "OPTIONAL".

Table of Contents

1. Introduction
2. Requirements
3. Protocol Description
3.1. Transport Initiation
3.2. Target Entity Response
3.3. Exchanging Address Information
3.4. Informational Messages
4. Security Considerations
4.1. End-to-End Data Encryption
5. IANA Considerations
6. XMPP Registrar Considerations
6.1. Protocol Namespaces
6.2. Jingle Transport Methods
7. XML Schema
Revision History

1. Introduction

Jingle [1] defines a framework for negotiating and managing out-of-band data sessions over XMPP. In order to provide a flexible framework, the base Jingle specification defines neither data transport methods nor content (session) types, leaving that up to separate specifications. The current document defines a transport method for establishing and managing data between XMPP entities using a raw User Datagram Protocol (UDP) connection (see RFC 768 [2]).

2. Requirements

The Jingle transport method defined herein is designed to meet the following requirements:

  1. Make it possible to establish and manage out-of-band connections between two XMPP entities over the IP address and port that the initiator considers most likely to succeed.
  2. Make it relatively easy to implement support in standard Jabber/XMPP clients.
  3. Where communication with non-XMPP entities is needed, push as much complexity as possible onto server-side gateways between the XMPP network and the non-XMPP network.

3. Protocol Description

3.1 Transport Initiation

In order for the initiating entity in a Jingle exchange to start the negotiation, it MUST send a Jingle "session-initiate" stanza as described in XEP-0166. This stanza MUST include at least one transport methods. If the initiating entity wishes to negotiate the Raw UDP transport, it MUST include an empty <transport/> child element qualified by the 'http://jabber.org/protocol/jingle/transport/raw-udp' namespace.

Example 1. Initiation Example

<iq to='juliet@capulet.com/balcony' from='romeo@montague.net/orchard' id='jingle1' type='set'>
  <jingle xmlns='http://jabber.org/protocol/jingle' 
    <description ...>
    <transport xmlns='http://jabber.org/protocol/jingle/transport/raw-udp'/>

3.2 Target Entity Response

As described in XEP-0166, to provisionally accept the session initiation request, the target entity returns an IQ-result:

Example 2. Target Entity Provisionally Accepts the Session Request

<iq type='result' from='juliet@capulet.com/balcony' to='romeo@montague.net/orchard' id='jingle1'/>

3.3 Exchanging Address Information

Once the session is provisionally accepted, each entity should send one <transport/> element in a transport-info meessage, containing exactly one <candidate/> element per channel, whose 'ip' and 'port' attributes specify the IP address and port number of the candidate that the initiator has reason to believe will be most likely to succeed for that channel. (Note: In older versions of XEP-0166, this was referrred to as the "default candidate".) This is not necessarily the initiator's preferred address for communication, but instead is the "address most likely to succeed", i.e., the address that is assumed to be reachable by the vast majority of target entities. To determine reachability, the client needs classify ahead of time the permissiveness of the firewall or network address translator (NAT) it is behind, if any. If the NAT is symmetric (not permissive), the candidate SHOULD specify a relay address. Otherwise it SHOULD be an address derived via prior discovery using RFC 3489 [3], which will be an address on the outside of the firewall or NAT.

Example 3. Address Exchange Example

<iq to='juliet@capulet.com/balcony' from='romeo@montague.net/orchard' id='jingle2' type='set'>
  <jingle xmlns='http://jabber.org/protocol/jingle' 
    <transport xmlns='http://jabber.org/protocol/jingle/transport/raw-udp'>
      <candidate name='myvoicedata' ip='' port='13540' generation='0'/>

Note: The 'name' attribute specifies the name of the channel and the 'generation' attribute provides a tracking mechanism for determining which version of this candidate is in force (this is useful if the candidate is redefined mid-stream, for example if the port is changed).

Either entity may send this transport-info message at any time, after which the recipient should send and receive data to and from the new address.

3.4 Informational Messages

The syntax and semantics informational message payloads specific to the Raw UDP transport method will be defined in a future version of this specification.

4. Security Considerations

4.1 End-to-End Data Encryption

In order to secure the end-to-end data stream, implementations SHOULD use encryption methods appropriate to the transport method in use.

5. IANA Considerations

This document requires no interaction with the Internet Assigned Numbers Authority (IANA) [4].

6. XMPP Registrar Considerations

6.1 Protocol Namespaces

The XMPP Registrar [5] shall include 'http://jabber.org/protocol/jingle/transport/raw-udp' in its registry of protocol namespaces.

6.2 Jingle Transport Methods

The XMPP Registrar shall include "http://jabber.org/protocol/jingle/transport/raw-udp" in its registry of Jingle transport methods. The registry submission is as follows:

In order to submit new values to this registry, the registrant must define an XML fragment of the following form and either include it in the relevant XMPP Extension Protocol or send it to the email address <registrar@jabber.org>:

  <desc>A method for exchanging data over a raw UDP connection.</desc>

7. XML Schema

<?xml version='1.0' encoding='UTF-8'?>


  <xs:element name='transport'>
        <xs:element ref='candidate' minOccurs='0' maxOccurs='1'/>

  <xs:element name='candidate'>
        <xs:extension base='empty'>
          <xs:attribute name='generation' type='xs:unsignedByte' use='required'/>
          <xs:attribute name='name' type='xs:string' use='required'/>
          <xs:attribute name='ip' type='xs:string' use='required'/>
          <xs:attribute name='port' type='xs:unsignedShort' use='required'/>

  <xs:simpleType name='empty'>
    <xs:restriction base='xs:string'>
      <xs:enumeration value=''/>



1. XEP-0166: Jingle <http://www.xmpp.org/extensions/xep-0166.html>.

2. RFC 768: User Datagram Protocol <http://www.ietf.org/rfc/rfc0768.txt>.

3. RFC 3489: STUN - Simple Traversal of User Datagram Protocol (UDP) Through Network Address Translators (NATs) <http://www.ietf.org/rfc/rfc3489.txt>.

4. The Internet Assigned Numbers Authority (IANA) is the central coordinator for the assignment of unique parameter values for Internet protocols, such as port numbers and URI schemes. For further information, see <http://www.iana.org/>.

5. The XMPP Registrar maintains a list of reserved protocol namespaces as well as registries of parameters used in the context of XMPP extension protocols approved by the Jabber Software Foundation. For further information, see <http://www.xmpp.org/registrar/>.

Revision History

Version 0.2 (2006-07-12)

Removed candidate element and specified exchange of address information via transport-info messages; clarified usage of name attribute. (se/psa)

Version 0.1 (2006-03-01)

Initial version (split from XEP-0166). (psa/jb)