<?xml version='1.0' encoding='utf-8'?>
<!DOCTYPE rfc [
  <!ENTITY nbsp    "&#160;">
  <!ENTITY zwsp   "&#8203;">
  <!ENTITY nbhy   "&#8209;">
  <!ENTITY wj     "&#8288;">
]>
<?xml-stylesheet type="text/xsl" href="rfc2629.xslt" ?>
<!-- generated by https://github.com/cabo/kramdown-rfc version 1.7.15 (Ruby 3.2.4) -->
<rfc xmlns:xi="http://www.w3.org/2001/XInclude" ipr="trust200902" docName="draft-mcnally-deterministic-cbor-10" category="exp" submissionType="IETF" tocInclude="true" sortRefs="true" symRefs="true" version="3">
  <!-- xml2rfc v2v3 conversion 3.21.0 -->
  <front>
    <title abbrev="dCBOR">dCBOR: A Deterministic CBOR Application Profile</title>
    <seriesInfo name="Internet-Draft" value="draft-mcnally-deterministic-cbor-10"/>
    <author initials="W." surname="McNally" fullname="Wolf McNally">
      <organization>Blockchain Commons</organization>
      <address>
        <email>wolf@wolfmcnally.com</email>
      </address>
    </author>
    <author initials="C." surname="Allen" fullname="Christopher Allen">
      <organization>Blockchain Commons</organization>
      <address>
        <email>christophera@lifewithalacrity.com</email>
      </address>
    </author>
    <author initials="C." surname="Bormann" fullname="Carsten Bormann">
      <organization>Universität Bremen TZI</organization>
      <address>
        <email>cabo@tzi.org</email>
      </address>
    </author>
    <date year="2024" month="June" day="10"/>
    <area>Applications and Real-Time</area>
    <workgroup>Network Working Group</workgroup>
    <keyword>Internet-Draft</keyword>
    <abstract>
      <?line 76?>

<t>The purpose of determinism is to ensure that semantically equivalent data items are encoded into identical byte streams. CBOR (RFC 8949) defines "Deterministically Encoded CBOR" in its Section 4.2, but leaves some important choices up to the application developer. The CBOR Common Deterministic Encoding (CDE) Internet Draft builds on this by specifying a baseline for application profiles that wish to implement deterministic encoding with CBOR. The present document provides an application profile "dCBOR" that can be used to help achieve interoperable deterministic encoding based on CDE for a variety of applications wishing an even narrower and clearly defined set of choices.</t>
    </abstract>
    <note removeInRFC="true">
      <name>About This Document</name>
      <t>
        Status information for this document may be found at <eref target="https://datatracker.ietf.org/doc/draft-mcnally-deterministic-cbor/"/>.
      </t>
      <t>Source for this draft and an issue tracker can be found at
        <eref target="https://github.com/BlockchainCommons/WIPs-IETF-draft-deterministic-cbor"/>.</t>
    </note>
  </front>
  <middle>
    <?line 80?>

<section anchor="introduction">
      <name>Introduction</name>
      <t>CBOR <xref target="RFC8949"/> has many advantages over other data serialization formats. One of its strengths is specifications and guidelines for serializing data deterministically, such that multiple agents serializing the same data automatically achieve consensus on the exact byte-level form of that serialized data. This is particularly useful when data must be compared for semantic equivalence by comparing the hash of its contents.</t>
      <t>Nonetheless, determinism is an opt-in feature of CBOR, and most existing CBOR codecs put the primary burden of correct deterministic serialization and validation of deterministic encoding during deserialization on the engineer. Furthermore, the specification leaves a number of important decisions around determinism up to the application developer. The CBOR Common Deterministic Encoding (CDE) Internet Draft <xref target="CDE"/> builds on the basic CBOR specification by providing a baseline for application profiles that wish to implement deterministic encoding with CBOR.</t>
      <t>This document narrows CDE further into a set of requirements for the application profile "dCBOR". These requirements include but go beyond CDE, including requiring that dCBOR decoders validate that encoded CDE conforms to the requirements of this document.</t>
      <section anchor="conventions-and-definitions">
        <name>Conventions and Definitions</name>
        <t>The key words "<bcp14>MUST</bcp14>", "<bcp14>MUST NOT</bcp14>", "<bcp14>REQUIRED</bcp14>", "<bcp14>SHALL</bcp14>", "<bcp14>SHALL
