Network Working Group R. Housley Request for Comments: 4049 Vigil Security Category: Experimental April 2005BinaryTime: An Alternate Format for Representing Date and Time in ASN.1
1. Introduction
This document specifies a new ASN.1 [ASN1] type for representing time: BinaryTime. This ASN.1 type can be used to represent date and time values.
1.1. BinaryTime
Many operating systems represent date and time as an integer. This document specifies an ASN.1 type for representing date and time in a manner that is also an integer. Although some conversion may be necessary due to the selection of a different epoch or a different granularity, an integer representation has several advantages over the UTCTime and GeneralizedTime types. First, a BinaryTime value is smaller than either a UTCTime or a GeneralizedTime value.
Housley Experimental [Page 1]
RFC 4049 BinaryTime April 2005
Second, in some operating systems, the value can be used with little or no conversion. Conversion, when it is needed, requires only straightforward computation. If the endian ordering is different from the ASN.1 representation of an INTEGER, then straightforward manipulation is needed to obtain an equivalent integer value. If the epoch is different than the one chosen for BinaryTime, addition or subtraction is needed to compensate. If the granularity is something other than seconds, then multiplication or division is needed to compensate. Also, padding may be needed to convert the variable- length ASN.1 encoding of INTEGER to a fixed-length value used in the operating system.
1.2. Binary Signing Time Attribute
The signing-time attribute is defined in [CMS]. The alternative binary-signing-time attribute is defined in this document in order to obtain the benefits of the BinaryTime type.
1.3. Terminology
In this document, the key words MUST, MUST NOT, REQUIRED, SHOULD, SHOULD NOT, RECOMMENDED, MAY, and OPTIONAL are to be interpreted as described in [STDWORDS].
2. BinaryTime Definition
The BinaryTime ASN.1 type is used to represent an absolute time and date. A positive integer value is used to represent time values based on coordinated universal time (UTC), which is also called Greenwich Mean Time (GMT) and ZULU clock time.
Housley Experimental [Page 2]
RFC 4049 BinaryTime April 2005
The integer value is the number of seconds, excluding leap seconds, after midnight UTC, January 1, 1970. This time format cannot represent time values prior to January 1, 1970. The latest UTC time value that can be represented by a four-octet integer value is 03:14:07 on January 19, 2038, which is represented by the hexadecimal value 7FFFFFFF. Time values beyond 03:14:07 on January 19, 2038, are represented by integer values that are longer than four octets, and a five-octet integer value is sufficient to represent dates covering the next seventeen millennia.
3. Binary Signing Time Attribute Definition
The binary-signing-time attribute type specifies the time at which the signer (purportedly) performed the signing process. The binary- signing-time attribute type is intended for use in the CMS SignedData content type; however, the attribute can also be used with the AuthenticatedData content type.
Housley Experimental [Page 3]
RFC 4049 BinaryTime April 2005
In [CMS], the SignedAttributes syntax and the AuthAttributes syntax are each defined as a SET OF Attributes. However, the binary- signing-time attribute MUST have a single attribute value, even though the syntax is defined as a SET OF AttributeValue. There MUST NOT be zero or multiple instances of AttributeValue present.
4. References
This section provides normative and informative references.
4.1. Normative References
[ASN1] CCITT. Recommendation X.208: Specification of Abstract
4.2. Informative References
[TSP] Adams, C., Cain, P., Pinkas, D., and R. Zuccherato,
5. Security Considerations
Use of the binary-signing-time attribute does not necessarily provide confidence in the time when the signature value was produced. Therefore, acceptance of a purported signing time is a matter of a recipient's discretion. RFC 3161 [TSP] specifies a protocol for obtaining time stamps from a trusted entity. The original signing-time attribute defined in [CMS] has the same semantics as the binary-signing-time attribute specified in this document. Therefore, only one of these attributes SHOULD be present in the signedAttrs of a SignerInfo object or in the authAttrs of an AuthenticatedData object. However, if both of these attributes are present, they MUST provide the same date and time.
Housley Experimental [Page 4]
RFC 4049 BinaryTime April 2005 Housley Experimental [Page 5]
RFC 4049 BinaryTime April 2005
Appendix A: ASN.1 Module
Housley Experimental [Page 6]
RFC 4049 BinaryTime April 2005
Full Copyright Statement