RTCWEB
Internet Engineering Task Force (IETF)                     S. Nandakumar
Internet-Draft
Request for Comments: 7064                                  G. Salgueiro
Intended status:
Category: Standards Track                                       P. Jones
Expires: March 31, 2014
ISSN: 2070-1721                                            Cisco Systems
                                                       M. Petit-Huguenin
                                                      Impedance Mismatch
                                                      September 27,
                                                           November 2013

 URI Scheme for the Session Traversal Utilities for NAT (STUN) Protocol
                  draft-nandakumar-rtcweb-stun-uri-08

Abstract

   This document is the specification of specifies the syntax and semantics of the Uniform
   Resource Identifier (URI) scheme for the Session Traversal Utilities
   for NAT (STUN) protocol.

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 an Internet Standards Track document.

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

   Internet-Drafts are draft documents valid the IETF community.  It has
   received public review and has been approved for a maximum publication by the
   Internet Engineering Steering Group (IESG).  Further information on
   Internet Standards is available in Section 2 of RFC 5741.

   Information about the current status of six months this document, any errata,
   and how to provide feedback on it may be updated, replaced, or obsoleted by other documents obtained 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 March 31, 2014.
   http://www.rfc-editor.org/info/rfc7064.

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.

Table of Contents

   1.  Introduction  . . . . . . . . . . . . . . . . . . . . . . . .   2   3
   2.  Terminology . . . . . . . . . . . . . . . . . . . . . . . . .   3
   3.  Definition of the STUN "stun" or STUNS "stuns" URI . . . . . . . . . . . . .   3
     3.1.  URI Scheme Syntax . . . . . . . . . . . . . . . . . . . .   3
     3.2.  URI Scheme Semantics  . . . . . . . . . . . . . . . . . .   4
   4.  Implementation Status . . . . . . . . . . . . . . . . . . . .   4
     4.1.  libjingle . . . . . . . . . . . . . . . . . . . . . . . .   5
     4.2.  Firefox . . . . . . . . . . . . . . . . . . . . . . . . .   5
   5.  Security Considerations . . . . . . . . . . . . . . . . . . .   6
   6.   4
   5.  IANA Considerations . . . . . . . . . . . . . . . . . . . . .   6
     6.1.  STUN   5
     5.1.  "stun" URI Registration . . . . . . . . . . . . . . . . . .   6
     6.2.  STUNS   5
     5.2.  "stuns" URI Registration  . . . . . . . . . . . . . . . . .   7
   7.   6
   6.  Acknowledgements  . . . . . . . . . . . . . . . . . . . . . .   7
   8.   6
   7.  References  . . . . . . . . . . . . . . . . . . . . . . . . .   8
     8.1.   7
     7.1.  Normative References  . . . . . . . . . . . . . . . . . .   8
     8.2.   7
     7.2.  Informative References  . . . . . . . . . . . . . . . . .   8   7
   Appendix A.  Examples . . . . . . . . . . . . . . . . . . . . . .   9   8
   Appendix B.  Design Notes . . . . . . . . . . . . . . . . . . . .   9
   Appendix C.  Release notes  . . . . . . . . . . . . . . . . . . .   9
     C.1.  Modifications between draft-nandakumar-rtcweb-stun-uri-08
           and draft-nandakumar-rtcweb-stun-uri-07 . . . . . . . . .  10
   Authors' Addresses  . . . . . . . . . . . . . . . . . . . . . . .  10   8

1.  Introduction

   This document specifies the syntax and semantics of the Uniform
   Resource Identifier (URI) scheme for the Session Traversal Utilities
   for NAT (STUN) protocol.

   STUN is a protocol that serves as a tool for other protocols in
   dealing with Network Address Translator (NAT) traversal.  It can be
   used by an endpoint to determine the IP address and port allocated to
   it by a NAT, to perform connectivity checks between two endpoints,
   and used as a keepalive protocol to maintain NAT bindings.  RFC 5389
   [RFC5389] defines the specifics of the STUN protocol.

   The "stun" and "stuns" URI schemes are used to designate a standalone stand-
   alone STUN server or any Internet host performing the operations of a
   STUN server in the context of STUN usages (Section 14 of RFC 5389
   [RFC5389]).  With the advent of standards such as WEBRTC WebRTC [WEBRTC], we
   anticipate a plethora of endpoints and web applications to be able to
   identify and communicate with such a STUN server to carry out the
   STUN protocol.  This also implies those that endpoints and/or applications to must
   be provisioned with the appropriate configuration required to identify the
   STUN server. Having an inconsistent syntax has its drawbacks adds ambiguity and can
   result in non-interoperable solutions.  It can result in solutions
   that are ambiguous and have implementation limitations on the
   different aspects of the syntax and alike. limitations.
   The 'stun/stuns' "stun" and "stuns" URI
   scheme helps schemes help alleviate most of these
   issues by providing a consistent way to describe, configure configure, and
   exchange the information identifying a STUN server.  This would also prevent the shortcomings inherent with
   encoding similar information in non-uniform syntaxes such as the ones
   proposed in the WEBRTC Standards [WEBRTC], for example.