NOT</bcp14>", "<bcp14>SHOULD</bcp14>", "<bcp14>SHOULD NOT</bcp14>", "<bcp14>RECOMMENDED</bcp14>", "<bcp14>NOT RECOMMENDED</bcp14>",
"<bcp14>MAY</bcp14>", and "<bcp14>OPTIONAL</bcp14>" in this document are to be interpreted as
described in BCP 14 <xref target="RFC2119"/> <xref target="RFC8174"/> when, and only when, they
appear in all capitals, as shown here.</t>
        <?line -18?>

</section>
    </section>
    <section anchor="application-profile">
      <name>Application Profile</name>
      <t>The dCBOR Application Profile specifies the use of Deterministic Encoding as defined in <xref target="CDE"/> and adds several exclusions and reductions specified in this section.</t>
      <t>Just as CDE does not "fork" CBOR, the rules specified here do not "fork" CDE: A dCBOR implementation produces well-formed, deterministically encoded CDE according to <xref target="CDE"/>, and existing CBOR or CDE decoders will therefore be able to decode it. Similarly, CBOR or CDE encoders will be able to produce valid dCBOR if handed dCBOR conforming data model level information from an application.</t>
      <t>Note that the separation between standard CBOR or CDE processing and the processing required by the dCBOR application profile is a conceptual one: Both dCBOR processing and standard CDE/CBOR processing may be combined into a unified dCBOR/CDE/CBOR codec. The requirements in this document apply to encoding or decoding of dCBOR data, regardless of whether the codec is a unified dCBOR/CDE/CBOR codec operating in dCBOR-compliant modes, or a single-purpose dCBOR codec. Both of these are generically referred to as "dCBOR codecs" in this document.</t>
      <t>This application profile is intended to be used in conjunction with an application, which typically will use a subset of CDE/CBOR, which in turn influences which subset of the application profile is used. As a result, this application profile places no direct requirement on what subset of CDE/CBOR is implemented. For instance, there is no requirement that dCBOR implementations support floating point numbers (or any other kind of non-basic integer type, such as arbitrary precision integers or complex numbers) when they are used with applications that do not use them. However, this document does place requirements on dCBOR implementations that support negative 64-bit integers and 64-bit or smaller floating point numbers.</t>
      <section anchor="common-deterministic-encoding-conformance">
        <name>Common Deterministic Encoding Conformance</name>
        <t>dCBOR encoders:</t>
        <ol spacing="normal" type="1"><li>
            <t><bcp14>MUST</bcp14> only emit CBOR conforming "CBOR Common Deterministic Encoding (CDE)" <xref target="CDE"/>, including mandated preferred encoding of integers and floating point numbers and the lexicographic ordering of map keys.</t>
          </li>
        </ol>
        <t>dCBOR decoders:</t>
        <ol spacing="normal" type="1" start="2"><li>
            <t><bcp14>MUST</bcp14> validate that encoded CBOR conforms to the requirements of <xref target="CDE"/>.</t>
          </li>
        </ol>
      </section>
      <section anchor="duplicate-map-keys">
        <name>Duplicate Map Keys</name>
        <t>CBOR <xref target="RFC8949"/> defines maps with duplicate keys as invalid, but leaves how to handle such cases to the implementor (§2.2, §3.1, §5.4, §5.6). <xref target="CDE"/> provides no additional mandates on this issue.</t>
        <t>dCBOR encoders:</t>
        <ol spacing="normal" type="1"><li>
            <t><bcp14>MUST NOT</bcp14> emit CBOR maps that contain duplicate keys.</t>
          </li>
        </ol>
        <t>dCBOR decoders:</t>
        <ol spacing="normal" type="1" start="2"><li>
            <t><bcp14>MUST</bcp14> reject encoded maps with duplicate keys.</t>
          </li>
        </ol>
      </section>
      <section anchor="numeric-reduction">
        <name>Numeric Reduction</name>
        <t>The purpose of determinism is to ensure that semantically equivalent data items are encoded into identical byte streams. Numeric reduction ensures that semantically equal numeric values (e.g. <tt>2</tt> and <tt>2.0</tt>) are encoded into identical byte streams (e.g. <tt>0x02</tt>) by encoding "Integral floating point values" (floating point values with a zero fractional part) as integers when possible.</t>
        <t>dCBOR implementations that support floating point numbers:</t>
        <ol spacing="normal" type="1"><li>
            <t><bcp14>MUST</bcp14> check whether floating point values to be encoded have the numerically equal value in <tt>DCBOR_INT</tt> = [-2<sup>63</sup>, 2<sup>64</sup>-1]. If that is the case, it <bcp14>MUST</bcp14> be converted to that numerically equal integer value before encoding it. (Preferred encoding will then ensure the shortest length encoding is used.) If a floating point value has a non-zero fractional part, or an exponent that takes it out of <tt>DCBOR_INT</tt>, the original floating point value is used for encoding. (Specifically, conversion to a CBOR bignum is never considered.)  </t>
            <t>
