Debian Codegraph @

rfc5450.html

raw
1 <pre>Network Working Group D. Singer
2 Request for Comments: 5450 Apple Computer Inc.
3 Category: Standards Track H. Desineni
4 Qualcomm
5 March 2009
6
7
8 <span class="h1">Transmission Time Offsets in RTP Streams</span>
9
10 Status of This Memo
11
12 This document specifies an Internet standards track protocol for the
13 Internet community, and requests discussion and suggestions for
14 improvements. Please refer to the current edition of the "Internet
15 Official Protocol Standards" (STD 1) for the standardization state
16 and status of this protocol. Distribution of this memo is unlimited.
17
18 Copyright Notice
19
20 Copyright (c) 2009 IETF Trust and the persons identified as the
21 document authors. All rights reserved.
22
23 This document is subject to <a href="https://www.rfc-editor.org/bcp/bcp78">BCP 78</a> and the IETF Trust's Legal
24 Provisions Relating to IETF Documents in effect on the date of
25 publication of this document (<a href="http://trustee.ietf.org/license-info">http://trustee.ietf.org/license-info</a>).
26 Please review these documents carefully, as they describe your rights
27 and restrictions with respect to this document.
28
29 This document may contain material from IETF Documents or IETF
30 Contributions published or made publicly available before November
31 10, 2008. The person(s) controlling the copyright in some of this
32 material may not have granted the IETF Trust the right to allow
33 modifications of such material outside the IETF Standards Process.
34 Without obtaining an adequate license from the person(s) controlling
35 the copyright in such materials, this document may not be modified
36 outside the IETF Standards Process, and derivative works of it may
37 not be created outside the IETF Standards Process, except to format
38 it for publication as an RFC or to translate it into languages other
39 than English.
40
41 Abstract
42
43 This document describes a method to inform Real-time Transport
44 Protocol (RTP) clients when RTP packets are transmitted at a time
45 other than their 'nominal' transmission time. It also provides a
46 mechanism to provide improved inter-arrival jitter reports from the
47 clients, that take into account the reported transmission times.
48
49
50
51
52 <span class="grey">Singer &amp; Desineni Standards Track [Page 1]</span></pre>
53 <hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-2" ></span>
54 <span class="grey"><a href="./rfc5450">RFC 5450</a> RTP Transmission Offsets March 2009</span>
55
56
57 Table of Contents
58
59 <a href="#section-1">1</a>. Introduction . . . . . . . . . . . . . . . . . . . . . . . . . <a href="#page-2">2</a>
60 <a href="#section-2">2</a>. Requirements Notation . . . . . . . . . . . . . . . . . . . . . <a href="#page-3">3</a>
61 <a href="#section-3">3</a>. Transmission Offset . . . . . . . . . . . . . . . . . . . . . . <a href="#page-3">3</a>
62 <a href="#section-4">4</a>. Extended Jitter Reports . . . . . . . . . . . . . . . . . . . . <a href="#page-5">5</a>
63 <a href="#section-5">5</a>. Signaling (Setup) Information . . . . . . . . . . . . . . . . . <a href="#page-6">6</a>
64 <a href="#section-6">6</a>. Security Considerations . . . . . . . . . . . . . . . . . . . . <a href="#page-6">6</a>
65 <a href="#section-7">7</a>. IANA Considerations . . . . . . . . . . . . . . . . . . . . . . <a href="#page-7">7</a>
66 <a href="#section-8">8</a>. Acknowledgments . . . . . . . . . . . . . . . . . . . . . . . . <a href="#page-7">7</a>
67 <a href="#section-9">9</a>. Normative References . . . . . . . . . . . . . . . . . . . . . <a href="#page-7">7</a>
68
69 <span class="h2"><a class="selflink" id="section-1" href="#section-1">1</a>. Introduction</span>
70
71 In the Real-time Transport Protocol (RTP) specification [<a href="./rfc3550" title="&quot;RTP: A Transport Protocol for Real-Time Applications&quot;">RFC3550</a>],
72 network jitter calculations are based on the presumption that packets
73 are transmitted essentially in accordance with their RTP timestamps.
74 This must be true, of course, on average over longer time intervals,
75 as the client is playing the packets out according to those
76 timestamps. However, for individual packets, this may not be true
77 under some circumstances, such as:
78
79 o When the data rate of the stream is bursty, such as with video
80 where I-frames may be significantly larger than P or B frames,
81 traffic smoothing may need to be applied to maintain an
82 appropriate data rate.
83
84 o In video that has forward-decode dependencies, frames may need to
85 be transmitted in decoding order (the sequence number order) but
86 with, of course, presentation timestamps. Under these
87 circumstances, the transmission time of a frame sent early in
88 sequence does not correspond to its RTP timestamp.
89
90 o When retransmissions are sent, the retransmitted packet clearly
91 has a different actual transmission time from the original, even
92 though they share the same timestamp.
93
94 Under some circumstances, it can help the receiver, or intermediate
95 network elements, to know the actual transmission time of the packet.
96 This RTP header extension element allows the communication of this
97 information.
98
99 The RTP specification does not define a transmission timestamp; nor
100 does this specification. This specification merely provides
101 information on the relationship between the relative transmission
102 times and relative RTP timestamps.
103
104
105
106
107
108 <span class="grey">Singer &amp; Desineni Standards Track [Page 2]</span></pre>
109 <hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-3" ></span>
110 <span class="grey"><a href="./rfc5450">RFC 5450</a> RTP Transmission Offsets March 2009</span>
111
112
113 This specification allows the transmitter to indicate to the receiver
114 any known variation between the spacing of transmission times and the
115 spacing of RTP timestamps; any unreported variation introduced at or
116 after the point of measurement of the transmission time will be
117 treated as network jitter by the receiver. The definition of the
118 point where the transmission time is measured or defined is left to
119 the transmitter, though it should, of course, be consistent from
120 packet to packet.
121
122 This information can also be of use to report the inter-arrival
123 jitter caused by the network, excluding that introduced by the
124 source. A new RTP Control Protocol (RTCP) packet is defined to
125 enable this reporting.
126
127 <span class="h2"><a class="selflink" id="section-2" href="#section-2">2</a>. Requirements Notation</span>
128
129 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
130 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this
131 document are to be interpreted as described in [<a href="./rfc2119" title="&quot;Key words for use in RFCs to Indicate Requirement Levels&quot;">RFC2119</a>].
132
133 <span class="h2"><a class="selflink" id="section-3" href="#section-3">3</a>. Transmission Offset</span>
134
135 Classically, a pair of RTP packets with timestamps S2 and S1 are
136 transmitted with a time interval between them of (S2 - S1). This
137 specification permits sending an offset value O in each packet, O1
138 and O2. One characteristic of these offsets is that the original
139 transmission interval can be deduced to be (S2 + O2) - (S1 + O1).
140
141 More precisely, the offset is defined as follows (with the function
142 RtoN converting from RTP to Network Time Protocol (NTP) times, and
143 NtoR doing the reverse):
144
145 o Take an RTP stream that has a recent RTCP sender report relating
146 RTP timestamp S0 to NTP timestamp N0;
147
148 o Consider a packet sent after that with RTP timestamp S1.
149 Nominally, this is sent at N1 = (N0 + RtoN(S1 - S0));
150
151 o If it was actually sent at a different time, Na, then the offset
152 value O1 is O1 = NtoR(Na - N1).
153
154 The transmission time is signaled to the receiver in-band using the
155 general mechanism for RTP header extensions [<a href="./rfc5285" title="&quot;A General Mechanism for RTP Header Extensions&quot;">RFC5285</a>]. The payload
156 of this extension (the transmitted value) is a 24-bit signed integer.
157 When added to the RTP timestamp of the packet, it represents the
158 "effective" RTP transmission time of the packet, on the RTP
159 timescale. The reported transmission time T1 of a packet with
160
161
162
163
164 <span class="grey">Singer &amp; Desineni Standards Track [Page 3]</span></pre>
165 <hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-4" ></span>
166 <span class="grey"><a href="./rfc5450">RFC 5450</a> RTP Transmission Offsets March 2009</span>
167
168
169 timestamp S1 and an offset of O1, from the above equations, is T1 =
170 S1+O1 (though of course the transmission time values only have
171 meaning when two or more are compared).
172
173 The form of the transmission offset extension block is as follows:
174
175 0 1 2 3
176 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
177 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
178 | ID | len=2 | transmission offset |
179 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
180
181 The length field takes the value 2 to indicate that 3 bytes follow.
182
183 The sign of the offset value depends greatly on the choice of the
184 initial mapping of RTP to NTP times. In general, without scanning a
185 stream entirely it is not possible to ensure that this mapping would
186 keep all the offsets positive; therefore, this specification allows
187 negative values.
188
189 Imagine a stream with the following timestamps and sizes (in KB):
190
191 200 2 KB
192 300 4 KB
193 400 2 KB
194 500 12 KB
195 600 ...effective end of stream
196
197 This has 20 KB spread over 400 time units, i.e., on average, 1 KB per
198 20 time units. We traffic-smooth this, and establish that given a
199 transmission time of x for the first packet, we would transmit the
200 following packets at the given intervals later:
201
202 x + 000 2 KB
203 x + 040 4 KB
204 x + 120 2 KB
205 x + 160 12 KB
206 x + 400 ...effective end of stream
207
208 The choice of x is essentially arbitrary: only relative values of
209 timestamps matter. Now, let's say I claim on the first packet that
210 it went out *at* its RTP timestamp, i.e., with an offset of 0,
211 meaning that x is 200. Then the offset values are:
212
213 0
214 -60
215 -80
216 -140
217
218
219
220 <span class="grey">Singer &amp; Desineni Standards Track [Page 4]</span></pre>
221 <hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-5" ></span>
222 <span class="grey"><a href="./rfc5450">RFC 5450</a> RTP Transmission Offsets March 2009</span>
223
224
225 This is because in this case, I traffic-smooth by conceptually
226 sending the small packets 'early'. But since only the relative
227 values are significant, it is just as valid to say x is 400,
228 whereupon the offset values are:
229
230 200
231 140
232 120
233 60
234
235 In a stream where this extension is not in effect (i.e., not declared
236 or negotiated), the actual transmission offset is therefore unknown.
237 However, when the extension is in effect for the stream, it MAY be
238 omitted in those packets for which the offset is 0 (zero); that is,
239 packets sent at their nominal time do not need this to be tagged with
240 this extension. Therefore, the implied transmission time of an un-
241 tagged RTP packet depends on whether the extension is in effect for
242 the stream (and therefore the transmission offset is 0) or not
243 (whereupon the transmission offset is unknown).
244
245 The jitter calculations performed by an RTP client MUST NOT use these
246 transmission offsets. In general, the sender (or intermediate
247 network elements doing RTP analysis) cannot always know whether the
248 offsets have been taken into account or not. Therefore, for
249 consistency, the jitter calculation should continue to operate on the
250 'raw' reception times. However, see <a href="#section-4">Section 4</a> on extended jitter
251 reports, below.
252
253 There are no extensionattributes defined for this extension.
254
255 It is structurally possible to have more than one extension of the
256 same type in a packet. However, this extension is only defined for
257 the source to report. Intermediate network nodes that are not the
258 source of the RTP session MUST NOT add this extension (whether or not
259 it was previously present) and MUST NOT alter the existing
260 transmission offset value in a packet, if the extension is already
261 present.
262
263 (Of course, it is clear that network elements that terminate an RTP
264 flow, and are the source for a new RTP flow, can add a transmission
265 offset extension header to the RTP packets of the new flow, if
266 desired.)
267
268 <span class="h2"><a class="selflink" id="section-4" href="#section-4">4</a>. Extended Jitter Reports</span>
269
270 The inter-arrival jitter computed as defined in Section 6.4.1 of <a href="./rfc3550">RFC</a>
271 <a href="./rfc3550">3550</a> provides inter-arrival jitter reports that include any source-
272 introduced jitter (transmission time offsets). If it is desired to
273
274
275
276 <span class="grey">Singer &amp; Desineni Standards Track [Page 5]</span></pre>
277 <hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-6" ></span>
278 <span class="grey"><a href="./rfc5450">RFC 5450</a> RTP Transmission Offsets March 2009</span>
279
280
281 indicate the actual network jitter, excluding the source-introduced
282 jitter, the new RTCP packet type defined here may be used.
283
284 It has the following form:
285
286 0 1 2 3
287 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
288 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
289 hdr |V=2|P| RC | PT=IJ=195 | length |
290 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
291 | inter-arrival jitter |
292 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
293 . .
294 . .
295 . .
296 | inter-arrival jitter |
297 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
298
299 If present, this RTCP packet must be placed after a receiver report
300 (inside a compound RTCP packet), and MUST have the same value for RC
301 (reception report count) as the receiver report. The content is
302 exactly that number of inter-arrival jitter calculations, calculated
303 using the same formula as for sender and receiver reports, but taking
304 into account the transmission offsets for the streams (if any). That
305 is, the formula uses the values T1=S1+O1, T2, etc., as defined above,
306 instead of S1, S2, etc. (If no transmission offset information is
307 given for a stream, then the value of inter-arrival jitter in this
308 packet and in the receiver report will be identical).
309
310 Precisely, the replacement equation for the equation in the RTP
311 specification is as follows, where Rj is the most recent arrival
312 time:
313
314 D(i,j) = (Rj - Ri) - ((Sj + Oj) - (Si + Oi))
315 = (Rj - (Sj + Oj)) - (Ri - (Si + Oi))
316
317 <span class="h2"><a class="selflink" id="section-5" href="#section-5">5</a>. Signaling (Setup) Information</span>
318
319 The URI for declaring this header extension in an extmap attribute is
320 "urn:ietf:params:rtp-hdrext:toffset". There is no additional setup
321 information needed for this extension (no extensionattributes).
322
323 <span class="h2"><a class="selflink" id="section-6" href="#section-6">6</a>. Security Considerations</span>
324
325 The given transmission offsets are only informative, and it is hard
326 to see security considerations from associating them with media
327 streams.
328
329
330
331
332 <span class="grey">Singer &amp; Desineni Standards Track [Page 6]</span></pre>
333 <hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-7" ></span>
334 <span class="grey"><a href="./rfc5450">RFC 5450</a> RTP Transmission Offsets March 2009</span>
335
336
337 The underlying security considerations of [<a href="./rfc3550" title="&quot;RTP: A Transport Protocol for Real-Time Applications&quot;">RFC3550</a>] should be taken
338 into account.
339
340 It is possible that malicious senders (or systems tampering with
341 packets in transit) could send offsets that are implausible, could
342 confuse the receiver, or result in calculated jitter values that
343 might mislead the sender. Both the sender and receiver of the
344 transmission offsets and jitter values should take care that such
345 behavior does not result in denial of service or other problems.
346
347 <span class="h2"><a class="selflink" id="section-7" href="#section-7">7</a>. IANA Considerations</span>
348
349 The RTCP packet type used for the adjusted inter-arrival jitter has
350 been registered, in accordance with <a href="./rfc3550#section-15">Section&nbsp;15 of [RFC3550]</a>. IANA
351 has added a new value to the RTCP Control Packet types subregistry of
352 the Real-Time Transport Protocol (RTP) Parameters registry, according
353 to the following data:
354
355 abbrev. name value Reference
356 ------- ------------------------------------ ------ ---------
357 IJ Extended inter-arrival jitter report 195 <a href="./rfc5450">RFC 5450</a>
358
359 Additionally, IANA has registered a new extension URI to the RTP
360 Compact Header Extensions subregistry of the Real-Time Transport
361 Protocol (RTP) Parameters registry, according to the following data:
362
363 Extension URI: urn:ietf:params:rtp-hdrext:toffset
364 Description: Transmission Time offsets
365 Contact: [email protected]
366 Reference: <a href="./rfc5450">RFC 5450</a>
367
368 <span class="h2"><a class="selflink" id="section-8" href="#section-8">8</a>. Acknowledgments</span>
369
370 Ron Frederick, Colin Perkins, and Steve Casner all contributed
371 substantially to this document, and their help and contributions
372 helped turn an idea into a specification.
373
374 <span class="h2"><a class="selflink" id="section-9" href="#section-9">9</a>. Normative References</span>
375
376 [<a id="ref-RFC2119">RFC2119</a>] Bradner, S., "Key words for use in RFCs to Indicate
377 Requirement Levels", <a href="https://www.rfc-editor.org/bcp/bcp14">BCP 14</a>, <a href="./rfc2119">RFC 2119</a>, March 1997.
378
379 [<a id="ref-RFC3550">RFC3550</a>] Schulzrinne, H., Casner, S., Frederick, R., and V.
380 Jacobson, "RTP: A Transport Protocol for Real-Time
381 Applications", STD 64, <a href="./rfc3550">RFC 3550</a>, July 2003.
382
383 [<a id="ref-RFC5285">RFC5285</a>] Singer, D. and H. Desineni, "A General Mechanism for RTP
384 Header Extensions", <a href="./rfc5285">RFC 5285</a>, July 2008.
385
386
387
388 <span class="grey">Singer &amp; Desineni Standards Track [Page 7]</span></pre>
389 <hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-8" ></span>
390 <span class="grey"><a href="./rfc5450">RFC 5450</a> RTP Transmission Offsets March 2009</span>
391
392
393 Authors' Addresses
394
395 David Singer
396 Apple Computer Inc.
397 1 Infinite Loop
398 Cupertino, CA 95014
399 US
400
401 Phone: +1 408 996 1010
402 EMail: [email protected]
403
404
405 Harikishan Desineni
406 Qualcomm
407 5775 Morehouse Drive
408 San Diego, CA 92121
409 US
410
411 Phone: +1 858 845 8996
412 EMail: [email protected]
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444 Singer &amp; Desineni Standards Track [Page 8]
445 </pre>