2.  Terminology

   The key words "MUST", "MUST NOT", "REQUIRED", "MAY", and "OPTIONAL"
   in this document are to be interpreted as described in [RFC2119] when
   they appear in ALL CAPS.  When these words are not in ALL CAPS (such
   as "should" or "Should"), they have their usual english meanings, English meanings and
   are not to be interpreted as RFC 2119 key words.

3.  Definition of the STUN "stun" or STUNS "stuns" URI

3.1.  URI Scheme Syntax

   A STUN/STUNS URI has

   "stun" and "stuns" URIs have the following formal ABNF syntax
   [RFC5234]:

   stunURI       = scheme ":" host [ ":" port ]
   scheme        = "stun" / "stuns"

   <host>,

   <host> and <port> are specified in [RFC3986].  While these two ABNF
   productions are defined in [RFC3986] as components of the generic
   hierarchical URI, this does not imply that the stun "stun" and stuns "stuns" URI
   schemes are hierarchical URIs.  Developers MUST NOT use a generic
   hierarchical URI parser to parse a stun "stun" or stuns "stuns" URI.

3.2.  URI Scheme Semantics

   The "stun" and "stuns" URI schemes are used to designate a standalone stand-
   alone STUN server or any Internet host performing the operations of a
   STUN server in the context of STUN usages (Section 14 of RFC 5389
   [RFC5389]).  The STUN protocol supports sending messages over UDP, TCP
   TCP, or TLS-
   over-TCP. TLS-over-TCP.  The "stuns" URI scheme MUST be used when STUN
   is run over TLS-over-TCP (or in the future DTLS-over-UDP) DTLS-over-UDP), and the
   "stun" scheme MUST be used otherwise.

   The required <host> part of the "stun" URI denotes the STUN server
   host.

   For the optional DNS Discovery discovery procedure mentioned in the Section 9 of RFC5389,
   RFC 5389, the "stun" URI scheme implies UDP as the transport protocol
   for SRV lookup and "stuns" URI scheme indicates TCP as the transport
   protocol.

   As specified in [RFC5389], the <port> part, if present, denotes the
   port on which the STUN server is awaiting connection requests.  If it
   is absent, the default port is 3478 for both UDP and TCP.  The
   default port for STUN over TLS is 5349 as per Section 9 of [RFC5389].

4.  Implementation Status

   Note to RFC Editor: Please remove this section and the reference to
   [RFC6982] before publication.

   This section records the status of known implementations of the
   protocol defined by this specification at the time of posting of this
   Internet-Draft, and is based on a proposal described in [RFC6982].
   The description of implementations in this section is intended to
   assist the IETF in its decision processes in progressing drafts to
   RFCs.  Please note that the listing of any individual implementation
   here does not imply endorsement by the IETF.  Furthermore, no effort
   has been spent to verify the information presented here that was
   supplied by IETF contributors.  This is not intended as, and must not
   be construed to be, a catalog of available implementations or their
   features.  Readers are advised to note that other implementations may
   exist.

   According to [RFC6982], "this will allow reviewers lookup, and working groups
   to assign due consideration to documents that have the benefit of
   running code, which may serve "stuns" URI scheme indicates TCP as evidence of valuable experimentation
   and feedback that have made the implemented protocols more mature.
   It is up to
   transport protocol.

   As specified in [RFC5389], the individual working groups to use this information as
   they see fit".

4.1.  libjingle

   Organization:   Google Inc.

   Name:   libjingle revision 4831 https://code.google.com/p/chromium/
      codesearch#chromium/src/third_party/libjingle/source/talk/app/
      webrtc/peerconnection.cc

   Description:   Libjingle <port> part, if present, denotes the
   port on which the STUN server is a set of components provided by Google to
      implement Jingle protocols XEP-166 (http://xmpp.org/extensions/
      xep-0166.html) and XEP-167 (http://xmpp.org/extensions/
      xep-0167.html).

   Level of maturity:   Beta.

   Coverage:   Implements draft-nandakumar-rtcweb-stun-uri-07 without
      IPv6.  The stun and stuns schemes are parsed, and TLS awaiting connection requests.  If it
   is used when absent, the secure bit is set.

   Licensing:   BSD 3-clauses license.

   Contact:   https://code.google.com/p/chromium/

   URL:   https://code.google.com/p/chromium/codesearch#chromium/src/
      third_party/libjingle/source/talk/app/webrtc/peerconnection.cc