This also means that the three representations of a zero number in CBOR (<tt>0</tt>, <tt>0.0</tt>, <tt>-0.0</tt> in diagnostic notation) are all reduced to the basic integer <tt>0</tt> (with preferred encoding <tt>0x00</tt>).</t>
          </li>
        </ol>
        <aside>
          <t>Note that numeric reduction means that some maps that are valid CDE/CBOR cannot be reduced to valid dCBOR maps, as numeric reduction can result in multiple entries with the same keys ("duplicate keys"). For example, the following is a valid CBOR/CDE map:</t>
          <figure>
            <name>Valid CBOR data item with numeric map keys (also valid CDE)</name>
            <sourcecode type="cbor-diag"><![CDATA[
{
   10: "ten",
   10.0: "floating ten"
}
]]></sourcecode>
          </figure>
          <t>Applying numeric reduction to this map would yield the invalid map:</t>
          <figure>
            <name>Numeric reduction turns valid CBOR invalid</name>
            <sourcecode type="cbor-diag"><![CDATA[
{  / invalid: multiple entries with the same key /
   10: "ten",
   10: "floating ten"
}
]]></sourcecode>
          </figure>
          <t>In general, dCBOR applications need to avoid maps that have entries with keys that are semantically equivalent in dCBOR's numeric model.</t>
        </aside>
        <ol spacing="normal" type="1" start="2"><li>
            <t><bcp14>MUST</bcp14> reduce all encoded NaN values to the quiet NaN value having the half-width CBOR representation <tt>0xf97e00</tt>.</t>
          </li>
        </ol>
        <t>dCBOR decoders that support floating point numbers:</t>
        <ol spacing="normal" type="1" start="3"><li>
            <t><bcp14>MUST</bcp14> reject any encoded floating point values that are not encoded according to the above rules.</t>
          </li>
        </ol>
      </section>
      <section anchor="simple-values">
        <name>Simple Values</name>
        <t>Only the three "simple" (major type 7) values <tt>false</tt> (0xf4), <tt>true</tt> (0xf5), and <tt>null</tt> (0xf6) and the floating point values are valid in dCBOR.</t>
        <t>dCBOR encoders:</t>
        <ol spacing="normal" type="1"><li>
            <t><bcp14>MUST NOT</bcp14> encode major type 7 values other than <tt>false</tt>, <tt>true</tt>, <tt>null</tt>, and the floating point values.</t>
          </li>
        </ol>
        <t>dCBOR decoders:</t>
        <ol spacing="normal" type="1" start="2"><li>
            <t><bcp14>MUST</bcp14> reject any encoded major type 7 values other than <tt>false</tt>, <tt>true</tt>, <tt>null</tt>, and the floating point values.</t>
          </li>
        </ol>
      </section>
    </section>
    <section anchor="cddl-support-declarative-tag">
      <name>CDDL support, Declarative Tag</name>
      <t>Similar to the CDDL <xref target="RFC8610"/> support in CDE <xref target="CDE"/>, this specification adds two CDDL control operators that can be used to specify that the data items should be encoded in CBOR Common Deterministic Encoding (CDE), with the dCBOR application profile applied as well.</t>
      <t>The control operators <tt>.dcbor</tt> and <tt>.dcborseq</tt> are exactly like <tt>.cde</tt> and <tt>.cdeseq</tt> except that they also require the encoded data item(s) to conform to the dCBOR application profile.</t>
      <t>Tag 201 (<xref target="tag201"/>) is defined in this specification as a way to declare its tag
content to conform to the dCBOR application profile at the data model level.
As a result, when this data item is encoded using CDE rules, the encoded
result will conform to dCBOR also at the encoded data item level.
(In conjunction with this semantics, tag 201 may also be employed as a
boundary marker leading from an overall structure to specific
application data items; see <xref section="3" sectionFormat="of" target="GordianEnvelope"/> for an
example for this usage.)</t>
    </section>
    <section removeInRFC="true" anchor="implementation-status">
      <name>Implementation Status</name>
      <t>(Boilerplate as per <xref section="2.1" sectionFormat="of" target="RFC7942"/>:)</t>
      <t>This section records the status of known implementations of the
