Internet-Draft | Epoch Markers | October 2022 |
Birkholz, et al. | Expires 27 April 2023 | [Page] |
This document defines Epoch Markers as a way to establish a notion of freshness among actors in a distributed system. Epoch Markers are similar to "time ticks" and are produced and distributed by a dedicated system, the Epoch Bell. Systems that receive Epoch Markers do not have to track freshness using their own understanding of time (e.g., via a local real-time clock). Instead, the reception of a certain Epoch Marker establishes a new epoch that is shared between all recipients.¶
This note is to be removed before publishing as an RFC.¶
Status information for this document may be found at https://datatracker.ietf.org/doc/draft-birkholz-rats-epoch-markers/.¶
Discussion of this document takes place on the rats Working Group mailing list (mailto:rats@ietf.org), which is archived at https://mailarchive.ietf.org/arch/browse/rats/. Subscribe at https://www.ietf.org/mailman/listinfo/rats/.¶
Source for this draft and an issue tracker can be found at https://github.com/ietf-rats/draft-birkholz-rats-epoch-marker.¶
This Internet-Draft is submitted in full conformance with the provisions of BCP 78 and BCP 79.¶
Internet-Drafts are working documents of the Internet Engineering Task Force (IETF). Note that other groups may also distribute working documents as Internet-Drafts. The list of current Internet-Drafts is at https://datatracker.ietf.org/drafts/current/.¶
Internet-Drafts are draft documents valid for a maximum of six months and may be updated, replaced, or obsoleted by other documents at any time. It is inappropriate to use Internet-Drafts as reference material or to cite them other than as "work in progress."¶
This Internet-Draft will expire on 27 April 2023.¶
Copyright (c) 2022 IETF Trust and the persons identified as the document authors. All rights reserved.¶
This document is subject to BCP 78 and the IETF Trust's Legal Provisions Relating to IETF Documents (https://trustee.ietf.org/license-info) in effect on the date of publication of this document. Please review these documents carefully, as they describe your rights and restrictions with respect to this document. Code Components extracted from this document must include Revised BSD License text as described in Section 4.e of the Trust Legal Provisions and are provided without warranty as described in the Revised BSD License.¶
Systems that need to interact securely often require a shared understanding of the freshness of conveyed information. This is certainly the case in the domain of remote attestation procedures. In general, securely establishing a shared notion of freshness of the exchanged information among entities in a distributed system is not a simple task.¶
The entire Appendix A of [I-D.ietf-rats-architecture] deals solely with the topic of freshness, which is in itself an indication of how relevant, and complex, it is to establish a trusted and shared understanding of freshness in a RATS system.¶
This document defines Epoch Markers as a way to establish a notion of freshness among actors in a distributed system. Epoch Markers are similar to "time ticks" and are produced and distributed by a dedicated system, the Epoch Bell. Systems that receive Epoch Markers do not have to track freshness using their own understanding of time (e.g., via a local real-time clock). Instead, the reception of a certain Epoch Marker establishes a new epoch that is shared between all recipients. In essence, the emissions and corresponding receptions of Epoch Markers are like the ticks of a clock where the ticks are conveyed by the Internet.¶
In general (barring highly symmetrical topologies), epoch ticking incurs differential latency due to the non-uniform distribution of receivers with respect to the Epoch Bell. This introduces skew that needs to be taken into consideration when Epoch Markers are used.¶
While all Epoch Markers share the same core property of behaving like clock ticks in a shared domain, various "epoch id" types are defined to accommodate different use cases and diverse kinds of Epoch Bells.¶
While Epoch Markers are encoded in CBOR [STD94], and many of the epoch id types are themselves encoded in CBOR, a prominent format in this space is the Time-Stamp Token defined by [RFC3161], a DER-encoded TSTInfo value wrapped in a CMS envelope [RFC5652]. Time-Stamp Tokens (TST) are produced by Time-Stamp Authorities (TSA) and exchanged via the Time-Stamp Protocol (TSP). At the time of writing, TSAs are the most common providers of secure time-stamping services. Therefore, reusing the core TSTInfo structure as an epoch id type for Epoch Markers is instrumental for enabling smooth migration paths and promote interoperability. There are, however, several other ways to represent a signed timestamp, and therefore other kinds of payloads that can be used to implement Epoch Markers.¶
To inform the design, this document discusses a number of interaction models in which Epoch Markers are expected to be exchanged. The top-level structure of Epoch Markers and an initial set of epoch id types are specified using CDDL [RFC8610]. To increase trustworthiness in the Epoch Bell, Epoch Markers also provide the option to include a "veracity proof" in the form of attestation evidence, attestation results, or SCITT receipts [I-D.birkholz-scitt-receipts] associated with the trust status of the Epoch Bell.¶
The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in BCP 14 [RFC2119] [RFC8174] when, and only when, they appear in all capitals, as shown here.¶
In this document, CDDL [RFC8610] is used to describe the data formats. The examples in Appendix A use CBOR diagnostic notation as defined in Section 8 of [STD94] and Appendix G of [RFC8610].¶
The RATS architecture introduces the concept of Epoch IDs that mark certain events during remote attestation procedures ranging from simple handshakes to rather complex interactions including elaborate freshness proofs. The Epoch Markers defined in this document are a solution that includes the lessons learned from TSAs, the concept of Epoch IDs defined in the RATS architecture, and provides several means to identify a new freshness epoch. Some of these methods are introduced and discussed in Section 10.3 of the RATS architecture [I-D.ietf-rats-architecture].¶
The interaction models illustrated in this section are derived from the RATS Reference Interaction Models. In general, there are three interaction models:¶
At the top level, an Epoch Marker is a CBOR array with a header carrying an optional veracity proof about the Epoch Bell and a payload.¶
This memo comes with a set of predefined payloads.¶
CBOR extended time tag (1001) optionally bundled with a nonce.¶
See Section 3 of [I-D.ietf-cbor-time-tag] for the (many) details about the CBOR extended time format.¶
cbor-epoch-id = [ etime ? nonce ] etime = #6.1001({* (int/tstr) => any}) nonce = tstr / bstr / int¶
DER-encoded [X.690] TSTInfo [RFC3161]. See Appendix A.1 for the layout.¶
classical-rfc3161-TST-info = bytes¶
Semantically equivalent to classical RFC3161 TSTInfo rewritten using the CBOR type system.¶
TST-info-based-on-CBOR-time-tag = { &(version : 0) => int .default 1 ; obsolete? &(policy : 1) => oid &(messageImprint : 2) => MessageImprint &(serialNumber : 3) => int &(eTime : 4) => profiled-etime &(ordering : 5) => bool .default false ? &(nonce : 6) => int ? &(tsa : 7) => GeneralName * $$TSTInfoExtensions } oid = #6.110(bstr) / #6.111(bstr) / #6.112(bstr) ; based on COSE_Hash_Find (draft-ietf-cose-hash-algs) MessageImprint = [ hashAlg : int hashValue : bstr ] ; timeMap profiles etime, see: ; https://datatracker.ietf.org/doc/html/draft-ietf-cbor-time-tag profiled-etime = #6.1001(timeMap) timeMap = { 1 => #6.1(int / float) ; TIME_T -8 => profiled-duration ; guarantee aka RFC 3161 accuracy * int => any } profiled-duration = #6.1002({* int => any}) ; Section 11.8 of I-D.ietf-cose-cbor-encoded-cert GeneralName = [ GeneralNameType : int, GeneralNameValue : any ]¶
Typically, a nonce is a number only used once. In the context of Epoch Markers, one Nonce can be distributed to multiple consumers, each of them using that Nonce only once. Technically, that is not a Nonce anymore. This type of Nonce is called Multi-Nonce in Epoch Markers.¶
; Multi-Nonce ; a single nonce used by multiple entities multi-nonce = tstr / bstr / int¶
A list of nonces send to multiple consumers. The consumers use each Nonce in the list of Nonces sequentially. Technically, each sequential Nonce in the distributed list is not used just once, but by every Epoch Marker consumer involved. This renders each Nonce in the list a Multi-Nonce¶
; Multi-Nonce-List ; a list of nonces potentially used by multiple entities multi-nonce-list = [ + multi-nonce ]¶
A strictly monotonically increasing counter.¶
The counter context is defined by the Epoch bell.¶
strictly-monotonic-counter = uint¶
Epoch Markers are signed using [STD96] and inheritance of security considerations will be addressed here.¶
TODO¶
The example in Figure 2 shows an epoch marker with a cbor-epoch-id and no bell veracity proof.¶
As a reference for the definition of TST-info-based-on-CBOR-time-tag the code block below depects the original layout of the TSTInfo structure from [RFC3161].¶
TSTInfo ::= SEQUENCE { version INTEGER { v1(1) }, policy TSAPolicyId, messageImprint MessageImprint, -- MUST have the same value as the similar field in -- TimeStampReq serialNumber INTEGER, -- Time-Stamping users MUST be ready to accommodate integers -- up to 160 bits. genTime GeneralizedTime, accuracy Accuracy OPTIONAL, ordering BOOLEAN DEFAULT FALSE, nonce INTEGER OPTIONAL, -- MUST be present if the similar field was present -- in TimeStampReq. In that case it MUST have the same value. tsa [0] GeneralName OPTIONAL, extensions [1] IMPLICIT Extensions OPTIONAL }¶