4.2.  Firefox

   Organization:   Mozilla

   Name:   Firefox Aurora 21 http://hg.mozilla.org/mozilla-central/rev/
      6b5016ab9ebb

   Description:   Mozilla Firefox default port is a free 3478 for both UDP and open source web browser.

   Level of maturity:   Beta.

   Coverage:   Implements draft-nandakumar-rtcweb-stun-uri-03. TCP.  The
      mozilla code parses the turn and turns schemes but does not seems
      to use TLS.

   Licensing:   Mozilla Public License, v. 2.0.

   Contact:   http://www.mozilla.org/en-US/firefox/channel/

   URL:   http://hg.mozilla.org/mozilla-central/file/4ff1e574e509/media/
      webrtc/signaling/src/peerconnection/PeerConnectionImpl.cpp

5.
   default port for STUN over TLS is 5349 as per Section 9 of [RFC5389].

4.  Security Considerations

   The "stun" and "stuns" URI schemes do not introduce any specific
   security issues beyond the security considerations discussed in
   [RFC3986].  These URI schemes are intended for use in specific
   environments that involve NAT traversal.  Users of the scheme need to
   carefully consider the security properties of the context in which
   they are using them.

   While the stun and stuns URIs do

   Although a "stun" or "stuns" URI does not themselves itself include the username
   or password that will be used to authenticate the STUN client, in
   certain environments, such as WebRTC, the username and password will
   almost certainly be provisioned remotely by an external agent at the
   same time as a stuns "stuns" URI is sent to that client.  Thus, in such
   situations, if the username and password were received in clear the clear,
   there would be little or no benefit to using a stuns "stuns" URI.  For this reason
   reason, a STUN client MUST ensure that the username, password, and stuns URI
   "stuns" URI, and any other security-relevant parameters are received
   with equivalent security before using the stuns "stuns" URI.  Receiving
   those parameters over another TLS session can provide the appropriate
   level of security, security if both TLS sessions are similarly parameterised, e.g. parameterized,
   e.g., with commensurate strength ciphersuites.

6.

5.  IANA Considerations

   This section contains the registration information for the "stun" and
   "stuns" URI Schemes schemes (in accordance with [RFC4395]).  Note that these
   URI schemes are intended for use in very specific NAT traversal
   environments,
   environments and should not be used otherwise on the open Web or
   Internet.

6.1.  STUN

5.1.  "stun" URI Registration

   URI scheme name: stun

   Status: permanent

   URI scheme syntax: See Section 3.1. 3.1

   URI scheme semantics: See Section 3.2. 3.2

   Encoding considerations: There are no encoding considerations beyond
   those in [RFC3986].

   Applications/protocols that use this URI scheme name:

      The "stun" URI scheme is intended to be used by applications with
      a need to identify a STUN server to be used for NAT traversal.

   Interoperability considerations: N/A

   Security considerations: See Section 5. 4

   Contact: Suhas Nandakumar <snandaku@cisco.com>

   Author/Change controller: The IESG

   References: RFCXXXX

   [[NOTE TO RFC EDITOR: Please change XXXX to the number assigned to
   this specification, and remove this paragraph on publication.]]

6.2.  STUNS 7064

5.2.  "stuns" URI Registration

   URI scheme name: stuns

   Status: permanent

   URI scheme syntax: See Section 3.1. 3.1

   URI scheme semantics: See Section 3.2. 3.2

   Encoding considerations: There are no encoding considerations beyond
   those in [RFC3986].

   Applications/protocols that use this URI scheme name:

      The "stun" "stuns" URI scheme is intended to be used by applications with
      a need to identify a STUN server to be used for NAT traversal over
      a secure connection.

   Interoperability considerations: N/A

   Security considerations: See Section 5. 4

   Contact: Suhas Nandakumar <snandaku@cisco.com>

   Author/Change controller: The IESG

   References: RFCXXXX;

   [[NOTE TO RFC EDITOR: Please change XXXX to the number assigned to
   this specification, and remove this paragraph on publication.]]

7. 7064