protocol defined by this specification at the time of posting of
this Internet-Draft, and is based on a proposal described in
<xref target="RFC7942"/>.  The description of implementations in this section is
intended to assist the IETF in its decision processes in
progressing drafts to RFCs.  Please note that the listing of any
individual implementation here does not imply endorsement by the
IETF.  Furthermore, no effort has been spent to verify the
information presented here that was supplied by IETF contributors.
This is not intended as, and must not be construed to be, a
catalog of available implementations or their features.  Readers
are advised to note that other implementations may exist.</t>
      <t>According to <xref target="RFC7942"/>, "this will allow reviewers and working
groups to assign due consideration to documents that have the
benefit of running code, which may serve as evidence of valuable
experimentation and feedback that have made the implemented
protocols more mature.  It is up to the individual working groups
to use this information as they see fit".
<?line -22?>
      </t>
      <section anchor="swift">
        <name>Swift</name>
        <ul spacing="normal">
          <li>
            <t>Description: Single-purpose dCBOR reference implementation for Swift.</t>
          </li>
          <li>
            <t>Organization: Blockchain Commons</t>
          </li>
          <li>
            <t>Implementation Location: <xref target="BCSwiftDCBOR"/></t>
          </li>
          <li>
            <t>Primary Maintainer: Wolf McNally</t>
          </li>
          <li>
            <t>Languages: Swift</t>
          </li>
          <li>
            <t>Coverage: Complete</t>
          </li>
          <li>
            <t>Testing: Unit tests</t>
          </li>
          <li>
            <t>Licensing: BSD-2-Clause-Patent</t>
          </li>
        </ul>
      </section>
      <section anchor="rust">
        <name>Rust</name>
        <ul spacing="normal">
          <li>
            <t>Description: Single-purpose dCBOR reference implementation for Rust.</t>
          </li>
          <li>
            <t>Organization: Blockchain Commons</t>
          </li>
          <li>
            <t>Implementation Location: <xref target="BCRustDCBOR"/></t>
          </li>
          <li>
            <t>Primary Maintainer: Wolf McNally</t>
          </li>
          <li>
            <t>Languages: Rust</t>
          </li>
          <li>
            <t>Coverage: Complete</t>
          </li>
          <li>
            <t>Testing: Unit tests</t>
          </li>
          <li>
            <t>Licensing: BSD-2-Clause-Patent</t>
          </li>
        </ul>
      </section>
      <section anchor="typescript">
        <name>TypeScript</name>
        <ul spacing="normal">
          <li>
            <t>Description: Single-purpose dCBOR reference implementation for TypeScript.</t>
          </li>
          <li>
            <t>Organization: Blockchain Commons</t>
          </li>
          <li>
            <t>Implementation Location: <xref target="BCTypescriptDCBOR"/></t>
          </li>
          <li>
            <t>Primary Maintainer: Wolf McNally</t>
          </li>
          <li>
            <t>Languages: TypeScript (transpiles to JavaScript)</t>
          </li>
          <li>
            <t>Coverage: Complete</t>
          </li>
          <li>
            <t>Testing: Unit tests</t>
          </li>
          <li>
            <t>Licensing: BSD-2-Clause-Patent</t>
          </li>
        </ul>
      </section>
      <section anchor="ruby">
        <name>Ruby</name>
        <ul spacing="normal">
          <li>
            <t>Implementation Location: <xref target="cbor-dcbor"/></t>
          </li>
          <li>
            <t>Primary Maintainer: Carsten Bormann</t>
          </li>
          <li>
            <t>Languages: Ruby</t>
          </li>
          <li>
            <t>Coverage: Complete specification; complemented by CBOR encoder/decoder and command line interface from <xref target="cbor-diag"/> and deterministic encoding from <xref target="cbor-deterministic"/>. Checking of dCBOR - exclusions not yet implemented.</t>
          </li>
          <li>
            <t>Testing: Also available at https://cbor.me</t>
          </li>
          <li>
            <t>Licensing: Apache-2.0</t>
          </li>
        </ul>
      </section>
    </section>
    <section anchor="security-considerations">
      <name>Security Considerations</name>
      <t>This document inherits the security considerations of CBOR <xref target="RFC8949"/>.</t>
      <t>Vulnerabilities regarding dCBOR will revolve around whether an attacker can find value in producing semantically equivalent documents that are nonetheless serialized into non-identical byte streams. Such documents could be used to contain malicious payloads or exfiltrate sensitive data. The ability to create such documents could indicate the failure of a dCBOR decoder to correctly validate according to this document, or the failure of the developer to properly specify or implement application protocol requirements using dCBOR. Whether these possibilities present an identifiable attack surface is a question that developers should consider.</t>
    </section>
    <section anchor="tag201">
      <name>IANA Considerations</name>
      <t>RFC Editor: please replace RFCXXXX with the RFC number of this RFC and remove this note.</t>
      <t>This document requests IANA to register the following CBOR tag in the "CBOR Tags" registry of <xref target="IANACBORTAGS"/>:</t>
      <table>
        <name>CBOR Tag for dCBOR</name>
        <thead>
          <tr>
            <th align="left">Tag</th>
            <th align="left">Data Item</th>
            <th align="left">Semantics</th>
            <th align="left">Reference</th>
          </tr>
        </thead>
        <tbody>
          <tr>
            <td align="left">#201</td>
            <td align="left">(any)</td>
            <td align="left">enclosed dCBOR</td>
            <td align="left">[RFCXXXX]</td>
          </tr>
        </tbody>
      </table>
      <t>This document requests IANA to register the contents of Table 1 into the registry "CDDL Control Operators" of <xref target="IANACDDL"/>:</t>
      <table>
        <name>CDDL Control Operators for dCBOR</name>
        <thead>
          <tr>
            <th align="left">Name</th>
            <th align="left">Reference</th>
          </tr>
        </thead>
        <tbody>
          <tr>
            <td align="left">.dcbor</td>
            <td align="left">[RFCXXXX]</td>
          </tr>
          <tr>
            <td align="left">.dcborseq</td>
            <td align="left">[RFCXXXX]</td>
          </tr>
        </tbody>
      </table>
    </section>
  </middle>
  <back>
    <references>
      <name>References</name>
      <references anchor="sec-normative-references">
        <name>Normative References</name>
        <reference anchor="RFC8949">
          <front>
            <title>Concise Binary Object Representation (CBOR)</title>
            <author fullname="C. Bormann" initials="C." surname="Bormann"/>
            <author fullname="P. Hoffman" initials="P." surname="Hoffman"/>
            <date month="December" year="2020"/>
            <abstract>
              <t>The Concise Binary Object Representation (CBOR) is a data format whose design goals include the possibility of extremely small code size, fairly small message size, and extensibility without the need for version negotiation. These design goals make it different from earlier binary serializations such as ASN.1 and MessagePack.</t>
              <t>This document obsoletes RFC 7049, providing editorial improvements, new details, and errata fixes while keeping full compatibility with the interchange format of RFC 7049. It does not create a new version of the format.</t>
            </abstract>
          </front>
          <seriesInfo name="STD" value="94"/>
          <seriesInfo name="RFC" value="8949"/>
          <seriesInfo name="DOI" value="10.17487/RFC8949"/>
        </reference>
        <reference anchor="RFC8610">
          <front>
            <title>Concise Data Definition Language (CDDL): A Notational Convention to Express Concise Binary Object Representation (CBOR) and JSON Data Structures</title>
            <author fullname="H. Birkholz" initials="H." surname="Birkholz"/>
            <author fullname="C. Vigano" initials="C." surname="Vigano"/>
            <author fullname="C. Bormann" initials="C." surname="Bormann"/>
            <date month="June" year="2019"/>
            <abstract>
              <t>This document proposes a notational convention to express Concise Binary Object Representation (CBOR) data structures (RFC 7049). Its main goal is to provide an easy and unambiguous way to express structures for protocol messages and data formats that use CBOR or JSON.</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="8610"/>
          <seriesInfo name="DOI" value="10.17487/RFC8610"/>
        </reference>
        <reference anchor="CDE">
          <front>
            <title>CBOR Common Deterministic Encoding (CDE)</title>
            <author fullname="Carsten Bormann" initials="C." surname="Bormann">
              <organization>Universität Bremen TZI</organization>
            </author>
            <date day="3" month="March" year="2024"/>
            <abstract>
              <t>   CBOR (STD 94, RFC 8949) defines "Deterministically Encoded CBOR" in
   its Section 4.2, providing some flexibility for application specific
   decisions.  To facilitate Deterministic Encoding to be offered as a
   selectable feature of generic encoders, the present document defines
   a CBOR Common Deterministic Encoding (CDE) Profile that can be shared
   by a large set of applications with potentially diverging detailed
   requirements.

   This document also introduces the concept of Application Profiles,
   which are layered on top of the CBOR CDE Profile and can address more
   application specific requirements.  Application Profiles are defined
   in separate documents.

              </t>
            </abstract>
          </front>
          <seriesInfo name="Internet-Draft" value="draft-ietf-cbor-cde-02"/>
        </reference>
        <reference anchor="IANACDDL" target="http://www.iana.org/assignments/cddl">
          <front>
            <title>Concise Data Definition Language (CDDL)</title>
            <author>
              <organization>IANA</organization>
            </author>
          </front>
        </reference>
        <reference anchor="IANACBORTAGS" target="http://www.iana.org/assignments/cbor-tags">
          <front>
            <title>Concise Binary Object Representation (CBOR) Tags</title>
            <author>
              <organization>IANA</organization>
            </author>
          </front>
        </reference>
        <reference anchor="RFC2119">
          <front>
            <title>Key words for use in RFCs to Indicate Requirement Levels</title>
            <author fullname="S. Bradner" initials="S." surname="Bradner"/>
            <date month="March" year="1997"/>
            <abstract>
              <t>In many standards track documents several words are used to signify the requirements in the specification. These words are often capitalized. This document defines these words as they should be interpreted in IETF documents. This document specifies an Internet Best Current Practices for the Internet Community, and requests discussion and suggestions for improvements.</t>
            </abstract>
          </front>
          <seriesInfo name="BCP" value="14"/>
          <seriesInfo name="RFC" value="2119"/>
          <seriesInfo name="DOI" value="10.17487/RFC2119"/>
        </reference>
        <reference anchor="RFC8174">
          <front>
            <title>Ambiguity of Uppercase vs Lowercase in RFC 2119 Key Words</title>
            <author fullname="B. Leiba" initials="B." surname="Leiba"/>
            <date month="May" year="2017"/>
            <abstract>
              <t>RFC 2119 specifies common key words that may be used in protocol specifications. This document aims to reduce the ambiguity by clarifying that only UPPERCASE usage of the key words have the defined special meanings.</t>
            </abstract>
          </front>
          <seriesInfo name="BCP" value="14"/>
          <seriesInfo name="RFC" value="8174"/>
          <seriesInfo name="DOI" value="10.17487/RFC8174"/>
        </reference>
      </references>
      <references anchor="sec-informative-references">
        <name>Informative References</name>
        <reference anchor="BCSwiftDCBOR" target="https://github.com/BlockchainCommons/BCSwiftDCBOR">
          <front>
            <title>Deterministic CBOR (dCBOR) for Swift.</title>
            <author initials="W." surname="McNally" fullname="Wolf McNally">
              <organization/>
            </author>
            <date>n.d.</date>
          </front>
        </reference>
        <reference anchor="BCRustDCBOR" target="https://github.com/BlockchainCommons/bc-dcbor-rust">
          <front>
            <title>Deterministic CBOR (dCBOR) for Rust.</title>
            <author initials="W." surname="McNally" fullname="Wolf McNally">
              <organization/>
            </author>
            <date>n.d.</date>
          </front>
        </reference>
        <reference anchor="BCTypescriptDCBOR" target="https://github.com/BlockchainCommons/bc-dcbor-ts">
          <front>
            <title>Deterministic CBOR (dCBOR) for Typescript.</title>
            <author initials="W." surname="McNally" fullname="Wolf McNally">
              <organization/>
            </author>
            <date>n.d.</date>
          </front>
        </reference>
        <reference anchor="GordianEnvelope">
          <front>
            <title>The Gordian Envelope Structured Data Format</title>
            <author fullname="Wolf McNally" initials="W." surname="McNally">
              <organization>Blockchain Commons</organization>
            </author>
            <author fullname="Christopher Allen" initials="C." surname="Allen">
              <organization>Blockchain Commons</organization>
            </author>
            <date day="31" month="March" year="2024"/>
            <abstract>
              <t>   Gordian Envelope specifies a structured format for hierarchical
   binary data focused on the ability to transmit it in a privacy-
   focused way, offering support for privacy as described in RFC 6973
   and human rights as described in RFC 8280.  Envelopes are designed to
   facilitate "smart documents" and have a number of unique features
   including: easy representation of a variety of semantic structures, a
   built-in Merkle-like digest tree, deterministic representation using
   CBOR, and the ability for the holder of a document to selectively
   elide specific parts of a document without invalidating the digest
   tree structure.  This document specifies the base Envelope format,
   which is designed to be extensible.

              </t>
            </abstract>
          </front>
          <seriesInfo name="Internet-Draft" value="draft-mcnally-envelope-07"/>
        </reference>
        <reference anchor="cbor-deterministic" target="https://github.com/cabo/cbor-deterministic">
          <front>
            <title>cbor-deterministic gem</title>
            <author initials="C." surname="Bormann" fullname="Carsten Bormann">
              <organization/>
            </author>
            <date>n.d.</date>
          </front>
        </reference>
        <reference anchor="cbor-diag" target="https://github.com/cabo/cbor-diag">
          <front>
            <title>CBOR diagnostic utilities</title>
            <author initials="C." surname="Bormann" fullname="Carsten Bormann">
              <organization/>
            </author>
            <date>n.d.</date>
          </front>
        </reference>
        <reference anchor="cbor-dcbor" target="https://github.com/cabo/cbor-dcbor">
          <front>
            <title>PoC of the McNally/Allen dCBOR application-level CBOR representation rules</title>
            <author initials="C." surname="Bormann" fullname="Carsten Bormann">
              <organization/>
            </author>
            <date>n.d.</date>
          </front>
        </reference>
        <reference anchor="RFC7942">
          <front>
            <title>Improving Awareness of Running Code: The Implementation Status Section</title>
            <author fullname="Y. Sheffer" initials="Y." surname="Sheffer"/>
            <author fullname="A. Farrel" initials="A." surname="Farrel"/>
            <date month="July" year="2016"/>
            <abstract>
              <t>This document describes a simple process that allows authors of Internet-Drafts to record the status of known implementations by including an Implementation Status section. This will allow reviewers and working groups to assign due consideration to documents that have the benefit of running code, which may serve as evidence of valuable experimentation and feedback that have made the implemented protocols more mature.</t>
              <t>This process is not mandatory. Authors of Internet-Drafts are encouraged to consider using the process for their documents, and working groups are invited to think about applying the process to all of their protocol specifications. This document obsoletes RFC 6982, advancing it to a Best Current Practice.</t>
            </abstract>
          </front>
          <seriesInfo name="BCP" value="205"/>
          <seriesInfo name="RFC" value="7942"/>
          <seriesInfo name="DOI" value="10.17487/RFC7942"/>
        </reference>
      </references>
    </references>
    <?line 309?>

