draft-ietf-rtcweb-stun-consent-freshness-15.txt   draft-ietf-rtcweb-stun-consent-freshness-16.txt 
RTCWEB M. Perumal RTCWEB M. Perumal
Internet-Draft Ericsson Internet-Draft Ericsson
Intended status: Standards Track D. Wing Intended status: Standards Track D. Wing
Expires: December 24, 2015 R. Ravindranath Expires: February 14, 2016 R. Ravindranath
T. Reddy T. Reddy
Cisco Systems Cisco Systems
M. Thomson M. Thomson
Mozilla Mozilla
June 22, 2015 August 13, 2015
STUN Usage for Consent Freshness STUN Usage for Consent Freshness
draft-ietf-rtcweb-stun-consent-freshness-15 draft-ietf-rtcweb-stun-consent-freshness-16
Abstract Abstract
To prevent WebRTC applications, such as browsers, from launching To prevent WebRTC applications, such as browsers, from launching
attacks by sending media to unwilling victims, periodic consent to attacks by sending traffic to unwilling victims, periodic consent to
send needs to be obtained from remote endpoints. send needs to be obtained from remote endpoints.
This document describes a consent mechanism using a new Session This document describes a consent mechanism using a new Session
Traversal Utilities for NAT (STUN) usage. Traversal Utilities for NAT (STUN) usage.
Status of This Memo Status of This Memo
This Internet-Draft is submitted in full conformance with the This Internet-Draft is submitted in full conformance with the
provisions of BCP 78 and BCP 79. provisions of BCP 78 and BCP 79.
Internet-Drafts are working documents of the Internet Engineering Internet-Drafts are working documents of the Internet Engineering
Task Force (IETF). Note that other groups may also distribute Task Force (IETF). Note that other groups may also distribute
working documents as Internet-Drafts. The list of current Internet- working documents as Internet-Drafts. The list of current Internet-
Drafts is at http://datatracker.ietf.org/drafts/current/. Drafts is at http://datatracker.ietf.org/drafts/current/.
Internet-Drafts are draft documents valid for a maximum of six months Internet-Drafts are draft documents valid for a maximum of six months
and may be updated, replaced, or obsoleted by other documents at any and may be updated, replaced, or obsoleted by other documents at any
time. It is inappropriate to use Internet-Drafts as reference time. It is inappropriate to use Internet-Drafts as reference
material or to cite them other than as "work in progress." material or to cite them other than as "work in progress."
This Internet-Draft will expire on December 24, 2015. This Internet-Draft will expire on February 14, 2016.
Copyright Notice Copyright Notice
Copyright (c) 2015 IETF Trust and the persons identified as the Copyright (c) 2015 IETF Trust and the persons identified as the
document authors. All rights reserved. document authors. All rights reserved.
This document is subject to BCP 78 and the IETF Trust's Legal This document is subject to BCP 78 and the IETF Trust's Legal
Provisions Relating to IETF Documents Provisions Relating to IETF Documents
(http://trustee.ietf.org/license-info) in effect on the date of (http://trustee.ietf.org/license-info) in effect on the date of
publication of this document. Please review these documents publication of this document. Please review these documents
skipping to change at page 2, line 33 skipping to change at page 2, line 33
9. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 7 9. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 7
10. Acknowledgement . . . . . . . . . . . . . . . . . . . . . . . 7 10. Acknowledgement . . . . . . . . . . . . . . . . . . . . . . . 7
11. References . . . . . . . . . . . . . . . . . . . . . . . . . 8 11. References . . . . . . . . . . . . . . . . . . . . . . . . . 8
11.1. Normative References . . . . . . . . . . . . . . . . . . 8 11.1. Normative References . . . . . . . . . . . . . . . . . . 8
11.2. Informative References . . . . . . . . . . . . . . . . . 8 11.2. Informative References . . . . . . . . . . . . . . . . . 8
Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 9 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 9
1. Introduction 1. Introduction
To prevent attacks on peers, endpoints have to ensure the remote peer To prevent attacks on peers, endpoints have to ensure the remote peer
is willing to receive traffic. This is performed both when the is willing to receive traffic. Verification of peer consent before
session is first established to the remote peer using Interactive sending traffic is necessary in deployments like WebRTC to ensure
Connectivity Establishment ICE [RFC5245] connectivity checks, and that a malicious JavaScript cannot use the browser as a platform for
periodically for the duration of the session using the procedures launching attacks. This is performed both when the session is first
defined in this document. established to the remote peer using Interactive Connectivity
Establishment ICE [RFC5245] connectivity checks, and periodically for
the duration of the session using the procedures defined in this
document.
When a session is first established, ICE implementations obtain an When a session is first established, ICE implementations obtain an
initial consent to send by performing STUN connectivity checks. This initial consent to send by performing STUN connectivity checks. This
document describes a new STUN usage with exchange of request and document describes a new STUN usage with exchange of request and
response messages that verifies the remote peer's ongoing consent to response messages that verifies the remote peer's ongoing consent to
receive traffic. This consent expires after a period of time and receive traffic. This consent expires after a period of time and
needs to be continually renewed, which ensures that consent can be needs to be continually renewed, which ensures that consent can be
terminated. terminated.
This document defines what it takes to obtain, maintain, and lose This document defines what it takes to obtain, maintain, and lose
skipping to change at page 3, line 16 skipping to change at page 3, line 19
agent (as defined in Section 2.7 of [RFC5245]) does not generate agent (as defined in Section 2.7 of [RFC5245]) does not generate
connectivity checks or run the ICE state machine. Hence, an ICE-lite connectivity checks or run the ICE state machine. Hence, an ICE-lite
agent does not generate consent checks and will only respond to any agent does not generate consent checks and will only respond to any
checks that it receives. No changes are required to ICE-lite checks that it receives. No changes are required to ICE-lite
implementations in order to respond to consent checks, as they are implementations in order to respond to consent checks, as they are
processed as normal ICE connectivity checks. processed as normal ICE connectivity checks.
2. Applicability 2. Applicability
This document defines what it takes to obtain, maintain, and lose This document defines what it takes to obtain, maintain, and lose
consent to send using ICE. Verification of peer consent before consent to send using ICE. Section 4.4 and Section 5.3 of
sending traffic is necessary in deployments like WebRTC to ensure
that a malicious JavaScript cannot use the browser as a platform for
launching attacks. Section 4.4 and Section 5.3 of
[I-D.ietf-rtcweb-security-arch] further explains the value of [I-D.ietf-rtcweb-security-arch] further explains the value of
obtaining and maintaining consent. obtaining and maintaining consent.
Other Applications that have similar security requirements to verify Other Applications that have similar security requirements to verify
peer's consent before sending non-ICE packets can use the consent peer consent before sending non-ICE packets can use the consent
mechanism described in this document. The mechanism of how mechanism described in this document. The mechanism of how
applications are made aware of consent expiration is outside the applications are made aware of consent expiration is outside the
scope of the document. scope of the document.
3. Terminology 3. Terminology
The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
"SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this
document are to be interpreted as described in [RFC2119]. document are to be interpreted as described in [RFC2119].
Consent: The mechanism of obtaining permission from the remote Consent: The mechanism of obtaining permission from the remote
endpoint to send non-ICE traffic to a remote transport address. endpoint to send non-ICE traffic to a remote transport address.
Consent is obtained using ICE. Consent is obtained using ICE. Note that this is an application-
level consent; no human intervention is involved.
Consent Freshness: Maintaining and renewing consent over time. Consent Freshness: Maintaining and renewing consent over time.
Transport Address: The remote peer's IP address and UDP or TCP port Transport Address: The remote peer's IP address and UDP or TCP port
number. number.
4. Design Considerations 4. Design Considerations
Although ICE requires periodic keepalive traffic to keep NAT bindings Although ICE requires periodic keepalive traffic to keep NAT bindings
alive (Section 10 of [RFC5245], [RFC6263]), those keepalives are sent alive (Section 10 of [RFC5245], [RFC6263]), those keepalives are sent
skipping to change at page 4, line 46 skipping to change at page 4, line 48
ICE does not identify when consent to send traffic ends. This ICE does not identify when consent to send traffic ends. This
document describes two ways in which consent to send ends: expiration document describes two ways in which consent to send ends: expiration
of consent and immediate revocation of consent, which are discussed of consent and immediate revocation of consent, which are discussed
in the following sections. in the following sections.
5.1. Expiration of Consent 5.1. Expiration of Consent
A full ICE implementation obtains consent to send using ICE. After A full ICE implementation obtains consent to send using ICE. After
ICE concludes on a particular candidate pair and whenever the ICE concludes on a particular candidate pair and whenever the
endpoint sends application data on that pair consent MUST be endpoint sends application data on that pair consent is maintained
maintained following the procedure described in this document. following the procedure described in this document.
An endpoint MUST NOT send data other than the messages used to An endpoint MUST NOT send data other than the messages used to
establish consent unless the receiving endpoint has consented to establish consent unless the receiving endpoint has consented to
receive data. Connectivity checks that are paced as described in receive data. Connectivity checks that are paced as described in
Section 16 of [RFC5245] and responses to connectivity checks are Section 16 of [RFC5245] and responses to connectivity checks are
permitted. That is, no application data (e.g., RTP or Datagram permitted. That is, no application data (e.g., RTP or Datagram
Transport Layer Security (DTLS)) can be sent until consent is Transport Layer Security (DTLS)) can be sent until consent is
obtained. obtained.
Explicit consent to send is obtained and maintained by sending an Explicit consent to send is obtained and maintained by sending a STUN
STUN binding request to the remote peer's transport address and binding request to the remote peer's transport address and receiving
receiving a matching, authenticated, non-error STUN binding response a matching, authenticated, non-error STUN binding response from the
from the remote peer's transport address. These STUN binding remote peer's transport address. These STUN binding requests and
requests and responses are authenticated using the same short-term responses are authenticated using the same short-term credentials as
credentials as the initial ICE exchange. the initial ICE exchange.
Note: Although TCP has its own consent mechanism (TCP Note: Although TCP has its own consent mechanism (TCP
acknowledgements), consent is necessary over a TCP connection acknowledgements), consent is necessary over a TCP connection
because it could be translated to a UDP connection (e.g., because it could be translated to a UDP connection (e.g.,
[RFC6062]). [RFC6062]).
Consent expires after 30 seconds. That is, if a valid STUN binding Consent expires after 30 seconds. That is, if a valid STUN binding
response has not been received from the remote peer's transport response has not been received from the remote peer's transport
address in 30 seconds, the endpoint MUST cease transmission on that address in 30 seconds, the endpoint MUST cease transmission on that
5-tuple. STUN consent responses received after consent expiry do not 5-tuple. STUN consent responses received after consent expiry do not
skipping to change at page 5, line 36 skipping to change at page 5, line 40
To prevent expiry of consent, a STUN binding request can be sent To prevent expiry of consent, a STUN binding request can be sent
periodically. To prevent synchronization of consent checks, each periodically. To prevent synchronization of consent checks, each
interval MUST be randomized from between 0.8 and 1.2 times the basic interval MUST be randomized from between 0.8 and 1.2 times the basic
period. Implementations SHOULD set a default interval of 5 seconds, period. Implementations SHOULD set a default interval of 5 seconds,
resulting in a period between checks of 4 to 6 seconds. resulting in a period between checks of 4 to 6 seconds.
Implementations MUST NOT set the period between checks to less than 4 Implementations MUST NOT set the period between checks to less than 4
seconds. This timer is independent of the consent expiry timeout. seconds. This timer is independent of the consent expiry timeout.
Each STUN binding request for consent MUST use a new STUN transaction Each STUN binding request for consent MUST use a new STUN transaction
identifier for every consent binding request, as described in identifier, as described in Section 6 of [RFC5389]. Each STUN
Section 6 of [RFC5389]. Each STUN binding request for consent is binding request for consent is transmitted once only. A sender
transmitted once only. A sender therefore cannot assume that it will therefore cannot assume that it will receive a response for every
receive a response for every consent request, and a response might be consent request, and a response might be for a previous request
for a previous request (rather than for the most recently sent (rather than for the most recently sent request).
request).
An endpoint SHOULD await a binding response for each request it sends An endpoint SHOULD await a binding response for each request it sends
for a time based on the estimated round-trip time (RTT) (see for a time based on the estimated round-trip time (RTT) (see
Section 7.2.1 of [RFC5389]) with an allowance for variation in Section 7.2.1 of [RFC5389]) with an allowance for variation in
network delay. The RTT value can be updated as described in network delay. The RTT value can be updated as described in
[RFC5389]. All outstanding STUN consent transactions for a candidate [RFC5389]. All outstanding STUN consent transactions for a candidate
pair MUST be discarded when consent expires. pair MUST be discarded when consent expires.
To meet the security needs of consent, an untrusted application To meet the security needs of consent, an untrusted application
(e.g., JavaScript or signaling servers) MUST NOT be able to obtain or (e.g., JavaScript or signaling servers) MUST NOT be able to obtain or
skipping to change at page 7, line 30 skipping to change at page 7, line 32
7. DTLS applicability 7. DTLS applicability
The DTLS applicability is identical to what is described in The DTLS applicability is identical to what is described in
Section 4.2 of [RFC7350]. Section 4.2 of [RFC7350].
8. Security Considerations 8. Security Considerations
This document describes a security mechanism, details of which are This document describes a security mechanism, details of which are
mentioned in Section 4.1 and Section 4.2. Consent requires 96 bits mentioned in Section 4.1 and Section 4.2. Consent requires 96 bits
transaction ID to be uniformly and randomly chosen from the interval transaction ID defined in section 6 of [RFC5389] to be uniformly and
0 .. 2**96-1, and be cryptographically strong. This is good enough randomly chosen from the interval 0 .. 2**96-1, and be
security against an off-path attacker replaying old STUN consent cryptographically strong. This is good enough security against an
responses. Consent Verification to avoid attacks using a browser as off-path attacker replaying old STUN consent responses. Consent
an attack platform against machines is discussed in Sections 3.3 and Verification to avoid attacks using a browser as an attack platform
4.2 of [I-D.ietf-rtcweb-security]. against machines is discussed in Sections 3.3 and 4.2 of
[I-D.ietf-rtcweb-security].
The security considerations discussed in [RFC5245] should also be The security considerations discussed in [RFC5245] should also be
taken into account. taken into account.
9. IANA Considerations 9. IANA Considerations
This document does not require any action from IANA. This document does not require any action from IANA.
10. Acknowledgement 10. Acknowledgement
Thanks to Eric Rescorla, Harald Alvestrand, Bernard Aboba, Magnus Thanks to Eric Rescorla, Harald Alvestrand, Bernard Aboba, Magnus
Westerland, Cullen Jennings, Christer Holmberg, Simon Perreault, Paul Westerlund, Cullen Jennings, Christer Holmberg, Simon Perreault, Paul
Kyzivat, Emil Ivov, Jonathan Lennox, Inaki Baz Castillo, Rajmohan Kyzivat, Emil Ivov, Jonathan Lennox, Inaki Baz Castillo, Rajmohan
Banavi, Christian Groves, Meral Shirazipour and David Black for their Banavi, Christian Groves, Meral Shirazipour, David Black, Barry
valuable inputs and comments. Thanks to Christer Holmberg for doing Leiba, Ben Campbell and Stephen Farrell for their valuable inputs and
a thorough review. comments. Thanks to Christer Holmberg for doing a thorough review.
11. References 11. References
11.1. Normative References 11.1. Normative References
[I-D.ietf-rtcweb-security]
Rescorla, E., "Security Considerations for WebRTC", draft-
ietf-rtcweb-security-08 (work in progress), February 2015.
[I-D.ietf-rtcweb-security-arch]
Rescorla, E., "WebRTC Security Architecture", draft-ietf-
rtcweb-security-arch-11 (work in progress), March 2015.
[RFC2119] Bradner, S., "Key words for use in RFCs to Indicate [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate
Requirement Levels", BCP 14, RFC 2119, March 1997. Requirement Levels", BCP 14, RFC 2119,
DOI 10.17487/RFC2119, March 1997,
<http://www.rfc-editor.org/info/rfc2119>.
[RFC5245] Rosenberg, J., "Interactive Connectivity Establishment [RFC5245] Rosenberg, J., "Interactive Connectivity Establishment
(ICE): A Protocol for Network Address Translator (NAT) (ICE): A Protocol for Network Address Translator (NAT)
Traversal for Offer/Answer Protocols", RFC 5245, April Traversal for Offer/Answer Protocols", RFC 5245,
2010. DOI 10.17487/RFC5245, April 2010,
<http://www.rfc-editor.org/info/rfc5245>.
[RFC5389] Rosenberg, J., Mahy, R., Matthews, P., and D. Wing, [RFC5389] Rosenberg, J., Mahy, R., Matthews, P., and D. Wing,
"Session Traversal Utilities for NAT (STUN)", RFC 5389, "Session Traversal Utilities for NAT (STUN)", RFC 5389,
October 2008. DOI 10.17487/RFC5389, October 2008,
<http://www.rfc-editor.org/info/rfc5389>.
[RFC6263] Marjou, X. and A. Sollaud, "Application Mechanism for
Keeping Alive the NAT Mappings Associated with RTP / RTP
Control Protocol (RTCP) Flows", RFC 6263, June 2011.
11.2. Informative References 11.2. Informative References
[I-D.ietf-avtcore-srtp-ekt] [I-D.ietf-avtcore-srtp-ekt]
Mattsson, J., McGrew, D., and D. Wing, "Encrypted Key Mattsson, J., McGrew, D., and D. Wing, "Encrypted Key
Transport for Secure RTP", draft-ietf-avtcore-srtp-ekt-03 Transport for Secure RTP", draft-ietf-avtcore-srtp-ekt-03
(work in progress), October 2014. (work in progress), October 2014.
[I-D.ietf-rtcweb-security]
Rescorla, E., "Security Considerations for WebRTC", draft-
ietf-rtcweb-security-08 (work in progress), February 2015.
[I-D.ietf-rtcweb-security-arch]
Rescorla, E., "WebRTC Security Architecture", draft-ietf-
rtcweb-security-arch-11 (work in progress), March 2015.
[I-D.ietf-tsvwg-rtcweb-qos] [I-D.ietf-tsvwg-rtcweb-qos]
Dhesikan, S., Jennings, C., Druta, D., Jones, P., and J. Dhesikan, S., Jennings, C., Druta, D., Jones, P., and J.
Polk, "DSCP and other packet markings for RTCWeb QoS", Polk, "DSCP and other packet markings for RTCWeb QoS",
draft-ietf-tsvwg-rtcweb-qos-03 (work in progress), draft-ietf-tsvwg-rtcweb-qos-04 (work in progress), July
November 2014. 2015.
[RFC3830] Arkko, J., Carrara, E., Lindholm, F., Naslund, M., and K. [RFC3830] Arkko, J., Carrara, E., Lindholm, F., Naslund, M., and K.
Norrman, "MIKEY: Multimedia Internet KEYing", RFC 3830, Norrman, "MIKEY: Multimedia Internet KEYing", RFC 3830,
August 2004. DOI 10.17487/RFC3830, August 2004,
<http://www.rfc-editor.org/info/rfc3830>.
[RFC4568] Andreasen, F., Baugher, M., and D. Wing, "Session [RFC4568] Andreasen, F., Baugher, M., and D. Wing, "Session
Description Protocol (SDP) Security Descriptions for Media Description Protocol (SDP) Security Descriptions for Media
Streams", RFC 4568, July 2006. Streams", RFC 4568, DOI 10.17487/RFC4568, July 2006,
<http://www.rfc-editor.org/info/rfc4568>.
[RFC4953] Touch, J., "Defending TCP Against Spoofing Attacks", RFC [RFC4953] Touch, J., "Defending TCP Against Spoofing Attacks",
4953, July 2007. RFC 4953, DOI 10.17487/RFC4953, July 2007,
<http://www.rfc-editor.org/info/rfc4953>.
[RFC5961] Ramaiah, A., Stewart, R., and M. Dalal, "Improving TCP's [RFC5961] Ramaiah, A., Stewart, R., and M. Dalal, "Improving TCP's
Robustness to Blind In-Window Attacks", RFC 5961, August Robustness to Blind In-Window Attacks", RFC 5961,
2010. DOI 10.17487/RFC5961, August 2010,
<http://www.rfc-editor.org/info/rfc5961>.
[RFC6062] Perreault, S. and J. Rosenberg, "Traversal Using Relays [RFC6062] Perreault, S., Ed. and J. Rosenberg, "Traversal Using
around NAT (TURN) Extensions for TCP Allocations", RFC Relays around NAT (TURN) Extensions for TCP Allocations",
6062, November 2010. RFC 6062, DOI 10.17487/RFC6062, November 2010,
<http://www.rfc-editor.org/info/rfc6062>.
[RFC6263] Marjou, X. and A. Sollaud, "Application Mechanism for
Keeping Alive the NAT Mappings Associated with RTP / RTP
Control Protocol (RTCP) Flows", RFC 6263,
DOI 10.17487/RFC6263, June 2011,
<http://www.rfc-editor.org/info/rfc6263>.
[RFC7350] Petit-Huguenin, M. and G. Salgueiro, "Datagram Transport [RFC7350] Petit-Huguenin, M. and G. Salgueiro, "Datagram Transport
Layer Security (DTLS) as Transport for Session Traversal Layer Security (DTLS) as Transport for Session Traversal
Utilities for NAT (STUN)", RFC 7350, August 2014. Utilities for NAT (STUN)", RFC 7350, DOI 10.17487/RFC7350,
August 2014, <http://www.rfc-editor.org/info/rfc7350>.
Authors' Addresses Authors' Addresses
Muthu Arul Mozhi Perumal Muthu Arul Mozhi Perumal
Ericsson Ericsson
Ferns Icon Ferns Icon
Doddanekundi, Mahadevapura Doddanekundi, Mahadevapura
Bangalore, Karnataka 560037 Bangalore, Karnataka 560037
India India
 End of changes. 27 change blocks. 
68 lines changed or deleted 81 lines changed or added

This html diff was produced by rfcdiff 1.42. The latest version is available from http://tools.ietf.org/tools/rfcdiff/