6.  Acknowledgements

   The authors would like to extend a very special thanks to Cullen
   Jennings for bringing to our attention the WebRTC to WebRTC's need for this
   document, as well as his detailed review and thoughtful comments on
   this document.

   This document has benefited from extensive discussion and review of
   many of the members of the RTCWEB and BEHAVE working groups.  The
   authors would also like to acknowledge Ted Hardie, Bjoern Hoehrmann,
   Russ Housley, Subramanian Moonesamy, Hadriel Kaplan, Graham Klyne,
   Peter Saint-Andre, Ted Lemon, Barry Leiba, Pete Resnick, Spencer
   Dawkins, Stephen Farrell Farrell, and Harald Alvestrand for their invaluable
   input, reviews, feedback comments, and suggestions that helped to
   improve this document.

   The authors would also like to express their gratitude to Dan Wing
   for his assistance in shepherding this document.  We also want to
   thank Gonzalo Camarillo, the Real-time Applications and
   Infrastructure Area Director, for sponsoring this document as well as
   his careful reviews.

   This document was written with the xml2rfc tool described in
   [RFC2629].

8.

7.  References

8.1.

7.1.  Normative References

   [RFC2119]  Bradner, S., "Key words for use in RFCs to Indicate
              Requirement Levels", BCP 14, RFC 2119, March 1997.

   [RFC3986]  Berners-Lee, T., Fielding, R., and L. Masinter, "Uniform
              Resource Identifier (URI): Generic Syntax", STD 66, RFC
              3986, January 2005.

   [RFC5234]  Crocker, D. and P. Overell, "Augmented BNF for Syntax
              Specifications: ABNF", STD 68, RFC 5234, January 2008.

8.2.

7.2.  Informative References

   [RFC2629]  Rose, M., "Writing I-Ds and RFCs using XML", RFC 2629,
              June 1999.

   [RFC4395]  Hansen, T., Hardie, T., and L. Masinter, "Guidelines and
              Registration Procedures for New URI Schemes", BCP 35, RFC
              4395, February 2006.

   [RFC5389]  Rosenberg, J., Mahy, R., Matthews, P., and D. Wing,
              "Session Traversal Utilities for NAT (STUN)", RFC 5389,
              October 2008.

   [RFC6982]  Sheffer, Y. and A. Farrel, "Improving Awareness of Running
              Code: The Implementation Status Section", RFC 6982, July
              2013.

   [WEBRTC]   Bergkvist, A., Burnett, D., Jennings, C., and A.
              Narayanan, "WebRTC 1.0: Real-time Communication Between
              Browsers", World Wide Web Consortium WD WD-
              webrtc-20120821, August 2012,
              <http://www.w3.org/TR/2012/WD-webrtc-20120821>.

Appendix A.  Examples

   Table 1 shows examples for 'stun/stuns'uri scheme. the "stun" and "stuns" URI schemes.  For
   all these examples, the <host> component is populated with
   "example.org".

                          +-----------------------+
                          | URI                   |
                          +-----------------------+
                          | stun:example.org      |
                          | stuns:example.org     |
                          | stun:example.org:8000 |
                          +-----------------------+

                                  Table 1

Appendix B.  Design Notes

   o  One recurring comment was to stop using the suffix "s" on the URI
      scheme,
      scheme and to move the secure option to a parameter (e.g.,
      ";proto=tls").  We decided against this idea because the need for
      ";proto=" for the STUN URI cannot be sufficiently explained explained, and
      supporting it would render an incomplete specification.  This
      would also result in lost symmetry between the TURN and STUN URIs.
      A more detailed account of the reasoning behind this is available
      at <http://blog.marc.petit-huguenin.org/2012/09/on-design-of-stun-
      and-turn-uri-formats.html>

   o  Following the advice of Section 2.2 of [RFC4395], and because the
      STUN URI does not describe a hierarchical structure, the STUN URIs
      are opaque.

Appendix C.  Release notes
   NOTE TO RFC EDITOR: This section must be removed before publication
   as an RFC.

C.1.  Modifications between draft-nandakumar-rtcweb-stun-uri-08 and
      draft-nandakumar-rtcweb-stun-uri-07

   o  Changed the ABNF to use references from RFC 3986 instead of
      copying them.

   o  Converted the design note about hierarchical parsers into a MUST
      NOT statement.

   o  Updated the RFC 6982 forms for Chrome and Firefox.

   o  Added text in security section about verifying that username,
      password and uris are received over a secure connection.

Authors' Addresses

   Suhas Nandakumar
   Cisco Systems
   170 West Tasman Drive
   San Jose, CA  95134
   US

   Email:
   USA

   EMail: snandaku@cisco.com

   Gonzalo Salgueiro
   Cisco Systems
   7200-12 Kit Creek Road
   Research Triangle Park, NC  27709
   US

   Email:
   USA

   EMail: gsalguei@cisco.com

   Paul E. Jones
   Cisco Systems
   7025 Kit Creek Road
   Research Triangle Park, NC  27709
   US

   Email:
   USA

   EMail: paulej@packetizer.com

   Marc Petit-Huguenin
   Impedance Mismatch

   Email:

   EMail: petithug@acm.org