Application-Layer Protocol Negotiation (ALPN) for WebRTCMozillamartin.thomson@gmail.comALPNProtocolIdentifier
This document specifies two Application-Layer Protocol Negotiation (ALPN) labels for use
with Web Real-Time Communication (WebRTC). The "webrtc" label identifies regular WebRTC:
a DTLS session that is used to establish keys for the Secure Real-time Transport
Protocol (SRTP) or to establish data channels using the Stream Control
Transmission Protocol (SCTP) over DTLS. The "c-webrtc" label
describes the same protocol, but the peers also agree to maintain the confidentiality of the
media by not sharing it with other applications.
Status of This Memo
This is an Internet Standards Track document.
This document is a product of the Internet Engineering Task Force
(IETF). It represents the consensus of the IETF community. It has
received public review and has been approved for publication by
the Internet Engineering Steering Group (IESG). Further
information on Internet Standards is available in Section 2 of
RFC 7841.
Information about the current status of this document, any
errata, and how to provide feedback on it may be obtained at
.
Copyright Notice
Copyright (c) 2021 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
() 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
. Introduction
. Conventions
. ALPN Labels for WebRTC
. Media Confidentiality
. Security Considerations
. IANA Considerations
. References
. Normative References
. Informative References
Author's Address
IntroductionWeb Real-Time Communication (WebRTC) uses
Datagram Transport Layer Security (DTLS) to secure all
peer-to-peer communications.
Identifying WebRTC protocol usage with Application-Layer Protocol
Negotiation (ALPN) enables an endpoint to positively identify WebRTC uses and
distinguish them from other DTLS uses.
Different WebRTC uses can be advertised and behavior can be constrained to what is
appropriate to a given use. In particular, this allows for the identification of sessions
that require confidentiality protection from the application that manages the signaling for
the session.
Conventions
The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED",
"MAY", and "OPTIONAL" in this document are to be interpreted as
described in BCP 14
when, and only when, they appear in all capitals, as shown here.
ALPN Labels for WebRTC
The following identifiers are defined for use in ALPN:
webrtc:
The DTLS session is used to establish keys for the Secure Real-time Transport Protocol
(SRTP) -- known as DTLS-SRTP -- as described in . The DTLS record
layer is used for WebRTC data
channels.
c-webrtc:
The DTLS session is used for confidential WebRTC, where peers agree to
maintain the confidentiality of the media, as described in . The confidentiality protections ensure that media is
protected from other applications, but the confidentiality protections do not extend to
messages on data channels.
Both identifiers describe the same basic protocol: a DTLS session that is used to provide
keys for an SRTP session in combination with WebRTC data channels. Either SRTP or data
channels could be absent. The data channels send the Stream Control
Transmission Protocol (SCTP) over the DTLS record layer, which can be multiplexed
with SRTP on the same UDP flow. WebRTC requires the use of Interactive Connectivity Establishment (ICE) to establish UDP
flow, but this is not covered by the identifier.
A more thorough definition of what WebRTC entails is included in .
There is no functional difference between the identifiers except that an endpoint
negotiating c-webrtc makes a promise to preserve the
confidentiality of the media it receives.
A peer that is not aware of whether it needs to request confidentiality can use either
identifier. A peer in the client role MUST offer both identifiers if it is not aware of a
need for confidentiality. A peer in the server role SHOULD select webrtc if it does not prefer either.
An endpoint that requires media confidentiality might negotiate a session with a peer that
does not support this specification. An endpoint MUST abort a session if it requires
confidentiality but does not successfully negotiate c-webrtc. A
peer that is willing to accept webrtcSHOULD assume that a peer
that does not support this specification has negotiated webrtc
unless signaling provides other information; however, a peer MUST NOT assume that c-webrtc has been negotiated unless explicitly negotiated.
Media Confidentiality
Private communications in WebRTC depend on separating control (i.e., signaling) capabilities
and access to media . In this way, an
application can establish a session that is end-to-end confidential, where the ends in
question are user agents (or browsers) and not the signaling application. This allows an
application to manage signaling for a session without having access to the media that is
exchanged in the session.
Without some form of indication that is securely bound to the session, a WebRTC endpoint is
unable to properly distinguish between a session that requires this confidentiality
protection and one that does not. The ALPN identifier provides that signal.
A browser is required to enforce this confidentiality protection using isolation controls
similar to those used in content cross-origin protections
(see the "Origin" section of ).
These protections ensure that media is protected from
applications, which are not able to read or modify the contents of a protected flow
of media. Media that is produced from a session using the c-webrtc identifier MUST only be displayed to users.
The promise to apply confidentiality protections do not apply to data that is sent using
data channels. Confidential data depends on having both data sources and consumers that are
exclusively browser or user based. No mechanisms currently exist to take advantage of data
confidentiality, though some use cases suggest that this could be useful, for example,
confidential peer-to-peer file transfer. Alternative labels might be
provided in the future to support these use cases.
This mechanism explicitly does not define a specific authentication method; a WebRTC
endpoint that accepts a session with this ALPN identifier MUST respect confidentiality no
matter what identity is attributed to a peer.
RTP middleboxes and entities that forward media or data cannot promise to maintain
confidentiality. Any entity that forwards content, or records content for later access by
entities other than the authenticated peer, MUST NOT offer or accept a session with the
c-webrtc identifier.
Security Considerations
Confidential communications depend on more than just an agreement from browsers.
Information is not confidential if it is displayed to others than for whom it is
intended. Peer authentication is
necessary to ensure that data is only sent to the intended peer.
This is not a digital rights management mechanism. A user is not prevented from using other
mechanisms to record or forward media. This means that (for example) screen-recording
devices, tape recorders, portable cameras, or a cunning arrangement of mirrors could
variously be used to record or redistribute media once delivered. Similarly, if media is
visible or audible (or otherwise accessible) to others in the vicinity, there are no
technical measures that protect the confidentiality of that media.
The only guarantee provided by this mechanism and the browser that implements it is that the
media was delivered to the user that was authenticated. Individual users will still need to
make a judgment about how their peer intends to respect the confidentiality of any
information provided.
On a shared computing platform like a browser, other entities with access to that platform
(i.e., web applications) might be able to access information that would compromise the
confidentiality of communications. Implementations MAY choose to limit concurrent access to
input devices during confidential communications sessions.
For instance, another application that is able to access a microphone might be able to
sample confidential audio that is playing through speakers. This is true even if acoustic
echo cancellation, which attempts to prevent this from happening, is used. Similarly, an
application with access to a video camera might be able to use reflections to obtain all or
part of a confidential video stream.
IANA Considerations
The following two entries have been added to the "TLS Application-Layer
Protocol Negotiation (ALPN) Protocol IDs" registry established by
:
webrtc:
The webrtc label identifies mixed media and data
communications using SRTP and data channels:
Protocol:
WebRTC Media and Data
Identification Sequence:
0x77 0x65 0x62 0x72 0x74 0x63 ("webrtc")
Specification:
RFC 8833 (this document)
c-webrtc:
The c-webrtc label identifies WebRTC
with a promise to protect media confidentiality:
ReferencesNormative ReferencesKey words for use in RFCs to Indicate Requirement LevelsIn many standards track documents several words are used to signify the requirements in the specification. These words are often capitalized. This document defines these words as they should be interpreted in IETF documents. This document specifies an Internet Best Current Practices for the Internet Community, and requests discussion and suggestions for improvements.Datagram Transport Layer Security (DTLS) Extension to Establish Keys for the Secure Real-time Transport Protocol (SRTP)This document describes a Datagram Transport Layer Security (DTLS) extension to establish keys for Secure RTP (SRTP) and Secure RTP Control Protocol (SRTCP) flows. DTLS keying happens on the media path, independent of any out-of-band signalling channel present. [STANDARDS-TRACK]Datagram Transport Layer Security Version 1.2This document specifies version 1.2 of the Datagram Transport Layer Security (DTLS) protocol. The DTLS protocol provides communications privacy for datagram protocols. The protocol allows client/server applications to communicate in a way that is designed to prevent eavesdropping, tampering, or message forgery. The DTLS protocol is based on the Transport Layer Security (TLS) protocol and provides equivalent security guarantees. Datagram semantics of the underlying transport are preserved by the DTLS protocol. This document updates DTLS 1.0 to work with TLS version 1.2. [STANDARDS-TRACK]Transport Layer Security (TLS) Application-Layer Protocol Negotiation ExtensionThis document describes a Transport Layer Security (TLS) extension for application-layer protocol negotiation within the TLS handshake. For instances in which multiple application protocols are supported on the same TCP or UDP port, this extension allows the application layer to negotiate which protocol will be used within the TLS connection.Ambiguity of Uppercase vs Lowercase in RFC 2119 Key WordsRFC 2119 specifies common key words that may be used in protocol specifications. This document aims to reduce the ambiguity by clarifying that only UPPERCASE usage of the key words have the defined special meanings.WebRTC Security ArchitectureWebRTC Data ChannelsInformative ReferencesHTML - Living StandardWHATWGSection 7.5Stream Control Transmission ProtocolThis document obsoletes RFC 2960 and RFC 3309. It describes the Stream Control Transmission Protocol (SCTP). SCTP is designed to transport Public Switched Telephone Network (PSTN) signaling messages over IP networks, but is capable of broader applications.SCTP is a reliable transport protocol operating on top of a connectionless packet network such as IP. It offers the following services to its users:-- acknowledged error-free non-duplicated transfer of user data,-- data fragmentation to conform to discovered path MTU size,-- sequenced delivery of user messages within multiple streams, with an option for order-of-arrival delivery of individual user messages,-- optional bundling of multiple user messages into a single SCTP packet, and-- network-level fault tolerance through supporting of multi-homing at either or both ends of an association. The design of SCTP includes appropriate congestion avoidance behavior and resistance to flooding and masquerade attacks. [STANDARDS-TRACK]Interactive Connectivity Establishment (ICE): A Protocol for Network Address Translator (NAT) TraversalThis document describes a protocol for Network Address Translator (NAT) traversal for UDP-based communication. This protocol is called Interactive Connectivity Establishment (ICE). ICE makes use of the Session Traversal Utilities for NAT (STUN) protocol and its extension, Traversal Using Relay NAT (TURN).This document obsoletes RFC 5245.Overview: Real-Time Protocols for Browser-Based ApplicationsTransports for WebRTCAuthor's AddressMozillamartin.thomson@gmail.com