idnits 2.17.1 draft-ietf-httpauth-digest-update-02.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 an IANA Considerations section. (See Section 2.2 of https://www.ietf.org/id-info/checklist for how to handle the case when there are no actions for IANA.) ** There is 1 instance of lines with control characters in the document. -- The draft header indicates that this document updates RFC2617, but the abstract doesn't seem to mention this, which it should. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year (Using the creation date from RFC2617, updated by this document, for RFC5378 checks: 1997-12-01) -- 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 (June 30, 2013) is 3946 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: 'FIPS 186-3' is mentioned on line 78, but not defined == Unused Reference: 'RFC2617' is defined on line 338, but no explicit reference was found in the text == Unused Reference: 'FIPS186-3' is defined on line 345, but no explicit reference was found in the text ** Obsolete normative reference: RFC 2617 (Obsoleted by RFC 7235, RFC 7615, RFC 7616, RFC 7617) Summary: 3 errors (**), 0 flaws (~~), 4 warnings (==), 3 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 HTTPAuth Working Group R. Shekh-Yusef 3 Internet-Draft D. Ahrens 4 Updates: 2617 (if approved) Avaya 5 Intended Status: Standards Track June 30, 2013 6 Expires: January 1, 2014 8 HTTP Digest Update 9 draft-ietf-httpauth-digest-update-02 11 Abstract 13 This documents specifies extensions to the HTTP Digest Authentication 14 mechanism to add support for new digest algorithms to the HTTP Digest 15 Access Authentication scheme. 17 Status of this Memo 19 This Internet-Draft is submitted to IETF in full conformance with the 20 provisions of BCP 78 and BCP 79. 22 Internet-Drafts are working documents of the Internet Engineering 23 Task Force (IETF), its areas, and its working groups. Note that 24 other groups may also distribute working documents as 25 Internet-Drafts. 27 Internet-Drafts are draft documents valid for a maximum of six months 28 and may be updated, replaced, or obsoleted by other documents at any 29 time. It is inappropriate to use Internet-Drafts as reference 30 material or to cite them other than as "work in progress." 32 The list of current Internet-Drafts can be accessed at 33 http://www.ietf.org/1id-abstracts.html 35 The list of Internet-Draft Shadow Directories can be accessed at 36 http://www.ietf.org/shadow.html 38 Copyright and License Notice 40 Copyright (c) 2013 IETF Trust and the persons identified as the 41 document authors. All rights reserved. 43 This document is subject to BCP 78 and the IETF Trust's Legal 44 Provisions Relating to IETF Documents 45 (http://trustee.ietf.org/license-info) in effect on the date of 46 publication of this document. Please review these documents 47 carefully, as they describe your rights and restrictions with respect 48 to this document. Code Components extracted from this document must 49 include Simplified BSD License text as described in Section 4.e of 50 the Trust Legal Provisions and are provided without warranty as 51 described in the Simplified BSD License. 53 Table of Contents 55 1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . 3 56 1.1 Terminology . . . . . . . . . . . . . . . . . . . . . . . . 3 57 2 Syntax Convention . . . . . . . . . . . . . . . . . . . . . . . 3 58 3 Digest Access Authentication Scheme . . . . . . . . . . . . . . 3 59 3.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . 3 60 3.1.1 Representation of digest values . . . . . . . . . . . . 3 61 3.1.2 Limitations . . . . . . . . . . . . . . . . . . . . . . 4 62 3.2 Specification of Digest Headers . . . . . . . . . . . . . . 4 63 3.2.1 The WWW-Authenticate Response Header . . . . . . . . . . 4 64 3.2.2 The Authorization Request Header . . . . . . . . . . . . 5 65 3.3 Digest Operation . . . . . . . . . . . . . . . . . . . . . . 6 66 3.4 Security Protocol Operation . . . . . . . . . . . . . . . . 6 67 3.5 Example . . . . . . . . . . . . . . . . . . . . . . . . . . 7 68 4 Security Considerations . . . . . . . . . . . . . . . . . . . . 8 69 5 Acknowledgments . . . . . . . . . . . . . . . . . . . . . . . . 8 70 6 References . . . . . . . . . . . . . . . . . . . . . . . . . . 9 71 6.1 Normative References . . . . . . . . . . . . . . . . . . . 9 72 6.2 Informative References . . . . . . . . . . . . . . . . . . 9 73 7 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . 9 75 1 Introduction 77 This document specifies extensions to the HTTP Digest Access 78 Authentication scheme by adding support for SHA2-256 [FIPS 186-3] and 79 SHA3-256 hash algorithms. RFC2617 specifies the MD5 algorithm as the 80 default hash algorithm used in the digest access authentication 81 scheme. Since RFC2617 was first proposed, the MD5 algorithm has been 82 broken. In 2008 the US-CERT issued a note that MD5 "should be 83 considered cryptographically broken and unsuitable for further use" 84 [CERT-VU]. 86 1.1 Terminology 88 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 89 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this 90 document are to be interpreted as described in RFC2119 [RFC2119]. 92 2 Syntax Convention 94 In the interest of clarity and readability, the extended parameters, 95 and the headers and parameters in the examples in this document might 96 be broken into multiple lines. Any line that is indented in this 97 document is a continuation of the preceding line. 99 3 Digest Access Authentication Scheme 101 The Digest Access Authentication scheme is based on a simple 102 challenge-response paradigm. The Digest scheme challenges using a 103 nonce value. A valid response contains a checksum of the username, 104 the password, the given nonce value and the requested URI. In this 105 way the password is never sent in the clear. 107 3.1 Introduction 109 3.1.1 Representation of digest values 111 An optional header allows the server to specify the algorithm used to 112 create the checksum or digest. By default the SHA2-256 algorithm is 113 used, with SHA3-256 being used as a backup algorithm. To maintain 114 backwards compatibility, the MD5 algorithm is still supported but not 115 recommended. 117 The size of the digest depends on the algorithm used. The bits in 118 the digest are converted from the most significant to the least 119 significant bit, four bits at a time to the ASCII representation as 120 follows. Each four bits is represented by its familiar hexadecimal 121 notation from the characters 0123456789abcdef, that is binary 0000 is 122 represented by the character '0', 0001 by '1' and so on up to the 123 representation of 1111 as 'f'. If the MD5 algorithm is used to 124 calculate the digest, then the digest will be represented as 32 125 hexadecimal characters, SHA2-256 and SHA3-256 by 64 hexadecimal 126 characters. 128 3.1.2 Limitations 130 The Digest authentication scheme suffers from many known limitations 131 as specified in RFC2617, section 3.1.4. The update in this document 132 does not address those limitations. 134 HTTP Digest authentication, when used with human-memorable passwords, 135 is vulnerable to dictionary attacks. Such attacks are much easier 136 than cryptographic attacks on any widely used algorithm, including 137 those that are no longer considered secure. In other words, algorithm 138 agility does not make this usage any more secure. 140 As a result, Digest authentication SHOULD be used only with passwords 141 that have a reasonable amount of entropy, e.g. 128-bit or more. Such 142 passwords typically cannot be memorized by humans but can be used for 143 automated web services. 145 It is recommended that Digest authentication be used over a secure 146 channel like HTTPS. 148 3.2 Specification of Digest Headers 150 The modifications to the formats of the WWW-Authenticate Header line 151 and the Authorization header line are specified below. 153 3.2.1 The WWW-Authenticate Response Header 155 If a server receives a request for an access protected object, and an 156 acceptable Authorization header is not sent, the server responds with 157 a "401 Unauthorized" status code, and a WWW-Authenticate header. The 158 server MAY include multiple WWW-Authenticate headers to allow the 159 server to utilize the best available algorithm supported by the 160 client. 162 The algorithm directive is extended as follows: 164 algorithm = "algorithm" "=" ("MD5" | "MD5-sess" | 165 "SHA2" | "SHA2-sess" | 166 "SHA3" | "SHA3-sess" | 167 token) 169 Algorithm 170 A string indicating a pair of algorithms used to produce the 171 digest and a checksum. If the algorithm parameter is not present 172 it is assumed to be "MD5" to maintain backwards compatibility 173 with existing implementations. If the algorithm is not 174 understood, the challenge should be ignored and a different 175 challenge used if there is more than one. 177 The string obtained by applying the digest algorithm to the data 178 "data" with "secret" will be denoted KD(secret, data) and the 179 string obtained by applying the checksum algorithm to the data 180 "data" will be denoted H(data). The notation unq(x) means the 181 value of the quoted string X without the surrounding quotes. 183 For the "MD5 and "MD5-sess" algorithms 184 H(data) = MD5(data) 186 For the "SHA2" and "SHA2-sess" algorithms 187 H(data) = SHA2-256(data) 189 For the "SHA3" and "SHA3-sess" algorithms 190 H(data) = SHA3-256(data) 192 and 193 KD(secret, data) = H(concat(secret, ":", data)) 195 i.e the digest is the hash of the secret concatenated with a 196 colon concatenated with the data. The " -sess" algorithm is 197 intended to allow efficient 3rd party authentication servers; 198 for the difference in usage see the description in section 199 RFC2617, Section 3.2.2.2. 201 3.2.2 The Authorization Request Header 203 The client is expected to retry the request, passing an Authorization 204 Request Header line. The Authorization Request Header line is 205 modified as follows: 207 request-digest = <"> digest-size LHEX <"> 208 digest-size = "32" | "64" 210 The values of the opaque and algorithm fields must match those 211 supplied in the WWW-Authenticate response header for the entity being 212 requested. 214 response 215 A string of hex digits as defined in RFC2617 which proves 216 that the user knows a password. 218 3.3 Digest Operation 220 The modifications specified in this document does not introduce any 221 change to the digest operation specified in RFC2617. 223 3.4 Security Protocol Operation 225 When a server receives a request to access a resource, the server 226 might challenge the client by responding with "401 Unauthorized" 227 status code, and include one or more WWW-Authenticate headers. If the 228 server challenges with multiple Digest headers, then each one of 229 these headers MUST use a different digest algorithm. The server MUST 230 add these Digest headers to the response in order of preference, 231 starting with the most preferred header, followed by the less 232 preferred headers. 234 This specification defines the following preference list, starting 235 with the most preferred algorithm: 237 * SHA2-256 as the default algorithm. 238 * SHA3-256 as a backup algorithm. 239 * MD5 for backward compatibility. 241 When the client receives the response it SHOULD use the topmost 242 header that it supports, unless a local policy dictates otherwise. 243 The client should ignore any challenge it does not understand. 245 3.5 Example 247 The following example is borrowed from RFC2617 and assumes that an 248 access protected document is being requested from the server via a 249 GET request. The URI of the document is 250 http://www.nowhere.org/dir/index.html". Both client and server know 251 that the username for this document is "Mufasa" and the password is 252 "Circle of Life" ( with one space between each of the three words). 254 The first time the client requests the document, no Authorization 255 header is sent, so the server responds with: 257 HTTP/1.1 401 Unauthorized 258 WWW-Authenticate: Digest 259 realm = "testrealm@host.com" 260 qop="auth, auth-int", 261 algorithm="SHA2" 262 nonce="dcd98b7102dd2f0e8b11d0f600bfb0c093", 263 opaque="5ccc069c403ebaf9f0171e9517f40e41" 264 WWW-Authenticate: Digest 265 realm = "testrealm@host.com", 266 qop="auth, auth-int", 267 algorithm="SHA3", 268 nonce="dcd98b7102dd2f0e8b11d0f600bfb0c093", 269 opaque="5ccc069c403ebaf9f0171e9517f40e41" 270 WWW-Authenticate: Digest 271 realm="testrealm@host.com", 272 qop="auth, auth-int", 273 algorithm="MD5", 274 nonce="dcd98b7102dd2f0e8b11d0f600bfb0c093", 275 opaque="5ccc069c403ebaf9f0171e9517f40ef41" 277 The client may prompt the user for their username and password, after 278 which it will respond with a new request, including the following 279 Authorization header if the client chooses MD5 digest: 281 Authorization:Digest username="Mufasa", 282 realm="testrealm@host.com" 283 nonce="dcd98b7102dd2f0e8b11d0f600bfb0c093", 284 uri="/dir/index.html", 285 qop="auth", 286 algorithm="MD5" 287 nc=00000001, 288 cnonce="0a4f113b", 289 response="6629fae49393a05397450978507c4ef1", 290 opaque="5ccc069c403ebaf9f0171e9517f40e41" 292 If the client chooses to use the SHA2-256 algorithm for calculating 293 the response, the client responds with a new request including the 294 following Authorization header: 296 Authorization:Digest username="Mufasa", 297 realm="testrealm@host.com" 298 nonce="dcd98b7102dd2f0e8b11d0f600bfb0c093", 299 uri="/dir/index.html", 300 qop="auth" 301 algorithm="SHA2" 302 nc=00000001 303 cnonce="0a4f113b", 304 response="5abdd07184ba512a22c53f41470e5eea7dcaa3a93 305 a59b630c13dfe0a5dc6e38b", 306 opaque="5ccc069c403ebaf9f0171e9517f40e41" 308 4 Security Considerations 310 This specification updates the Digest Access Authentication scheme 311 specified in RFC2617 to add support for the SHA2-256 and SHA3-256 312 hash algorithms. Support for these additional hash algorithms does 313 not alter the security properties of the Digest Access Authentication 314 scheme. 316 5 Acknowledgments 318 The authors would like to thank Geoff Baskwill and Eric Cooper for 319 their careful review and comments on the pre published version of 320 this document. 322 The authors would also like to thank Stephen Farrell, Yoav Nir, 323 Phillip Hallam-Baker, Manu Sporny, Paul Hoffman, Julian Reschke, and 324 Sean Turner for their careful review and comments on and off the 325 mailing list. 327 Special thanks to Yaron Sheffer for his thorough review, comments on 328 and off the list, and for the text he provided for the limitation 329 section. 331 6 References 333 6.1 Normative References 335 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 336 Requirement Levels", BCP 14, RFC 2119, March 1997. 338 [RFC2617] Franks, J., Hallam-Baker, P., Hostetler, J., Lawrence, S., 339 Leach, P., Luotonen, A., and L. Stewart, "HTTP 340 Authentication: Basic and Digest Access Authentication", 341 RFC 2617, June 1999. 343 6.2 Informative References 345 [FIPS186-3] National Institute of Standards and Technology (NIST), 346 FIPS Publication 186-3: Digital Signature Standard, June 2009. 348 [CERT-VU] Vulnerability Note VU#836068, MD5 vulnerable to collision 349 attacks, December 2008. 351 7 Authors' Addresses 353 Rifaat Shekh-Yusef 354 Avaya 355 250 Sydney Street 356 Belleville, Ontario 357 Canada 359 Phone: +1-613-967-5267 360 Email: rifatyu@avaya.com 362 David Ahrens 363 Avaya 364 4655 Great America Parkway 365 Santa Clara, CA 95054 367 Phone: (408) 562-5502 368 EMail: davidahrens@avaya.com