idnits 2.17.00 (12 Aug 2021) /tmp/idnits21119/draft-ietf-lamps-crmf-update-algs-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 draft header indicates that this document updates RFC4211, but the abstract doesn't seem to directly say this. It does mention RFC4211 though, so this could be OK. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year (Using the creation date from RFC4211, updated by this document, for RFC5378 checks: 2000-11-29) -- The document seems to lack a disclaimer for pre-RFC5378 work, but may have content which was first submitted before 10 November 2008. If you have contacted all the original authors and they are all willing to grant the BCP78 rights to the IETF Trust, then this is fine, and you can ignore this comment. If not, you may need to add the pre-RFC5378 disclaimer. (See the Legal Provisions document at https://trustee.ietf.org/license-info for more information.) -- The document date (29 January 2021) is 477 days in the past. Is this intentional? Checking references for intended status: Proposed Standard ---------------------------------------------------------------------------- (See RFCs 3967 and 4897 for information about using normative references to lower-maturity documents in RFCs) == Missing Reference: 'HMAC' is mentioned on line 192, but not defined == Missing Reference: 'PKCS11' is mentioned on line 186, but not defined -- Possible downref: Non-RFC (?) normative reference: ref. 'AES' -- Possible downref: Non-RFC (?) normative reference: ref. 'GMAC' ** Downref: Normative reference to an Informational RFC: RFC 8018 -- Possible downref: Non-RFC (?) normative reference: ref. 'SHS' == Outdated reference: draft-ietf-lamps-cms-aes-gmac-alg has been published as RFC 9044 Summary: 1 error (**), 0 flaws (~~), 4 warnings (==), 6 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 Network Working Group R. Housley 3 Internet-Draft Vigil Security 4 Updates: 4211 (if approved) 29 January 2021 5 Intended status: Standards Track 6 Expires: 2 August 2021 8 Algorithm Requirements Update to the Internet X.509 Public Key 9 Infrastructure Certificate Request Message Format (CRMF) 10 draft-ietf-lamps-crmf-update-algs-03 12 Abstract 14 This document updates the cryptographic algorithm requirements for 15 the Password-Based Message Authentication Code in the Internet X.509 16 Public Key Infrastructure Certificate Request Message Format (CRMF) 17 specified in RFC 4211. 19 Status of This Memo 21 This Internet-Draft is submitted in full conformance with the 22 provisions of BCP 78 and BCP 79. 24 Internet-Drafts are working documents of the Internet Engineering 25 Task Force (IETF). Note that other groups may also distribute 26 working documents as Internet-Drafts. The list of current Internet- 27 Drafts is at https://datatracker.ietf.org/drafts/current/. 29 Internet-Drafts are draft documents valid for a maximum of six months 30 and may be updated, replaced, or obsoleted by other documents at any 31 time. It is inappropriate to use Internet-Drafts as reference 32 material or to cite them other than as "work in progress." 34 This Internet-Draft will expire on 2 August 2021. 36 Copyright Notice 38 Copyright (c) 2021 IETF Trust and the persons identified as the 39 document authors. All rights reserved. 41 This document is subject to BCP 78 and the IETF Trust's Legal 42 Provisions Relating to IETF Documents (https://trustee.ietf.org/ 43 license-info) in effect on the date of publication of this document. 44 Please review these documents carefully, as they describe your rights 45 and restrictions with respect to this document. Code Components 46 extracted from this document must include Simplified BSD License text 47 as described in Section 4.e of the Trust Legal Provisions and are 48 provided without warranty as described in the Simplified BSD License. 50 Table of Contents 52 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 2 53 2. Terminology . . . . . . . . . . . . . . . . . . . . . . . . . 2 54 3. Signature Key POP . . . . . . . . . . . . . . . . . . . . . . 2 55 4. Password-Based Message Authentication Code . . . . . . . . . 3 56 4.1. Introduction Paragraph . . . . . . . . . . . . . . . . . 3 57 4.2. One-Way Function . . . . . . . . . . . . . . . . . . . . 3 58 4.3. Iteration Count . . . . . . . . . . . . . . . . . . . . . 4 59 4.4. MAC Algorithm . . . . . . . . . . . . . . . . . . . . . . 4 60 5. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 6 61 6. Security Considerations . . . . . . . . . . . . . . . . . . . 6 62 7. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . 6 63 8. References . . . . . . . . . . . . . . . . . . . . . . . . . 6 64 8.1. Normative References . . . . . . . . . . . . . . . . . . 6 65 8.2. Informative References . . . . . . . . . . . . . . . . . 7 66 Author's Address . . . . . . . . . . . . . . . . . . . . . . . . 8 68 1. Introduction 70 This document updates the cryptographic algorithm requirements for 71 the Password-Based Message Authentication Code (MAC) in the Internet 72 X.509 Public Key Infrastructure Certificate Request Message Format 73 (CRMF) [RFC4211]. The algorithms specified in [RFC4211] were 74 appropriate in 2005; however, these algorithms are no longer 75 considered the best choices. This update specifies algorithms that 76 are more appropriate today. 78 2. Terminology 80 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 81 "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and 82 "OPTIONAL" in this document are to be interpreted as described in 83 BCP 14 [RFC2119] [RFC8174] when, and only when, they appear in all 84 capitals, as shown here. 86 3. Signature Key POP 88 Section 4.1 of [RFC4211] specifies the Proof-of-Possession (POP) 89 processing. This section is updated to explicitly allow the use of 90 the PBMAC1 algorithm presented in Section 7.1 of [RFC8018]. 92 OLD: 94 algId identifies the algorithm used to compute the MAC value. All 95 implementations MUST support id-PasswordBasedMAC. The details on 96 this algorithm are presented in section 4.4 97 NEW: 99 algId identifies the algorithm used to compute the MAC value. All 100 implementations MUST support id-PasswordBasedMAC as presented in 101 Section 4.4 of this document. Implementations MAY also support 102 PBMAC1 presented in Section 7.1 of [RFC8018]. 104 4. Password-Based Message Authentication Code 106 Section 4.4 of [RFC4211] specifies a Password-Based MAC that relies 107 on a one-way function to compute a symmetric key from the password 108 and a MAC algorithm. This section specifies algorithm requirements 109 for the one-way function and the MAC algorithm. 111 4.1. Introduction Paragraph 113 Add guidance about limiting the use of the password. 115 OLD: 117 This MAC algorithm was designed to take a shared secret (a 118 password) and use it to compute a check value over a piece of 119 information. The assumption is that, without the password, the 120 correct check value cannot be computed. The algorithm computes 121 the one-way function multiple times in order to slow down any 122 dictionary attacks against the password value. 124 NEW: 126 This MAC algorithm was designed to take a shared secret (a 127 password) and use it to compute a check value over a piece of 128 information. The assumption is that, without the password, the 129 correct check value cannot be computed. The algorithm computes 130 the one-way function multiple times in order to slow down any 131 dictionary attacks against the password value. The password used 132 to compute this MAC SHOULD NOT be used for any other purpose. 134 4.2. One-Way Function 136 Change the paragraph describing the "owf" as follows: 138 OLD: 140 owf identifies the algorithm and associated parameters used to 141 compute the key used in the MAC process. All implementations MUST 142 support SHA-1. 144 NEW: 146 owf identifies the algorithm and associated parameters used to 147 compute the key used in the MAC process. All implementations MUST 148 support SHA-256 [SHS]. 150 4.3. Iteration Count 152 Update the guidance on appropriate iteration count values. 154 OLD: 156 iterationCount identifies the number of times the hash is applied 157 during the key computation process. The iterationCount MUST be a 158 minimum of 100. Many people suggest using values as high as 1000 159 iterations as the minimum value. The trade off here is between 160 protection of the password from attacks and the time spent by the 161 server processing all of the different iterations in deriving 162 passwords. Hashing is generally considered a cheap operation but 163 this may not be true with all hash functions in the future. 165 NEW: 167 iterationCount identifies the number of times the hash is applied 168 during the key computation process. The iterationCount MUST be a 169 minimum of 100; however, the iterationCount SHOULD be as large as 170 server performance will allow, typically at least 10,000 [DIGALM]. 171 There is a trade off between protection of the password from 172 attacks and the time spent by the server processing the 173 iterations. As part of that tradeoff, an iteration count smaller 174 than 10,000 can be used when automated generation produces shared 175 secrets with high entropy. 177 4.4. MAC Algorithm 179 Change the paragraph describing the "mac" as follows: 181 OLD: 183 mac identifies the algorithm and associated parameters of the MAC 184 function to be used. All implementations MUST support HMAC-SHA1 185 [HMAC]. All implementations SHOULD support DES-MAC and Triple- 186 DES-MAC [PKCS11]. 188 NEW: 190 mac identifies the algorithm and associated parameters of the MAC 191 function to be used. All implementations MUST support HMAC-SHA256 192 [HMAC]. All implementations SHOULD support AES-GMAC AES [GMAC] 193 with a 128 bit key. 195 For convenience, the identifiers for these two algorithms are 196 repeated here. 198 The algorithm identifier for HMAC-SHA256 is defined in [RFC4231]: 200 id-hmacWithSHA256 OBJECT IDENTIFIER ::= { iso(1) member-body(2) 201 us(840) rsadsi(113549) digestAlgorithm(2) 9 } 203 When this algorithm identifier is used, the parameters SHOULD be 204 present. When present, the parameters MUST contain a type of NULL. 206 The algorithm identifier for AES-GMAC [AES][GMAC] with a 128-bit key 207 is defined in [I-D.ietf-lamps-cms-aes-gmac-alg]: 209 id-aes128-GMAC OBJECT IDENTIFIER ::= { joint-iso-itu-t(2) 210 country(16) us(840) organization(1) gov(101) csor(3) 211 nistAlgorithm(4) aes(1) 9 } 213 When this algorithm identifier is used, the parameters MUST be 214 present, and the parameters MUST contain the GMACParameters structure 215 as follows: 217 GMACParameters ::= SEQUENCE { 218 nonce OCTET STRING, 219 length MACLength DEFAULT 12 } 221 MACLength ::= INTEGER (12 | 13 | 14 | 15 | 16) 223 The GMACParameters nonce parameter is the GMAC initialization vector. 224 The nonce may have any number of bits between 8 and (2^64)-1, but it 225 MUST be a multiple of 8 bits. Within the scope of any GMAC key, the 226 nonce value MUST be unique. A nonce value of 12 octets can be 227 processed more efficiently, so that length for the nonce value is 228 RECOMMENDED. 230 The GMACParameters length parameter field tells the size of the 231 message authentication code in octets. GMAC supports lengths between 232 12 and 16 octets, inclusive. However, for use with CRMF, the maximum 233 length of 16 octets MUST be used. 235 5. IANA Considerations 237 This document makes no requests of the IANA. 239 6. Security Considerations 241 The security of the password-based MAC relies on the number of times 242 the hash function is applied as well as the entropy of the shared 243 secret (the password). Hardware support for hash calculation is 244 available at very low cost [PHS], which reduces the protection 245 provided by a high iterationCount value. Therefore, the entropy of 246 the password is crucial for the security of the password-based MAC 247 function. In 2010, researchers showed that about half of the real- 248 world passwords can be broken with less than 150 million trials, 249 indicating a median entropy of only 27 bits [DMR]. Higher entropy 250 can be achieved by using randomly generated strings. For example, 251 assuming an alphabet of 60 characters a randomly chosen password with 252 10 characters offers 59 bits a entropy, and 20 characters offers 118 253 bits of entropy. Using a one-time password also increases the 254 security of the MAC, assuming that the integrity-protected 255 transaction will complete before the attacker is able to learn the 256 password with an offline attack. 258 Cryptographic algorithms age; they become weaker with time. As new 259 cryptanalysis techniques are developed and computing capabilities 260 improve, the work required to break a particular cryptographic 261 algorithm will reduce, making an attack on the algorithm more 262 feasible for more attackers. While it is unknown how cryptoanalytic 263 attacks will evolve, it is certain that they will get better. It is 264 unknown how much better they will become or when the advances will 265 happen. For this reason, the algorithm requirements for CRMF are 266 updated by this specification. 268 When a Password-Based MAC is used, implementations must protect the 269 password and the MAC key. Compromise of either the password or the 270 MAC key may result in the ability of an attacker to undermine 271 authentication. 273 7. Acknowledgements 275 Many thanks to Hans Aschauer, Hendrik Brockhaus, Quynh Dang, Roman 276 Danyliw, Tomas Gustavsson, Jonathan Hammell, Lijun Liao, Mike 277 Ounsworth, Tim Polk, Mike StJohns, and Sean Turner for their careful 278 review and improvements. 280 8. References 282 8.1. Normative References 284 [AES] National Institute of Standards and Technology, "Advanced 285 encryption standard (AES)", DOI 10.6028/nist.fips.197, 286 November 2001, . 288 [GMAC] National Institute of Standards and Technology, 289 "Recommendation for block cipher modes of operation: 290 Galois Counter Mode (GCM) and GMAC", 291 DOI 10.6028/nist.sp.800-38d, 2007, 292 . 294 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 295 Requirement Levels", BCP 14, RFC 2119, 296 DOI 10.17487/RFC2119, March 1997, 297 . 299 [RFC4211] Schaad, J., "Internet X.509 Public Key Infrastructure 300 Certificate Request Message Format (CRMF)", RFC 4211, 301 DOI 10.17487/RFC4211, September 2005, 302 . 304 [RFC8018] Moriarty, K., Ed., Kaliski, B., and A. Rusch, "PKCS #5: 305 Password-Based Cryptography Specification Version 2.1", 306 RFC 8018, DOI 10.17487/RFC8018, January 2017, 307 . 309 [RFC8174] Leiba, B., "Ambiguity of Uppercase vs Lowercase in RFC 310 2119 Key Words", BCP 14, RFC 8174, DOI 10.17487/RFC8174, 311 May 2017, . 313 [SHS] National Institute of Standards and Technology, "Secure 314 Hash Standard", DOI 10.6028/nist.fips.180-4, July 2015, 315 . 317 8.2. Informative References 319 [DIGALM] National Institute of Standards and Technology, "Digital 320 identity guidelines: authentication and lifecycle 321 management", DOI 10.6028/nist.sp.800-63b, June 2017, 322 . 324 [DMR] Dell'Amico, M., Michiardi, P., and Y. Roudier, "Password 325 Strength: An Empirical Analysis", 326 DOI 10.1109/INFCOM.2010.5461951, March 2010, 327 . 329 [I-D.ietf-lamps-cms-aes-gmac-alg] 330 Housley, R., "Using the AES-GMAC Algorithm with the 331 Cryptographic Message Syntax (CMS)", Work in Progress, 332 Internet-Draft, draft-ietf-lamps-cms-aes-gmac-alg-03, 333 27 January 2020, . 336 [PHS] Pathirana, A., Halgamuge, M., and A. Syed, "Energy 337 efficient bitcoin mining to maximize the mining profit: 338 Using data from 119 bitcoin mining hardware setups", 339 International Conference on Advances in Business 340 Management and Information Technology, pp 1-14, November 341 2019. 343 [RFC4231] Nystrom, M., "Identifiers and Test Vectors for HMAC-SHA- 344 224, HMAC-SHA-256, HMAC-SHA-384, and HMAC-SHA-512", 345 RFC 4231, DOI 10.17487/RFC4231, December 2005, 346 . 348 Author's Address 350 Russ Housley 351 Vigil Security, LLC 352 516 Dranesville Road 353 Herndon, VA, 20170 354 United States of America 356 Email: housley@vigilsec.com