<section numbered="false" anchor="acknowledgments">
      <name>Acknowledgments</name>
      <t>The authors are grateful for the contributions of Joe Hildebrand, Laurence Lundblade, and Anders Rundgren in the CBOR working group.</t>
    </section>
  </back>
  <!-- ##markdown-source:
H4sIAAAAAAAAA8Vb6XIbR5L+309RC/1YcgMAD3FkC2PLpkjKpleitCRt76ys
WBa6C0CZfcB9kIIp+lnmx0TMe3hfbL/MrOoDh0b2yrOMsIBu1JGZlceXmeXB
YBDcjNTDIChtGZuR6kVHT1+ej9ShOjalyROb2qK0oaK36nA+j22oS5ul6lWe
TWxseoEej3Nz42f2gigLU51gqSjXk3KQ4CmOF4OovdwgHGf5YG83wGJmmuWL
kTJv50FR5kYnI3V6cvksCOw8H6kyr4pyf3f38e5+oPHrqE1EoXQaqXOj48Gl
TUxwm+XX0zyr5iN1Zkp6Ut/jH5tO1Vf0Org2C7yNsEMKalJTDo6JyCCY25F6
XWZhXxVZDiomBb4tEvryJghuTFqZUfBAKbd6j8XxQlssk+o0NEzIyVs8FURX
j8Ym2sYYSqx+aU05GWb5tBdgDVvOqvFIPY2z8DqcYZGjLEkwa+f701fFgJgf
iOxWZRYEuipnWT4K1ABLKSWi/j6LJ+pFeEaS5tfYSqf2Z5ZSeyfltuJBRii8
xeQv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