idnits 2.17.1 draft-murillo-whip-00.txt: Checking boilerplate required by RFC 5378 and the IETF Trust (see https://trustee.ietf.org/license-info): ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/1id-guidelines.txt: ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/checklist : ---------------------------------------------------------------------------- No issues found here. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year -- The document date (September 09, 2020) is 1324 days in the past. Is this intentional? Checking references for intended status: Informational ---------------------------------------------------------------------------- No issues found here. Summary: 0 errors (**), 0 flaws (~~), 1 warning (==), 1 comment (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 Network Working Group S. Murillo 3 Internet-Draft A. Gouaillard 4 Intended status: Informational CoSMo Software 5 Expires: March 13, 2021 September 09, 2020 7 WebRTC-HTTP ingestion protocol (WHIP) 8 draft-murillo-whip-00 10 Abstract 12 While WebRTC has been very sucessfull in a wide range of scenarios, 13 its adption in the broadcasting/streaming industry is lagging behind. 14 Currently there is no standard protocol (like SIP or RTSP) designed 15 for ingesting media in a streaming service, and content providers 16 still rely heavily on protocols like RTMP for it. 18 These protocols are much older than webrtc and lack by default some 19 important security and resilience features provided by webrtc with 20 minimal delay. 22 The media codecs used in older protocols do not always match those 23 being used in WebRTC, mandating transcoding on the ingest node, 24 introducing delay and degrading media quality. This transcoding step 25 is always present in traditionnal streaming to support e.g. ABR, and 26 comes at no cost. However webrtc implements client-side ABR, also 27 called Network-Aware Encoding by e.g. Huavision, by means of 28 simulcast and SVC codecs, which otherwise alleviate the need for 29 server-side transcoding. Content protection and Privacy Enhancement 30 can be achieve with End-to-End Encryption, which preclude any server- 31 side media processing. 33 This document proposes a simple HTTP based protocol that will allow 34 WebRTC endpoings to ingest content into streaming servics and/or CDNs 35 to fill this gap and facilitate deployment. 37 Status of This Memo 39 This Internet-Draft is submitted in full conformance with the 40 provisions of BCP 78 and BCP 79. 42 Internet-Drafts are working documents of the Internet Engineering 43 Task Force (IETF). Note that other groups may also distribute 44 working documents as Internet-Drafts. The list of current Internet- 45 Drafts is at https://datatracker.ietf.org/drafts/current/. 47 Internet-Drafts are draft documents valid for a maximum of six months 48 and may be updated, replaced, or obsoleted by other documents at any 49 time. It is inappropriate to use Internet-Drafts as reference 50 material or to cite them other than as "work in progress." 52 This Internet-Draft will expire on March 13, 2021. 54 Copyright Notice 56 Copyright (c) 2020 IETF Trust and the persons identified as the 57 document authors. All rights reserved. 59 This document is subject to BCP 78 and the IETF Trust's Legal 60 Provisions Relating to IETF Documents 61 (https://trustee.ietf.org/license-info) in effect on the date of 62 publication of this document. Please review these documents 63 carefully, as they describe your rights and restrictions with respect 64 to this document. Code Components extracted from this document must 65 include Simplified BSD License text as described in Section 4.e of 66 the Trust Legal Provisions and are provided without warranty as 67 described in the Simplified BSD License. 69 Table of Contents 71 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 2 72 2. Terminology . . . . . . . . . . . . . . . . . . . . . . . . . 3 73 3. Overview . . . . . . . . . . . . . . . . . . . . . . . . . . 3 74 4. Protocol Operation . . . . . . . . . . . . . . . . . . . . . 4 75 4.1. ICE and NAT support . . . . . . . . . . . . . . . . . . . 4 76 4.2. Webrtc contrains . . . . . . . . . . . . . . . . . . . . 5 77 4.3. Load balancing and redirections . . . . . . . . . . . . . 5 78 4.4. Authentication and authorization . . . . . . . . . . . . 5 79 4.5. Simulcast and scalable video coding . . . . . . . . . . . 5 80 5. Security Considerations . . . . . . . . . . . . . . . . . . . 6 81 6. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 6 82 7. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . 6 83 8. Normative References . . . . . . . . . . . . . . . . . . . . 6 84 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 6 86 1. Introduction 88 WebRTC intentionaly does not specify a signaling transport protocol 89 at application level, while RTCWEB standardized the signalling 90 protocol itself (JSEP, SDP O/A) and everything that was going over 91 the wire (media, codec, encryption, ...). This flexibility has 92 allowed for implementing a wide range of services. However, those 93 services are typically standalone silos which don't require 94 interoperability with other services or leverage the existence of 95 tools that can communicate with them. 97 In the broadcasting/streaming world, the usage of hardware encoders 98 that would make it very simple to plug in (SDI) cables carrying raw 99 media, encoding it in place, and pushing it to any streaming service 100 or CDN ingest is ubiquitous. Having to implement a custom signalling 101 transport protocol for each different webrtc services has hindered 102 adoption. 104 While some standard signalling protocols are available that can be 105 integrated with WebRTC, like SIP or XMPP, they are not designed to be 106 used in broadcasting/streaming services, and there also is no sign of 107 adoption in that industry. RTSP, which is based on RTP and maybe the 108 closest in terms of features to webrtc, is not compatible with WebRTC 109 SDP offer/answer model. 111 In the specific case of ingest into a platform, some assumption can 112 be made about the server-side which simplifies the webrtc compliance 113 burden, as detailled in webrtc-gateway document. 114 https://tools.ietf.org/html/draft-ietf-rtcweb-gateways-02 116 This document proposse a simple protocol for supporting WebRTC as 117 ingest method which is: - Easy to implement, - As easy to use as 118 current RTMP URI. - Fully compliant with Webrtc and RTCWEB specs. - 119 Allow for both ingest in traditionnal media platforms for extention 120 and ingest in webrtc end-to-end platform for lowest possible latency. 121 - Lowers the requirements on both hardware encoders and broadcasting 122 services to support webrtc. - Usable both in web browsers and in 123 native encoders. 125 2. Terminology 127 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 128 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this 129 document are to be interpreted as described in [RFC2119]. 131 3. Overview 133 The WebRTC-HTTP ingest protocol (WHIP) uses an HTTP POST request to 134 perform a single shot SDP offer/answer so an ICE/DTLS session can be 135 established between the encoder/media producer and the broadcasting 136 ingestion endpoint. 138 Once the ICE/DTLS session is set up, the media will flow 139 unidirectionally from the encoder/media producer broadcasting 140 ingestion endpoint. In order to reduce complexity, no SDP 141 renegotiation is supported, so no tracks or streams can be added or 142 removed once the initial SDP O/A over HTTP is completed. 144 +-----------------+ +---------------+ +--------------+ 145 | WebRTC Producer | | WHIP endpoint | | Media Server | 146 +---------+-------+ +-------+- -----+ +------+-------+ 147 | | | 148 | | | 149 |HTTP POST (SDP Offer) | | 150 +-------------------------+ | 151 |202 Accepted (SDP answer)| | 152 +<------------------------+ | 153 | ICE REQUEST | 154 +----------------------------------------->+ 155 | ICE RESPONSE | 156 <------------------------------------------+ 157 | DTLS SETUP | 158 <==========================================> 159 | RTP FLOW | 160 +------------------------------------------> 162 WHIP session setup 164 4. Protocol Operation 166 In order to setup an ingestion session, the WebRTC encoder/media 167 producer will generate an SDP offer according the the JSEP rules and 168 do an HTTP POST request to the WHIP endpoint configured URL. 170 The HTTP POST request will have a content type of application/sdp and 171 contain the SDP offer as body. The WHIP ingestion endpoint will 172 generate an SDP answer and return it on a 202 Accepted response with 173 content type of application/sdp and the SDP answer as body. 175 SDP offer SHOULD use the sendonly attribute and the SDP answer MUST 176 use the recvonly attribute. 178 Once session is setup ICE consent freshness [RFC7675] will be used to 179 detect abrupt disconnection and DTLS teardown for session termination 180 by either side. 182 4.1. ICE and NAT support 184 In order to simplify the protocol, there is no support of exchanging 185 gathered tickle ICE candidates one the SDP offer or answer is sent. 186 So in order to support encoders/media producers behind NAT, the WHIP 187 media server MUST be publicly accessible. 189 The initial offer by the encoder/media producer MAY be sent after the 190 full ICE gathering is complete containing the full list of ICE 191 candidates, or only contain local candidates or even an empty list of 192 candidates. The WHIP endpoint SDP answer SHALL contain the full list 193 of ICE candidates publicly accessible of the media server. The media 194 server MAY use ICE lite, while the encoder/media producer MUST 195 implement full ICE. 197 If the Encoder/Media producer gathers additional candidates (via 198 STUN/TURN) after the SDP offer is sent, it will send directly a STUN 199 request to the ICE candidates received from the media server as per 200 [I-D.draft-ietf-ice-trickle-21]. 202 4.2. Webrtc contrains 204 In order to reduce the complexity of implementing WHIP in both 205 encoders and media servers, some restrictions regarding WebRTC usage 206 are made. 208 SDP bundle SHALL be used by both the encoder/media producer and the 209 media server. The SDP offer created by the encoder/media producer 210 MUST include the bundle-only attribute in all m-lines as per 211 [I-D.draft-ietf-mmusic-sdp-bundle-negotiation-54]. Also, RTCP muxing 212 SHALL be supported by the both the encoder/media producer and the 213 media server. 215 4.3. Load balancing and redirections 217 Encoders/media MAY not be colocated on the same server so it is 218 possible to load balance incoming request to different media server. 219 Encoders/media producers SHALL support HTTP redirection via 307 220 Temporary Redirect response code. 222 In case of high load, the WHIP endpoints may return a 503 (Service 223 Unavailable) status code indicating that the server is currently 224 unable to handle the request due to a temporary overload or scheduled 225 maintenance, which will likely be alleviated after some delay. The 226 server MAY send a Retry-After header field indicating the minimum 227 time that the user agent is asked to wait before issuing the 228 redirected request. 230 4.4. Authentication and authorization 232 Authtentication and authorization is supported by the Authorization 233 HTTP header with a bearear token as per [RFC6750]. 235 4.5. Simulcast and scalable video coding 237 Both simulcast and scalable video coding (including K-SVC modes) MAY 238 be supported by both media servers and encoders/media producers. 240 5. Security Considerations 242 HTTPS SHALL be used in order to preserve WebRTC security model. 244 6. IANA Considerations 246 7. Acknowledgements 248 8. Normative References 250 [I-D.draft-ietf-ice-trickle-21] 251 Ivov, E., Rescorla, E., Uberti, J., and P. Saint-Andre, 252 "Trickle ICE: Incremental Provisioning of Candidates for 253 the Interactive Connectivity Establishment (ICE) 254 Protocol", draft-ietf-ice-trickle-21 (work in progress), 255 April 2018. 257 [I-D.draft-ietf-mmusic-sdp-bundle-negotiation-54] 258 Holmberg, C., Alvestrand, H., and C. Jennings, 259 "Negotiating Media Multiplexing Using the Session 260 Description Protocol (SDP)", draft-ietf-mmusic-sdp-bundle- 261 negotiation-54 (work in progress), December 2018. 263 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 264 Requirement Levels", BCP 14, RFC 2119, 265 DOI 10.17487/RFC2119, March 1997, 266 . 268 [RFC6750] Jones, M. and D. Hardt, "The OAuth 2.0 Authorization 269 Framework: Bearer Token Usage", RFC 6750, 270 DOI 10.17487/RFC6750, October 2012, 271 . 273 [RFC7675] Perumal, M., Wing, D., Ravindranath, R., Reddy, T., and M. 274 Thomson, "Session Traversal Utilities for NAT (STUN) Usage 275 for Consent Freshness", RFC 7675, DOI 10.17487/RFC7675, 276 October 2015, . 278 Authors' Addresses 280 Sergio Garcia Murillo 281 CoSMo Software 283 Email: sergio.garcia.murillo@cosmosoftware.io 284 Alexandre Gouaillard 285 CoSMo Software 287 Email: alex.gouaillard@cosmosoftware.io