draft-ietf-rtcweb-ip-handling-07.txt | draft-ietf-rtcweb-ip-handling-08.txt | |||
---|---|---|---|---|
Network Working Group J. Uberti | Network Working Group J. Uberti | |||
Internet-Draft Google | Internet-Draft Google | |||
Intended status: Standards Track G. Shieh | Intended status: Standards Track G. Shieh | |||
Expires: October 20, 2018 Facebook | Expires: December 5, 2018 Facebook | |||
April 18, 2018 | June 3, 2018 | |||
WebRTC IP Address Handling Requirements | WebRTC IP Address Handling Requirements | |||
draft-ietf-rtcweb-ip-handling-07 | draft-ietf-rtcweb-ip-handling-08 | |||
Abstract | Abstract | |||
This document provides information and requirements for how IP | This document provides information and requirements for how IP | |||
addresses should be handled by WebRTC implementations. | addresses should be handled by WebRTC implementations. | |||
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. | |||
skipping to change at page 1, line 32 ¶ | skipping to change at page 1, line 32 ¶ | |||
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 https://datatracker.ietf.org/drafts/current/. | Drafts is at https://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 October 20, 2018. | This Internet-Draft will expire on December 5, 2018. | |||
Copyright Notice | Copyright Notice | |||
Copyright (c) 2018 IETF Trust and the persons identified as the | Copyright (c) 2018 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 | |||
(https://trustee.ietf.org/license-info) in effect on the date of | (https://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 16 ¶ | skipping to change at page 2, line 16 ¶ | |||
1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 2 | 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 2 | |||
2. Terminology . . . . . . . . . . . . . . . . . . . . . . . . . 2 | 2. Terminology . . . . . . . . . . . . . . . . . . . . . . . . . 2 | |||
3. Problem Statement . . . . . . . . . . . . . . . . . . . . . . 2 | 3. Problem Statement . . . . . . . . . . . . . . . . . . . . . . 2 | |||
4. Goals . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4 | 4. Goals . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4 | |||
5. Detailed Design . . . . . . . . . . . . . . . . . . . . . . . 4 | 5. Detailed Design . . . . . . . . . . . . . . . . . . . . . . . 4 | |||
5.1. Principles . . . . . . . . . . . . . . . . . . . . . . . 4 | 5.1. Principles . . . . . . . . . . . . . . . . . . . . . . . 4 | |||
5.2. Modes and Recommendations . . . . . . . . . . . . . . . . 5 | 5.2. Modes and Recommendations . . . . . . . . . . . . . . . . 5 | |||
6. Implementation Guidance . . . . . . . . . . . . . . . . . . . 6 | 6. Implementation Guidance . . . . . . . . . . . . . . . . . . . 6 | |||
6.1. Ensuring Normal Routing . . . . . . . . . . . . . . . . . 6 | 6.1. Ensuring Normal Routing . . . . . . . . . . . . . . . . . 6 | |||
6.2. Determining Host Candidates . . . . . . . . . . . . . . . 6 | 6.2. Determining Host Candidates . . . . . . . . . . . . . . . 7 | |||
7. Application Guidance . . . . . . . . . . . . . . . . . . . . 7 | 7. Application Guidance . . . . . . . . . . . . . . . . . . . . 7 | |||
8. Security Considerations . . . . . . . . . . . . . . . . . . . 7 | 8. Security Considerations . . . . . . . . . . . . . . . . . . . 7 | |||
9. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 7 | 9. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 8 | |||
10. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . 7 | 10. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . 8 | |||
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 | |||
Appendix A. Change log . . . . . . . . . . . . . . . . . . . . . 9 | Appendix A. Change log . . . . . . . . . . . . . . . . . . . . . 9 | |||
Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 10 | Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 11 | |||
1. Introduction | 1. Introduction | |||
One of WebRTC's key features is its support of peer-to-peer | One of WebRTC's key features is its support of peer-to-peer | |||
connections. However, when establishing such a connection, which | connections. However, when establishing such a connection, which | |||
involves connection attempts from various IP addresses, WebRTC may | involves connection attempts from various IP addresses, WebRTC may | |||
allow a web application to learn additional information about the | allow a web application to learn additional information about the | |||
user compared to an application that only uses the Hypertext Transfer | user compared to an application that only uses the Hypertext Transfer | |||
Protocol (HTTP) [RFC7230]. This may be problematic in certain cases. | Protocol (HTTP) [RFC7230]. This may be problematic in certain cases. | |||
This document summarizes the concerns, and makes recommendations on | This document summarizes the concerns, and makes recommendations on | |||
skipping to change at page 3, line 31 ¶ | skipping to change at page 3, line 31 ¶ | |||
interfaces (a "split-tunnel" VPN), WebRTC will discover not only | interfaces (a "split-tunnel" VPN), WebRTC will discover not only | |||
the public address for the VPN, but also the ISP public address | the public address for the VPN, but also the ISP public address | |||
over which the VPN is running. | over which the VPN is running. | |||
2. If the client is behind a Network Address Translator (NAT), the | 2. If the client is behind a Network Address Translator (NAT), the | |||
client's private IP addresses, often [RFC1918] addresses, can be | client's private IP addresses, often [RFC1918] addresses, can be | |||
learned. | learned. | |||
3. If the client is behind a proxy (a client-configured "classical | 3. If the client is behind a proxy (a client-configured "classical | |||
application proxy", as defined in [RFC1919], Section 3), but | application proxy", as defined in [RFC1919], Section 3), but | |||
direct access to the Internet is also supported, WebRTC's STUN | direct access to the Internet is permitted, WebRTC's STUN checks | |||
checks will bypass the proxy and reveal the public IP address of | will bypass the proxy and reveal the public IP address of the | |||
the client. | client. This concern also applies to the "enterprise TURN | |||
server" scenario described in [RFC7478], Section 2.3.5.1, if, as | ||||
above, direct Internet access is permitted. However, when the | ||||
term "proxy" is used in this document, it is always in reference | ||||
to an [RFC1919] proxy server. | ||||
Of these three concerns, #1 is the most significant, because for some | Of these three concerns, #1 is the most significant, because for some | |||
users, the purpose of using a VPN is for anonymity. However, | users, the purpose of using a VPN is for anonymity. However, | |||
different VPN users will have different needs, and some VPN users | different VPN users will have different needs, and some VPN users | |||
(e.g., corporate VPN users) may in fact prefer WebRTC to send media | (e.g., corporate VPN users) may in fact prefer WebRTC to send media | |||
traffic directly, i.e., not through the VPN. | traffic directly, i.e., not through the VPN. | |||
#2 is considered to be a less significant concern, given that the | #2 is considered to be a less significant concern, given that the | |||
local address values often contain minimal information (e.g., | local address values often contain minimal information (e.g., | |||
192.168.0.2), or have built-in privacy protection (e.g., the | 192.168.0.2), or have built-in privacy protection (e.g., the | |||
skipping to change at page 4, line 37 ¶ | skipping to change at page 4, line 42 ¶ | |||
information in a way that might violate user expectations. | information in a way that might violate user expectations. | |||
5. Detailed Design | 5. Detailed Design | |||
5.1. Principles | 5.1. Principles | |||
The key principles for our framework are stated below: | The key principles for our framework are stated below: | |||
1. By default, WebRTC traffic should follow typical IP routing, | 1. By default, WebRTC traffic should follow typical IP routing, | |||
i.e., WebRTC should use the same interface used for HTTP traffic, | i.e., WebRTC should use the same interface used for HTTP traffic, | |||
and only the system's 'typical' public addresses should be | and only the system's 'typical' public addresses (or those of an | |||
visible to the application. However, in the interest of optimal | enterprise TURN server, if present) should be visible to the | |||
media quality, it should be possible to enable WebRTC to make use | application. However, in the interest of optimal media quality, | |||
of all network interfaces to determine the ideal route. | it should be possible to enable WebRTC to make use of all network | |||
interfaces to determine the ideal route. | ||||
2. By default, WebRTC should be able to negotiate direct peer-to- | 2. By default, WebRTC should be able to negotiate direct peer-to- | |||
peer connections between endpoints (i.e., without traversing a | peer connections between endpoints (i.e., without traversing a | |||
NAT or relay server), by providing a minimal set of local IP | NAT or relay server), by providing a minimal set of local IP | |||
addresses to the application for use in the ICE process. This | addresses to the application for use in the ICE process. This | |||
ensures that applications that need true peer-to-peer routing for | ensures that applications that need true peer-to-peer routing for | |||
bandwidth or latency reasons can operate successfully. However, | bandwidth or latency reasons can operate successfully. However, | |||
it should be possible to suppress these addresses (with the | it should be possible to suppress these addresses (with the | |||
resultant impact on direct connections) if desired. | resultant impact on direct connections) if desired. | |||
3. By default, WebRTC traffic should not be sent through proxy | 3. By default, WebRTC traffic should not be sent through application | |||
servers, due to the media quality problems associated with | proxy servers, due to the media quality problems associated with | |||
sending WebRTC traffic over TCP, which is almost always used when | sending WebRTC traffic over TCP, which is almost always used when | |||
communicating with proxies, as well as proxy performance issues | communicating with such proxies, as well as proxy performance | |||
that may result from proxying WebRTC's long-lived, high-bandwidth | issues that may result from proxying WebRTC's long-lived, high- | |||
connections. However, it should be possible to force WebRTC to | bandwidth connections. However, it should be possible to force | |||
send its traffic through a configured proxy if desired. | WebRTC to send its traffic through a configured proxy if desired. | |||
5.2. Modes and Recommendations | 5.2. Modes and Recommendations | |||
Based on these ideas, we define four specific modes of WebRTC | Based on these ideas, we define four specific modes of WebRTC | |||
behavior, reflecting different media quality/privacy tradeoffs: | behavior, reflecting different media quality/privacy tradeoffs: | |||
Mode 1: Enumerate all addresses: WebRTC MUST use all network | Mode 1: Enumerate all addresses: WebRTC MUST use all network | |||
interfaces to attempt communication with STUN servers, TURN | interfaces to attempt communication with STUN servers, TURN | |||
servers, or peers. This will converge on the best media | servers, or peers. This will converge on the best media | |||
path, and is ideal when media performance is the highest | path, and is ideal when media performance is the highest | |||
priority, but it discloses the most information. | priority, but it discloses the most information. | |||
Mode 2: Default route + associated local addresses: WebRTC MUST | Mode 2: Default route + associated local addresses: WebRTC MUST | |||
follow the kernel routing table rules, which will typically | follow the kernel routing table rules, which will typically | |||
cause media packets to take the same route as the | cause media packets to take the same route as the | |||
application's HTTP traffic. In addition, the private IPv4 | application's HTTP traffic. If an application TURN server | |||
and IPv6 addresses associated with the kernel-chosen | is present, the preferred route MUST be through this TURN | |||
interface MUST be discovered and provided to the | server. Once an interface has been chosen, the private IPv4 | |||
application. This ensures that direct connections can still | and IPv6 addresses associated with this interface MUST be | |||
be established in this mode. | discovered and provided to the application. This ensures | |||
that direct connections can still be established in this | ||||
mode. | ||||
Mode 3: Default route only: This is the the same as Mode 2, except | Mode 3: Default route only: This is the the same as Mode 2, except | |||
that the associated private addresses MUST NOT be provided; | that the associated private addresses MUST NOT be provided; | |||
the only IP addresses gathered are those discovered via | the only IP addresses gathered are those discovered via | |||
mechanisms like STUN and TURN (on the default route). This | mechanisms like STUN and TURN (on the default route). This | |||
may cause traffic to hairpin through a NAT, fall back to an | may cause traffic to hairpin through a NAT, fall back to an | |||
application TURN server, or fail altogether, with resulting | application TURN server, or fail altogether, with resulting | |||
quality implications. | quality implications. | |||
Mode 4: Force proxy: This is the same as Mode 3, but all WebRTC | Mode 4: Force proxy: This is the same as Mode 3, but when the | |||
media traffic is forced through a proxy, if one is | application's HTTP traffic is sent through an application | |||
configured. If the proxy does not support UDP (as is the | proxy, WebRTC media traffic MUST also be proxied. If the | |||
case for all HTTP and most SOCKS [RFC1928] proxies), or the | proxy does not support UDP (as is the case for all HTTP and | |||
WebRTC implementation does not support UDP proxying, the use | most SOCKS [RFC1928] proxies), or the WebRTC implementation | |||
of UDP will be disabled, and TCP will be used to send and | does not support UDP proxying, the use of UDP will be | |||
receive media through the proxy. Use of TCP will result in | disabled, and TCP will be used to send and receive media | |||
reduced media quality, in addition to any performance | through the proxy. Use of TCP will result in reduced media | |||
considerations associated with sending all WebRTC media | quality, in addition to any performance considerations | |||
through the proxy server. | associated with sending all WebRTC media through the proxy | |||
server. | ||||
Mode 1 MUST only be used when user consent has been provided. The | Mode 1 MUST only be used when user consent has been provided. The | |||
details of this consent are left to the implementation; one potential | details of this consent are left to the implementation; one potential | |||
mechanism is to tie this consent to getUserMedia consent. | mechanism is to tie this consent to getUserMedia consent. | |||
Alternatively, implementations can provide a specific mechanism to | Alternatively, implementations can provide a specific mechanism to | |||
obtain user consent. | obtain user consent. | |||
In cases where user consent has not been obtained, Mode 2 SHOULD be | In cases where user consent has not been obtained, Mode 2 SHOULD be | |||
used. | used. | |||
These defaults provide a reasonable tradeoff that permits trusted | These defaults provide a reasonable tradeoff that permits trusted | |||
WebRTC applications to achieve optimal network performance, but gives | WebRTC applications to achieve optimal network performance, but gives | |||
applications without consent (e.g., 1-way streaming or data channel | applications without consent (e.g., 1-way streaming or data channel | |||
applications) only the minimum information needed to achieve direct | applications) only the minimum information needed to achieve direct | |||
skipping to change at page 6, line 21 ¶ | skipping to change at page 6, line 29 ¶ | |||
These defaults provide a reasonable tradeoff that permits trusted | These defaults provide a reasonable tradeoff that permits trusted | |||
WebRTC applications to achieve optimal network performance, but gives | WebRTC applications to achieve optimal network performance, but gives | |||
applications without consent (e.g., 1-way streaming or data channel | applications without consent (e.g., 1-way streaming or data channel | |||
applications) only the minimum information needed to achieve direct | applications) only the minimum information needed to achieve direct | |||
connections, as defined in Mode 2. However, implementations MAY | connections, as defined in Mode 2. However, implementations MAY | |||
choose stricter modes if desired, e.g., if a user indicates they want | choose stricter modes if desired, e.g., if a user indicates they want | |||
all WebRTC traffic to follow the default route. | all WebRTC traffic to follow the default route. | |||
Note that the suggested defaults can still be used even for | Note that the suggested defaults can still be used even for | |||
organizations that want all external WebRTC traffic to traverse a | organizations that want all external WebRTC traffic to traverse a | |||
proxy, simply by setting an organizational firewall policy that | proxy or enterprise TURN server, simply by setting an organizational | |||
allows WebRTC traffic to only leave through the proxy. This provides | firewall policy that allows WebRTC traffic to only leave through the | |||
a way to ensure the proxy is used for any external traffic, but | proxy or TURN server. This provides a way to ensure the proxy or | |||
avoids the performance issues associated with Mode 4 (where all media | TURN server is used for any external traffic, but still allows direct | |||
is forced through said proxy) for intra-organization traffic. | connections (and, in the proxy case, avoids the performance issues | |||
associated with forcing media through said proxy) for intra- | ||||
organization traffic. | ||||
6. Implementation Guidance | 6. Implementation Guidance | |||
This section provides guidance to WebRTC implementations on how to | This section provides guidance to WebRTC implementations on how to | |||
implement the policies described above. | implement the policies described above. | |||
6.1. Ensuring Normal Routing | 6.1. Ensuring Normal Routing | |||
When trying to follow typical IP routing, the simplest approach is to | When trying to follow typical IP routing, the simplest approach is to | |||
bind the sockets used for peer-to-peer connections to the wildcard | bind the sockets used for peer-to-peer connections to the wildcard | |||
skipping to change at page 9, line 25 ¶ | skipping to change at page 9, line 31 ¶ | |||
[RFC7016] Thornburgh, M., "Adobe's Secure Real-Time Media Flow | [RFC7016] Thornburgh, M., "Adobe's Secure Real-Time Media Flow | |||
Protocol", RFC 7016, DOI 10.17487/RFC7016, November 2013, | Protocol", RFC 7016, DOI 10.17487/RFC7016, November 2013, | |||
<https://www.rfc-editor.org/info/rfc7016>. | <https://www.rfc-editor.org/info/rfc7016>. | |||
[RFC7230] Fielding, R., Ed. and J. Reschke, Ed., "Hypertext Transfer | [RFC7230] Fielding, R., Ed. and J. Reschke, Ed., "Hypertext Transfer | |||
Protocol (HTTP/1.1): Message Syntax and Routing", | Protocol (HTTP/1.1): Message Syntax and Routing", | |||
RFC 7230, DOI 10.17487/RFC7230, June 2014, | RFC 7230, DOI 10.17487/RFC7230, June 2014, | |||
<https://www.rfc-editor.org/info/rfc7230>. | <https://www.rfc-editor.org/info/rfc7230>. | |||
[RFC7478] Holmberg, C., Hakansson, S., and G. Eriksson, "Web Real- | ||||
Time Communication Use Cases and Requirements", RFC 7478, | ||||
DOI 10.17487/RFC7478, March 2015, | ||||
<https://www.rfc-editor.org/info/rfc7478>. | ||||
[RFC8089] Kerwin, M., "The "file" URI Scheme", RFC 8089, | [RFC8089] Kerwin, M., "The "file" URI Scheme", RFC 8089, | |||
DOI 10.17487/RFC8089, February 2017, | DOI 10.17487/RFC8089, February 2017, | |||
<https://www.rfc-editor.org/info/rfc8089>. | <https://www.rfc-editor.org/info/rfc8089>. | |||
Appendix A. Change log | Appendix A. Change log | |||
Changes in draft -08: | ||||
o Discuss how enterprise TURN servers should be handled. | ||||
Changes in draft -07: | Changes in draft -07: | |||
o Clarify consent guidance. | o Clarify consent guidance. | |||
Changes in draft -06: | Changes in draft -06: | |||
o Clarify recommendations. | o Clarify recommendations. | |||
o Split implementation guidance into two sections. | o Split implementation guidance into two sections. | |||
End of changes. 16 change blocks. | ||||
42 lines changed or deleted | 60 lines changed or added | |||
This html diff was produced by rfcdiff 1.46. The latest version is available from http://tools.ietf.org/tools/rfcdiff/ |