idnits 2.17.1 draft-westerlund-avtcore-multiplex-architecture-03.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 : ---------------------------------------------------------------------------- ** The document seems to lack a both a reference to RFC 2119 and the recommended RFC 2119 boilerplate, even if it appears to use RFC 2119 keywords. RFC 2119 keyword, line 748: '... SHOULD be carried in a separate RTP...' RFC 2119 keyword, line 751: '...nd video streams SHOULD NOT be carried...' RFC 2119 keyword, line 833: '...ely, each medium SHOULD be carried in ...' Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year -- The document date (February 25, 2013) is 4075 days in the past. Is this intentional? Checking references for intended status: Informational ---------------------------------------------------------------------------- == Unused Reference: 'RFC4607' is defined on line 1882, but no explicit reference was found in the text == Unused Reference: 'RFC5760' is defined on line 1903, but no explicit reference was found in the text == Outdated reference: A later version (-06) exists of draft-ietf-avtcore-6222bis-00 == Outdated reference: A later version (-13) exists of draft-ietf-avtcore-multi-media-rtp-session-01 == Outdated reference: A later version (-10) exists of draft-ietf-avtcore-rtp-security-options-01 == Outdated reference: A later version (-11) exists of draft-ietf-avtext-multiple-clock-rates-08 == Outdated reference: A later version (-54) exists of draft-ietf-mmusic-sdp-bundle-negotiation-03 == Outdated reference: A later version (-14) exists of draft-ietf-payload-rtp-howto-02 == Outdated reference: A later version (-07) exists of draft-westerlund-avtcore-transport-multiplexing-04 == Outdated reference: A later version (-03) exists of draft-westerlund-avtext-rtcp-sdes-srcname-02 -- Obsolete informational reference (is this intentional?): RFC 2326 (Obsoleted by RFC 7826) -- Obsolete informational reference (is this intentional?): RFC 4566 (Obsoleted by RFC 8866) -- Obsolete informational reference (is this intentional?): RFC 5117 (Obsoleted by RFC 7667) -- Obsolete informational reference (is this intentional?): RFC 6222 (Obsoleted by RFC 7022) Summary: 1 error (**), 0 flaws (~~), 11 warnings (==), 5 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 Network Working Group M. Westerlund 3 Internet-Draft B. Burman 4 Intended status: Informational Ericsson 5 Expires: August 29, 2013 C. Perkins 6 University of Glasgow 7 H. Alvestrand 8 Google 9 February 25, 2013 11 Guidelines for using the Multiplexing Features of RTP 12 draft-westerlund-avtcore-multiplex-architecture-03 14 Abstract 16 Real-time Transport Protocol (RTP) is a flexible protocol possible to 17 use in a wide range of applications and network and system 18 topologies. This flexibility and the implications of different 19 choices should be understood by any application developer using RTP. 20 To facilitate that understanding, this document contains an in-depth 21 discussion of the usage of RTP's multiplexing points; the RTP session 22 and the Synchronisation Source Identifier (SSRC). The document tries 23 to give guidance and source material for an analysis on the most 24 suitable choices for the application being designed. 26 Status of this Memo 28 This Internet-Draft is submitted in full conformance with the 29 provisions of BCP 78 and BCP 79. 31 Internet-Drafts are working documents of the Internet Engineering 32 Task Force (IETF). Note that other groups may also distribute 33 working documents as Internet-Drafts. The list of current Internet- 34 Drafts is at http://datatracker.ietf.org/drafts/current/. 36 Internet-Drafts are draft documents valid for a maximum of six months 37 and may be updated, replaced, or obsoleted by other documents at any 38 time. It is inappropriate to use Internet-Drafts as reference 39 material or to cite them other than as "work in progress." 41 This Internet-Draft will expire on August 29, 2013. 43 Copyright Notice 45 Copyright (c) 2013 IETF Trust and the persons identified as the 46 document authors. All rights reserved. 48 This document is subject to BCP 78 and the IETF Trust's Legal 49 Provisions Relating to IETF Documents 50 (http://trustee.ietf.org/license-info) in effect on the date of 51 publication of this document. Please review these documents 52 carefully, as they describe your rights and restrictions with respect 53 to this document. Code Components extracted from this document must 54 include Simplified BSD License text as described in Section 4.e of 55 the Trust Legal Provisions and are provided without warranty as 56 described in the Simplified BSD License. 58 Table of Contents 60 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . . 4 61 2. Definitions . . . . . . . . . . . . . . . . . . . . . . . . . 5 62 2.1. Terminology . . . . . . . . . . . . . . . . . . . . . . . 5 63 2.2. Subjects Out of Scope . . . . . . . . . . . . . . . . . . 7 64 3. RTP Concepts . . . . . . . . . . . . . . . . . . . . . . . . . 7 65 3.1. Session . . . . . . . . . . . . . . . . . . . . . . . . . 7 66 3.2. SSRC . . . . . . . . . . . . . . . . . . . . . . . . . . . 8 67 3.3. CSRC . . . . . . . . . . . . . . . . . . . . . . . . . . . 10 68 3.4. Payload Type . . . . . . . . . . . . . . . . . . . . . . . 10 69 4. Multiple Streams Alternatives . . . . . . . . . . . . . . . . 12 70 5. RTP Topologies and Issues . . . . . . . . . . . . . . . . . . 13 71 5.1. Point to Point . . . . . . . . . . . . . . . . . . . . . . 13 72 5.2. Translators & Gateways . . . . . . . . . . . . . . . . . . 13 73 5.3. Point to Multipoint Using Multicast . . . . . . . . . . . 14 74 5.4. Point to Multipoint Using an RTP Transport Translator . . 15 75 5.5. Point to Multipoint Using an RTP Mixer . . . . . . . . . . 15 76 6. Multiple Streams Discussion . . . . . . . . . . . . . . . . . 16 77 6.1. Introduction . . . . . . . . . . . . . . . . . . . . . . . 16 78 6.2. RTP/RTCP Aspects . . . . . . . . . . . . . . . . . . . . . 16 79 6.2.1. The RTP Specification . . . . . . . . . . . . . . . . 16 80 6.2.2. Multiple SSRCs in a Session . . . . . . . . . . . . . 19 81 6.2.3. Handling Varying Sets of Senders . . . . . . . . . . . 19 82 6.2.4. Cross Session RTCP Requests . . . . . . . . . . . . . 19 83 6.2.5. Binding Related Sources . . . . . . . . . . . . . . . 20 84 6.2.6. Forward Error Correction . . . . . . . . . . . . . . . 21 85 6.2.7. Transport Translator Sessions . . . . . . . . . . . . 22 86 6.3. Interworking . . . . . . . . . . . . . . . . . . . . . . . 22 87 6.3.1. Types of Interworking . . . . . . . . . . . . . . . . 22 88 6.3.2. RTP Translator Interworking . . . . . . . . . . . . . 23 89 6.3.3. Gateway Interworking . . . . . . . . . . . . . . . . . 23 90 6.3.4. Multiple SSRC Legacy Considerations . . . . . . . . . 24 91 6.4. Network Aspects . . . . . . . . . . . . . . . . . . . . . 25 92 6.4.1. Quality of Service . . . . . . . . . . . . . . . . . . 25 93 6.4.2. NAT and Firewall Traversal . . . . . . . . . . . . . . 25 94 6.4.3. Multicast . . . . . . . . . . . . . . . . . . . . . . 27 95 6.4.4. Multiplexing multiple RTP Session on a Single 96 Transport . . . . . . . . . . . . . . . . . . . . . . 28 97 6.5. Security Aspects . . . . . . . . . . . . . . . . . . . . . 28 98 6.5.1. Security Context Scope . . . . . . . . . . . . . . . . 28 99 6.5.2. Key Management for Multi-party session . . . . . . . . 29 100 6.5.3. Complexity Implications . . . . . . . . . . . . . . . 29 101 7. Arch-Types . . . . . . . . . . . . . . . . . . . . . . . . . . 29 102 7.1. Single SSRC per Session . . . . . . . . . . . . . . . . . 30 103 7.2. Multiple SSRCs of the Same Media Type . . . . . . . . . . 31 104 7.3. Multiple Sessions for one Media type . . . . . . . . . . . 33 105 7.4. Multiple Media Types in one Session . . . . . . . . . . . 34 106 7.5. Summary . . . . . . . . . . . . . . . . . . . . . . . . . 35 107 8. Summary considerations and guidelines . . . . . . . . . . . . 36 108 8.1. Guidelines . . . . . . . . . . . . . . . . . . . . . . . . 36 109 9. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 37 110 10. Security Considerations . . . . . . . . . . . . . . . . . . . 37 111 11. References . . . . . . . . . . . . . . . . . . . . . . . . . . 37 112 11.1. Normative References . . . . . . . . . . . . . . . . . . . 37 113 11.2. Informative References . . . . . . . . . . . . . . . . . . 38 114 Appendix A. Dismissing Payload Type Multiplexing . . . . . . . . 42 115 Appendix B. Proposals for Future Work . . . . . . . . . . . . . . 43 116 Appendix C. RTP Specification Clarifications . . . . . . . . . . 44 117 C.1. RTCP Reporting from all SSRCs . . . . . . . . . . . . . . 44 118 C.2. RTCP Self-reporting . . . . . . . . . . . . . . . . . . . 45 119 C.3. Combined RTCP Packets . . . . . . . . . . . . . . . . . . 45 120 Appendix D. Signalling considerations . . . . . . . . . . . . . . 45 121 D.1. Signalling Aspects . . . . . . . . . . . . . . . . . . . . 45 122 D.1.1. Session Oriented Properties . . . . . . . . . . . . . 46 123 D.1.2. SDP Prevents Multiple Media Types . . . . . . . . . . 46 124 D.1.3. Signalling Media Stream Usage . . . . . . . . . . . . 47 125 Appendix E. Changes from -01 to -02 . . . . . . . . . . . . . . . 47 126 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . . 48 128 1. Introduction 130 Real-time Transport Protocol (RTP) [RFC3550] is a commonly used 131 protocol for real-time media transport. It is a protocol that 132 provides great flexibility and can support a large set of different 133 applications. RTP has several multiplexing points designed for 134 different purposes. These enable support of multiple media streams 135 and switching between different encoding or packetization of the 136 media. By using multiple RTP sessions, sets of media streams can be 137 structured for efficient processing or identification. Thus the 138 question for any RTP application designer is how to best use the RTP 139 session, the SSRC and the payload type to meet the application's 140 needs. 142 The purpose of this document is to provide clear information about 143 the possibilities of RTP when it comes to multiplexing. The RTP 144 application designer should understand the implications that come 145 from a particular usage of the RTP multiplexing points. The document 146 will recommend against some usages as being unsuitable, in general or 147 for particular purposes. 149 RTP was from the beginning designed for multiple participants in a 150 communication session. This is not restricted to multicast, as some 151 may believe, but also provides functionality over unicast, using 152 either multiple transport flows below RTP or a network node that re- 153 distributes the RTP packets. The re-distributing node can for 154 example be a transport translator (relay) that forwards the packets 155 unchanged, a translator performing media or protocol translation in 156 addition to forwarding, or an RTP mixer that creates new conceptual 157 sources from the received streams. In addition, multiple streams may 158 occur when a single endpoint have multiple media sources, like 159 multiple cameras or microphones that need to be sent simultaneously. 161 This document has been written due to increased interest in more 162 advanced usage of RTP, resulting in questions regarding the most 163 appropriate RTP usage. The limitations in some implementations, RTP/ 164 RTCP extensions, and signalling has also been exposed. It is 165 expected that some limitations will be addressed by updates or new 166 extensions resolving the shortcomings. The authors also hope that 167 clarification on the usefulness of some functionalities in RTP will 168 result in more complete implementations in the future. 170 The document starts with some definitions and then goes into the 171 existing RTP functionalities around multiplexing. Both the desired 172 behaviour and the implications of a particular behaviour depend on 173 which topologies are used, which requires some consideration. This 174 is followed by a discussion of some choices in multiplexing behaviour 175 and their impacts. Some arch-types of RTP usage are discussed. 177 Finally, some recommendations and examples are provided. 179 This document is currently an individual contribution, but it is the 180 intention of the authors that this should become a WG document that 181 objectively describes and provides suitable recommendations for which 182 there is WG consensus. Currently this document only represents the 183 views of the authors. The authors gladly accept any feedback on the 184 document and will be happy to discuss suitable recommendations. 186 2. Definitions 188 2.1. Terminology 190 The following terms and abbreviations are used in this document: 192 Endpoint: A single entity sending or receiving RTP packets. It may 193 be decomposed into several functional blocks, but as long as it 194 behaves a single RTP stack entity it is classified as a single 195 endpoint. 197 Multiparty: A communication situation including multiple end-points. 198 In this document it will be used to refer to situations where more 199 than two end-points communicate. 201 Media Source: The source of a stream of data of one Media Type, It 202 can either be a single media capturing device such as a video 203 camera, a microphone, or a specific output of a media production 204 function, such as an audio mixer, or some video editing function. 205 Sending data from a Media Source may cause multiple RTP sources to 206 send multiple Media Streams. 208 Media Stream: A sequence of RTP packets using a single SSRC that 209 together carries part or all of the content of a specific Media 210 Type from a specific sender source within a given RTP session. 212 RTP Source: The originator or source of a particular Media Stream. 213 Identified using an SSRC in a particular RTP session. An RTP 214 source is the source of a single media stream, and is associated 215 with a single endpoint and a single Media Source. An RTP Source 216 is just called a Source in RFC 3550. 218 Media Sink: A recipient of a Media Stream. The endpoint sinking 219 media are Identified using one or more SSRCs. There may be more 220 than one Media Sink for one RTP source. 222 CNAME: "Canonical name" - identifier associated with one or more RTP 223 sources from a single endpoint. Defined in the RTP specification 224 [RFC3550]. A CNAME identifies a synchronisation context. A CNAME 225 is associated with a single endpoint, although some RTP nodes will 226 use an end-points CNAME on that end-points behalf. An endpoint 227 may use multiple CNAMEs. A CNAME is intended to be globally 228 unique and stable for the full duration of a communication 229 session. [RFC6222][I-D.ietf-avtcore-6222bis] gives updated 230 guidelines for choosing CNAMEs. 232 Media Type: Audio, video, text or data whose form and meaning are 233 defined by a specific real-time application. 235 Multiplex: The operation of taking multiple entities as input, 236 aggregating them onto some common resource while keeping the 237 individual entities addressable such that they can later be fully 238 and unambiguously separated (de-multiplexed) again. 240 RTP Session: As defined by [RFC3550], the endpoints belonging to the 241 same RTP Session are those that share a single SSRC space. That 242 is, those endpoints can see an SSRC identifier transmitted by any 243 one of the other endpoints. An endpoint can receive an SSRC 244 either as SSRC or as CSRC in RTP and RTCP packets. Thus, the RTP 245 Session scope is decided by the endpoints' network interconnection 246 topology, in combination with RTP and RTCP forwarding strategies 247 deployed by endpoints and any interconnecting middle nodes. 249 RTP Session Group: One or more RTP sessions that are used together 250 to perform some function. Examples are multiple RTP sessions used 251 to carry different layers of a layered encoding. In an RTP 252 Session Group, CNAMEs are assumed to be valid across all RTP 253 sessions, and designate synchronisation contexts that can cross 254 RTP sessions. 256 Source: Term that should not be used alone. An RTP Source, as 257 identified by its SSRC, is the source of a single Media Stream; a 258 Media Source can be the source of mutiple Media Streams. 260 SSRC: An RTP 32-bit unsigned integer used as identifier for a RTP 261 Source. 263 CSRC: Contributing Source, A SSRC identifier used in a context, like 264 the RTP headers CSRC list, where it is clear that the Media Source 265 is not the source of the media stream, instead only a contributor 266 to the Media Stream. 268 Signalling: The process of configuring endpoints to participate in 269 one or more RTP sessions. 271 2.2. Subjects Out of Scope 273 This document is focused on issues that affect RTP. Thus, issues 274 that involve signalling protocols, such as whether SIP, Jingle or 275 some other protocol is in use for session configuration, the 276 particular syntaxes used to define RTP session properties, or the 277 constraints imposed by particular choices in the signalling 278 protocols, are mentioned only as examples in order to describe the 279 RTP issues more precisely. 281 This document assumes the applications will use RTCP. While there 282 are such applications that don't send RTCP, they do not conform to 283 the RTP specification, and thus should be regarded as reusing the RTP 284 packet format, not as implementing the RTP protocol. 286 3. RTP Concepts 288 This section describes the existing RTP tools that are particularly 289 important when discussing multiplexing of different media streams. 291 3.1. Session 293 The RTP Session is the highest semantic level in RTP and contains all 294 of the RTP functionality. RTP itself has no normative statements 295 about the relationship between different RTP sessions. 297 Identifier: RTP in itself does not contain any Session identifier, 298 but relies either on the underlying transport or on the used 299 signalling protocol, depending on in which context the identifier 300 is used (e.g. transport or signalling). Due to this, a single RTP 301 Session may have multiple associated identifiers belonging to 302 different contexts. 304 Position: Depending on underlying transport and signalling 305 protocol. For example, when running RTP on top of UDP, an RTP 306 endpoint can identify and delimit an RTP Session from other RTP 307 Sessions through the UDP source and destination transport 308 address, consisting of network address and port number(s). 309 Commonly, RTP and RTCP use separate ports and the destination 310 transport address is in fact an address pair, but in the case 311 of RTP/RTCP multiplex [RFC5761] there is only a single port. 312 Another example is SDP signalling [RFC4566], where the grouping 313 framework [RFC5888] uses an identifier per "m="-line. If there 314 is a one-to-one mapping between "m="-line and RTP Session, that 315 grouping framework identifier can identify a single RTP 316 Session. 318 Usage: Identify separate RTP Sessions. 320 Uniqueness: Globally unique, but identity can only be detected by 321 the general communication context for the specific endpoint. 323 Inter-relation: Depending on the underlying transport and 324 signalling protocol. 326 Special Restrictions: None. 328 A RTP source in an RTP session that changes its source transport 329 address during a session must also choose a new SSRC identifier to 330 avoid being interpreted as a looped source. 332 The set of participants considered part of the same RTP Session is 333 defined by the RTP specification [RFC3550] as those that share a 334 single SSRC space. That is, those participants that can see an SSRC 335 identifier transmitted by any one of the other participants. A 336 participant can receive an SSRC either as SSRC or CSRC in RTP and 337 RTCP packets. Thus, the RTP Session scope is decided by the 338 participants' network interconnection topology, in combination with 339 RTP and RTCP forwarding strategies deployed by endpoints and any 340 interconnecting middle nodes. 342 3.2. SSRC 344 An SSRC identifies a RTP source or a media sink. For end-points that 345 both source and sink media streams its SSRCs are used in both roles. 346 At any given time, a RTP source has one and only one SSRC - although 347 that may change over the lifetime of the RTP source or sink. An RTP 348 Session serves one or more RTP sources. 350 Identifier: Synchronisation Source (SSRC), 32-bit unsigned number. 352 Position: In every RTP and RTCP packet header. May be present in 353 RTCP payload. May be present in SDP signalling. 355 Usage: Identify individual RTP sources and media sinks within an 356 RTP Session. Refer to individual RTP sources and media sinks 357 in RTCP messages and SDP signalling. 359 Uniqueness: Randomly chosen, intended to be globally unique 360 within an RTP Session and not dependent on network address. 361 SSRC value collisions may occur and must be handled as 362 specified in RTP [RFC3550]. 364 Inter-relation: SSRC belonging to the same synchronisation 365 context (originating from the same endpoint), within or between 366 RTP Sessions, are indicated through use of identical SDES CNAME 367 items in RTCP compound packets with those SSRC as originating 368 source. SDP signalling can provide explicit SSRC grouping 369 [RFC5576]. When CNAME is inappropriate or insufficient, there 370 exist a few other methods to relate different SSRC. One such 371 case is session-based RTP retransmission [RFC4588]. In some 372 cases, the same SSRC Identifier value is used to relate streams 373 in two different RTP Sessions, such as in Multi-Session 374 Transmission of scalable video [RFC6190]. 376 Special Restrictions: All RTP implementations must be prepared to 377 use procedures for SSRC collision handling, which results in an 378 SSRC number change. A RTP source that changes its RTP Session 379 identifier (e.g. source transport address) during a session must 380 also choose a new SSRC identifier to avoid being interpreted as 381 looped source. 383 Note that RTP sequence number and RTP timestamp are scoped by SSRC 384 and thus independent between different SSRCs. 386 An SSRC identifier is used by different type of sources as well as 387 sinks: 389 Real Media Source: Connected to a "physical" media source, for 390 example a camera or microphone. 392 Conceptual Media Source: A source with some attributed property 393 generated by some network node, for example a filtering function 394 in an RTP mixer that provides the most active speaker based on 395 some criteria, or a mix representing a set of other sources. 397 Media Sink: A source that does not generate any RTP media stream in 398 itself (e.g. an endpoint or middlebox only receiving in an RTP 399 session), but anyway need a sender SSRC for use as source in RTCP 400 reports. 402 Note that a endpoint that generates more than one media type, e.g. a 403 conference participant sending both audio and video, need not (and 404 commonly should not) use the same SSRC value across RTP sessions. 405 RTCP Compound packets containing the CNAME SDES item is the 406 designated method to bind an SSRC to a CNAME, effectively cross- 407 correlating SSRCs within and between RTP Sessions as coming from the 408 same endpoint. The main property attributed to SSRCs associated with 409 the same CNAME is that they are from a particular synchronisation 410 context and may be synchronised at playback. 412 An RTP receiver receiving a previously unseen SSRC value must 413 interpret it as a new source. It may in fact be a previously 414 existing source that had to change SSRC number due to an SSRC 415 conflict. However, the originator of the previous SSRC should have 416 ended the conflicting source by sending an RTCP BYE for it prior to 417 starting to send with the new SSRC, so the new SSRC is anyway 418 effectively a new source. 420 3.3. CSRC 422 The Contributing Source (CSRC) is not a separate identifier, but an 423 usage of the SSRC identifier. It is optionally included in the RTP 424 header as list of up to 15 contributing RTP sources. CSRC shares the 425 SSRC number space and specifies which set of SSRCs that has 426 contributed to the RTP payload. However, even though each RTP packet 427 and SSRC can be tagged with the contained CSRCs, the media 428 representation of an individual CSRC is in general not possible to 429 extract from the RTP payload since it is typically the result of a 430 media mixing (merge) operation (by an RTP mixer) on the individual 431 media streams corresponding to the CSRC identifiers. The exception 432 is the case when only a single CSRC is indicated as this represent 433 forwarding of a media stream, possibly modified. The RTP header 434 extension for Mixer-to-Client Audio Level Indication [RFC6465] 435 expands on the receivers information about a packet with a CSRC list. 436 Due to these restrictions, CSRC will not be considered a fully 437 qualified multiplex point and will be disregarded in the rest of this 438 document. 440 3.4. Payload Type 442 Each Media Stream utilises one or more encoding formats, identified 443 by the Payload Type. 445 The Payload Type is not a multiplexing point. Appendix A gives some 446 of the many reasons why attempting to use it as a multiplexing point 447 will have bad results. 449 Identifier: Payload Type number. 451 Position: In every RTP header and in signalling. 453 Usage: Identify a specific Media Stream encoding format. The 454 format definition may be taken from [RFC3551] for statically 455 allocated Payload Types, but should be explicitly defined in 456 signalling, such as SDP, both for static and dynamic Payload 457 Types. The term "format" here includes whatever can be 458 described by out-of-band signalling means. In SDP, the term 459 "format" includes media type, RTP timestamp sampling rate, 460 codec, codec configuration, payload format configurations, and 461 various robustness mechanisms such as redundant encodings 462 [RFC2198]. 464 Uniqueness: Scoped by sending endpoint within an RTP Session. To 465 avoid any potential for ambiguity, it is desirable that payload 466 types are unique across all sending endpoints within an RTP 467 session, but this is often not true in practice. All SSRC in 468 an RTP session sent from an single endpoint share the same 469 Payload Types definitions. The RTP Payload Type is designed 470 such that only a single Payload Type is valid at any time 471 instant in the SSRC's RTP timestamp time line, effectively 472 time-multiplexing different Payload Types if any change occurs. 473 Used Payload Type may change on a per-packet basis for an SSRC, 474 for example a speech codec making use of generic Comfort Noise 475 [RFC3389]. 477 Inter-relation: There are some uses where Payload Type numbers 478 need to be unique across RTP Sessions. This is for example the 479 case in Media Decoding Dependency [RFC5583] where Payload Types 480 are used to describe media dependency across RTP Sessions. 481 Another example is session-based RTP retransmission [RFC4588]. 483 Special Restrictions: Using different RTP timestamp clock rates for 484 the RTP Payload Types in use in the same RTP Session have issues 485 such as potential for loss of synchronisation. Payload Type clock 486 rate switching requires some special consideration that is 487 described in the multiple clock rates specification 488 [I-D.ietf-avtext-multiple-clock-rates]. 490 If there is a true need to send multiple Payload Types for the same 491 SSRC that are valid for the same RTP Timestamps, then redundant 492 encodings [RFC2198] can be used. Several additional constraints than 493 the ones mentioned above need to be met to enable this use, one of 494 which is that the combined payload sizes of the different Payload 495 Types must not exceed the transport MTU. 497 Other aspects of RTP payload format use are described in RTP Payload 498 HowTo [I-D.ietf-payload-rtp-howto]. 500 4. Multiple Streams Alternatives 502 The reasons why an endpoint may choose to send multiple media streams 503 are widespread. In the below discussion, please keep in mind that 504 the reasons for having multiple media streams vary and include but 505 are not limited to the following: 507 o Multiple Media Sources 509 o Multiple Media Streams may be needed to represent one Media Source 510 (for instance when using layered encodings) 512 o A Retransmission stream may repeat the content of another Media 513 Stream 515 o An FEC stream may provide material that can be used to repair 516 another Media Stream 518 o Alternative Encodings, for instance different codecs for the same 519 audio stream 521 o Alternative formats, for instance multiple resolutions of the same 522 video stream 524 Thus the choice made due to one reason may not be the choice suitable 525 for another reason. In the above list, the different items have 526 different levels of maturity in the discussion on how to solve them. 527 The clearest understanding is associated with multiple media sources 528 of the same media type. However, all warrant discussion and 529 clarification on how to deal with them. 531 This section reviews the alternatives to enable multi-stream 532 handling. Let's start with describing mechanisms that could enable 533 multiple media streams, independent of the purpose for having 534 multiple streams. 536 Additional SSRC: Each additional Media Stream gets its own SSRC 537 within a RTP Session. 539 Multiple RTP Sessions: Using additional RTP Sessions to handle 540 additional Media Streams. 542 As the below discussion will show, in reality we cannot choose a 543 single one of the two solutions. To utilise RTP well and as 544 efficiently as possible, both are needed. The real issue is finding 545 the right guidance on when to create RTP sessions and when additional 546 SSRCs in an RTP session is the right choice. 548 5. RTP Topologies and Issues 550 The impact of how RTP Multiplex is performed will in general vary 551 with how the RTP Session participants are interconnected, described 552 by RTP Topology [RFC5117] and its intended successor 553 [I-D.westerlund-avtcore-rtp-topologies-update]. 555 5.1. Point to Point 557 Even the most basic use case, denoted Topo-Point-to-Point in 558 [I-D.westerlund-avtcore-rtp-topologies-update], raises a number of 559 considerations that are discussed in detail below (Section 6). They 560 range over such aspects as: 562 o Does my communication peer support RTP as defined with multiple 563 SSRCs? 565 o Do I need network differentiation in form of QoS? 567 o Can the application more easily process and handle the media 568 streams if they are in different RTP sessions? 570 o Do I need to use additional media streams for RTP retransmission 571 or FEC. 573 o etc. 575 The application designer will have to make choices here. The point 576 to point topology can contain one to many RTP sessions with one to 577 many media sources per session, resulting in one or more RTP source 578 (SSRC) per media source. 580 5.2. Translators & Gateways 582 A point to point communication can end up in a situation when the 583 peer it is communicating with is not compatible with the other peer 584 for various reasons: 586 o No common media codec for a media type thus requiring transcoding 588 o Different support for multiple RTP sources and RTP sessions 590 o Usage of different media transport protocols, i.e RTP or other. 592 o Usage of different transport protocols, e.g. UDP, DCCP, TCP 594 o Different security solutions, e.g. IPsec, TLS, DTLS, SRTP with 595 different keying mechanisms. 597 This is in many situations resolved by the inclusion of a translator 598 in-between the two peers, as described by Topo-PtP-Translator in 599 [I-D.westerlund-avtcore-rtp-topologies-update]. The translator's 600 main purpose is to make the peer look to the other peer like 601 something it is compatible with. There may also be other reasons 602 than compatibility to insert a translator in the form of a middlebox 603 or gateway, for example a need to monitor the media streams. If the 604 stream transport characteristics are changed by the translator, 605 appropriate media handling can require thorough understanding of the 606 application logic, specifically any congestion control or media 607 adaptation. 609 5.3. Point to Multipoint Using Multicast 611 This section discusses the Point to Multi-point using Multicast to 612 interconnect the session participants. This includes both Topo-ASM 613 and Topo-SSM in [I-D.westerlund-avtcore-rtp-topologies-update]. 615 Special considerations must be made as multicast is a one to many 616 distribution system. For example, the only practical method for 617 adapting the bit-rate sent towards a given receiver for large groups 618 is to use a set of multicast groups, where each multicast group 619 represents a particular bit-rate. Otherwise the whole group gets 620 media adapted to the participant with the worst conditions. The 621 media encoding is either scalable, where multiple layers can be 622 combined, or simulcast where a single version is selected. By either 623 selecting or combing multicast groups, the receiver can control the 624 bit-rate sent on the path to itself. It is also common that streams 625 that improve transport robustness are sent in their own multicast 626 group to allow for interworking with legacy or to support different 627 levels of protection. 629 The result of this is some common behaviours for RTP multicast: 631 1. Multicast applications use a group of RTP sessions, not one. 632 Each endpoint will need to be a member of a number of RTP 633 sessions in order to perform well. 635 2. Within each RTP session, the number of media sinks is likely to 636 be much larger than the number of RTP sources. 638 3. Multicast applications need signalling functions to identify the 639 relationships between RTP sessions. 641 4. Multicast applications need signalling functions to identify the 642 relationships between SSRCs in different RTP sessions. 644 All multicast configurations share a signalling requirement; all of 645 the participants will need to have the same RTP and payload type 646 configuration. Otherwise, A could for example be using payload type 647 97 as the video codec H.264 while B thinks it is MPEG-2. It should 648 be noted that SDP offer/answer [RFC3264] has issues with ensuring 649 this property. The signalling aspects of multicast are not explored 650 further in this memo. 652 Security solutions for this type of group communications are also 653 challenging. First of all the key-management and the security 654 protocol must support group communication. Source authentication 655 becomes more difficult and requires special solutions. For more 656 discussion on this please review Options for Securing RTP Sessions 657 [I-D.ietf-avtcore-rtp-security-options]. 659 5.4. Point to Multipoint Using an RTP Transport Translator 661 This mode is described as Topo-Translator in 662 [I-D.westerlund-avtcore-rtp-topologies-update]. 664 Transport Translators (Relays) result in an RTP session situation 665 that is very similar to how an ASM group RTP session would behave. 667 One of the most important aspects with the simple relay is that it is 668 only rewriting transport headers, no RTP modifications nor media 669 transcoding occur. The most obvious downside of this basic relaying 670 is that the translator has no control over how many streams need to 671 be delivered to a receiver. Nor can it simply select to deliver only 672 certain streams, as this creates session inconsistencies: If the 673 translator temporarily stops a stream, this prevents some receivers 674 from reporting on it. From the sender's perspective it will look 675 like a transport failure. Applications having needs to stop or 676 switch streams in the central node should consider using an RTP mixer 677 to avoid this issue. 679 The Transport Translator has the same signalling requirement as 680 multicast: All participants must have the same payload type 681 configuration. Most of the ASM security issues also arise here. 682 Some alternative when it comes to solution do exist as there after 683 all exist a central node to communicate with. One that also can 684 enforce some security policies depending on the level of trust placed 685 in the node. 687 5.5. Point to Multipoint Using an RTP Mixer 689 A mixer, described by Topo-Mixer in 690 [I-D.westerlund-avtcore-rtp-topologies-update], is a centralised node 691 that selects or mixes content in a conference to optimise the RTP 692 session so that each endpoint only needs connect to one entity, the 693 mixer. The media sent from the mixer to the end-point can be 694 optimised in different ways. These optimisations include methods 695 like only choosing media from the currently most active speaker or 696 mixing together audio so that only one audio stream is required. 698 Mixers have some downsides, the first is that the mixer must be a 699 trusted node as they either perform media operations or at least 700 repacketize the media. When using SRTP, both media operations and 701 repacketization requires that the mixer verifies integrity, decrypts 702 the content, performs the operation and forms new RTP packets, 703 encrypts and integrity-protects them. This applies to all types of 704 mixers. The second downside is that all these operations and 705 optimisations of the session requires processing. How much depends 706 on the implementation, as will become evident below. 708 A mixer, unlike a pure transport translator, is always application 709 specific: the application logic for stream mixing or stream selection 710 has to be embedded within the mixer, and controlled using application 711 specific signalling. The implementation of a mixer can take several 712 different forms and we will discuss the main themes available that 713 doesn't break RTP. 715 Please note that a Mixer could also contain translator 716 functionalities, like a media transcoder to adjust the media bit-rate 717 or codec used for a particular RTP media stream. 719 6. Multiple Streams Discussion 721 6.1. Introduction 723 Using multiple media streams is a well supported feature of RTP. 724 However, it can be unclear for most implementers or people writing 725 RTP/RTCP applications or extensions attempting to apply multiple 726 streams when it is most appropriate to add an additional SSRC in an 727 existing RTP session and when it is better to use multiple RTP 728 sessions. This section tries to discuss the various considerations 729 needed. The next section then concludes with some guidelines. 731 6.2. RTP/RTCP Aspects 733 This section discusses RTP and RTCP aspects worth considering when 734 selecting between using an additional SSRC and Multiple RTP sessions. 736 6.2.1. The RTP Specification 738 RFC 3550 contains some recommendations and a bullet list with 5 739 arguments for different aspects of RTP multiplexing. Let's review 740 Section 5.2 of [RFC3550], reproduced below: 742 "For efficient protocol processing, the number of multiplexing points 743 should be minimised, as described in the integrated layer processing 744 design principle [ALF]. In RTP, multiplexing is provided by the 745 destination transport address (network address and port number) which 746 is different for each RTP session. For example, in a teleconference 747 composed of audio and video media encoded separately, each medium 748 SHOULD be carried in a separate RTP session with its own destination 749 transport address. 751 Separate audio and video streams SHOULD NOT be carried in a single 752 RTP session and demultiplexed based on the payload type or SSRC 753 fields. Interleaving packets with different RTP media types but 754 using the same SSRC would introduce several problems: 756 1. If, say, two audio streams shared the same RTP session and the 757 same SSRC value, and one were to change encodings and thus 758 acquire a different RTP payload type, there would be no general 759 way of identifying which stream had changed encodings. 761 2. An SSRC is defined to identify a single timing and sequence 762 number space. Interleaving multiple payload types would require 763 different timing spaces if the media clock rates differ and would 764 require different sequence number spaces to tell which payload 765 type suffered packet loss. 767 3. The RTCP sender and receiver reports (see Section 6.4) can only 768 describe one timing and sequence number space per SSRC and do not 769 carry a payload type field. 771 4. An RTP mixer would not be able to combine interleaved streams of 772 incompatible media into one stream. 774 5. Carrying multiple media in one RTP session precludes: the use of 775 different network paths or network resource allocations if 776 appropriate; reception of a subset of the media if desired, for 777 example just audio if video would exceed the available bandwidth; 778 and receiver implementations that use separate processes for the 779 different media, whereas using separate RTP sessions permits 780 either single- or multiple-process implementations. 782 Using a different SSRC for each medium but sending them in the same 783 RTP session would avoid the first three problems but not the last 784 two. 786 On the other hand, multiplexing multiple related sources of the same 787 medium in one RTP session using different SSRC values is the norm for 788 multicast sessions. The problems listed above don't apply: an RTP 789 mixer can combine multiple audio sources, for example, and the same 790 treatment is applicable for all of them. It may also be appropriate 791 to multiplex streams of the same medium using different SSRC values 792 in other scenarios where the last two problems do not apply." 794 Let's consider one argument at a time. The first is an argument for 795 using different SSRC for each individual media stream, which is very 796 applicable. 798 The second argument is advocating against using payload type 799 multiplexing, which still stands as can been seen by the extensive 800 list of issues found in Appendix A. 802 The third argument is yet another argument against payload type 803 multiplexing. 805 The fourth is an argument against multiplexing media streams that 806 require different handling into the same session. As we saw in the 807 discussion of RTP mixers, the RTP mixer has to embed application 808 logic in order to handle streams anyway; the separation of streams 809 according to stream type is just another piece of application logic, 810 which may or may not be appropriate for a particular application. A 811 type of application that can mix different media sources "blindly" is 812 the audio only "telephone" bridge; most other type of application 813 needs application-specific logic to perform the mix correctly. 815 The fifth argument discusses network aspects that we will discuss 816 more below in Section 6.4. It also goes into aspects of 817 implementation, like decomposed endpoints where different processes 818 or inter-connected devices handle different aspects of the whole 819 multi-media session. 821 A summary of RFC 3550's view on multiplexing is to use unique SSRCs 822 for anything that is its own media/packet stream, and to use 823 different RTP sessions for media streams that don't share media type. 824 The first this document support as very valid. The later is one 825 thing which is further discussed in this document as something the 826 application developer needs to make a conscious choice for. 828 6.2.1.1. Different Media Types Recommendations 830 The above quote from RTP [RFC3550] includes a strong recommendation: 832 "For example, in a teleconference composed of audio and video 833 media encoded separately, each medium SHOULD be carried in a 834 separate RTP session with its own destination transport address." 836 It was identified in "Why RTP Sessions Should Be Content Neutral" 837 [I-D.alvestrand-rtp-sess-neutral] that the above statement is poorly 838 supported by any of the motivations provided in the RTP 839 specification. This has resulted in the creation of a specification 840 Multiple Media Types in an RTP Session specification 841 [I-D.ietf-avtcore-multi-media-rtp-session] which intend to update 842 this recommendation. That document has a detailed analysis of the 843 potential issues in having multiple media types in the same RTP 844 session. This document tries to provide an more over arching 845 consideration regarding the usage of RTP session and considers 846 multiple media types in one RTP session as possible choice for the 847 RTP application designer. 849 6.2.2. Multiple SSRCs in a Session 851 Using multiple SSRCs in an RTP session at one endpoint has some 852 unclarities in the RTP specification. These could potentially lead 853 to some interoperability issues as well as some potential significant 854 inefficencies. These are further discussed in "RTP Considerations 855 for Endpoints Sending Multiple Media Streams" 856 [I-D.lennox-avtcore-rtp-multi-stream]. A application designer may 857 need to consider these issues and the impact availability or lack of 858 the optimization in the endpoints has on their application. 860 If an application will become affected by the issues described, using 861 Multiple RTP sessions can mitigate these issues. 863 6.2.3. Handling Varying Sets of Senders 865 In some applications, the set of simultaneously active sources varies 866 within a larger set of session members. A receiver can then possibly 867 try to use a set of decoding chains that is smaller than the number 868 of senders, switching the decoding chains between different senders. 869 As each media decoding chain may contain state, either the receiver 870 must either be able to save the state of swapped-out senders, or the 871 sender must be able to send data that permits the receiver to 872 reinitialise when it resumes activity. 874 This behaviour will cause similar issues independent of Additional 875 SSRC or Multiple RTP session. 877 6.2.4. Cross Session RTCP Requests 879 There currently exists no functionality to make truly synchronised 880 and atomic RTCP messages with some type of request semantics across 881 multiple RTP Sessions. Instead, separate RTCP messages will have to 882 be sent in each session. This gives streams in the same RTP session 883 a slight advantage as RTCP messages for different streams in the same 884 session can be sent in a compound RTCP packet. Thus providing an 885 atomic operation if different modifications of different streams are 886 requested at the same time. 888 When using multiple RTP sessions, the RTCP timing rules in the 889 sessions and the transport aspects, such as packet loss and jitter, 890 prevents a receiver from relying on atomic operations, forcing it to 891 use more robust and forgiving mechanisms. 893 6.2.5. Binding Related Sources 895 A common problem in a number of various RTP extensions has been how 896 to bind related RTP sources and their media streams together. This 897 issue is common to both using additional SSRCs and Multiple RTP 898 sessions. 900 The solutions can be divided into some groups, RTP/RTCP based, 901 Signalling based (SDP), grouping related RTP sessions, and grouping 902 SSRCs within an RTP session. Most solutions are explicit, but some 903 implicit methods have also been applied to the problem. 905 The SDP-based signalling solutions are: 907 SDP Media Description Grouping: The SDP Grouping Framework [RFC5888] 908 uses various semantics to group any number of media descriptions. 909 These has previously been considered primarily as grouping RTP 910 sessions, but this may change. 912 SDP SSRC grouping: Source-Specific Media Attributes in SDP [RFC5576] 913 includes a solution for grouping SSRCs the same way as the 914 Grouping framework groupes Media Descriptions. 916 This supports a lot of use cases. Both solutions have shortcomings 917 in cases where the session's dynamic properties are such that it is 918 difficult or resource consuming to keep the list of related SSRCs up 919 to date. As they are two related but still separated solutions it is 920 not well specified to group SSRCs across multiple RTP sessions and 921 SDP media descriptions. 923 Within RTP/RTCP based solutions when binding to a endpoint or 924 synchronization context, i.e. the CNAME has not be sufficient and one 925 has multiple RTP sessions has been to using the same SSRC value 926 across all the RTP sessions. RTP Retransmission [RFC4588] is 927 multiple RTP session mode, Generic FEC [RFC5109], as well as the RTP 928 payload format for Scalable Video Coding [RFC6190] in Multi Session 929 Transmission (MST) mode uses this method. This method clearly works 930 but might have some downside in RTP sessions with many participating 931 SSRCs. The birthday paradox ensures that if you populate a single 932 session with 9292 SSRCs at random, the chances are approximately 1% 933 that at least one collision will occur. When a collision occur this 934 will force one to change SSRC in all RTP sessions and thus 935 resynchronizing all of them instead of only the single media stream 936 having the collision. 938 It can be noted that Section 8.3 of the RTP Specification [RFC3550] 939 recommends using a single SSRC space across all RTP sessions for 940 layered coding. 942 Another solution that has been applied to binding SSRCs have been an 943 implicit method used by RTP Retransmission [RFC4588] when doing 944 retransmissions in the same RTP session as the source RTP media 945 stream. This issues an RTP retransmission request, and then await a 946 new SSRC carrying the RTP retransmission payload and where that SSRC 947 is from the same CNAME. This limits a requestor to having only one 948 outstanding request on any new source SSRCs per endpoint. 950 There exist no RTP/RTCP based mechanism capable of supporting 951 explicit association accross multiple RTP sessions as well within an 952 RTP session. A proposed solution for handling this issue is 953 [I-D.westerlund-avtext-rtcp-sdes-srcname]. This can potentially be 954 part of an SDP based solution also by reusing the same identifiers 955 and name space. 957 6.2.6. Forward Error Correction 959 There exist a number of Forward Error Correction (FEC) based schemes 960 for how to reduce the packet loss of the original streams. Most of 961 the FEC schemes will protect a single source flow. The protection is 962 achieved by transmitting a certain amount of redundant information 963 that is encoded such that it can repair one or more packet loss over 964 the set of packets they protect. This sequence of redundant 965 information also needs to be transmitted as its own media stream, or 966 in some cases instead of the original media stream. Thus many of 967 these schemes create a need for binding the related flows as 968 discussed above. They also create additional flows that need to be 969 transported. Looking at the history of these schemes, there is both 970 schemes using multiple SSRCs and multiple RTP sessions, and some 971 schemes that support both modes of operation. 973 Using multiple RTP sessions supports the case where some set of 974 receivers may not be able to utilise the FEC information. By placing 975 it in a separate RTP session, it can easily be ignored. 977 In usages involving multicast, having the FEC information on its own 978 multicast group, and therefore in its own RTP session, allows for 979 flexibility, for example when using Rapid Acquisition of Multicast 980 Groups (RAMS) [RFC6285]. During the RAMS burst where data is 981 received over unicast and where it is possible to combine with 982 unicast based retransmission [RFC4588], there is no need to burst the 983 FEC data related to the burst of the source media streams needed to 984 catch up with the multicast group. This saves bandwidth to the 985 receiver during the burst, enabling quicker catch up. When the 986 receiver has caught up and joins the multicast group(s) for the 987 source, it can at the same time join the multicast group with the FEC 988 information. Having the source stream and the FEC in separate groups 989 allows for easy separation in the Burst/Retransmission Source (BRS) 990 without having to individually classify packets. 992 6.2.7. Transport Translator Sessions 994 A basic Transport Translator relays any incoming RTP and RTCP packets 995 to the other participants. The main difference between Additional 996 SSRCs and Multiple RTP Sessions resulting from this use case is that 997 with Additional SSRCs it is not possible for a particular session 998 participant to decide to receive a subset of media streams. When 999 using separate RTP sessions for the different sets of media streams, 1000 a single participant can choose to leave one of the sessions but not 1001 the other. 1003 6.3. Interworking 1005 There are several different kinds of interworking, and this section 1006 discusses two related ones. The interworking between different 1007 applications and the implications of potentially different choices of 1008 usage of RTP's multiplexing points. The second topic relates to what 1009 limitations may have to be considered working with some legacy 1010 applications. 1012 6.3.1. Types of Interworking 1014 It is not uncommon that applications or services of similar usage, 1015 especially the ones intended for interactive communication, ends up 1016 in a situation where one want to interconnect two or more of these 1017 applications. 1019 In these cases one ends up in a situation where one might use a 1020 gateway to interconnect applications. This gateway then needs to 1021 change the multiplexing structure or adhere to limitations in each 1022 application. 1024 There are two fundamental approaches to gatewaying: RTP bridging, 1025 where the gateway acts as an RTP Translator, and the two applications 1026 are members of the same RTP session, and RTP termination, where there 1027 are independent RTP sessions running from each interconnected 1028 application to the gateway. 1030 6.3.2. RTP Translator Interworking 1032 From an RTP perspective the RTP Translator approach could work if all 1033 the applications are using the same codecs with the same payload 1034 types, have made the same multiplexing choices, have the same 1035 capabilities in number of simultaneous media streams combined with 1036 the same set of RTP/RTCP extensions being supported. Unfortunately 1037 this may not always be true. 1039 When one is gatewaying via an RTP Translator, a natural requirement 1040 is that the two applications being interconnected must use the same 1041 approach to multiplexing. Furthermore, if one of the applications is 1042 capable of working in several modes (such as being able to use 1043 Additional SSRCs or Multiple RTP sessions at will), and the other one 1044 is not, successful interconnection depends on locking the more 1045 flexible application into the operating mode where interconnection 1046 can be successful, even if no participants using the less flexible 1047 application are present when the RTP sessions are being created. 1049 6.3.3. Gateway Interworking 1051 When one terminates RTP sessions at the gateway, there are certain 1052 tasks that the gateway must carry out: 1054 o Generating appropriate RTCP reports for all media streams 1055 (possibly based on incoming RTCP reports), originating from SSRCs 1056 controlled by the gateway. 1058 o Handling SSRC collision resolution in each application's RTP 1059 sessions. 1061 o Signalling, choosing and policing appropriate bit-rates for each 1062 session. 1064 If either of the applications has any security applied, e.g. in the 1065 form of SRTP, the gateway must be able to decrypt incoming packets 1066 and re-encrypt them in the other application's security context. 1067 This is necessary even if all that's required is a simple remapping 1068 of SSRC numbers. If this is done, the gateway also needs to be a 1069 member of the security contexts of both sides, of course. 1071 Other tasks a gateway may need to apply include transcoding (for 1072 incompatible codec types), rescaling (for incompatible video size 1073 requirements), suppression of content that is known not to be handled 1074 in the destination application, or the addition or removal of 1075 redundancy coding or scalability layers to fit the need of the 1076 destination domain. 1078 From the above, we can see that the gateway needs to have an intimate 1079 knowledge of the application requirements; a gateway is by its nature 1080 application specific, not a commodity product. 1082 This fact reveals the potential for these gateways to block evolution 1083 of the applications by blocking unknown RTP and RTCP extensions that 1084 the regular application has been extended with. 1086 If one uses security functions, like SRTP, they can as seen above 1087 incur both additional risk due to the gateway needing to be in 1088 security association between the endpoints, unless the gateway is on 1089 the transport level, and additional complexities in form of the 1090 decrypt-encrypt cycles needed for each forwarded packet. SRTP, due 1091 to its keying structure, also requires that each RTP session must 1092 have different master keys, as use of the same key in two RTP 1093 sessions can result in two-time pads that completely breaks the 1094 confidentiality of the packets. 1096 6.3.4. Multiple SSRC Legacy Considerations 1098 Historically, the most common RTP use cases have been point to point 1099 Voice over IP (VoIP) or streaming applications, commonly with no more 1100 than one media source per endpoint and media type (typically audio 1101 and video). Even in conferencing applications, especially voice 1102 only, the conference focus or bridge has provided a single stream 1103 with a mix of the other participants to each participant. It is also 1104 common to have individual RTP sessions between each endpoint and the 1105 RTP mixer, meaning that the mixer functions as an RTP-terminating 1106 gateway. 1108 When establishing RTP sessions that may contain endpoints that aren't 1109 updated to handle multiple streams following these recommendations, a 1110 particular application can have issues with multiple SSRCs within a 1111 single session. These issues include: 1113 1. Need to handle more than one stream simultaneously rather than 1114 replacing an already existing stream with a new one. 1116 2. Be capable of decoding multiple streams simultaneously. 1118 3. Be capable of rendering multiple streams simultaneously. 1120 This indicates that gateways attempting to interconnect to this class 1121 of devices must make sure that only one media stream of each type 1122 gets delivered to the endpoint if it's expecting only one, and that 1123 the multiplexing format is what the device expects. It is highly 1124 unlikely that RTP translator-based interworking can be made to 1125 function successfully in such a context. 1127 6.4. Network Aspects 1129 The multiplexing choice has impact on network level mechanisms that 1130 need to be considered by the implementor. 1132 6.4.1. Quality of Service 1134 When it comes to Quality of Service mechanisms, they are either flow 1135 based or marking based. RSVP [RFC2205] is an example of a flow based 1136 mechanism, while Diff-Serv [RFC2474] is an example of a Marking based 1137 one. For a marking based scheme, the method of multiplexing will not 1138 affect the possibility to use QoS. 1140 However, for a flow based scheme there is a clear difference between 1141 the methods. Additional SSRC will result in all media streams being 1142 part of the same 5-tuple (protocol, source address, destination 1143 address, source port, destination port) which is the most common 1144 selector for flow based QoS. Thus, separation of the level of QoS 1145 between media streams is not possible. That is however possible when 1146 using multiple RTP sessions, where each media stream for which a 1147 separate QoS handling is desired can be in a different RTP session 1148 that can be sent over different 5-tuples. 1150 6.4.2. NAT and Firewall Traversal 1152 In today's network there exist a large number of middleboxes. The 1153 ones that normally have most impact on RTP are Network Address 1154 Translators (NAT) and Firewalls (FW). 1156 Below we analyze and comment on the impact of requiring more 1157 underlying transport flows in the presence of NATs and Firewalls: 1159 End-Point Port Consumption: A given IP address only has 65536 1160 available local ports per transport protocol for all consumers of 1161 ports that exist on the machine. This is normally never an issue 1162 for an end-user machine. It can become an issue for servers that 1163 handle large number of simultaneous streams. However, if the 1164 application uses ICE to authenticate STUN requests, a server can 1165 serve multiple endpoints from the same local port, and use the 1166 whole 5-tuple (source and destination address, source and 1167 destination port, protocol) as identifier of flows after having 1168 securely bound them to the remote endpoint address using the STUN 1169 request. In theory the minimum number of media server ports 1170 needed are the maximum number of simultaneous RTP Sessions a 1171 single endpoint may use. In practice, implementation will 1172 probably benefit from using more server ports to simplify 1173 implementation or avoid performance bottlenecks. 1175 NAT State: If an endpoint sits behind a NAT, each flow it generates 1176 to an external address will result in a state that has to be kept 1177 in the NAT. That state is a limited resource. In home or Small 1178 Office/Home Office (SOHO) NATs, memory or processing are usually 1179 the most limited resources. For large scale NATs serving many 1180 internal endpoints, available external ports are likely the scarce 1181 resource. Port limitations is primarily a problem for larger 1182 centralised NATs where endpoint independent mapping requires each 1183 flow to use one port for the external IP address. This affects 1184 the maximum number of internal users per external IP address. 1185 However, it is worth pointing out that a real-time video 1186 conference session with audio and video is likely using less than 1187 10 UDP flows, compared to certain web applications that can use 1188 100+ TCP flows to various servers from a single browser instance. 1190 NAT Traversal Excess Time: Making the NAT/FW traversal takes a 1191 certain amount of time for each flow. It also takes time in a 1192 phase of communication between accepting to communicate and the 1193 media path being established which is fairly critical. The best 1194 case scenario for how much extra time it takes after finding the 1195 first valid candidate pair following the specified ICE procedures 1196 are: 1.5*RTT + Ta*(Additional_Flows-1), where Ta is the pacing 1197 timer, which ICE specifies to be no smaller than 20 ms. That 1198 assumes a message in one direction, and then an immediate 1199 triggered check back. The reason it isn't more, is that ICE first 1200 finds one candidate pair that works prior to attempting to 1201 establish multiple flows. Thus, there is no extra time until one 1202 has found a working candidate pair. Based on that working pair 1203 the needed extra time is to in parallel establish the, in most 1204 cases 2-3, additional flows. However, packet loss causes extra 1205 delays, at least 100 ms, which is the minimal retransmission timer 1206 for ICE. 1208 NAT Traversal Failure Rate: Due to the need to establish more than a 1209 single flow through the NAT, there is some risk that establishing 1210 the first flow succeeds but that one or more of the additional 1211 flows fail. The risk that this happens is hard to quantify, but 1212 it should be fairly low as one flow from the same interfaces has 1213 just been successfully established. Thus only rare events such as 1214 NAT resource overload, or selecting particular port numbers that 1215 are filtered etc, should be reasons for failure. 1217 Deep Packet Inspection and Multiple Streams: Firewalls differ in how 1218 deeply they inspect packets. There exist some potential that 1219 deeply inspecting firewalls will have similar legacy issues with 1220 multiple SSRCs as some stack implementations. 1222 Additional SSRC keeps the additional media streams within one RTP 1223 Session and transport flow and does not introduce any additional NAT 1224 traversal complexities per media stream. This can be compared with 1225 normally one or two additional transport flows per RTP session when 1226 using multiple RTP sessions. Additional lower layer transport flows 1227 will be required, unless an explicit de-multiplexing layer is added 1228 between RTP and the transport protocol. A proposal for how to 1229 multiplex multiple RTP sessions over the same single lower layer 1230 transport exist in [I-D.westerlund-avtcore-transport-multiplexing]. 1232 6.4.3. Multicast 1234 Multicast groups provides a powerful semantics for a number of real- 1235 time applications, especially the ones that desire broadcast-like 1236 behaviours with one endpoint transmitting to a large number of 1237 receivers, like in IPTV. But that same semantics do result in a 1238 certain number of limitations. 1240 One limitation is that for any group, sender side adaptation to the 1241 actual receiver properties causes degradation for all participants to 1242 what is supported by the receiver with the worst conditions among the 1243 group participants. In most cases this is not acceptable. Instead 1244 various receiver based solutions are employed to ensure that the 1245 receivers achieve best possible performance. By using scalable 1246 encoding and placing each scalability layer in a different multicast 1247 group, the receiver can control the amount of traffic it receives. 1248 To have each scalability layer on a different multicast group, one 1249 RTP session per multicast group is used. 1251 RTP can't function correctly if media streams sent over different 1252 multicast groups where considered part of the same RTP session. 1253 First of all the different layers needs different SSRCs or the 1254 sequence number space seen for a receiver of any sub set of the 1255 layers would have sender side holes. Thus triggering packet loss 1256 reactions. Also any RTCP reporting of such a session would be non 1257 consistent and making it difficult for the sender to determine the 1258 sessions actual state. 1260 Thus it appears easiest and most straightforward to use multiple RTP 1261 sessions. In addition, the transport flow considerations in 1262 multicast are a bit different from unicast. First of all there is no 1263 shortage of port space, as each multicast group has its own port 1264 space. 1266 6.4.4. Multiplexing multiple RTP Session on a Single Transport 1268 For applications that doesn't need flow based QoS and like to save 1269 ports and NAT/FW traversal costs and where usage of multiple media 1270 types in one RTP session is not suitable, there is a proposal for how 1271 to achieve multiplexing of multiple RTP sessions over the same lower 1272 layer transport [I-D.westerlund-avtcore-transport-multiplexing]. 1273 Using such a solution would allow Multiple RTP session without most 1274 of the perceived downsides of Multiple RTP sessions creating a need 1275 for additional transport flows. 1277 6.5. Security Aspects 1279 When dealing with point-to-point, 2-member RTP sessions only, there 1280 are few security issues that are relevant to the choice of having one 1281 RTP session or multiple RTP sessions. However, there are a few 1282 aspects of multiparty sessions that might warrant consideration. For 1283 general information of possible methods of securing RTP, please 1284 review RTP Security Options [I-D.ietf-avtcore-rtp-security-options]. 1286 6.5.1. Security Context Scope 1288 When using SRTP [RFC3711] the security context scope is important and 1289 can be a necessary differentiation in some applications. As SRTP's 1290 crypto suites (so far) is built around symmetric keys, the receiver 1291 will need to have the same key as the sender. This results in that 1292 no one in a multi-party session can be certain that a received packet 1293 really was sent by the claimed sender or by another party having 1294 access to the key. In most cases this is a sufficient security 1295 property, but there are a few cases where this does create 1296 situations. 1298 The first case is when someone leaves a multi-party session and one 1299 wants to ensure that the party that left can no longer access the 1300 media streams. This requires that everyone re-keys without 1301 disclosing the keys to the excluded party. 1303 A second case is when using security as an enforcing mechanism for 1304 differentiation. Take for example a scalable layer or a high quality 1305 simulcast version which only premium users are allowed to access. 1306 The mechanism preventing a receiver from getting the high quality 1307 stream can be based on the stream being encrypted with a key that 1308 user can't access without paying premium, having the key-management 1309 limit access to the key. 1311 SRTP [RFC3711] has not special functions for dealing with different 1312 sets of master keys for different SSRCs. The key-management 1313 functions has different capabilities to establish different set of 1314 keys, normally on a per end-point basis. DTLS-SRTP [RFC5764] and 1315 Security Descriptions [RFC4568] for example establish different keys 1316 for outgoing and incoming traffic from an end-point. This key usage 1317 must be written into the cryptographic context, possibly associated 1318 with different SSRCs. 1320 6.5.2. Key Management for Multi-party session 1322 Performing key-management for multi-party session can be a challenge. 1323 This section considers some of the issues. 1325 Multi-party sessions, such as transport translator based sessions and 1326 multicast sessions, cannot use Security Description [RFC4568] nor 1327 DTLS-SRTP [RFC5764] without an extension as each endpoint provides 1328 its set of keys. In centralised conference, the signalling 1329 counterpart is a conference server and the media plane unicast 1330 counterpart (to which DTLS messages would be sent) is the transport 1331 translator. Thus an extension like Encrypted Key Transport 1332 [I-D.ietf-avt-srtp-ekt] is needed or a MIKEY [RFC3830] based solution 1333 that allows for keying all session participants with the same master 1334 key. 1336 6.5.3. Complexity Implications 1338 The usage of security functions can surface complexity implications 1339 of the choice of multiplexing and topology. This becomes especially 1340 evident in RTP topologies having any type of middlebox that processes 1341 or modifies RTP/RTCP packets. Where there is very small overhead for 1342 an RTP translator or mixer to rewrite an SSRC value in the RTP packet 1343 of an unencrypted session, the cost of doing it when using 1344 cryptographic security functions is higher. For example if using 1345 SRTP [RFC3711], the actual security context and exact crypto key are 1346 determined by the SSRC field value. If one changes it, the 1347 encryption and authentication tag must be performed using another 1348 key. Thus changing the SSRC value implies a decryption using the old 1349 SSRC and its security context followed by an encryption using the new 1350 one. 1352 7. Arch-Types 1354 This section discusses some arch-types of how RTP multiplexing can be 1355 used in applications to achieve certain goals and a summary of their 1356 implications. For each arch-type there is discussion of benefits and 1357 downsides. 1359 7.1. Single SSRC per Session 1361 In this arch-type each endpoint in a point-to-point session has only 1362 a single SSRC, thus the RTP session contains only two SSRCs, one 1363 local and one remote. This session can be used both unidirectional, 1364 i.e. only a single media stream or bi-directional, i.e. both 1365 endpoints have one media stream each. If the application needs 1366 additional media flows between the endpoints, they will have to 1367 establish additional RTP sessions. 1369 The Pros: 1371 1. This arch-type has great legacy interoperability potential as it 1372 will not tax any RTP stack implementations. 1374 2. The signalling has good possibilities to negotiate and describe 1375 the exact formats and bit-rates for each media stream, especially 1376 using today's tools in SDP. 1378 3. It does not matter if usage or purpose of the media stream is 1379 signalled on media stream level or session level as there is no 1380 difference. 1382 4. It is possible to control security association per RTP session 1383 with current key-management. 1385 The Cons: 1387 a. The number of required RTP sessions grows directly in proportion 1388 with the number of media streams, which has the implications: 1390 * Linear growth of the amount of NAT/FW state with number of 1391 media streams. 1393 * Increased delay and resource consumption from NAT/FW 1394 traversal. 1396 * Likely larger signalling message and signalling processing 1397 requirement due to the amount of session related information. 1399 * Higher potential for a single media stream to fail during 1400 transport between the endpoints. 1402 b. When the number of RTP sessions grows, the amount of explicit 1403 state for relating media stream also grows, linearly or possibly 1404 exponentially, depending on how the application needs to relate 1405 media streams. 1407 c. The port consumption may become a problem for centralised 1408 services, where the central node's port consumption grows rapidly 1409 with the number of sessions. 1411 d. For applications where the media streams are highly dynamic in 1412 their usage, i.e. entering and leaving, the amount of signalling 1413 can grow high. Issues arising from the timely establishment of 1414 additional RTP sessions can also arise. 1416 e. Cross session RTCP requests needs is likely to exist and may 1417 cause issues. 1419 f. If the same SSRC value is reused in multiple RTP sessions rather 1420 than being randomly chosen, interworking with applications that 1421 uses another multiplexing structure than this application will 1422 have issues and require SSRC translation. 1424 g. Cannot be used with Any Source Multicast (ASM) as one cannot 1425 guarantee that only two endpoints participate as packet senders. 1426 Using SSM, it is possible to restrict to these requirements if no 1427 RTCP feedback is injected back into the SSM group. 1429 h. For most security mechanisms, each RTP session or transport flow 1430 requires individual key-management and security association 1431 establishment thus increasing the overhead. 1433 RTP applications that need to inter-work with legacy RTP 1434 applications, like VoIP and video conferencing, can potentially 1435 benefit from this structure. However, a large number of media 1436 descriptions in SDP can also run into issues with existing 1437 implementations. For any application needing a larger number of 1438 media flows, the overhead can become very significant. This 1439 structure is also not suitable for multi-party sessions, as any given 1440 media stream from each participant, although having same usage in the 1441 application, must have its own RTP session. In addition, the dynamic 1442 behaviour that can arise in multi-party applications can tax the 1443 signalling system and make timely media establishment more difficult. 1445 7.2. Multiple SSRCs of the Same Media Type 1447 In this arch-type, each RTP session serves only a single media type. 1448 The RTP session can contain multiple media streams, either from a 1449 single endpoint or due to multiple endpoints. This commonly creates 1450 a low number of RTP sessions, typically only two one for audio and 1451 one for video with a corresponding need for two listening ports when 1452 using RTP and RTCP multiplexing. 1454 The Pros: 1456 1. Low number of RTP sessions needed compared to single SSRC case. 1457 This implies: 1459 * Reduced NAT/FW state 1461 * Lower NAT/FW Traversal Cost in both processing and delay. 1463 2. Allows for early de-multiplexing in the processing chain in RTP 1464 applications where all media streams of the same type have the 1465 same usage in the application. 1467 3. Works well with media type de-composite endpoints. 1469 4. Enables Flow-based QoS with different prioritisation between 1470 media types. 1472 5. For applications with dynamic usage of media streams, i.e. they 1473 come and go frequently, having much of the state associated with 1474 the RTP session rather than an individual SSRC can avoid the need 1475 for in-session signalling of meta-information about each SSRC. 1477 6. Low overhead for security association establishment. 1479 The Cons: 1481 a. May have some need for cross session RTCP requests for things 1482 that affect both media types in an asynchronous way. 1484 b. Some potential for concern with legacy implementations that does 1485 not support the RTP specification fully when it comes to handling 1486 multiple SSRC per endpoint. 1488 c. Will not be able to control security association for sets of 1489 media streams within the same media type with today's key- 1490 management mechanisms, only between SDP media descriptions. 1492 For RTP applications where all media streams of the same media type 1493 share same usage, this structure provides efficiency gains in amount 1494 of network state used and provides more faith sharing with other 1495 media flows of the same type. At the same time, it is still 1496 maintaining almost all functionalities when it comes to negotiation 1497 in the signalling of the properties for the individual media type and 1498 also enabling flow based QoS prioritisation between media types. It 1499 handles multi-party session well, independently of multicast or 1500 centralised transport distribution, as additional sources can 1501 dynamically enter and leave the session. 1503 7.3. Multiple Sessions for one Media type 1505 In this arch-type one goes one step further than in the above 1506 (Section 7.2) by using multiple RTP sessions also for a single media 1507 type. The main reason for going in this direction is that the RTP 1508 application needs separation of the media streams due to their usage. 1509 Some typical reasons for going to this arch-type are scalability over 1510 multicast, simulcast, need for extended QoS prioritisation of media 1511 streams due to their usage in the application, or the need for fine 1512 granular signalling using today's tools. 1514 The Pros: 1516 1. More suitable for Multicast usage where receivers can 1517 individually select which RTP sessions they want to participate 1518 in, assuming each RTP session has its own multicast group. 1520 2. Detailed indication of the application's usage of the media 1521 stream, where multiple different usages exist. 1523 3. Less need for SSRC specific explicit signalling for each media 1524 stream and thus reduced need for explicit and timely signalling. 1526 4. Enables detailed QoS prioritisation for flow based mechanisms. 1528 5. Works well with de-composite endpoints. 1530 6. Handles dynamic usage of media streams well. 1532 7. For transport translator based multi-party sessions, this 1533 structure allows for improved control of which type of media 1534 streams an endpoint receives. 1536 8. The scope for who is included in a security association can be 1537 structured around the different RTP sessions, thus enabling such 1538 functionality with existing key-management. 1540 The Cons: 1542 a. Increases the amount of RTP sessions compared to Multiple SSRCs 1543 of the Same Media Type. 1545 b. Increased amount of session configuration state. 1547 c. May need synchronised cross-session RTCP requests and require 1548 some consideration due to this. 1550 d. For media streams that are part of scalability, simulcast or 1551 transport robustness it will be needed to bind sources, which 1552 must support multiple RTP sessions. 1554 e. Some potential for concern with legacy implementations that does 1555 not support the RTP specification fully when it comes to handling 1556 multiple SSRC per endpoint. 1558 f. Higher overhead for security association establishment. 1560 g. If the applications need finer control than on media type level 1561 over which session participants that are included in different 1562 sets of security associations, most of today's key-management 1563 will have difficulties establishing such a session. 1565 For more complex RTP applications that have several different usages 1566 for media streams of the same media type and / or uses scalability or 1567 simulcast, this solution can enable those functions at the cost of 1568 increased overhead associated with the additional sessions. This 1569 type of structure is suitable for more advanced applications as well 1570 as multicast based applications requiring differentiation to 1571 different participants. 1573 7.4. Multiple Media Types in one Session 1575 This arch-type is to use a single RTP session for multiple different 1576 media types, like audio and video, and possibly also transport 1577 robustness mechanisms like FEC or Retransmission. Each media stream 1578 will use its own SSRC and a given SSRC value from a particular 1579 endpoint will never use the SSRC for more than a single media type. 1581 The Pros: 1583 1. Single RTP session which implies: 1585 * Minimal NAT/FW state. 1587 * Minimal NAT/FW Traversal Cost. 1589 * Fate-sharing for all media flows. 1591 2. Enables separation of the different media types based on the 1592 payload types so media type specific endpoint or central 1593 processing can still be supported despite single session. 1595 3. Can handle dynamic allocations of media streams well on an RTP 1596 level. Depends on the application's needs for explicit 1597 indication of the stream usage and how timely that can be 1598 signalled. 1600 4. Minimal overhead for security association establishment. 1602 The Cons: 1604 a. Less suitable for interworking with other applications that uses 1605 individual RTP sessions per media type or multiple sessions for a 1606 single media type, due to need of SSRC translation. 1608 b. Negotiation of bandwidth for the different media types is 1609 currently not possible in SDP. This requires SDP extensions to 1610 enable payload or source specific bandwidth. Likely to be a 1611 problem due to media type asymmetry in required bandwidth. 1613 c. Not suitable for de-composite end-points as it requires higher 1614 bandwidth and processing. 1616 d. Flow based QoS cannot provide separate treatment to some media 1617 streams compared to other in the single RTP session. 1619 e. If there is significant asymmetry between the media streams RTCP 1620 reporting needs, there are some challenges in configuration and 1621 usage to avoid wasting RTCP reporting on the media stream that 1622 does not need that frequent reporting. 1624 f. Not suitable for applications where some receivers like to 1625 receive only a subset of the media streams, especially if 1626 multicast or transport translator is being used. 1628 g. Additional concern with legacy implementations that does not 1629 support the RTP specification fully when it comes to handling 1630 multiple SSRC per endpoint, as also multiple simultaneous media 1631 types needs to be handled. 1633 h. If the applications need finer control over which session 1634 participants that are included in different sets of security 1635 associations, most key-management will have difficulties 1636 establishing such a session. 1638 7.5. Summary 1640 There are some clear relations between these arch-types. Both the 1641 "single SSRC per RTP session" and the "multiple media types in one 1642 session" are cases which require full explicit signalling of the 1643 media stream relations. However, they operate on two different 1644 levels where the first primarily enables session level binding, and 1645 the second needs to do it all on SSRC level. From another 1646 perspective, the two solutions are the two extreme points when it 1647 comes to number of RTP sessions required. 1649 The two other arch-types "Multiple SSRCs of the Same Media Type" and 1650 "Multiple Sessions for one Media Type" are examples of two other 1651 cases that first of all allows for some implicit mapping of the role 1652 or usage of the media streams based on which RTP session they appear 1653 in. It thus potentially allows for less signalling and in particular 1654 reduced need for real-time signalling in dynamic sessions. They also 1655 represent points in between the first two when it comes to amount of 1656 RTP sessions established, i.e. representing an attempt to reduce the 1657 amount of sessions as much as possible without compromising the 1658 functionality the session provides both on network level and on 1659 signalling level. 1661 8. Summary considerations and guidelines 1663 8.1. Guidelines 1665 This section contains a number of recommendations for implementors or 1666 specification writers when it comes to handling multi-stream. 1668 Do not Require the same SSRC across Sessions: As discussed in 1669 Section 6.2.5 there exist drawbacks in using the same SSRC in 1670 multiple RTP sessions as a mechanism to bind related media streams 1671 together. It is instead recommended that a mechanism to 1672 explicitly signal the relation is used, either in RTP/RTCP or in 1673 the used signalling mechanism that establishes the RTP session(s). 1675 Use additional SSRCs additional Media Sources: In the cases an RTP 1676 endpoint needs to transmit additional media streams of the same 1677 media type in the application, with the same processing 1678 requirements at the network and RTP layers, it is recommended to 1679 send them as additional SSRCs in the same RTP session. For 1680 example a telepresence room where there are three cameras, and 1681 each camera captures 2 persons sitting at the table, sending each 1682 camera as its own SSRC within a single RTP session is recommended. 1684 Use additional RTP sessions for streams with different requirements: 1685 When media streams have different processing requirements from the 1686 network or the RTP layer at the endpoints, it is recommended that 1687 the different types of streams are put in different RTP sessions. 1688 This includes the case where different participants want different 1689 subsets of the set of RTP streams. 1691 When using multiple RTP Sessions use grouping: When using Multiple 1692 RTP session solutions, it is recommended to be explicitly group 1693 the involved RTP sessions when needed using the signalling 1694 mechanism, for example The Session Description Protocol (SDP) 1695 Grouping Framework. [RFC5888], using some appropriate grouping 1696 semantics. 1698 RTP/RTCP Extensions May Support Additional SSRCs as well as Multiple 1699 RTP sessions: When defining an RTP or RTCP extension, the creator 1700 needs to consider if this extension is applicable to usage with 1701 additional SSRCs and Multiple RTP sessions. Any extension 1702 intended to be generic is recommended to support both. 1703 Applications that are not as generally applicable will have to 1704 consider if interoperability is better served by defining a single 1705 solution or providing both options. 1707 Transport Support Extensions: When defining new RTP/RTCP extensions 1708 intended for transport support, like the retransmission or FEC 1709 mechanisms, they are recommended to include support for both 1710 additional SSRCs and multiple RTP sessions so that application 1711 developers can choose freely from the set of mechanisms without 1712 concerning themselves with which of the multiplexing choices a 1713 particular solution supports. 1715 9. IANA Considerations 1717 This document makes no request of IANA. 1719 Note to RFC Editor: this section may be removed on publication as an 1720 RFC. 1722 10. Security Considerations 1724 There is discussion of the security implications of choosing SSRC vs 1725 Multiple RTP session in Section 6.5. 1727 11. References 1729 11.1. Normative References 1731 [RFC3550] Schulzrinne, H., Casner, S., Frederick, R., and V. 1732 Jacobson, "RTP: A Transport Protocol for Real-Time 1733 Applications", STD 64, RFC 3550, July 2003. 1735 11.2. Informative References 1737 [ALF] Clark, D. and D. Tennenhouse, "Architectural 1738 Considerations for a New Generation of Protocols", SIGCOMM 1739 Symposium on Communications Architectures and 1740 Protocols (Philadelphia, Pennsylvania), pp. 200--208, IEEE 1741 Computer Communications Review, Vol. 20(4), 1742 September 1990. 1744 [I-D.alvestrand-rtp-sess-neutral] 1745 Alvestrand, H., "Why RTP Sessions Should Be Content 1746 Neutral", draft-alvestrand-rtp-sess-neutral-01 (work in 1747 progress), June 2012. 1749 [I-D.ietf-avt-srtp-ekt] 1750 Wing, D., McGrew, D., and K. Fischer, "Encrypted Key 1751 Transport for Secure RTP", draft-ietf-avt-srtp-ekt-03 1752 (work in progress), October 2011. 1754 [I-D.ietf-avtcore-6222bis] 1755 Rescorla, E. and A. Begen, "Guidelines for Choosing RTP 1756 Control Protocol (RTCP) Canonical Names (CNAMEs)", 1757 draft-ietf-avtcore-6222bis-00 (work in progress), 1758 December 2012. 1760 [I-D.ietf-avtcore-multi-media-rtp-session] 1761 Westerlund, M., Perkins, C., and J. Lennox, "Multiple 1762 Media Types in an RTP Session", 1763 draft-ietf-avtcore-multi-media-rtp-session-01 (work in 1764 progress), October 2012. 1766 [I-D.ietf-avtcore-rtp-security-options] 1767 Westerlund, M. and C. Perkins, "Options for Securing RTP 1768 Sessions", draft-ietf-avtcore-rtp-security-options-01 1769 (work in progress), October 2012. 1771 [I-D.ietf-avtext-multiple-clock-rates] 1772 Petit-Huguenin, M. and G. Zorn, "Support for Multiple 1773 Clock Rates in an RTP Session", 1774 draft-ietf-avtext-multiple-clock-rates-08 (work in 1775 progress), November 2012. 1777 [I-D.ietf-mmusic-sdp-bundle-negotiation] 1778 Holmberg, C., Alvestrand, H., and C. Jennings, 1779 "Multiplexing Negotiation Using Session Description 1780 Protocol (SDP) Port Numbers", 1781 draft-ietf-mmusic-sdp-bundle-negotiation-03 (work in 1782 progress), February 2013. 1784 [I-D.ietf-payload-rtp-howto] 1785 Westerlund, M., "How to Write an RTP Payload Format", 1786 draft-ietf-payload-rtp-howto-02 (work in progress), 1787 July 2012. 1789 [I-D.lennox-avtcore-rtp-multi-stream] 1790 Lennox, J., Westerlund, M., Wu, W., and C. Perkins, "RTP 1791 Considerations for Endpoints Sending Multiple Media 1792 Streams", draft-lennox-avtcore-rtp-multi-stream-02 (work 1793 in progress), February 2013. 1795 [I-D.lennox-mmusic-sdp-source-selection] 1796 Lennox, J. and H. Schulzrinne, "Mechanisms for Media 1797 Source Selection in the Session Description Protocol 1798 (SDP)", draft-lennox-mmusic-sdp-source-selection-05 (work 1799 in progress), October 2012. 1801 [I-D.westerlund-avtcore-max-ssrc] 1802 Westerlund, M., Burman, B., and F. Jansson, "Multiple 1803 Synchronization sources (SSRC) in RTP Session Signaling", 1804 draft-westerlund-avtcore-max-ssrc-02 (work in progress), 1805 July 2012. 1807 [I-D.westerlund-avtcore-rtp-topologies-update] 1808 Westerlund, M. and S. Wenger, "RTP Topologies", 1809 draft-westerlund-avtcore-rtp-topologies-update-02 (work in 1810 progress), February 2013. 1812 [I-D.westerlund-avtcore-transport-multiplexing] 1813 Westerlund, M. and C. Perkins, "Multiple RTP Sessions on a 1814 Single Lower-Layer Transport", 1815 draft-westerlund-avtcore-transport-multiplexing-04 (work 1816 in progress), October 2012. 1818 [I-D.westerlund-avtext-rtcp-sdes-srcname] 1819 Westerlund, M., Burman, B., and P. Sandgren, "RTCP SDES 1820 Item SRCNAME to Label Individual Sources", 1821 draft-westerlund-avtext-rtcp-sdes-srcname-02 (work in 1822 progress), October 2012. 1824 [RFC2198] Perkins, C., Kouvelas, I., Hodson, O., Hardman, V., 1825 Handley, M., Bolot, J., Vega-Garcia, A., and S. Fosse- 1826 Parisis, "RTP Payload for Redundant Audio Data", RFC 2198, 1827 September 1997. 1829 [RFC2205] Braden, B., Zhang, L., Berson, S., Herzog, S., and S. 1830 Jamin, "Resource ReSerVation Protocol (RSVP) -- Version 1 1831 Functional Specification", RFC 2205, September 1997. 1833 [RFC2326] Schulzrinne, H., Rao, A., and R. Lanphier, "Real Time 1834 Streaming Protocol (RTSP)", RFC 2326, April 1998. 1836 [RFC2474] Nichols, K., Blake, S., Baker, F., and D. Black, 1837 "Definition of the Differentiated Services Field (DS 1838 Field) in the IPv4 and IPv6 Headers", RFC 2474, 1839 December 1998. 1841 [RFC2974] Handley, M., Perkins, C., and E. Whelan, "Session 1842 Announcement Protocol", RFC 2974, October 2000. 1844 [RFC3261] Rosenberg, J., Schulzrinne, H., Camarillo, G., Johnston, 1845 A., Peterson, J., Sparks, R., Handley, M., and E. 1846 Schooler, "SIP: Session Initiation Protocol", RFC 3261, 1847 June 2002. 1849 [RFC3264] Rosenberg, J. and H. Schulzrinne, "An Offer/Answer Model 1850 with Session Description Protocol (SDP)", RFC 3264, 1851 June 2002. 1853 [RFC3389] Zopf, R., "Real-time Transport Protocol (RTP) Payload for 1854 Comfort Noise (CN)", RFC 3389, September 2002. 1856 [RFC3551] Schulzrinne, H. and S. Casner, "RTP Profile for Audio and 1857 Video Conferences with Minimal Control", STD 65, RFC 3551, 1858 July 2003. 1860 [RFC3711] Baugher, M., McGrew, D., Naslund, M., Carrara, E., and K. 1861 Norrman, "The Secure Real-time Transport Protocol (SRTP)", 1862 RFC 3711, March 2004. 1864 [RFC3830] Arkko, J., Carrara, E., Lindholm, F., Naslund, M., and K. 1865 Norrman, "MIKEY: Multimedia Internet KEYing", RFC 3830, 1866 August 2004. 1868 [RFC4103] Hellstrom, G. and P. Jones, "RTP Payload for Text 1869 Conversation", RFC 4103, June 2005. 1871 [RFC4566] Handley, M., Jacobson, V., and C. Perkins, "SDP: Session 1872 Description Protocol", RFC 4566, July 2006. 1874 [RFC4568] Andreasen, F., Baugher, M., and D. Wing, "Session 1875 Description Protocol (SDP) Security Descriptions for Media 1876 Streams", RFC 4568, July 2006. 1878 [RFC4588] Rey, J., Leon, D., Miyazaki, A., Varsa, V., and R. 1879 Hakenberg, "RTP Retransmission Payload Format", RFC 4588, 1880 July 2006. 1882 [RFC4607] Holbrook, H. and B. Cain, "Source-Specific Multicast for 1883 IP", RFC 4607, August 2006. 1885 [RFC5104] Wenger, S., Chandra, U., Westerlund, M., and B. Burman, 1886 "Codec Control Messages in the RTP Audio-Visual Profile 1887 with Feedback (AVPF)", RFC 5104, February 2008. 1889 [RFC5109] Li, A., "RTP Payload Format for Generic Forward Error 1890 Correction", RFC 5109, December 2007. 1892 [RFC5117] Westerlund, M. and S. Wenger, "RTP Topologies", RFC 5117, 1893 January 2008. 1895 [RFC5576] Lennox, J., Ott, J., and T. Schierl, "Source-Specific 1896 Media Attributes in the Session Description Protocol 1897 (SDP)", RFC 5576, June 2009. 1899 [RFC5583] Schierl, T. and S. Wenger, "Signaling Media Decoding 1900 Dependency in the Session Description Protocol (SDP)", 1901 RFC 5583, July 2009. 1903 [RFC5760] Ott, J., Chesterfield, J., and E. Schooler, "RTP Control 1904 Protocol (RTCP) Extensions for Single-Source Multicast 1905 Sessions with Unicast Feedback", RFC 5760, February 2010. 1907 [RFC5761] Perkins, C. and M. Westerlund, "Multiplexing RTP Data and 1908 Control Packets on a Single Port", RFC 5761, April 2010. 1910 [RFC5764] McGrew, D. and E. Rescorla, "Datagram Transport Layer 1911 Security (DTLS) Extension to Establish Keys for the Secure 1912 Real-time Transport Protocol (SRTP)", RFC 5764, May 2010. 1914 [RFC5888] Camarillo, G. and H. Schulzrinne, "The Session Description 1915 Protocol (SDP) Grouping Framework", RFC 5888, June 2010. 1917 [RFC6190] Wenger, S., Wang, Y., Schierl, T., and A. Eleftheriadis, 1918 "RTP Payload Format for Scalable Video Coding", RFC 6190, 1919 May 2011. 1921 [RFC6222] Begen, A., Perkins, C., and D. Wing, "Guidelines for 1922 Choosing RTP Control Protocol (RTCP) Canonical Names 1923 (CNAMEs)", RFC 6222, April 2011. 1925 [RFC6285] Ver Steeg, B., Begen, A., Van Caenegem, T., and Z. Vax, 1926 "Unicast-Based Rapid Acquisition of Multicast RTP 1927 Sessions", RFC 6285, June 2011. 1929 [RFC6465] Ivov, E., Marocco, E., and J. Lennox, "A Real-time 1930 Transport Protocol (RTP) Header Extension for Mixer-to- 1931 Client Audio Level Indication", RFC 6465, December 2011. 1933 Appendix A. Dismissing Payload Type Multiplexing 1935 This section documents a number of reasons why using the payload type 1936 as a multiplexing point for most things related to multiple streams 1937 is unsuitable. If one attempts to use Payload type multiplexing 1938 beyond it's defined usage, that has well known negative effects on 1939 RTP. To use Payload type as the single discriminator for multiple 1940 streams implies that all the different media streams are being sent 1941 with the same SSRC, thus using the same timestamp and sequence number 1942 space. This has many effects: 1944 1. Putting restraint on RTP timestamp rate for the multiplexed 1945 media. For example, media streams that use different RTP 1946 timestamp rates cannot be combined, as the timestamp values need 1947 to be consistent across all multiplexed media frames. Thus 1948 streams are forced to use the same rate. When this is not 1949 possible, Payload Type multiplexing cannot be used. 1951 2. Many RTP payload formats may fragment a media object over 1952 multiple packets, like parts of a video frame. These payload 1953 formats need to determine the order of the fragments to 1954 correctly decode them. Thus it is important to ensure that all 1955 fragments related to a frame or a similar media object are 1956 transmitted in sequence and without interruptions within the 1957 object. This can relatively simple be solved on the sender side 1958 by ensuring that the fragments of each media stream are sent in 1959 sequence. 1961 3. Some media formats require uninterrupted sequence number space 1962 between media parts. These are media formats where any missing 1963 RTP sequence number will result in decoding failure or invoking 1964 of a repair mechanism within a single media context. The text/ 1965 T140 payload format [RFC4103] is an example of such a format. 1966 These formats will need a sequence numbering abstraction 1967 function between RTP and the individual media stream before 1968 being used with Payload Type multiplexing. 1970 4. Sending multiple streams in the same sequence number space makes 1971 it impossible to determine which Payload Type and thus which 1972 stream a packet loss relates to. 1974 5. If RTP Retransmission [RFC4588] is used and there is a loss, it 1975 is possible to ask for the missing packet(s) by SSRC and 1976 sequence number, not by Payload Type. If only some of the 1977 Payload Type multiplexed streams are of interest, there is no 1978 way of telling which missing packet(s) belong to the interesting 1979 stream(s) and all lost packets must be requested, wasting 1980 bandwidth. 1982 6. The current RTCP feedback mechanisms are built around providing 1983 feedback on media streams based on stream ID (SSRC), packet 1984 (sequence numbers) and time interval (RTP Timestamps). There is 1985 almost never a field to indicate which Payload Type is reported, 1986 so sending feedback for a specific media stream is difficult 1987 without extending existing RTCP reporting. 1989 7. The current RTCP media control messages [RFC5104] specification 1990 is oriented around controlling particular media flows, i.e. 1991 requests are done addressing a particular SSRC. Such mechanisms 1992 would need to be redefined to support Payload Type multiplexing. 1994 8. The number of payload types are inherently limited. 1995 Accordingly, using Payload Type multiplexing limits the number 1996 of streams that can be multiplexed and does not scale. This 1997 limitation is exacerbated if one uses solutions like RTP and 1998 RTCP multiplexing [RFC5761] where a number of payload types are 1999 blocked due to the overlap between RTP and RTCP. 2001 9. At times, there is a need to group multiplexed streams and this 2002 is currently possible for RTP Sessions and for SSRC, but there 2003 is no defined way to group Payload Types. 2005 10. It is currently not possible to signal bandwidth requirements 2006 per media stream when using Payload Type Multiplexing. 2008 11. Most existing SDP media level attributes cannot be applied on a 2009 per Payload Type level and would require re-definition in that 2010 context. 2012 12. A legacy endpoint that doesn't understand the indication that 2013 different RTP payload types are different media streams may be 2014 slightly confused by the large amount of possibly overlapping or 2015 identically defined RTP Payload Types. 2017 Appendix B. Proposals for Future Work 2019 The above discussion and guidelines indicates that a small set of 2020 extension mechanisms could greatly improve the situation when it 2021 comes to using multiple streams independently of Multiple RTP session 2022 or Additional SSRC. These extensions are: 2024 Media Source Identification: A Media source identification that can 2025 be used to bind together media streams that are related to the 2026 same media source. A proposal 2027 [I-D.westerlund-avtext-rtcp-sdes-srcname] exist for a new SDES 2028 item SRCNAME that also can be used with the a=ssrc SDP attribute 2029 to provide signalling layer binding information. 2031 SSRC limitations within RTP sessions: By providing a signalling 2032 solution that allows the signalling peers to explicitly express 2033 both support and limitations on how many simultaneous media 2034 streams an endpoint can handle within a given RTP Session. That 2035 ensures that usage of Additional SSRC occurs when supported and 2036 without overloading an endpoint. This extension is proposed in 2037 [I-D.westerlund-avtcore-max-ssrc]. 2039 Appendix C. RTP Specification Clarifications 2041 This section describes a number of clarifications to the RTP 2042 specifications that are likely necessary for aligned behaviour when 2043 RTP sessions contain more SSRCs than one local and one remote. 2045 All of the below proposals are under consideration in 2046 [I-D.lennox-avtcore-rtp-multi-stream]. 2048 C.1. RTCP Reporting from all SSRCs 2050 When one has multiple SSRC in an RTP node, all these SSRC must send 2051 some RTP or RTCP packet as long as the SSRC exist. It is not 2052 sufficient that only one SSRC in the node sends report blocks on the 2053 incoming RTP streams; any SSRC that intends to remain in the session 2054 must send some packets to avoid timing out according to the rules in 2055 RFC 3550 section 6.3.5. 2057 It has been hypothesised that a third party monitor may be confused 2058 by not necessarily being able to determine that all these SSRC are in 2059 fact co-located and originate from the same stack instance; if this 2060 hypothesis is true, this may argue for having all the sources send 2061 full reception reports, even though they are reporting the same 2062 packet delivery. 2064 The contrary argument is that such double reporting may confuse the 2065 third party monitor even more by making it seem that utilisation of 2066 the last-hop link to the recipient is (number of SSRCs) times higher 2067 than what it actually is. 2069 C.2. RTCP Self-reporting 2071 For any RTP node that sends more than one SSRC, there is the question 2072 if SSRC1 needs to report its reception of SSRC2 and vice versa. The 2073 reason that they in fact need to report on all other local streams as 2074 being received is report consistency. The hypothetical third party 2075 monitor that considers the full matrix of media streams and all known 2076 SSRC reports on these media streams would detect a gap in the reports 2077 which could be a transport issue unless identified as in fact being 2078 sources from the same node. 2080 C.3. Combined RTCP Packets 2082 When a node contains multiple SSRCs, it is questionable if an RTCP 2083 compound packet can only contain RTCP packets from a single SSRC or 2084 if multiple SSRCs can include their packets in a joint compound 2085 packet. The high level question is a matter for any receiver 2086 processing on what to expect. In addition to that question there is 2087 the issue of how to use the RTCP timer rules in these cases, as the 2088 existing rules are focused on determining when a single SSRC can 2089 send. 2091 Appendix D. Signalling considerations 2093 Signalling is not an architectural consideration for RTP itself, so 2094 this discussion has been moved to an appendix. However, it is hugely 2095 important for anyone building complete applications, so it is 2096 deserving of discussion. 2098 The issues raised here need to be addressed in the WGs that deal with 2099 signalling; they cannot be addressed by tweaking, extending or 2100 profiling RTP. 2102 D.1. Signalling Aspects 2104 There exist various signalling solutions for establishing RTP 2105 sessions. Many are SDP [RFC4566] based, however SDP functionality is 2106 also dependent on the signalling protocols carrying the SDP. Where 2107 RTSP [RFC2326] and SAP [RFC2974] both use SDP in a declarative 2108 fashion, while SIP [RFC3261] uses SDP with the additional definition 2109 of Offer/Answer [RFC3264]. The impact on signalling and especially 2110 SDP needs to be considered as it can greatly affect how to deploy a 2111 certain multiplexing point choice. 2113 D.1.1. Session Oriented Properties 2115 One aspect of the existing signalling is that it is focused around 2116 sessions, or at least in the case of SDP the media description. 2117 There are a number of things that are signalled on a session level/ 2118 media description but those are not necessarily strictly bound to an 2119 RTP session and could be of interest to signal specifically for a 2120 particular media stream (SSRC) within the session. The following 2121 properties have been identified as being potentially useful to signal 2122 not only on RTP session level: 2124 o Bitrate/Bandwidth exist today only at aggregate or a common any 2125 media stream limit, unless either codec-specific bandwidth 2126 limiting or RTCP signalling using TMMBR is used. 2128 o Which SSRC that will use which RTP Payload Types (this will be 2129 visible from the first media packet, but is sometimes useful to 2130 know before packet arrival). 2132 Some of these issues are clearly SDP's problem rather than RTP 2133 limitations. However, if the aim is to deploy an solution using 2134 additional SSRCs that contains several sets of media streams with 2135 different properties (encoding/packetization parameter, bit-rate, 2136 etc), putting each set in a different RTP session would directly 2137 enable negotiation of the parameters for each set. If insisting on 2138 Additional SSRC only, a number of signalling extensions are needed to 2139 clarify that there are multiple sets of media streams with different 2140 properties and that they shall in fact be kept different, since a 2141 single set will not satisfy the application's requirements. 2143 For some parameters, such as resolution and framerate, a SSRC-linked 2144 mechanism has been proposed: 2145 [I-D.lennox-mmusic-sdp-source-selection]. 2147 D.1.2. SDP Prevents Multiple Media Types 2149 SDP chose to use the m= line both to delineate an RTP session and to 2150 specify the top level of the MIME media type; audio, video, text, 2151 image, application. This media type is used as the top-level media 2152 type for identifying the actual payload format bound to a particular 2153 payload type using the rtpmap attribute. This binding has to be 2154 loosened in order to use SDP to describe RTP sessions containing 2155 multiple MIME top level types. 2157 There is an accepted WG item in the MMUSIC WG to define how multiple 2158 media lines describe a single underlying transport 2159 [I-D.ietf-mmusic-sdp-bundle-negotiation] and thus it becomes possible 2160 in SDP to define one RTP session with media types having different 2161 MIME top level types. 2163 D.1.3. Signalling Media Stream Usage 2165 Media streams being transported in RTP has some particular usage in 2166 an RTP application. This usage of the media stream is in many 2167 applications so far implicitly signalled. For example, an 2168 application may choose to take all incoming audio RTP streams, mix 2169 them and play them out. However, in more advanced applications that 2170 use multiple media streams there will be more than a single usage or 2171 purpose among the set of media streams being sent or received. RTP 2172 applications will need to signal this usage somehow. The signalling 2173 used will have to identify the media streams affected by their RTP- 2174 level identifiers, which means that they have to be identified either 2175 by their session or by their SSRC + session. 2177 In some applications, the receiver cannot utilise the media stream at 2178 all before it has received the signalling message describing the 2179 media stream and its usage. In other applications, there exists a 2180 default handling that is appropriate. 2182 If all media streams in an RTP session are to be treated in the same 2183 way, identifying the session is enough. If SSRCs in a session are to 2184 be treated differently, signalling must identify both the session and 2185 the SSRC. 2187 If this signalling affects how any RTP central node, like an RTP 2188 mixer or translator that selects, mixes or processes streams, treats 2189 the streams, the node will also need to receive the same signalling 2190 to know how to treat media streams with different usage in the right 2191 fashion. 2193 Appendix E. Changes from -01 to -02 2195 o Added Harald Alvestrand as co-author. 2197 o Removed unused term "Media aggregate". 2199 o Added term "RTP session group", noted that CNAMEs are assumed to 2200 bind across the sessions of an RTP session group, and used it when 2201 appropriate (TODO) 2203 o Moved discussion of signalling aspects to appendix 2205 o Removed all suggestion that PT can be a multiplexing point 2206 o Normalised spelling of "endpoint" to follow RFC 3550 and not use a 2207 hyphen. 2209 o Added CNAME to definition list. 2211 o Added term "Media Sink" for the thing that is identified by a 2212 listen-only SSRC. 2214 o Added term "RTP source" for the thing that transmits one media 2215 stream, separating it from "Media Source". [[OUTSTANDING: Whether 2216 to use "RTP Source" or "Media Sender" here]] 2218 o Rewrote section on distributed endpoint, noting that this, like 2219 any endpoint that wants a subset of a set of RTP streams, needs 2220 multiple RTP sessions. 2222 o Removed all substantive references to the undefined term "purpose" 2223 from the main body of the document when it referred to the purpose 2224 of an RTP stream. 2226 o Moved the summary section of section 6 to the guidelines section 2227 that it most closely supports. 2229 o 2231 Authors' Addresses 2233 Magnus Westerlund 2234 Ericsson 2235 Farogatan 6 2236 SE-164 80 Kista 2237 Sweden 2239 Phone: +46 10 714 82 87 2240 Email: magnus.westerlund@ericsson.com 2242 Bo Burman 2243 Ericsson 2244 Farogatan 6 2245 SE-164 80 Kista 2246 Sweden 2248 Phone: +46 10 714 13 11 2249 Email: bo.burman@ericsson.com 2250 Colin Perkins 2251 University of Glasgow 2252 School of Computing Science 2253 Glasgow G12 8QQ 2254 United Kingdom 2256 Email: csp@csperkins.org 2258 Harald Tveit Alvestrand 2259 Google 2260 Kungsbron 2 2261 Stockholm, 11122 2262 Sweden 2264 Phone: 2265 Fax: 2266 Email: harald@alvestrand.no 2267 URI: