 1/draftietfsmimesha203.txt 20080311 22:12:30.000000000 +0100
+++ 2/draftietfsmimesha204.txt 20080311 22:12:30.000000000 +0100
@@ 1,17 +1,17 @@
S/MIME WG Sean Turner, IECA
Intended Status: Standard Track
Expires: July 30, 2008
+Expires: September 11, 2008
Using SHA2 Algorithms with Cryptographic Message Syntax
 draftietfsmimesha203.txt
+ draftietfsmimesha204.txt
Status of this Memo
By submitting this InternetDraft, each author represents that any
applicable patent or other IPR claims of which he or she is aware
have been or will be disclosed, and any of which he or she becomes
aware will be disclosed, in accordance with Section 6 of BCP 79.
InternetDrafts are working documents of the Internet Engineering
Task Force (IETF), its areas, and its working groups. Note that
@@ 22,33 +22,34 @@
and may be updated, replaced, or obsoleted by other documents at any
time. It is inappropriate to use InternetDrafts as reference
material or to cite them other than as "work in progress."
The list of current InternetDrafts can be accessed at
http://www.ietf.org/ietf/1idabstracts.txt
The list of InternetDraft Shadow Directories can be accessed at
http://www.ietf.org/shadow.html
 This InternetDraft will expire on July 30, 2008.
+ This InternetDraft will expire on September 11, 2008.
Copyright Notice
Copyright (C) The IETF Trust (2008).
Abstract
 This document describes the conventions for using the message digest
 algorithms SHA224, SHA256, SHA384, SHA512, as defined in FIPS
 1803, with the Cryptographic Message Syntax (CMS). It also describes
 the conventions for using these algorithms with CMS and the DSA, RSA,
 and ECDSA signature algorithms.
+ This document describes the conventions for using the Secure Hash
+ Algorithm (SHA) message digest algorithms (SHA224, SHA256, SHA384,
+ SHA512) with the Cryptographic Message Syntax (CMS). It also
+ describes the conventions for using these algorithms with CMS and the
+ Digital Signature Algorithm (DSA), Rivest Shamir Adleman (RSA), and
+ Elliptic Curve DSA (ECDSA) signature algorithms.
Conventions used in this document
The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
"SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this
document are to be interpreted as described in [RFC2119].
Table of Contents
1. Introduction...................................................2
@@ 65,40 +66,35 @@
5. IANA Considerations............................................7
6. References.....................................................7
6.1. Normative References......................................7
6.2. Informative References....................................8
1. Introduction
This document specifies the algorithm identifiers and specifies
parameters for the message digest algorithms SHA224, SHA256, SHA
384, and SHA512 for use with the Cryptographic Message Syntax (CMS)
 [RFC3852]. The message digest algorithms are defined in and [SHS].
 If an implementation chooses to support one of the algorithms
 discussed in this document, then the implementation MUST do so as
 described in this document.
+ [RFC3852]. The message digest algorithms are defined in [SHS].
This document also specifies the algorithm identifiers and parameters
 for use of SHA224, SHA256, SHA384, and SHA512 with DSA, RSA, and
 ECDSA. If an implementation chooses to support one of the algorithms
 discussed in this document, then the implementation MUST do so as
 described in this document.
+ for use of SHA224, SHA256, SHA384, and SHA512 with DSA [DSS], RSA
+ [RFC2313], and ECDSA [X9.62].
This document does not define new identifiers; they are taken from
 [RFC3874], [RFC4055], [ECCADD], [RFC3278], and [RFC3370].
 Additionally, the parameters follow the conventions specified
 therein. Therefore, there is no ASN.1 module included in this
 document.
+ [RFC3874], [RFC4055], [ECCADD], and [RFC3278]. Additionally, the
+ parameters follow the conventions specified therein. Therefore,
+ there is no Abstract Syntax Notation One (ASN.1) module included in
+ this document.
 Note that [RFC4231] specifies the conventions for use of for the
 message authentication code (MAC) algorithms: HMAC with SHA224, HMAC
 with SHA256, HMAC with SHA384, and HMAC with SHA512.
+ Note that [RFC4231] specifies the conventions for the message
+ authentication code (MAC) algorithms: HMAC with SHA224, HMAC with
+ SHA256, HMAC with SHA384, and HMAC with SHA512.
In CMS, the various algorithm identifiers use the AlgorithmIdentifier
syntax, which is included here for convenience:
AlgorithmIdentifier ::= SEQUENCE {
algorithm OBJECT IDENTIFIER,
parameters ANY DEFINED BY algorithm OPTIONAL }
2. Message Digest Algorithms
@@ 110,22 +106,20 @@
Digest values are located in the DigestedData digest field and the
Message Digest authenticated attribute. In addition, digest values
are input to signature algorithms.
The digest algorithm identifiers use the AlgorithmIdentifier syntax
elaborated upon in Section 1.
The algorithm field is discussed in Sections 2.12.4 for each message
digest algorithm.
 The following addresses the parameters field:

There are two possible encodings for the SHA AlgorithmIdentifier
parameters field. The two alternatives arise from the fact that when
the 1988 syntax for AlgorithmIdentifier was translated into the 1997
syntax, the OPTIONAL associated with the AlgorithmIdentifier
parameters got lost. Later the OPTIONAL was recovered via a defect
report, but by then many people thought that algorithm parameters
were mandatory. Because of this history some implementations encode
parameters as a NULL element and others omit them entirely. The
correct encoding is to omit the parameters field; however,
implementations MUST also handle a SHA AlgorithmIdentifier parameters
@@ 166,66 +160,65 @@
algorithm identifier for SHA384 is:
idsha384 OBJECT IDENTIFIER ::= {
jointisoitut(2) country(16) us(840) organization(1) gov(101)
csor(3) nistalgorithm(4) hashalgs(2) 2 }
The parameters are as specified in Section 2.
2.4. SHA512
 The SHA256 message digest algorithm is defined in [SHS]. The
+ The SHA512 message digest algorithm is defined in [SHS]. The
algorithm identifier for SHA512 is:
idsha512 OBJECT IDENTIFIER ::= {
jointisoitut(2) country(16) us(840) organization(1) gov(101)
csor(3) nistalgorithm(4) hashalgs(2) 3 }
The parameters are as specified in Section 2.
3. Signature Algorithms
This section specifies the conventions employed by CMS
 implementations that support DSA [DSS], ECDSA [X9.62], and RSA
 [RFC2313] with SHA2 algorithms.
+ implementations that support DSA, RSA, and ECDSA with SHA2
+ algorithms.
Signature algorithm identifiers are located in the SignerInfo
signatureAlgorithm field of SignedData. Also, signature algorithm
identifiers are located in the SignerInfo signatureAlgorithm field of
countersignature attributes.
Signature values are located in the SignerInfo signature field of
SignedData. Also, signature values are located in the SignerInfo
signature field of countersignature attributes.
 NOTE [to be removed upon publication as an RFC]: NIST has not yet
 finalized FIPS 1863 and there is a chance that the draft may be
 changed. This may result in differences between what is documented
 in the current version of this document and what is in the FIPS. It
 is intended to synchronize the final version of this draft with the
 FIPS before publication as an RFC.

3.1. DSA
[RFC3370] section 3.1 specifies the conventions for DSA with SHA1
public key algorithm identifiers, parameters, public keys, and
signature values. DSA with SHA2 algorithms uses the same conventions
for these public key algorithm identifiers, parameters, public keys,
and signature values. DSA MAY be used with SHA224 and SHA256.
+ DSA has not been specified with SHA384 and SHA512. SHA384 and
+ SHA512 are not supported because the maximum bit length of p
+ (specified as L) is 3072 for DSA. For consistent cryptographic
+ strength, SHA384 would be used with DSA where L is 7068, and SHA512
+ would be used with DSA where L is 15360.
+
The algorithm identifier for DSA with SHA224 signature values is:
iddsawithsha224 OBJECT IDENTIFIER ::= { jointisoccitt(2)
country(16) us(840) organization(1) gov(101) csor(3)
algorithms(4) iddsawithsha2(3) 1 }
 The algorithm identifier for DSA with SHA224 signature values is:
+ The algorithm identifier for DSA with SHA256 signature values is:
iddsawithsha256 OBJECT IDENTIFIER ::= { jointisoccitt(2)
country(16) us(840) organization(1) gov(101) csor(3)
algorithms(4) iddsawithsha2(3) 2 }
When either of these algorithm identifiers is used, the
AlgorithmIdentifier parameters field MUST be absent.
3.2. RSA
@@ 261,21 +254,21 @@
MUST accept the parameters being absent as well as present.
3.3. ECDSA
[RFC3278] section 2.1 specifies the conventions for ECDSA with SHA1
public key algorithm identifiers, parameters, public keys, and
signature values. ECDSA with SHA2 algorithms uses the same
conventions for these public key algorithm identifiers, parameters,
public keys, and signature values, except that the digestAlgorithm
MUST include the corresponding message digest algorithm identifier,
 and not sha1 object identifier. ECDSA MAY be used with SHA224,
+ and not the sha1 object identifier. ECDSA MAY be used with SHA224,
SHA256, SHA384, or SHA512.
The algorithm identifier for ECDSA with SHA224 signature values is:
ecdsawithSHA224 OBJECT IDENTIFIER ::= { iso(1) memberbody(2)
us(840) ansiX962(10045) signatures(4) ecdsawithSHA2(3) 1 }
The algorithm identifier for ECDSA with SHA256 signature values is:
ecdsawithSHA256 OBJECT IDENTIFIER ::= { iso(1) memberbody(2)
@@ 308,21 +301,21 @@
6. References
6.1. Normative References
[ECCADD] Dang, S., Santesson, S., Moriarty, K., and Brown,
"Internet X.509 Public Key Infrastructure: Additional
Algorithms and Identifiers for DSA and ECDSA", workin
progress.
[DSS] Federal Information Processing Standards Publication
 (FIPS PUB) 1863, Secure Hash Standard (SHS), July 2007.
+ (FIPS PUB) 1862, Secure Hash Standard (SHS), 2000.
[RFC2119] Bradner, S., "Key words for use in RFCs to Indicate
Requirement Levels", BCP 14, RFC 2119. March 1997.
[RFC2313] Kaliski, B., "PKCS #1: RSA Encryption Version 1.5", RFC
2313, March 1998.
[RFC3278] BlakeWilson, S., Brown, D., and P. Lambert, "Use of
Elliptic Curve Cryptography (ECC) Algorithms in
Cryptographic Message Syntax (CMS)", RFC 3278, April
@@ 340,21 +333,21 @@
[RFC3874] Housley, R., "A 224bit One Way Hash Function: SHA224",
RFC 3874. September 2004.
[RFC4055] Schaad, J., Kaliski, B., and R. Housley, "Additional
Algorithms and Identifiers for RSA Cryptography for use
in the Internet Public Key Infrastructure Certificate and
Certificate Revocation List (CRL) Profile", RFC 4055.
June 2005.
[SHS] National Institute of Standards and Technology (NIST),
 FIPS Publication 1803: Secure Hash Standard, June 2007.
+ FIPS Publication 1802: Secure Hash Standard, 2002.
[X9.62] X9.622005, "Public Key Cryptography for the Financial
Services Industry: The Elliptic Curve Digital Signature
Standard (ECDSA)", November, 2005.
6.2. Informative References
[RFC4231] Nystrom, A. "Identifiers and Test Vectors for HMACSHA
224, HMACSHA256, HMACSHA384, and HMACSHA512",
RFC4231. December 2005.