draft-ietf-kitten-aes-cts-hmac-sha2-07.txt   draft-ietf-kitten-aes-cts-hmac-sha2-08.txt 
Network Working Group M. Jenkins Network Working Group M. Jenkins
Internet Draft National Security Agency Internet Draft National Security Agency
Intended Status: Informational M. Peck Intended Status: Informational M. Peck
Expires: June 5, 2016 The MITRE Corporation Expires: June 11, 2016 The MITRE Corporation
K. Burgin K. Burgin
December 3, 2015 December 9, 2015
AES Encryption with HMAC-SHA2 for Kerberos 5 AES Encryption with HMAC-SHA2 for Kerberos 5
draft-ietf-kitten-aes-cts-hmac-sha2-07 draft-ietf-kitten-aes-cts-hmac-sha2-08
Abstract Abstract
This document specifies two encryption types and two corresponding This document specifies two encryption types and two corresponding
checksum types for Kerberos 5. The new types use AES in CTS mode checksum types for Kerberos 5. The new types use AES in CTS mode
(CBC mode with ciphertext stealing) for confidentiality and HMAC with (CBC mode with ciphertext stealing) for confidentiality and HMAC with
a SHA-2 hash for integrity. a SHA-2 hash for integrity.
Status of this Memo Status of this Memo
skipping to change at page 1, line 35 skipping to change at page 1, line 35
Internet-Drafts are working documents of the Internet Engineering Internet-Drafts are working documents of the Internet Engineering
Task Force (IETF). Note that other groups may also distribute Task Force (IETF). Note that other groups may also distribute
working documents as Internet-Drafts. The list of current Internet- working documents as Internet-Drafts. The list of current Internet-
Drafts is at http://datatracker.ietf.org/drafts/current/. Drafts is at http://datatracker.ietf.org/drafts/current/.
Internet-Drafts are draft documents valid for a maximum of six months Internet-Drafts are draft documents valid for a maximum of six months
and may be updated, replaced, or obsoleted by other documents at any and may be updated, replaced, or obsoleted by other documents at any
time. It is inappropriate to use Internet-Drafts as reference time. It is inappropriate to use Internet-Drafts as reference
material or to cite them other than as "work in progress." material or to cite them other than as "work in progress."
This Internet-Draft will expire on June 5, 2016. This Internet-Draft will expire on June 11, 2016.
Copyright and License Notice Copyright and License Notice
Copyright (c) 2015 IETF Trust and the persons identified as the Copyright (c) 2015 IETF Trust and the persons identified as the
document authors. All rights reserved. document authors. All rights reserved.
This document is subject to BCP 78 and the IETF Trust's Legal This document is subject to BCP 78 and the IETF Trust's Legal
Provisions Relating to IETF Documents Provisions Relating to IETF Documents
(http://trustee.ietf.org/license-info) in effect on the date of (http://trustee.ietf.org/license-info) in effect on the date of
publication of this document. Please review these documents publication of this document. Please review these documents
skipping to change at page 2, line 14 skipping to change at page 2, line 14
Table of Contents Table of Contents
1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . . 3 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . . 3
2. Protocol Key Representation . . . . . . . . . . . . . . . . . 3 2. Protocol Key Representation . . . . . . . . . . . . . . . . . 3
3. Key Derivation Function . . . . . . . . . . . . . . . . . . . 3 3. Key Derivation Function . . . . . . . . . . . . . . . . . . . 3
4. Key Generation from Pass Phrases . . . . . . . . . . . . . . . 4 4. Key Generation from Pass Phrases . . . . . . . . . . . . . . . 4
5. Kerberos Algorithm Protocol Parameters . . . . . . . . . . . . 5 5. Kerberos Algorithm Protocol Parameters . . . . . . . . . . . . 5
6. Checksum Parameters . . . . . . . . . . . . . . . . . . . . . 7 6. Checksum Parameters . . . . . . . . . . . . . . . . . . . . . 7
7. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 7 7. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 7
8. Security Considerations . . . . . . . . . . . . . . . . . . . 7 8. Security Considerations . . . . . . . . . . . . . . . . . . . 8
8.1. Random Values in Salt Strings . . . . . . . . . . . . . . 8 8.1. Random Values in Salt Strings . . . . . . . . . . . . . . 8
8.2. Algorithm Rationale . . . . . . . . . . . . . . . . . . . 8 8.2. Algorithm Rationale . . . . . . . . . . . . . . . . . . . 9
9. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . . 9 9. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . . 9
10. References . . . . . . . . . . . . . . . . . . . . . . . . . 9 10. References . . . . . . . . . . . . . . . . . . . . . . . . . 9
10.1. Normative References . . . . . . . . . . . . . . . . . . 9 10.1. Normative References . . . . . . . . . . . . . . . . . . 9
10.2. Informative References . . . . . . . . . . . . . . . . . 9 10.2. Informative References . . . . . . . . . . . . . . . . . 9
Appendix A. Test Vectors . . . . . . . . . . . . . . . . . . . . 10 Appendix A. Test Vectors . . . . . . . . . . . . . . . . . . . . 10
Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . . 16 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . . 17
1. Introduction 1. Introduction
This document defines two encryption types and two corresponding This document defines two encryption types and two corresponding
checksum types for Kerberos 5 using AES with 128-bit or 256-bit keys. checksum types for Kerberos 5 using AES with 128-bit or 256-bit keys.
To avoid ciphertext expansion, we use a variation of the CBC-CS3 mode To avoid ciphertext expansion, we use a variation of the CBC-CS3 mode
defined in [SP800-38A+], also referred to as ciphertext stealing or defined in [SP800-38A+], also referred to as ciphertext stealing or
CTS mode. The new types conform to the framework specified in CTS mode. The new types conform to the framework specified in
[RFC3961], but do not use the simplified profile. [RFC3961], but do not use the simplified profile.
skipping to change at page 4, line 34 skipping to change at page 4, line 34
K1 = HMAC-SHA-256(key, 0x00000001 | label | 0x00 | k) K1 = HMAC-SHA-256(key, 0x00000001 | label | 0x00 | k)
When the encryption type is aes256-cts-hmac-sha384-192, then K1 is When the encryption type is aes256-cts-hmac-sha384-192, then K1 is
computed as follows: computed as follows:
K1 = HMAC-SHA-384(key, 0x00000001 | label | 0x00 | k) K1 = HMAC-SHA-384(key, 0x00000001 | label | 0x00 | k)
4. Key Generation from Pass Phrases 4. Key Generation from Pass Phrases
PBKDF2 [RFC2898] is used to derive the base-key from a passphrase and As defined below, the string-to-key function uses PBKDF2 [RFC2898]
salt. and KDF-HMAC-SHA2 to derive the base-key from a passphrase and salt.
To ensure that different long-term base-keys are used with different To ensure that different long-term base-keys are used with different
enctypes, we prepend the enctype name to the salt, separated by a enctypes, we prepend the enctype name to the salt, separated by a
null byte. The enctype-name is "aes128-cts-hmac-sha256-128" or null byte. The enctype-name is "aes128-cts-hmac-sha256-128" or
"aes256-cts-hmac-sha384-192" (without the quotes). "aes256-cts-hmac-sha384-192" (without the quotes).
The user's long-term base-key is derived as follows: The user's long-term base-key is derived as follows:
iter_count = string-to-key parameter (default is iter_count = string-to-key parameter (default is
decimal 32768 if not specified) decimal 32768 if not specified)
saltp = enctype-name | 0x00 | salt saltp = enctype-name | 0x00 | salt
tkey = PBKDF2(passphrase, saltp, iter_count, keylength) tkey = random-to-key(PBKDF2(passphrase, saltp,
base-key = KDF-HMAC-SHA2(tkey, "kerberos", keylength) iter_count, keylength))
base-key = random-to-key(KDF-HMAC-SHA2(tkey, "kerberos",
keylength))
where "kerberos" is the octet-string where "kerberos" is the octet-string
0x6B65726265726F73 0x6B65726265726F73
where the pseudorandom function used by PBKDF2 is HMAC-SHA-256 when where the pseudorandom function used by PBKDF2 is HMAC-SHA-256 when
the enctype is "aes128-cts-hmac-sha256-128" and HMAC-SHA-384 when the the enctype is "aes128-cts-hmac-sha256-128" and HMAC-SHA-384 when the
enctype is "aes256-cts-hmac-sha384-192", the value for keylength is enctype is "aes256-cts-hmac-sha384-192", the value for keylength is
the AES key length (128 or 256 bits), and the algorithm KDF-HMAC-SHA2 the AES key length (128 or 256 bits), and the algorithm KDF-HMAC-SHA2
is defined in Section 3. is defined in Section 3.
5. Kerberos Algorithm Protocol Parameters 5. Kerberos Algorithm Protocol Parameters
skipping to change at page 6, line 7 skipping to change at page 6, line 7
function" below. function" below.
required checksum mechanism: as defined in Section 6. required checksum mechanism: as defined in Section 6.
key-generation seed length: key size (128 or 256 bits). key-generation seed length: key size (128 or 256 bits).
string-to-key function: as defined in Section 4. string-to-key function: as defined in Section 4.
default string-to-key parameters: decimal 32768. default string-to-key parameters: decimal 32768.
random-to-key function: identity function.
key-derivation function: KDF-HMAC-SHA2 as defined in Section 3. The key-derivation function: KDF-HMAC-SHA2 as defined in Section 3. The
key usage number is expressed as four octets in big-endian order. key usage number is expressed as four octets in big-endian order.
If the enctype is aes128-cts-hmac-sha256-128: If the enctype is aes128-cts-hmac-sha256-128:
Kc = KDF-HMAC-SHA2(base-key, usage | 0x99, 128) Kc = KDF-HMAC-SHA2(base-key, usage | 0x99, 128)
Ke = KDF-HMAC-SHA2(base-key, usage | 0xAA, 128) Ke = KDF-HMAC-SHA2(base-key, usage | 0xAA, 128)
Ki = KDF-HMAC-SHA2(base-key, usage | 0x55, 128) Ki = KDF-HMAC-SHA2(base-key, usage | 0x55, 128)
If the enctype is aes256-cts-hmac-sha384-192: If the enctype is aes256-cts-hmac-sha384-192:
Kc = KDF-HMAC-SHA2(base-key, usage | 0x99, 192) Kc = KDF-HMAC-SHA2(base-key, usage | 0x99, 192)
skipping to change at page 6, line 34 skipping to change at page 6, line 36
encryption function: as follows, where E() is AES encryption in encryption function: as follows, where E() is AES encryption in
CBC-CS3 mode, and h is the size of truncated HMAC (128 bits or CBC-CS3 mode, and h is the size of truncated HMAC (128 bits or
192 bits as described above). 192 bits as described above).
N = random nonce of length 128 bits (the AES block size) N = random nonce of length 128 bits (the AES block size)
IV = cipherstate IV = cipherstate
C = E(Ke, N | plaintext, IV) C = E(Ke, N | plaintext, IV)
H = HMAC(Ki, IV | C) H = HMAC(Ki, IV | C)
ciphertext = C | H[1..h] ciphertext = C | H[1..h]
cipherstate = the last full (128 bit) block of C
(i.e. the next-to-last block if the last block Steps to compute the 128-bit cipherstate:
is not a full 128 bits) L = length of C in bits
portion C into 128-bit blocks, placing any remainder
of less than 128 bits into a final block
if L == 128: cipherstate = C
else if L mod 128 > 0: cipherstate = last full (128-bit)
block of C (the
next-to-last block)
else if L mod 128 == 0: cipherstate = next-to-last block
of C
decryption function: as follows, where D() is AES decryption in decryption function: as follows, where D() is AES decryption in
CBC-CS3 mode, and h is the size of truncated HMAC. CBC-CS3 mode, and h is the size of truncated HMAC.
(C, H) = ciphertext (C, H) = ciphertext
IV = cipherstate IV = cipherstate
if H != HMAC(Ki, IV | C)[1..h] if H != HMAC(Ki, IV | C)[1..h]
stop, report error stop, report error
(N, P) = D(Ke, C, IV) (N, P) = D(Ke, C, IV)
Note: N is set to the first block of the decryption output, Note: N is set to the first block of the decryption output,
P is set to the rest of the output. P is set to the rest of the output.
cipherstate = the last full (128 bit) block of C cipherstate = same as described above in encryption function
(i.e. the next-to-last block if the last block
is not a full 128 bits)
pseudo-random function: pseudo-random function:
If the enctype is aes128-cts-hmac-sha256-128: If the enctype is aes128-cts-hmac-sha256-128:
PRF = KDF-HMAC-SHA2(base-key, "prf" | octet-string, 256) PRF = KDF-HMAC-SHA2(base-key, "prf" | octet-string, 256)
If the enctype is aes256-cts-hmac-sha384-192: If the enctype is aes256-cts-hmac-sha384-192:
PRF = KDF-HMAC-SHA2(base-key, "prf" | octet-string, 384) PRF = KDF-HMAC-SHA2(base-key, "prf" | octet-string, 384)
where "prf" is the octet-string 0x707266 where "prf" is the octet-string 0x707266
6. Checksum Parameters 6. Checksum Parameters
 End of changes. 13 change blocks. 
18 lines changed or deleted 27 lines changed or added

This html diff was produced by rfcdiff 1.42. The latest version is available from http://tools.ietf.org/tools/rfcdiff/