Debian Codegraph @

rfc6188.html

raw
1 <pre>Internet Engineering Task Force (IETF) D. McGrew
2 Request for Comments: 6188 Cisco Systems, Inc.
3 Category: Standards Track March 2011
4 ISSN: 2070-1721
5
6
7 <span class="h1">The Use of AES-192 and AES-256 in Secure RTP</span>
8
9 Abstract
10
11 This memo describes the use of the Advanced Encryption Standard (AES)
12 with 192- and 256-bit keys within the Secure RTP (SRTP) protocol. It
13 details counter mode encryption for SRTP and Secure Realtime
14 Transport Control Protocol (SRTCP) and a new SRTP Key Derivation
15 Function (KDF) for AES-192 and AES-256.
16
17 Status of This Memo
18
19 This is an Internet Standards Track document.
20
21 This document is a product of the Internet Engineering Task Force
22 (IETF). It represents the consensus of the IETF community. It has
23 received public review and has been approved for publication by the
24 Internet Engineering Steering Group (IESG). Further information on
25 Internet Standards is available in <a href="./rfc5741#section-2">Section&nbsp;2 of RFC 5741</a>.
26
27 Information about the current status of this document, any errata,
28 and how to provide feedback on it may be obtained at
29 <a href="http://www.rfc-editor.org/info/rfc6188">http://www.rfc-editor.org/info/rfc6188</a>.
30
31 Copyright Notice
32
33 Copyright (c) 2011 IETF Trust and the persons identified as the
34 document authors. All rights reserved.
35
36 This document is subject to <a href="https://www.rfc-editor.org/bcp/bcp78">BCP 78</a> and the IETF Trust's Legal
37 Provisions Relating to IETF Documents
38 (<a href="http://trustee.ietf.org/license-info">http://trustee.ietf.org/license-info</a>) in effect on the date of
39 publication of this document. Please review these documents
40 carefully, as they describe your rights and restrictions with respect
41 to this document. Code Components extracted from this document must
42 include Simplified BSD License text as described in Section 4.e of
43 the Trust Legal Provisions and are provided without warranty as
44 described in the Simplified BSD License.
45
46
47
48
49
50
51
52 <span class="grey">McGrew 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="./rfc6188">RFC 6188</a> SRTP AES-192 and AES-256 March 2011</span>
55
56
57 Table of Contents
58
59 <a href="#section-1">1</a>. Introduction ....................................................<a href="#page-3">3</a>
60 <a href="#section-1.1">1.1</a>. Conventions Used in This Document ..........................<a href="#page-3">3</a>
61 <a href="#section-2">2</a>. AES-192 and AES-256 Encryption ..................................<a href="#page-3">3</a>
62 <a href="#section-3">3</a>. The AES_192_CM_PRF and AES_256_CM_PRF Key Derivation Functions ..4
63 <a href="#section-3.1">3.1</a>. Usage Requirements .........................................<a href="#page-5">5</a>
64 <a href="#section-4">4</a>. Crypto Suites ...................................................<a href="#page-6">6</a>
65 <a href="#section-5">5</a>. IANA Considerations .............................................<a href="#page-9">9</a>
66 <a href="#section-6">6</a>. Security Considerations .........................................<a href="#page-9">9</a>
67 <a href="#section-7">7</a>. Test Cases .....................................................<a href="#page-10">10</a>
68 <a href="#section-7.1">7.1</a>. AES-256-CM Test Cases .....................................<a href="#page-10">10</a>
69 <a href="#section-7.2">7.2</a>. AES_256_CM_PRF Test Cases .................................<a href="#page-11">11</a>
70 <a href="#section-7.3">7.3</a>. AES-192-CM Test Cases .....................................<a href="#page-13">13</a>
71 <a href="#section-7.4">7.4</a>. AES_192_CM_PRF Test Cases .................................<a href="#page-13">13</a>
72 <a href="#section-8">8</a>. Acknowledgements ...............................................<a href="#page-15">15</a>
73 <a href="#section-9">9</a>. References .....................................................<a href="#page-15">15</a>
74 <a href="#section-9.1">9.1</a>. Normative References ......................................<a href="#page-15">15</a>
75 <a href="#section-9.2">9.2</a>. Informative References ....................................<a href="#page-15">15</a>
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108 <span class="grey">McGrew 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="./rfc6188">RFC 6188</a> SRTP AES-192 and AES-256 March 2011</span>
111
112
113 <span class="h2"><a class="selflink" id="section-1" href="#section-1">1</a>. Introduction</span>
114
115 This memo describes the use of the Advanced Encryption Standard (AES)
116 [<a href="#ref-FIPS197" title="&quot;The Advanced Encryption Standard (AES)&quot;">FIPS197</a>] with 192- and 256-bit keys within the Secure RTP (SRTP)
117 protocol [<a href="./rfc3711" title="&quot;The Secure Real-time Transport Protocol (SRTP)&quot;">RFC3711</a>]. Below, those block ciphers are referred to as
118 AES-192 and AES-256, respectively, and the use of AES with a 128-bit
119 key is referred to as AES-128. This document describes counter mode
120 encryption for SRTP and SRTCP and appropriate SRTP key derivation
121 functions for AES-192 and AES-256. It also defines new crypto suites
122 that use these new functions.
123
124 While AES-128 is widely regarded as more than adequately secure, some
125 users may be motivated to adopt AES-192 or AES-256 due to a perceived
126 need to pursue a highly conservative security strategy. For
127 instance, the Suite B profile requires AES-256 for the protection of
128 TOP SECRET information [<a href="#ref-suiteB" title="&quot;Suite B Cryptography&quot;">suiteB</a>]. (Note that while the AES-192 and
129 AES-256 encryption methods defined in this document use Suite B
130 algorithms, the crypto suites in this document use the HMAC-SHA-1
131 algorithm, which is not included in Suite B.) See <a href="#section-6">Section 6</a> for more
132 discussion of security issues.
133
134 The crypto functions described in this document are an addition to,
135 and not a replacement for, the crypto functions defined in [<a href="./rfc3711" title="&quot;The Secure Real-time Transport Protocol (SRTP)&quot;">RFC3711</a>].
136
137 <span class="h3"><a class="selflink" id="section-1.1" href="#section-1.1">1.1</a>. Conventions Used in This Document</span>
138
139 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
140 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this
141 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>].
142
143 <span class="h2"><a class="selflink" id="section-2" href="#section-2">2</a>. AES-192 and AES-256 Encryption</span>
144
145 <a href="./rfc3711#section-4.1.1">Section&nbsp;4.1.1 of [RFC3711]</a> defines AES counter mode encryption, which
146 it refers to as AES_CM. This definition applies to all of the AES
147 key sizes. In this note, AES-192 counter mode and AES-256 counter
148 mode and are denoted as AES_192_CM and AES_256_CM, respectively. In
149 both of these ciphers, the plaintext inputs to the block cipher are
150 formed as in AES_CM, and the block cipher outputs are processed as in
151 AES_CM. The only difference in the processing is that AES_192_CM
152 uses AES-192, and AES_256_CM uses AES-256. Both AES_192_CM and
153 AES_256_CM use a 112-bit salt as an input, as does AES_CM.
154
155 For the convenience of the reader, the structure of the counter
156 blocks in SRTP counter mode encryption is illustrated in Figure 1,
157 using the terminology from <a href="./rfc3711#section-4.1.1">Section&nbsp;4.1.1 of [RFC3711]</a>. In this
158 diagram, the symbol (+) denotes the bitwise exclusive-or operation,
159 and the AES encrypt operation uses AES-128, AES-192, or AES-256 for
160 AES_CM, AES_192_CM, and AES_256_CM, respectively. The field labeled
161
162
163
164 <span class="grey">McGrew 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="./rfc6188">RFC 6188</a> SRTP AES-192 and AES-256 March 2011</span>
167
168
169 b_c contains a block counter, the value of which increments once for
170 each invocation of the "AES Encrypt" function. The SSRC field is
171 part of the RTP header [<a href="./rfc3550" title="&quot;RTP: A Transport Protocol for Real-Time Applications&quot;">RFC3550</a>].
172
173 one octet
174 &lt;--&gt;
175 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
176 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
177 |00|00|00|00| SSRC | packet index | b_c |---+
178 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+ |
179 |
180 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+ v
181 | salt (k_s) |00|00|-&gt;(+)
182 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+ |
183 |
184 v
185 +-------------+
186 encryption key (k_e) -&gt; | AES encrypt |
187 +-------------+
188 |
189 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+ |
190 | keystream block |&lt;--+
191 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
192
193 Figure 1: AES Counter Mode
194
195 <span class="h2"><a class="selflink" id="section-3" href="#section-3">3</a>. The AES_192_CM_PRF and AES_256_CM_PRF Key Derivation Functions</span>
196
197 <a href="./rfc3711#section-4.3.3">Section&nbsp;4.3.3 of [RFC3711]</a> defines an AES counter mode key derivation
198 function, which it refers to as AES_CM PRF (and sometimes as AES-CM
199 PRF). (That specification uses the term PRF, or pseudo-random
200 function, interchangeably with the phrase "key derivation function".)
201 This key derivation function can be used with any AES key size. In
202 this note, the AES-192 counter mode PRF and AES-256 counter mode PRF
203 are denoted as AES_192_CM_PRF and AES_256_CM_PRF, respectively. In
204 both of these PRFs, the plaintext inputs to the block cipher are
205 formed as in the AES_CM PRF, and the block cipher outputs are
206 processed as in the AES_CM PRF. The only difference in the
207 processing is that AES_192_CM_PRF uses AES-192, and AES_256_CM_PRF
208 uses AES-256. Both AES_192_CM_PRF and AES_256_CM_PRF use a 112-bit
209 salt as an input, as does the AES_CM PRF.
210
211 For the convenience of the reader, the structure of the counter
212 blocks in SRTP counter mode key derivation is illustrated in
213 Figure 2, using the terminology from <a href="./rfc3711#section-4.3.3">Section&nbsp;4.3.3 of [RFC3711]</a>. In
214 this diagram, the symbol (+) denotes the bitwise exclusive-or
215 operation, and the "AES Encrypt" operation uses AES-128, AES-192, or
216 AES-256 for the AES_CM PRF, AES_192_CM_PRF, and AES_256_CM_PRF,
217
218
219
220 <span class="grey">McGrew 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="./rfc6188">RFC 6188</a> SRTP AES-192 and AES-256 March 2011</span>
223
224
225 respectively. The field "LB" contains the 8-bit constant "label",
226 which is provided as an input to the key derivation function (and
227 which is distinct for each type of key generated by that function).
228 The field labeled b_c contains a block counter, the value of which
229 increments once for each invocation of the "AES Encrypt" function.
230 The DIV operation is defined in <a href="./rfc3711#section-4.3.1">Section&nbsp;4.3.1 of [RFC3711]</a> as
231 follows. Let "a DIV t" denote integer division of a by t, rounded
232 down, and with the convention that "a DIV 0 = 0" for all a. We also
233 make the convention of treating "a DIV t" as a bit string of the same
234 length as a, and thus "a DIV t" will, in general, have leading zeros.
235
236 one octet
237 &lt;--&gt;
238 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
239 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
240 |00|00|00|00|00|00|00|LB| index DIV kdr | b_c |---+
241 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+ |
242 |
243 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+ v
244 | master salt |00|00|-&gt;(+)
245 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+ |
246 |
247 v
248 +-------------+
249 master key -&gt; | AES encrypt |
250 +-------------+
251 |
252 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+ |
253 | output block |&lt;--+
254 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
255
256 Figure 2: The AES Counter Mode Key Derivation Function
257
258 <span class="h3"><a class="selflink" id="section-3.1" href="#section-3.1">3.1</a>. Usage Requirements</span>
259
260 When AES_192_CM is used for encryption, AES_192_CM_PRF SHOULD be used
261 as the key derivation function, and AES_128_CM_PRF MUST NOT be used
262 as the key derivation function.
263
264 When AES_256_CM is used for encryption, AES_256_CM_PRF SHOULD be used
265 as the key derivation function. Both AES_128_CM_PRF and
266 AES_192_CM_PRF MUST NOT be used as the key derivation function.
267
268 AES_256_CM_PRF MAY be used as the key derivation function when AES_CM
269 is used for encryption, and when AES_192_CM is used for encryption.
270 AES_192_CM_PRF MAY be used as the key derivation function when AES_CM
271 is used for encryption.
272
273
274
275
276 <span class="grey">McGrew 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="./rfc6188">RFC 6188</a> SRTP AES-192 and AES-256 March 2011</span>
279
280
281 Rationale: it is essential that the cryptographic strength of the
282 key derivation meets or exceeds that of the encryption method. It
283 is natural to use the same function for both encryption and key
284 derivation. However, it is not required to do so because it is
285 desirable to allow these ciphers to be used with alternative key
286 derivation functions that may be defined in the future.
287
288 <span class="h2"><a class="selflink" id="section-4" href="#section-4">4</a>. Crypto Suites</span>
289
290 This section defines SRTP crypto suites that use the ciphers and key
291 derivation functions defined in this document. The parameters in
292 these crypto suites are described in <a href="./rfc3711#section-8.2">Section&nbsp;8.2 of [RFC3711]</a>. These
293 suites are registered with IANA for use with the SDP Security
294 Descriptions attributes (<a href="./rfc4568#section-10.3.2.1">Section&nbsp;10.3.2.1 of [RFC4568]</a>). Other SRTP
295 key management methods that use the crypto functions defined in this
296 document are encouraged to also use these crypto suite definitions.
297
298 Rationale: the crypto suites use the same authentication function
299 that is mandatory to implement in SRTP, HMAC-SHA1 with a 160-bit
300 key. HMAC-SHA1 would accept larger key sizes, but when it is used
301 with keys larger than 160 bits, it does not provide resistance to
302 cryptanalysis greater than that security level, because it has
303 only 160 bits of internal state. By retaining 160-bit
304 authentication keys, the crypto suites in this note have more
305 compatibility with existing crypto suites and implementations of
306 them.
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332 <span class="grey">McGrew 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="./rfc6188">RFC 6188</a> SRTP AES-192 and AES-256 March 2011</span>
335
336
337 +------------------------------+------------------------------------+
338 | Parameter | Value |
339 +------------------------------+------------------------------------+
340 | Master key length | 192 bits |
341 | Master salt length | 112 bits |
342 | Key Derivation Function | AES_192_CM_PRF (<a href="#section-3">Section 3</a>) |
343 | Default key lifetime | 2^31 packets |
344 | Cipher (for SRTP and SRTCP) | AES_192_CM (<a href="#section-2">Section 2</a>) |
345 | SRTP authentication function | HMAC-SHA1 (<a href="#section-4.2.1">Section 4.2.1</a> of |
346 | | [<a href="./rfc3711" title="&quot;The Secure Real-time Transport Protocol (SRTP)&quot;">RFC3711</a>]) |
347 | SRTP authentication key | 160 bits |
348 | length | |
349 | SRTP authentication tag | 80 bits |
350 | length | |
351 | SRTCP authentication | HMAC-SHA1 (<a href="#section-4.2.1">Section 4.2.1</a> of |
352 | function | [<a href="./rfc3711" title="&quot;The Secure Real-time Transport Protocol (SRTP)&quot;">RFC3711</a>]) |
353 | SRTCP authentication key | 160 bits |
354 | length | |
355 | SRTCP authentication tag | 80 bits |
356 | length | |
357 +------------------------------+------------------------------------+
358
359 Table 1: The AES_192_CM_HMAC_SHA1_80 Crypto Suite
360
361 +------------------------------+------------------------------------+
362 | Parameter | Value |
363 +------------------------------+------------------------------------+
364 | Master key length | 192 bits |
365 | Master salt length | 112 bits |
366 | Key Derivation Function | AES_192_CM_PRF (<a href="#section-3">Section 3</a>) |
367 | Default key lifetime | 2^31 packets |
368 | Cipher (for SRTP and SRTCP) | AES_192_CM (<a href="#section-2">Section 2</a>) |
369 | SRTP authentication function | HMAC-SHA1 (<a href="#section-4.2.1">Section 4.2.1</a> of |
370 | | [<a href="./rfc3711" title="&quot;The Secure Real-time Transport Protocol (SRTP)&quot;">RFC3711</a>]) |
371 | SRTP authentication key | 160 bits |
372 | length | |
373 | SRTP authentication tag | 32 bits |
374 | length | |
375 | SRTCP authentication | HMAC-SHA1 (<a href="#section-4.2.1">Section 4.2.1</a> of |
376 | function | [<a href="./rfc3711" title="&quot;The Secure Real-time Transport Protocol (SRTP)&quot;">RFC3711</a>]) |
377 | SRTCP authentication key | 160 bits |
378 | length | |
379 | SRTCP authentication tag | 80 bits |
380 | length | |
381 +------------------------------+------------------------------------+
382
383 Table 2: The AES_192_CM_HMAC_SHA1_32 Crypto Suite
384
385
386
387
388 <span class="grey">McGrew 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="./rfc6188">RFC 6188</a> SRTP AES-192 and AES-256 March 2011</span>
391
392
393 +------------------------------+------------------------------------+
394 | Parameter | Value |
395 +------------------------------+------------------------------------+
396 | Master key length | 256 bits |
397 | Master salt length | 112 bits |
398 | Key Derivation Function | AES_256_CM_PRF (<a href="#section-3">Section 3</a>) |
399 | Default key lifetime | 2^31 packets |
400 | Cipher (for SRTP and SRTCP) | AES_256_CM (<a href="#section-2">Section 2</a>) |
401 | SRTP authentication function | HMAC-SHA1 (<a href="#section-4.2.1">Section 4.2.1</a> of |
402 | | [<a href="./rfc3711" title="&quot;The Secure Real-time Transport Protocol (SRTP)&quot;">RFC3711</a>]) |
403 | SRTP authentication key | 160 bits |
404 | length | |
405 | SRTP authentication tag | 80 bits |
406 | length | |
407 | SRTCP authentication | HMAC-SHA1 (<a href="#section-4.2.1">Section 4.2.1</a> of |
408 | function | [<a href="./rfc3711" title="&quot;The Secure Real-time Transport Protocol (SRTP)&quot;">RFC3711</a>]) |
409 | SRTCP authentication key | 160 bits |
410 | length | |
411 | SRTCP authentication tag | 80 bits |
412 | length | |
413 +------------------------------+------------------------------------+
414
415 Table 3: The AES_256_CM_HMAC_SHA1_80 Crypto Suite
416
417 +------------------------------+------------------------------------+
418 | Parameter | Value |
419 +------------------------------+------------------------------------+
420 | Master key length | 256 bits |
421 | Master salt length | 112 bits |
422 | Key Derivation Function | AES_256_CM_PRF (<a href="#section-3">Section 3</a>) |
423 | Default key lifetime | 2^31 packets |
424 | Cipher (for SRTP and SRTCP) | AES_256_CM (<a href="#section-2">Section 2</a>) |
425 | SRTP authentication function | HMAC-SHA1 (<a href="#section-4.2.1">Section 4.2.1</a> of |
426 | | [<a href="./rfc3711" title="&quot;The Secure Real-time Transport Protocol (SRTP)&quot;">RFC3711</a>]) |
427 | SRTP authentication key | 160 bits |
428 | length | |
429 | SRTP authentication tag | 32 bits |
430 | length | |
431 | SRTCP authentication | HMAC-SHA1 (<a href="#section-4.2.1">Section 4.2.1</a> of |
432 | function | [<a href="./rfc3711" title="&quot;The Secure Real-time Transport Protocol (SRTP)&quot;">RFC3711</a>]) |
433 | SRTCP authentication key | 160 bits |
434 | length | |
435 | SRTCP authentication tag | 80 bits |
436 | length | |
437 +------------------------------+------------------------------------+
438
439 Table 4: The AES_256_CM_HMAC_SHA1_32 Crypto Suite
440
441
442
443
444 <span class="grey">McGrew Standards Track [Page 8]</span></pre>
445 <hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-9" ></span>
446 <span class="grey"><a href="./rfc6188">RFC 6188</a> SRTP AES-192 and AES-256 March 2011</span>
447
448
449 <span class="h2"><a class="selflink" id="section-5" href="#section-5">5</a>. IANA Considerations</span>
450
451 IANA has assigned the following parameters in the Session Description
452 Protocol (SDP) Security Descriptions registry.
453
454 +-------------------------+-----------+
455 | Crypto Suite Name | Reference |
456 +-------------------------+-----------+
457 | AES_192_CM_HMAC_SHA1_80 | [<a href="./rfc6188">RFC6188</a>] |
458 | AES_192_CM_HMAC_SHA1_32 | [<a href="./rfc6188">RFC6188</a>] |
459 | AES_256_CM_HMAC_SHA1_80 | [<a href="./rfc6188">RFC6188</a>] |
460 | AES_256_CM_HMAC_SHA1_32 | [<a href="./rfc6188">RFC6188</a>] |
461 +-------------------------+-----------+
462
463 <span class="h2"><a class="selflink" id="section-6" href="#section-6">6</a>. Security Considerations</span>
464
465 AES-128 provides a level of security that is widely regarded as being
466 more than sufficient for providing confidentiality. It is believed
467 that the economic cost of breaking AES-128 is significantly higher
468 than the cost of more direct approaches to violating system security,
469 e.g., theft, bribery, wiretapping, and other forms of malfeasance.
470
471 Future advances in state-of-the art cryptanalysis could eliminate
472 this confidence in AES-128, and motivate the use of AES-192 or AES-
473 256. AES-192 is regarded as being secure even against some
474 adversaries for which breaking AES-128 may be feasible. Similarly,
475 AES-256 is regarded as being secure even against some adversaries for
476 which it may be feasible to break AES-192. The availability of the
477 larger key size versions of AES provides a fallback plan in case of
478 unanticipated cryptanalytic results.
479
480 It is conjectured that AES-256 provides adequate security even
481 against adversaries that possess the ability to construct a quantum
482 computer that works on 256 or more quantum bits. No such computer is
483 known to exist; its feasibility is an area of active speculation and
484 research.
485
486 Despite the apparent sufficiency of AES-128, some users are
487 interested in the larger AES key sizes. For some applications, the
488 40% increase in computational cost for AES-256 over AES-128 is a
489 worthwhile bargain when traded for the security advantages outlined
490 above. These applications include those with a perceived need for
491 very high security, e.g., due to a desire for very long-term
492 confidentiality.
493
494 AES-256 (as it is used in this note) provides the highest level of
495 security, and it SHOULD be used whenever the highest possible
496 security is desired. AES-192 provides a middle ground between the
497
498
499
500 <span class="grey">McGrew Standards Track [Page 9]</span></pre>
501 <hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-10" ></span>
502 <span class="grey"><a href="./rfc6188">RFC 6188</a> SRTP AES-192 and AES-256 March 2011</span>
503
504
505 128-bit and 256-bit versions of AES, and it MAY be used when security
506 higher than that of AES-128 is desired. In this note, AES-192 and
507 AES-256 are used with keys that are generated via a strong pseudo-
508 random source, and thus the related-key attacks that have been
509 described in the theoretical literature are not applicable.
510
511 As with any cipher, the conjectured security level of AES may change
512 over time. The considerations in this section reflect the best
513 knowledge available at the time of publication of this document.
514
515 It is desirable that AES_192_CM and AES_192_CM_PRF be used with an
516 authentication function that uses a 192-bit key, and that AES_256_CM
517 and AES_256_CM_PRF be used with an authentication function that uses
518 a 256-bit key. However, this desire is not regarded as security
519 critical. Cryptographic authentication is resilient against future
520 advances in cryptanalysis, since the opportunity for a forgery attack
521 against a session closes when that session closes. For this reason,
522 this note defines new ciphers, but not new authentication functions.
523
524 <span class="h2"><a class="selflink" id="section-7" href="#section-7">7</a>. Test Cases</span>
525
526 The test cases in this section are based on <a href="./rfc3711#appendix-B">Appendix&nbsp;B of [RFC3711]</a>.
527
528 <span class="h3"><a class="selflink" id="section-7.1" href="#section-7.1">7.1</a>. AES-256-CM Test Cases</span>
529
530
531 Keystream segment length: 1044512 octets (65282 AES blocks)
532 Session Key: 57f82fe3613fd170a85ec93c40b1f092
533 2ec4cb0dc025b58272147cc438944a98
534 Rollover Counter: 00000000
535 Sequence Number: 0000
536 SSRC: 00000000
537 Session Salt: f0f1f2f3f4f5f6f7f8f9fafbfcfd0000 (already shifted)
538 Offset: f0f1f2f3f4f5f6f7f8f9fafbfcfd0000
539
540 Counter Keystream
541
542 f0f1f2f3f4f5f6f7f8f9fafbfcfd0000 92bdd28a93c3f52511c677d08b5515a4
543 f0f1f2f3f4f5f6f7f8f9fafbfcfd0001 9da71b2378a854f67050756ded165bac
544 f0f1f2f3f4f5f6f7f8f9fafbfcfd0002 63c4868b7096d88421b563b8c94c9a31
545 ... ...
546 f0f1f2f3f4f5f6f7f8f9fafbfcfdfeff cea518c90fd91ced9cbb18c078a54711
547 f0f1f2f3f4f5f6f7f8f9fafbfcfdff00 3dbc4814f4da5f00a08772b63c6a046d
548 f0f1f2f3f4f5f6f7f8f9fafbfcfdff01 6eb246913062a16891433e97dd01a57f
549
550
551
552
553
554
555
556 <span class="grey">McGrew Standards Track [Page 10]</span></pre>
557 <hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-11" ></span>
558 <span class="grey"><a href="./rfc6188">RFC 6188</a> SRTP AES-192 and AES-256 March 2011</span>
559
560
561 <span class="h3"><a class="selflink" id="section-7.2" href="#section-7.2">7.2</a>. AES_256_CM_PRF Test Cases</span>
562
563 This section provides test data for the AES_256_CM_PRF key derivation
564 function, which uses AES-256 in counter mode. In the following, we
565 walk through the initial key derivation for the AES-256 counter mode
566 cipher, which requires a 32-octet session encryption key and a 14-
567 octet session salt, and the HMAC-SHA1 authentication function, which
568 requires a 20-octet session authentication key. These values are
569 called the cipher key, the cipher salt, and the auth key in the
570 following. Since this is the initial key derivation and the key
571 derivation rate is equal to zero, the value of (index DIV
572 key_derivation_rate) is zero (actually, a six-octet string of zeros).
573 In the following, we shorten key_derivation_rate to kdr.
574
575 The inputs to the key derivation function are the 32-octet master key
576 and the 14-octet master salt:
577
578 master key: f0f04914b513f2763a1b1fa130f10e29
579 98f6f6e43e4309d1e622a0e332b9f1b6
580 master salt: 3b04803de51ee7c96423ab5b78d2
581
582 We first show how the cipher key is generated. The input block for
583 AES-256-CM is generated by exclusive-oring the master salt with the
584 concatenation of the encryption key label 0x00 with (index DIV kdr),
585 then padding on the right with two null octets (which implements the
586 multiply-by-2^16 operation, see <a href="./rfc3711#section-4.3.3">Section&nbsp;4.3.3 of RFC 3711</a>). The
587 resulting value is then AES-256-CM-encrypted using the master key to
588 get the cipher key.
589
590 index DIV kdr: 000000000000
591 label: 00
592 master salt: 3b04803de51ee7c96423ab5b78d2
593 -----------------------------------------------
594 xor: 3b04803de51ee7c96423ab5b78d2 (x, PRF input)
595
596 x*2^16: 3b04803de51ee7c96423ab5b78d20000 (AES-256-CM input)
597 x*2^16 + 1: 3b04803de51ee7c96423ab5b78d20001 (2nd AES input)
598
599 cipher key: 5ba1064e30ec51613cad926c5a28ef73 (1st AES output)
600 1ec7fb397f70a960653caf06554cd8c4 (2nd AES output)
601
602 Next, we show how the cipher salt is generated. The input block for
603 AES-256-CM is generated by exclusive-oring the master salt with the
604 concatenation of the encryption salt label. That value is padded and
605 encrypted as above.
606
607
608
609
610
611
612 <span class="grey">McGrew Standards Track [Page 11]</span></pre>
613 <hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-12" ></span>
614 <span class="grey"><a href="./rfc6188">RFC 6188</a> SRTP AES-192 and AES-256 March 2011</span>
615
616
617 index DIV kdr: 000000000000
618 label: 02
619 master salt: 3b04803de51ee7c96423ab5b78d2
620
621 ----------------------------------------------
622 xor: 3b04803de51ee7cb6423ab5b78d2 (x, PRF input)
623
624 x*2^16: 3b04803de51ee7cb6423ab5b78d20000 (AES-256-CM input)
625
626 fa31791685ca444a9e07c6c64e93ae6b (AES-256 ouptut)
627
628 cipher salt: fa31791685ca444a9e07c6c64e93
629
630 We now show how the auth key is generated. The input block for AES-
631 256-CM is generated as above, but using the authentication key label.
632
633 index DIV kdr: 000000000000
634 label: 01
635 master salt: 3b04803de51ee7c96423ab5b78d2
636 -----------------------------------------------
637 xor: 3b04803de51ee7c86423ab5b78d2 (x, PRF input)
638
639 x*2^16: 3b04803de51ee7c86423ab5b78d20000 (AES-256-CM in)
640
641 Below, the AES-256 output blocks that form the auth key are shown
642 on the left, while the corresponding AES-256 input blocks are shown
643 on the right. Note that the final AES-256 output is truncated to a
644 4-byte length. The final auth key is shown below.
645
646 auth key blocks AES-256 input blocks
647 fd9c32d39ed5fbb5a9dc96b30818454d 3b04803de51ee7c86423ab5b78d20000
648 1313dc05 3b04803de51ee7c86423ab5b78d20001
649
650 auth key: fd9c32d39ed5fbb5a9dc96b30818454d1313dc05
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668 <span class="grey">McGrew Standards Track [Page 12]</span></pre>
669 <hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-13" ></span>
670 <span class="grey"><a href="./rfc6188">RFC 6188</a> SRTP AES-192 and AES-256 March 2011</span>
671
672
673 <span class="h3"><a class="selflink" id="section-7.3" href="#section-7.3">7.3</a>. AES-192-CM Test Cases</span>
674
675 Keystream segment length: 1044512 octets (65282 AES blocks)
676 Session Key: eab234764e517b2d3d160d587d8c8621
677 9740f65f99b6bcf7
678 Rollover Counter: 00000000
679 Sequence Number: 0000
680 SSRC: 00000000
681 Session Salt: f0f1f2f3f4f5f6f7f8f9fafbfcfd0000 (already shifted)
682 Offset: f0f1f2f3f4f5f6f7f8f9fafbfcfd0000
683
684 Counter Keystream
685
686 f0f1f2f3f4f5f6f7f8f9fafbfcfd0000 35096cba4610028dc1b57503804ce37c
687 f0f1f2f3f4f5f6f7f8f9fafbfcfd0001 5de986291dcce161d5165ec4568f5c9a
688 f0f1f2f3f4f5f6f7f8f9fafbfcfd0002 474a40c77894bc17180202272a4c264d
689 ... ...
690 f0f1f2f3f4f5f6f7f8f9fafbfcfdfeff d108d1a31a00bad6367ec23eb044b415
691 f0f1f2f3f4f5f6f7f8f9fafbfcfdff00 c8f57129fdeb970b59f917b257662d4c
692 f0f1f2f3f4f5f6f7f8f9fafbfcfdff01 a5dab625811034e8cebdfeb6dc158dd3
693
694 <span class="h3"><a class="selflink" id="section-7.4" href="#section-7.4">7.4</a>. AES_192_CM_PRF Test Cases</span>
695
696 This section provides test data for the AES_192_CM_PRF key derivation
697 function, which uses AES-192 in counter mode. In the following, we
698 walk through the initial key derivation for the AES-192 counter mode
699 cipher, which requires a 24-octet session encryption key and a 14-
700 octet session salt, and the HMAC-SHA1 authentication function, which
701 requires a 20-octet session authentication key. These values are
702 called the cipher key, the cipher salt, and the auth key in the
703 following. Since this is the initial key derivation and the key
704 derivation rate is equal to zero, the value of (index DIV
705 key_derivation_rate) is zero (actually, a six-octet string of zeros).
706 In the following, we shorten key_derivation_rate to kdr.
707
708 The inputs to the key derivation function are the 24-octet master key
709 and the 14-octet master salt:
710
711 master key: 73edc66c4fa15776fb57f9505c171365
712 50ffda71f3e8e5f1
713 master salt: c8522f3acd4ce86d5add78edbb11
714
715 We first show how the cipher key is generated. The input block for
716 AES-192-CM is generated by exclusive-oring the master salt with the
717 concatenation of the encryption key label 0x00 with (index DIV kdr),
718 then padding on the right with two null octets (which implements the
719
720
721
722
723
724 <span class="grey">McGrew Standards Track [Page 13]</span></pre>
725 <hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-14" ></span>
726 <span class="grey"><a href="./rfc6188">RFC 6188</a> SRTP AES-192 and AES-256 March 2011</span>
727
728
729 multiply-by-2^16 operation, see <a href="./rfc3711#section-4.3.3">Section&nbsp;4.3.3 of RFC 3711</a>). The
730 resulting value is then AES-192-CM encrypted using the master key to
731 get the cipher key.
732
733 index DIV kdr: 000000000000
734 label: 00
735 master salt: c8522f3acd4ce86d5add78edbb11
736 -----------------------------------------------
737 xor: c8522f3acd4ce86d5add78edbb11 (x, PRF input)
738
739 x*2^16: c8522f3acd4ce86d5add78edbb110000 (AES-192-CM input)
740 x*2^16 + 1: c8522f3acd4ce86d5add78edbb110001 (2nd AES input)
741
742 cipher key: 31874736a8f1143870c26e4857d8a5b2 (1st AES output)
743 c4a354407faadabb (2nd AES output)
744
745 Next, we show how the cipher salt is generated. The input block for
746 AES-192-CM is generated by exclusive-oring the master salt with the
747 concatenation of the encryption salt label. That value is padded and
748 encrypted as above.
749
750 index DIV kdr: 000000000000
751 label: 02
752 master salt: c8522f3acd4ce86d5add78edbb11
753
754 ----------------------------------------------
755 xor: c8522f3acd4ce86f5add78edbb11 (x, PRF input)
756
757 x*2^16: c8522f3acd4ce86f5add78edbb110000 (AES-192-CM input)
758
759 2372b82d639b6d8503a47adc0a6c2590 (AES-192 ouptut)
760
761 cipher salt: 2372b82d639b6d8503a47adc0a6c
762
763 We now show how the auth key is generated. The input block for AES-
764 192-CM is generated as above, but using the authentication key label.
765
766 index DIV kdr: 000000000000
767 label: 01
768 master salt: c8522f3acd4ce86d5add78edbb11
769 -----------------------------------------------
770 xor: c8522f3acd4ce86c5add78edbb11 (x, PRF input)
771
772 x*2^16: c8522f3acd4ce86c5add78edbb110000 (AES-192-CM in)
773
774
775
776
777
778
779
780 <span class="grey">McGrew Standards Track [Page 14]</span></pre>
781 <hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-15" ></span>
782 <span class="grey"><a href="./rfc6188">RFC 6188</a> SRTP AES-192 and AES-256 March 2011</span>
783
784
785 Below, the AES-192 output blocks that form the auth key are shown
786 on the left, while the corresponding AES-192 input blocks are shown
787 on the right. Note that the final AES-192 output is truncated to a
788 four-byte length. The final auth key is shown below.
789
790 auth key blocks AES-192 input blocks
791 355b10973cd95b9eacf4061c7e1a7151 c8522f3acd4ce86c5add78edbb110000
792 e7cfbfcb c8522f3acd4ce86c5add78edbb110001
793
794 auth key: 355b10973cd95b9eacf4061c7e1a7151e7cfbfcb
795
796 <span class="h2"><a class="selflink" id="section-8" href="#section-8">8</a>. Acknowledgements</span>
797
798 Thanks are due to John Mattsson for verifying the test cases in the
799 document and providing comments, to Bob Bell for feedback and
800 encouragement, and to Richard Barnes and Hilarie Orman for
801 constructive review.
802
803 <span class="h2"><a class="selflink" id="section-9" href="#section-9">9</a>. References</span>
804
805 <span class="h3"><a class="selflink" id="section-9.1" href="#section-9.1">9.1</a>. Normative References</span>
806
807 [<a id="ref-FIPS197">FIPS197</a>] "The Advanced Encryption Standard (AES)", FIPS-197 Federal
808 Information Processing Standard.
809
810 [<a id="ref-RFC2119">RFC2119</a>] Bradner, S., "Key words for use in RFCs to Indicate
811 Requirement Levels", <a href="https://www.rfc-editor.org/bcp/bcp14">BCP 14</a>, <a href="./rfc2119">RFC 2119</a>, March 1997.
812
813 [<a id="ref-RFC3550">RFC3550</a>] Schulzrinne, H., Casner, S., Frederick, R., and V.
814 Jacobson, "RTP: A Transport Protocol for Real-Time
815 Applications", STD 64, <a href="./rfc3550">RFC 3550</a>, July 2003.
816
817 [<a id="ref-RFC3711">RFC3711</a>] Baugher, M., McGrew, D., Naslund, M., Carrara, E., and K.
818 Norrman, "The Secure Real-time Transport Protocol (SRTP)",
819 <a href="./rfc3711">RFC 3711</a>, March 2004.
820
821 [<a id="ref-RFC4568">RFC4568</a>] Andreasen, F., Baugher, M., and D. Wing, "Session
822 Description Protocol (SDP) Security Descriptions for Media
823 Streams", <a href="./rfc4568">RFC 4568</a>, July 2006.
824
825 <span class="h3"><a class="selflink" id="section-9.2" href="#section-9.2">9.2</a>. Informative References</span>
826
827 [<a id="ref-suiteB">suiteB</a>] "Suite B Cryptography", <a href="http://www.nsa.gov/ia/programs/suiteb_cryptography/index.shtml">http://www.nsa.gov/ia/programs/</a>
828 <a href="http://www.nsa.gov/ia/programs/suiteb_cryptography/index.shtml">suiteb_cryptography/index.shtml</a>.
829
830
831
832
833
834
835
836 <span class="grey">McGrew Standards Track [Page 15]</span></pre>
837 <hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-16" ></span>
838 <span class="grey"><a href="./rfc6188">RFC 6188</a> SRTP AES-192 and AES-256 March 2011</span>
839
840
841 Author's Address
842
843 David A. McGrew
844 Cisco Systems, Inc.
845 510 McCarthy Blvd.
846 Milpitas, CA 95035
847 US
848
849 Phone: (408) 525 8651
850 EMail: [email protected]
851 URI: <a href="http://www.mindspring.com/~dmcgrew/dam.htm">http://www.mindspring.com/~dmcgrew/dam.htm</a>
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892 McGrew Standards Track [Page 16]
893 </pre>