<?xml version='1.0' encoding='utf-8'?>
<rfc xmlns:xi="http://www.w3.org/2001/XInclude" version="3" category="exp" consensus="true" docName="draft-ietf-trans-rfc6962-bis-42" indexInclude="true" ipr="trust200902" number="9162" obsoletes="6962" prepTime="2021-12-09T23:20:06" scripts="Common,Latin" sortRefs="true" submissionType="IETF" symRefs="true" tocDepth="3" tocInclude="true" xml:lang="en">
  <link href="https://datatracker.ietf.org/doc/draft-ietf-trans-rfc6962-bis-42" rel="prev"/>
  <link href="https://dx.doi.org/10.17487/rfc9162" rel="alternate"/>
  <link href="urn:issn:2070-1721" rel="alternate"/>
  <front>
    <title>Certificate Transparency Version 2.0</title>
    <seriesInfo name="RFC" value="9162" stream="IETF"/>
    <author initials="B." surname="Laurie" fullname="Ben Laurie">
      <organization abbrev="Google" showOnFrontPage="true">Google UK Ltd.</organization>
      <address>
        <email>benl@google.com</email>
      </address>
    </author>
    <author initials="E." surname="Messeri" fullname="Eran Messeri">
      <organization abbrev="Google" showOnFrontPage="true">Google UK Ltd.</organization>
      <address>
        <email>eranm@google.com</email>
      </address>
    </author>
    <author initials="R." surname="Stradling" fullname="Rob Stradling">
      <organization abbrev="Sectigo" showOnFrontPage="true">Sectigo Ltd.</organization>
      <address>
        <email>rob@sectigo.com</email>
      </address>
    </author>
    <date month="12" year="2021"/>
    <area>Security</area>
    <workgroup>TRANS (Public Notary Transparency)</workgroup>
    <keyword>certificates</keyword>
    <keyword>pkix</keyword>
    <keyword>tls</keyword>
    <keyword>website</keyword>
    <keyword>webpki</keyword>
    <keyword>browsers</keyword>
    <abstract pn="section-abstract">
      <t indent="0" pn="section-abstract-1">This document describes version 2.0 of the Certificate Transparency (CT)
protocol for publicly logging the existence of Transport Layer Security (TLS)
server certificates as they are issued or observed, in a manner that allows
anyone to audit certification authority (CA) activity and notice the issuance of
suspect certificates as well as to audit the certificate logs themselves. The
intent is that eventually clients would refuse to honor certificates that do not
appear in a log, effectively forcing CAs to add all issued certificates to the
logs.</t>
      <t indent="0" pn="section-abstract-2">This document obsoletes RFC 6962.  It also specifies a new TLS extension that is
used to send various CT log artifacts.</t>
      <t indent="0" pn="section-abstract-3">Logs are network services that implement the protocol operations for submissions
and queries that are defined in this document.</t>
    </abstract>
    <boilerplate>
      <section anchor="status-of-memo" numbered="false" removeInRFC="false" toc="exclude" pn="section-boilerplate.1">
        <name slugifiedName="name-status-of-this-memo">Status of This Memo</name>
        <t indent="0" pn="section-boilerplate.1-1">
            This document is not an Internet Standards Track specification; it is
            published for examination, experimental implementation, and
            evaluation.
        </t>
        <t indent="0" pn="section-boilerplate.1-2">
            This document defines an Experimental Protocol for the Internet
            community.  This document is a product of the Internet Engineering
            Task Force (IETF).  It represents the consensus of the IETF community.
            It has received public review and has been approved for publication
            by the Internet Engineering Steering Group (IESG).  Not all documents
            approved by the IESG are candidates for any level of Internet
            Standard; see Section 2 of RFC 7841. 
        </t>
        <t indent="0" pn="section-boilerplate.1-3">
            Information about the current status of this document, any
            errata, and how to provide feedback on it may be obtained at
            <eref target="https://www.rfc-editor.org/info/rfc9162" brackets="none"/>.
        </t>
      </section>
      <section anchor="copyright" numbered="false" removeInRFC="false" toc="exclude" pn="section-boilerplate.2">
        <name slugifiedName="name-copyright-notice">Copyright Notice</name>
        <t indent="0" pn="section-boilerplate.2-1">
            Copyright (c) 2021 IETF Trust and the persons identified as the
            document authors. All rights reserved.
        </t>
        <t indent="0" pn="section-boilerplate.2-2">
            This document is subject to BCP 78 and the IETF Trust's Legal
            Provisions Relating to IETF Documents
            (<eref target="https://trustee.ietf.org/license-info" brackets="none"/>) 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.
        </t>
      </section>
    </boilerplate>
    <toc>
      <section anchor="toc" numbered="false" removeInRFC="false" toc="exclude" pn="section-toc.1">
        <name slugifiedName="name-table-of-contents">Table of Contents</name>
        <ul bare="true" empty="true" indent="2" spacing="compact" pn="section-toc.1-1">
          <li pn="section-toc.1-1.1">
            <t indent="0" pn="section-toc.1-1.1.1"><xref derivedContent="1" format="counter" sectionFormat="of" target="section-1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-introduction">Introduction</xref></t>
            <ul bare="true" empty="true" indent="2" spacing="compact" pn="section-toc.1-1.1.2">
              <li pn="section-toc.1-1.1.2.1">
                <t indent="0" keepWithNext="true" pn="section-toc.1-1.1.2.1.1"><xref derivedContent="1.1" format="counter" sectionFormat="of" target="section-1.1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-requirements-language">Requirements Language</xref></t>
              </li>
              <li pn="section-toc.1-1.1.2.2">
                <t indent="0" keepWithNext="true" pn="section-toc.1-1.1.2.2.1"><xref derivedContent="1.2" format="counter" sectionFormat="of" target="section-1.2"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-data-structures">Data Structures</xref></t>
              </li>
              <li pn="section-toc.1-1.1.2.3">
                <t indent="0" keepWithNext="true" pn="section-toc.1-1.1.2.3.1"><xref derivedContent="1.3" format="counter" sectionFormat="of" target="section-1.3"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-major-differences-from-ct-1">Major Differences from CT 1.0</xref></t>
              </li>
            </ul>
          </li>
          <li pn="section-toc.1-1.2">
            <t indent="0" pn="section-toc.1-1.2.1"><xref derivedContent="2" format="counter" sectionFormat="of" target="section-2"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-cryptographic-components">Cryptographic Components</xref></t>
            <ul bare="true" empty="true" indent="2" spacing="compact" pn="section-toc.1-1.2.2">
              <li pn="section-toc.1-1.2.2.1">
                <t indent="0" pn="section-toc.1-1.2.2.1.1"><xref derivedContent="2.1" format="counter" sectionFormat="of" target="section-2.1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-merkle-trees">Merkle Trees</xref></t>
                <ul bare="true" empty="true" indent="2" spacing="compact" pn="section-toc.1-1.2.2.1.2">
                  <li pn="section-toc.1-1.2.2.1.2.1">
                    <t indent="0" pn="section-toc.1-1.2.2.1.2.1.1"><xref derivedContent="2.1.1" format="counter" sectionFormat="of" target="section-2.1.1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-definition-of-the-merkle-tr">Definition of the Merkle Tree</xref></t>
                  </li>
                  <li pn="section-toc.1-1.2.2.1.2.2">
                    <t indent="0" pn="section-toc.1-1.2.2.1.2.2.1"><xref derivedContent="2.1.2" format="counter" sectionFormat="of" target="section-2.1.2"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-verifying-a-tree-head-given">Verifying a Tree Head Given Entries</xref></t>
                  </li>
                  <li pn="section-toc.1-1.2.2.1.2.3">
                    <t indent="0" pn="section-toc.1-1.2.2.1.2.3.1"><xref derivedContent="2.1.3" format="counter" sectionFormat="of" target="section-2.1.3"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-merkle-inclusion-proofs">Merkle Inclusion Proofs</xref></t>
                  </li>
                  <li pn="section-toc.1-1.2.2.1.2.4">
                    <t indent="0" pn="section-toc.1-1.2.2.1.2.4.1"><xref derivedContent="2.1.4" format="counter" sectionFormat="of" target="section-2.1.4"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-merkle-consistency-proofs">Merkle Consistency Proofs</xref></t>
                  </li>
                  <li pn="section-toc.1-1.2.2.1.2.5">
                    <t indent="0" pn="section-toc.1-1.2.2.1.2.5.1"><xref derivedContent="2.1.5" format="counter" sectionFormat="of" target="section-2.1.5"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-example">Example</xref></t>
                  </li>
                </ul>
              </li>
              <li pn="section-toc.1-1.2.2.2">
                <t indent="0" pn="section-toc.1-1.2.2.2.1"><xref derivedContent="2.2" format="counter" sectionFormat="of" target="section-2.2"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-signatures">Signatures</xref></t>
              </li>
            </ul>
          </li>
          <li pn="section-toc.1-1.3">
            <t indent="0" pn="section-toc.1-1.3.1"><xref derivedContent="3" format="counter" sectionFormat="of" target="section-3"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-submitters">Submitters</xref></t>
            <ul bare="true" empty="true" indent="2" spacing="compact" pn="section-toc.1-1.3.2">
              <li pn="section-toc.1-1.3.2.1">
                <t indent="0" pn="section-toc.1-1.3.2.1.1"><xref derivedContent="3.1" format="counter" sectionFormat="of" target="section-3.1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-certificates">Certificates</xref></t>
              </li>
              <li pn="section-toc.1-1.3.2.2">
                <t indent="0" pn="section-toc.1-1.3.2.2.1"><xref derivedContent="3.2" format="counter" sectionFormat="of" target="section-3.2"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-precertificates">Precertificates</xref></t>
                <ul bare="true" empty="true" indent="2" spacing="compact" pn="section-toc.1-1.3.2.2.2">
                  <li pn="section-toc.1-1.3.2.2.2.1">
                    <t indent="0" pn="section-toc.1-1.3.2.2.2.1.1"><xref derivedContent="3.2.1" format="counter" sectionFormat="of" target="section-3.2.1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-binding-intent-to-issue">Binding Intent to Issue</xref></t>
                  </li>
                </ul>
              </li>
            </ul>
          </li>
          <li pn="section-toc.1-1.4">
            <t indent="0" pn="section-toc.1-1.4.1"><xref derivedContent="4" format="counter" sectionFormat="of" target="section-4"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-log-format-and-operation">Log Format and Operation</xref></t>
            <ul bare="true" empty="true" indent="2" spacing="compact" pn="section-toc.1-1.4.2">
              <li pn="section-toc.1-1.4.2.1">
                <t indent="0" pn="section-toc.1-1.4.2.1.1"><xref derivedContent="4.1" format="counter" sectionFormat="of" target="section-4.1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-log-parameters">Log Parameters</xref></t>
              </li>
              <li pn="section-toc.1-1.4.2.2">
                <t indent="0" pn="section-toc.1-1.4.2.2.1"><xref derivedContent="4.2" format="counter" sectionFormat="of" target="section-4.2"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-evaluating-submissions">Evaluating Submissions</xref></t>
                <ul bare="true" empty="true" indent="2" spacing="compact" pn="section-toc.1-1.4.2.2.2">
                  <li pn="section-toc.1-1.4.2.2.2.1">
                    <t indent="0" pn="section-toc.1-1.4.2.2.2.1.1"><xref derivedContent="4.2.1" format="counter" sectionFormat="of" target="section-4.2.1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-minimum-acceptance-criteria">Minimum Acceptance Criteria</xref></t>
                  </li>
                  <li pn="section-toc.1-1.4.2.2.2.2">
                    <t indent="0" pn="section-toc.1-1.4.2.2.2.2.1"><xref derivedContent="4.2.2" format="counter" sectionFormat="of" target="section-4.2.2"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-discretionary-acceptance-cr">Discretionary Acceptance Criteria</xref></t>
                  </li>
                </ul>
              </li>
              <li pn="section-toc.1-1.4.2.3">
                <t indent="0" pn="section-toc.1-1.4.2.3.1"><xref derivedContent="4.3" format="counter" sectionFormat="of" target="section-4.3"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-log-entries">Log Entries</xref></t>
              </li>
              <li pn="section-toc.1-1.4.2.4">
                <t indent="0" pn="section-toc.1-1.4.2.4.1"><xref derivedContent="4.4" format="counter" sectionFormat="of" target="section-4.4"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-log-id">Log ID</xref></t>
              </li>
              <li pn="section-toc.1-1.4.2.5">
                <t indent="0" pn="section-toc.1-1.4.2.5.1"><xref derivedContent="4.5" format="counter" sectionFormat="of" target="section-4.5"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-transitem-structure">TransItem Structure</xref></t>
              </li>
              <li pn="section-toc.1-1.4.2.6">
                <t indent="0" pn="section-toc.1-1.4.2.6.1"><xref derivedContent="4.6" format="counter" sectionFormat="of" target="section-4.6"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-log-artifact-extensions">Log Artifact Extensions</xref></t>
              </li>
              <li pn="section-toc.1-1.4.2.7">
                <t indent="0" pn="section-toc.1-1.4.2.7.1"><xref derivedContent="4.7" format="counter" sectionFormat="of" target="section-4.7"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-merkle-tree-leaves">Merkle Tree Leaves</xref></t>
              </li>
              <li pn="section-toc.1-1.4.2.8">
                <t indent="0" pn="section-toc.1-1.4.2.8.1"><xref derivedContent="4.8" format="counter" sectionFormat="of" target="section-4.8"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-signed-certificate-timestam">Signed Certificate Timestamp (SCT)</xref></t>
              </li>
              <li pn="section-toc.1-1.4.2.9">
                <t indent="0" pn="section-toc.1-1.4.2.9.1"><xref derivedContent="4.9" format="counter" sectionFormat="of" target="section-4.9"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-merkle-tree-head">Merkle Tree Head</xref></t>
              </li>
              <li pn="section-toc.1-1.4.2.10">
                <t indent="0" pn="section-toc.1-1.4.2.10.1"><xref derivedContent="4.10" format="counter" sectionFormat="of" target="section-4.10"/>. <xref derivedContent="" format="title" sectionFormat="of" target="name-signed-tree-head-sth">Signed Tree Head (STH)</xref></t>
              </li>
              <li pn="section-toc.1-1.4.2.11">
                <t indent="0" pn="section-toc.1-1.4.2.11.1"><xref derivedContent="4.11" format="counter" sectionFormat="of" target="section-4.11"/>. <xref derivedContent="" format="title" sectionFormat="of" target="name-merkle-consistency-proofs-2">Merkle Consistency Proofs</xref></t>
              </li>
              <li pn="section-toc.1-1.4.2.12">
                <t indent="0" pn="section-toc.1-1.4.2.12.1"><xref derivedContent="4.12" format="counter" sectionFormat="of" target="section-4.12"/>. <xref derivedContent="" format="title" sectionFormat="of" target="name-merkle-inclusion-proofs-2">Merkle Inclusion Proofs</xref></t>
              </li>
              <li pn="section-toc.1-1.4.2.13">
                <t indent="0" pn="section-toc.1-1.4.2.13.1"><xref derivedContent="4.13" format="counter" sectionFormat="of" target="section-4.13"/>. <xref derivedContent="" format="title" sectionFormat="of" target="name-shutting-down-a-log">Shutting Down a Log</xref></t>
              </li>
            </ul>
          </li>
          <li pn="section-toc.1-1.5">
            <t indent="0" pn="section-toc.1-1.5.1"><xref derivedContent="5" format="counter" sectionFormat="of" target="section-5"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-log-client-messages">Log Client Messages</xref></t>
            <ul bare="true" empty="true" indent="2" spacing="compact" pn="section-toc.1-1.5.2">
              <li pn="section-toc.1-1.5.2.1">
                <t indent="0" pn="section-toc.1-1.5.2.1.1"><xref derivedContent="5.1" format="counter" sectionFormat="of" target="section-5.1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-submit-entry-to-log">Submit Entry to Log</xref></t>
              </li>
              <li pn="section-toc.1-1.5.2.2">
                <t indent="0" pn="section-toc.1-1.5.2.2.1"><xref derivedContent="5.2" format="counter" sectionFormat="of" target="section-5.2"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-retrieve-latest-sth">Retrieve Latest STH</xref></t>
              </li>
              <li pn="section-toc.1-1.5.2.3">
                <t indent="0" pn="section-toc.1-1.5.2.3.1"><xref derivedContent="5.3" format="counter" sectionFormat="of" target="section-5.3"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-retrieve-merkle-consistency">Retrieve Merkle Consistency Proof between Two STHs</xref></t>
              </li>
              <li pn="section-toc.1-1.5.2.4">
                <t indent="0" pn="section-toc.1-1.5.2.4.1"><xref derivedContent="5.4" format="counter" sectionFormat="of" target="section-5.4"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-retrieve-merkle-inclusion-p">Retrieve Merkle Inclusion Proof from Log by Leaf Hash</xref></t>
              </li>
              <li pn="section-toc.1-1.5.2.5">
                <t indent="0" pn="section-toc.1-1.5.2.5.1"><xref derivedContent="5.5" format="counter" sectionFormat="of" target="section-5.5"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-retrieve-merkle-inclusion-pr">Retrieve Merkle Inclusion Proof, STH, and Consistency Proof by Leaf Hash</xref></t>
              </li>
              <li pn="section-toc.1-1.5.2.6">
                <t indent="0" pn="section-toc.1-1.5.2.6.1"><xref derivedContent="5.6" format="counter" sectionFormat="of" target="section-5.6"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-retrieve-entries-and-sth-fr">Retrieve Entries and STH from Log</xref></t>
              </li>
              <li pn="section-toc.1-1.5.2.7">
                <t indent="0" pn="section-toc.1-1.5.2.7.1"><xref derivedContent="5.7" format="counter" sectionFormat="of" target="section-5.7"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-retrieve-accepted-trust-anc">Retrieve Accepted Trust Anchors</xref></t>
              </li>
            </ul>
          </li>
          <li pn="section-toc.1-1.6">
            <t indent="0" pn="section-toc.1-1.6.1"><xref derivedContent="6" format="counter" sectionFormat="of" target="section-6"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-tls-servers">TLS Servers</xref></t>
            <ul bare="true" empty="true" indent="2" spacing="compact" pn="section-toc.1-1.6.2">
              <li pn="section-toc.1-1.6.2.1">
                <t indent="0" pn="section-toc.1-1.6.2.1.1"><xref derivedContent="6.1" format="counter" sectionFormat="of" target="section-6.1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-tls-client-authentication">TLS Client Authentication</xref></t>
              </li>
              <li pn="section-toc.1-1.6.2.2">
                <t indent="0" pn="section-toc.1-1.6.2.2.1"><xref derivedContent="6.2" format="counter" sectionFormat="of" target="section-6.2"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-multiple-scts">Multiple SCTs</xref></t>
              </li>
              <li pn="section-toc.1-1.6.2.3">
                <t indent="0" pn="section-toc.1-1.6.2.3.1"><xref derivedContent="6.3" format="counter" sectionFormat="of" target="section-6.3"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-transitemlist-structure">TransItemList Structure</xref></t>
              </li>
              <li pn="section-toc.1-1.6.2.4">
                <t indent="0" pn="section-toc.1-1.6.2.4.1"><xref derivedContent="6.4" format="counter" sectionFormat="of" target="section-6.4"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-presenting-scts-inclusions-">Presenting SCTs, Inclusions Proofs, and STHs</xref></t>
              </li>
              <li pn="section-toc.1-1.6.2.5">
                <t indent="0" pn="section-toc.1-1.6.2.5.1"><xref derivedContent="6.5" format="counter" sectionFormat="of" target="section-6.5"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-transparency_info-tls-exten">transparency_info TLS Extension</xref></t>
              </li>
            </ul>
          </li>
          <li pn="section-toc.1-1.7">
            <t indent="0" pn="section-toc.1-1.7.1"><xref derivedContent="7" format="counter" sectionFormat="of" target="section-7"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-certification-authorities">Certification Authorities</xref></t>
            <ul bare="true" empty="true" indent="2" spacing="compact" pn="section-toc.1-1.7.2">
              <li pn="section-toc.1-1.7.2.1">
                <t indent="0" pn="section-toc.1-1.7.2.1.1"><xref derivedContent="7.1" format="counter" sectionFormat="of" target="section-7.1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-transparency-information-x5">Transparency Information X.509v3 Extension</xref></t>
                <ul bare="true" empty="true" indent="2" spacing="compact" pn="section-toc.1-1.7.2.1.2">
                  <li pn="section-toc.1-1.7.2.1.2.1">
                    <t indent="0" pn="section-toc.1-1.7.2.1.2.1.1"><xref derivedContent="7.1.1" format="counter" sectionFormat="of" target="section-7.1.1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-ocsp-response-extension">OCSP Response Extension</xref></t>
                  </li>
                  <li pn="section-toc.1-1.7.2.1.2.2">
                    <t indent="0" pn="section-toc.1-1.7.2.1.2.2.1"><xref derivedContent="7.1.2" format="counter" sectionFormat="of" target="section-7.1.2"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-certificate-extension">Certificate Extension</xref></t>
                  </li>
                </ul>
              </li>
              <li pn="section-toc.1-1.7.2.2">
                <t indent="0" pn="section-toc.1-1.7.2.2.1"><xref derivedContent="7.2" format="counter" sectionFormat="of" target="section-7.2"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-tls-feature-x509v3-extensio">TLS Feature X.509v3 Extension</xref></t>
              </li>
            </ul>
          </li>
          <li pn="section-toc.1-1.8">
            <t indent="0" pn="section-toc.1-1.8.1"><xref derivedContent="8" format="counter" sectionFormat="of" target="section-8"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-clients">Clients</xref></t>
            <ul bare="true" empty="true" indent="2" spacing="compact" pn="section-toc.1-1.8.2">
              <li pn="section-toc.1-1.8.2.1">
                <t indent="0" pn="section-toc.1-1.8.2.1.1"><xref derivedContent="8.1" format="counter" sectionFormat="of" target="section-8.1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-tls-client">TLS Client</xref></t>
                <ul bare="true" empty="true" indent="2" spacing="compact" pn="section-toc.1-1.8.2.1.2">
                  <li pn="section-toc.1-1.8.2.1.2.1">
                    <t indent="0" pn="section-toc.1-1.8.2.1.2.1.1"><xref derivedContent="8.1.1" format="counter" sectionFormat="of" target="section-8.1.1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-receiving-scts-and-inclusio">Receiving SCTs and Inclusion Proofs</xref></t>
                  </li>
                  <li pn="section-toc.1-1.8.2.1.2.2">
                    <t indent="0" pn="section-toc.1-1.8.2.1.2.2.1"><xref derivedContent="8.1.2" format="counter" sectionFormat="of" target="section-8.1.2"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-reconstructing-the-tbscerti">Reconstructing the TBSCertificate</xref></t>
                  </li>
                  <li pn="section-toc.1-1.8.2.1.2.3">
                    <t indent="0" pn="section-toc.1-1.8.2.1.2.3.1"><xref derivedContent="8.1.3" format="counter" sectionFormat="of" target="section-8.1.3"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-validating-scts">Validating SCTs</xref></t>
                  </li>
                  <li pn="section-toc.1-1.8.2.1.2.4">
                    <t indent="0" pn="section-toc.1-1.8.2.1.2.4.1"><xref derivedContent="8.1.4" format="counter" sectionFormat="of" target="section-8.1.4"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-fetching-inclusion-proofs">Fetching Inclusion Proofs</xref></t>
                  </li>
                  <li pn="section-toc.1-1.8.2.1.2.5">
                    <t indent="0" pn="section-toc.1-1.8.2.1.2.5.1"><xref derivedContent="8.1.5" format="counter" sectionFormat="of" target="section-8.1.5"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-validating-inclusion-proofs">Validating Inclusion Proofs</xref></t>
                  </li>
                  <li pn="section-toc.1-1.8.2.1.2.6">
                    <t indent="0" pn="section-toc.1-1.8.2.1.2.6.1"><xref derivedContent="8.1.6" format="counter" sectionFormat="of" target="section-8.1.6"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-evaluating-compliance">Evaluating Compliance</xref></t>
                  </li>
                </ul>
              </li>
              <li pn="section-toc.1-1.8.2.2">
                <t indent="0" pn="section-toc.1-1.8.2.2.1"><xref derivedContent="8.2" format="counter" sectionFormat="of" target="section-8.2"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-monitor">Monitor</xref></t>
              </li>
              <li pn="section-toc.1-1.8.2.3">
                <t indent="0" pn="section-toc.1-1.8.2.3.1"><xref derivedContent="8.3" format="counter" sectionFormat="of" target="section-8.3"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-auditing">Auditing</xref></t>
              </li>
            </ul>
          </li>
          <li pn="section-toc.1-1.9">
            <t indent="0" pn="section-toc.1-1.9.1"><xref derivedContent="9" format="counter" sectionFormat="of" target="section-9"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-algorithm-agility">Algorithm Agility</xref></t>
          </li>
          <li pn="section-toc.1-1.10">
            <t indent="0" pn="section-toc.1-1.10.1"><xref derivedContent="10" format="counter" sectionFormat="of" target="section-10"/>. <xref derivedContent="" format="title" sectionFormat="of" target="name-iana-considerations">IANA Considerations</xref></t>
            <ul bare="true" empty="true" indent="2" spacing="compact" pn="section-toc.1-1.10.2">
              <li pn="section-toc.1-1.10.2.1">
                <t indent="0" pn="section-toc.1-1.10.2.1.1"><xref derivedContent="10.1" format="counter" sectionFormat="of" target="section-10.1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-additions-to-existing-regis">Additions to Existing Registries</xref></t>
                <ul bare="true" empty="true" indent="2" spacing="compact" pn="section-toc.1-1.10.2.1.2">
                  <li pn="section-toc.1-1.10.2.1.2.1">
                    <t indent="0" pn="section-toc.1-1.10.2.1.2.1.1"><xref derivedContent="10.1.1" format="counter" sectionFormat="of" target="section-10.1.1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-new-entry-to-the-tls-extens">New Entry to the TLS ExtensionType Registry</xref></t>
                  </li>
                  <li pn="section-toc.1-1.10.2.1.2.2">
                    <t indent="0" pn="section-toc.1-1.10.2.1.2.2.1"><xref derivedContent="10.1.2" format="counter" sectionFormat="of" target="section-10.1.2"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-urn-sub-namespace-for-trans">URN Sub-namespace for TRANS (urn:ietf:params:trans)</xref></t>
                  </li>
                </ul>
              </li>
              <li pn="section-toc.1-1.10.2.2">
                <t indent="0" pn="section-toc.1-1.10.2.2.1"><xref derivedContent="10.2" format="counter" sectionFormat="of" target="section-10.2"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-new-ct-related-registries">New CT-Related Registries</xref></t>
                <ul bare="true" empty="true" indent="2" spacing="compact" pn="section-toc.1-1.10.2.2.2">
                  <li pn="section-toc.1-1.10.2.2.2.1">
                    <t indent="0" pn="section-toc.1-1.10.2.2.2.1.1"><xref derivedContent="10.2.1" format="counter" sectionFormat="of" target="section-10.2.1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-hash-algorithms">Hash Algorithms</xref></t>
                  </li>
                  <li pn="section-toc.1-1.10.2.2.2.2">
                    <t indent="0" pn="section-toc.1-1.10.2.2.2.2.1"><xref derivedContent="10.2.2" format="counter" sectionFormat="of" target="section-10.2.2"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-signature-algorithms">Signature Algorithms</xref></t>
                  </li>
                  <li pn="section-toc.1-1.10.2.2.2.3">
                    <t indent="0" pn="section-toc.1-1.10.2.2.2.3.1"><xref derivedContent="10.2.3" format="counter" sectionFormat="of" target="section-10.2.3"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-versionedtranstypes">VersionedTransTypes</xref></t>
                  </li>
                  <li pn="section-toc.1-1.10.2.2.2.4">
                    <t indent="0" pn="section-toc.1-1.10.2.2.2.4.1"><xref derivedContent="10.2.4" format="counter" sectionFormat="of" target="section-10.2.4"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-log-artifact-extensions-2">Log Artifact Extensions</xref></t>
                  </li>
                  <li pn="section-toc.1-1.10.2.2.2.5">
                    <t indent="0" pn="section-toc.1-1.10.2.2.2.5.1"><xref derivedContent="10.2.5" format="counter" sectionFormat="of" target="section-10.2.5"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-log-ids">Log IDs</xref></t>
                  </li>
                  <li pn="section-toc.1-1.10.2.2.2.6">
                    <t indent="0" pn="section-toc.1-1.10.2.2.2.6.1"><xref derivedContent="10.2.6" format="counter" sectionFormat="of" target="section-10.2.6"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-error-types">Error Types</xref></t>
                  </li>
                </ul>
              </li>
              <li pn="section-toc.1-1.10.2.3">
                <t indent="0" pn="section-toc.1-1.10.2.3.1"><xref derivedContent="10.3" format="counter" sectionFormat="of" target="section-10.3"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-oid-assignment">OID Assignment</xref></t>
              </li>
            </ul>
          </li>
          <li pn="section-toc.1-1.11">
            <t indent="0" pn="section-toc.1-1.11.1"><xref derivedContent="11" format="counter" sectionFormat="of" target="section-11"/>. <xref derivedContent="" format="title" sectionFormat="of" target="name-security-considerations">Security Considerations</xref></t>
            <ul bare="true" empty="true" indent="2" spacing="compact" pn="section-toc.1-1.11.2">
              <li pn="section-toc.1-1.11.2.1">
                <t indent="0" pn="section-toc.1-1.11.2.1.1"><xref derivedContent="11.1" format="counter" sectionFormat="of" target="section-11.1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-misissued-certificates">Misissued Certificates</xref></t>
              </li>
              <li pn="section-toc.1-1.11.2.2">
                <t indent="0" pn="section-toc.1-1.11.2.2.1"><xref derivedContent="11.2" format="counter" sectionFormat="of" target="section-11.2"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-detection-of-misissue">Detection of Misissue</xref></t>
              </li>
              <li pn="section-toc.1-1.11.2.3">
                <t indent="0" pn="section-toc.1-1.11.2.3.1"><xref derivedContent="11.3" format="counter" sectionFormat="of" target="section-11.3"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-misbehaving-logs">Misbehaving Logs</xref></t>
              </li>
              <li pn="section-toc.1-1.11.2.4">
                <t indent="0" pn="section-toc.1-1.11.2.4.1"><xref derivedContent="11.4" format="counter" sectionFormat="of" target="section-11.4"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-multiple-scts-2">Multiple SCTs</xref></t>
              </li>
              <li pn="section-toc.1-1.11.2.5">
                <t indent="0" pn="section-toc.1-1.11.2.5.1"><xref derivedContent="11.5" format="counter" sectionFormat="of" target="section-11.5"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-leakage-of-dns-information">Leakage of DNS Information</xref></t>
              </li>
            </ul>
          </li>
          <li pn="section-toc.1-1.12">
            <t indent="0" pn="section-toc.1-1.12.1"><xref derivedContent="12" format="counter" sectionFormat="of" target="section-12"/>. <xref derivedContent="" format="title" sectionFormat="of" target="name-references">References</xref></t>
            <ul bare="true" empty="true" indent="2" spacing="compact" pn="section-toc.1-1.12.2">
              <li pn="section-toc.1-1.12.2.1">
                <t indent="0" pn="section-toc.1-1.12.2.1.1"><xref derivedContent="12.1" format="counter" sectionFormat="of" target="section-12.1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-normative-references">Normative References</xref></t>
              </li>
              <li pn="section-toc.1-1.12.2.2">
                <t indent="0" pn="section-toc.1-1.12.2.2.1"><xref derivedContent="12.2" format="counter" sectionFormat="of" target="section-12.2"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-informative-references">Informative References</xref></t>
              </li>
            </ul>
          </li>
          <li pn="section-toc.1-1.13">
            <t indent="0" pn="section-toc.1-1.13.1"><xref derivedContent="Appendix A" format="default" sectionFormat="of" target="section-appendix.a"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-supporting-v1-and-v2-simult">Supporting v1 and v2 Simultaneously (Informative)</xref></t>
          </li>
          <li pn="section-toc.1-1.14">
            <t indent="0" pn="section-toc.1-1.14.1"><xref derivedContent="Appendix B" format="default" sectionFormat="of" target="section-appendix.b"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-an-asn1-module-informative">An ASN.1 Module (Informative)</xref></t>
          </li>
          <li pn="section-toc.1-1.15">
            <t indent="0" pn="section-toc.1-1.15.1"><xref derivedContent="" format="none" sectionFormat="of" target="section-appendix.c"/><xref derivedContent="" format="title" sectionFormat="of" target="name-acknowledgements">Acknowledgements</xref></t>
          </li>
          <li pn="section-toc.1-1.16">
            <t indent="0" pn="section-toc.1-1.16.1"><xref derivedContent="" format="none" sectionFormat="of" target="section-appendix.d"/><xref derivedContent="" format="title" sectionFormat="of" target="name-authors-addresses">Authors' Addresses</xref></t>
          </li>
        </ul>
      </section>
    </toc>
  </front>
  <middle>
    <section anchor="introduction" numbered="true" toc="include" removeInRFC="false" pn="section-1">
      <name slugifiedName="name-introduction">Introduction</name>
      <t indent="0" pn="section-1-1">Certificate Transparency aims to mitigate the problem of misissued certificates
by providing append-only logs of issued certificates. The logs do not themselves
prevent misissuance, but they ensure that interested parties (particularly those
named in certificates) can detect such misissuance. Note that this is a general
mechanism that could be used for transparently logging any form of binary data,
subject to some kind of inclusion criteria. In this document, we only describe
its use for public TLS server certificates (i.e., where the inclusion criteria
is a valid certificate issued by a public certification authority (CA)).
A typical definition of "public" can be found in <xref target="CABBR" format="default" sectionFormat="of" derivedContent="CABBR"/>.</t>
      <t indent="0" pn="section-1-2">Each log contains certificate chains, which can be submitted by anyone. It is
expected that public CAs will contribute all their newly issued certificates to
one or more logs; however, certificate holders can also contribute their own
certificate chains, as can third parties. In order to avoid logs being rendered
useless by the submission of large numbers of spurious certificates, it is
required that each chain ends with a trust anchor that is accepted by the log.
A log may also limit the length of the chain it is willing to accept;
such chains must also end with an acceptable trust anchor.
When a chain is accepted by a log, a signed timestamp is returned, which can
later be used to provide evidence to TLS clients that the chain has been
submitted. TLS clients can thus require that all certificates they accept as
valid are accompanied by signed timestamps.</t>
      <t indent="0" pn="section-1-3">Those who are concerned about misissuance can monitor the logs, asking them
regularly for all new entries, and can thus check whether domains for which they
are responsible have had certificates issued that they did not expect. What
they do with this information, particularly when they find that a misissuance
has happened, is beyond the scope of this document. However, broadly speaking,
they can invoke existing business mechanisms for dealing with misissued
certificates, such as working with the CA to get the certificate revoked or
with maintainers of trust anchor lists to get the CA removed. Of course, anyone
who wants can monitor the logs and, if they believe a certificate is incorrectly
issued, take action as they see fit.</t>
      <t indent="0" pn="section-1-4">Similarly, those who have seen signed timestamps from a particular log can later
demand a proof of inclusion from that log. If the log is unable to provide this
(or, indeed, if the corresponding certificate is absent from monitors' copies of
that log), that is evidence of the incorrect operation of the log. The checking
operation is asynchronous to allow clients to proceed without delay, despite
possible issues, such as network connectivity and the vagaries of firewalls.</t>
      <t indent="0" pn="section-1-5">The append-only property of each log is achieved using Merkle Trees, which can
be used to efficiently prove that any particular instance of the log is a
superset of any particular previous instance and to efficiently detect various
misbehaviors of the log (e.g., issuing a signed timestamp for a certificate that
is not subsequently logged).</t>
      <t indent="0" pn="section-1-6">The log auditing mechanisms described in this document can
be circumvented by a misbehaving log that shows different, inconsistent
views of itself to different clients. Therefore, it is necessary to treat each log 
as a trusted third party. While mechanisms are being developed to address these
shortcomings and thereby avoid the need to blindly trust logs,
such mechanisms are outside the scope of this document.</t>
      <section anchor="requirements-language" numbered="true" toc="include" removeInRFC="false" pn="section-1.1">
        <name slugifiedName="name-requirements-language">Requirements Language</name>
        <t indent="0" pn="section-1.1-1">
    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" format="default" sectionFormat="of" derivedContent="RFC2119"/> <xref target="RFC8174" format="default" sectionFormat="of" derivedContent="RFC8174"/> 
    when, and only when, they appear in all capitals, as shown here.
        </t>
      </section>
      <section anchor="data_structures" numbered="true" toc="include" removeInRFC="false" pn="section-1.2">
        <name slugifiedName="name-data-structures">Data Structures</name>
        <t indent="0" pn="section-1.2-1">Data structures are defined and encoded according to the conventions laid out
	in <xref target="RFC8446" sectionFormat="of" section="3" format="default" derivedLink="https://rfc-editor.org/rfc/rfc8446#section-3" derivedContent="RFC8446"/>.</t>
        <t indent="0" pn="section-1.2-2">This document uses object identifiers (OIDs) to identify Log IDs (see
	<xref target="log_id" format="default" sectionFormat="of" derivedContent="Section 4.4"/>), the precertificate Cryptographic Message
	Syntax (CMS) <tt>eContentType</tt> (see <xref target="precertificates" format="default" sectionFormat="of" derivedContent="Section 3.2"/>), X.509v3 extensions in certificates (see <xref target="cert_transinfo_extension" format="default" sectionFormat="of" derivedContent="Section 7.1.2"/>), and
	Online Certificate Status Protocol (OCSP) responses (see <xref target="ocsp_transinfo_extension" format="default" sectionFormat="of" derivedContent="Section 7.1.1"/>). The OIDs are defined in an
	arc that was selected due to its short encoding.</t>
      </section>
      <section anchor="major-differences-from-ct-10" numbered="true" toc="include" removeInRFC="false" pn="section-1.3">
        <name slugifiedName="name-major-differences-from-ct-1">Major Differences from CT 1.0</name>
        <t indent="0" pn="section-1.3-1">This document revises and obsoletes the CT 1.0 protocol <xref target="RFC6962" format="default" sectionFormat="of" derivedContent="RFC6962"/>, drawing on
	insights gained from CT 1.0 deployments and on feedback from the community. The
	major changes are:</t>
        <ul spacing="normal" bare="false" empty="false" indent="3" pn="section-1.3-2">
          <li pn="section-1.3-2.1">Hash and signature algorithm agility: Permitted algorithms are now specified
	  in IANA registries.</li>
          <li pn="section-1.3-2.2">Precertificate format: Precertificates are now CMS objects rather than X.509
	  certificates, which avoids violating the certificate serial number uniqueness
	  requirement in <xref target="RFC5280" sectionFormat="of" section="4.1.2.2" format="default" derivedLink="https://rfc-editor.org/rfc/rfc5280#section-4.1.2.2" derivedContent="RFC5280"/>.</li>
          <li pn="section-1.3-2.3">Removal of precertificate signing certificates and the precertificate poison
	  extension: The change of precertificate format means that these are no longer
	  needed.</li>
          <li pn="section-1.3-2.4">Logs IDs: Each log is now identified by an OID rather than by the hash of its
	  public key. OID allocations are available from an IANA registry.</li>
          <li pn="section-1.3-2.5">
            <tt>TransItem</tt> structure: This new data structure is used to encapsulate
	  most types of CT data. A <tt>TransItemList</tt>, consisting of one or more
	  <tt>TransItem</tt> structures, can be used anywhere that
	  <tt>SignedCertificateTimestampList</tt> was
	  used in <xref target="RFC6962" format="default" sectionFormat="of" derivedContent="RFC6962"/>.</li>
          <li pn="section-1.3-2.6">Merkle Tree leaves: The <tt>MerkleTreeLeaf</tt> structure has been replaced by
	  the <tt>TransItem</tt> structure, which eases extensibility and simplifies the leaf
	  structure by removing one layer of abstraction.</li>
          <li pn="section-1.3-2.7">Unified leaf format: The structure for both certificate and precertificate
	  entries now includes only the TBSCertificate (whereas certificate entries in
	  <xref target="RFC6962" format="default" sectionFormat="of" derivedContent="RFC6962"/> included the entire certificate).</li>
          <li pn="section-1.3-2.8">Log artifact extensions: These are now typed and managed by an IANA registry,
	  and they can now appear not only in Signed Certificate Timestamps (SCTs) but also
	  in Signed Tree Heads (STHs).</li>
          <li pn="section-1.3-2.9">API outputs: Complete <tt>TransItem</tt> structures are returned rather than
	  the constituent parts of each structure.</li>
          <li pn="section-1.3-2.10">
            <tt>get-all-by-hash</tt>: This is a new client API for obtaining an inclusion proof and
	  the corresponding consistency proof at the same time.</li>
          <li pn="section-1.3-2.11">
            <tt>submit-entry</tt>: This is a new client API, replacing <tt>add-chain</tt> and
	  <tt>add-pre-chain</tt>.</li>
          <li pn="section-1.3-2.12">Presenting SCTs with proofs: TLS servers may present SCTs together with the
	  corresponding inclusion proofs, using any of the mechanisms that <xref target="RFC6962" format="default" sectionFormat="of" derivedContent="RFC6962"/>
	  defined for presenting SCTs only. (Presenting SCTs only is still supported).</li>
          <li pn="section-1.3-2.13">CT TLS extension: The <tt>signed_certificate_timestamp</tt> TLS extension has
	  been replaced by the <tt>transparency_info</tt> TLS extension.</li>
          <li pn="section-1.3-2.14">Verification algorithms: Detailed algorithms for verifying inclusion
	  proofs, for verifying consistency between two STHs, and for verifying a root
	  hash given a complete list of the relevant leaf input entries have been added.</li>
          <li pn="section-1.3-2.15">Extensive clarifications and editorial work.</li>
        </ul>
      </section>
    </section>
    <section anchor="cryptographic-components" numbered="true" toc="include" removeInRFC="false" pn="section-2">
      <name slugifiedName="name-cryptographic-components">Cryptographic Components</name>
      <section anchor="mht" numbered="true" toc="include" removeInRFC="false" pn="section-2.1">
        <name slugifiedName="name-merkle-trees">Merkle Trees</name>
        <t indent="0" pn="section-2.1-1">A full description of the Merkle Tree is beyond the scope of this
	document. Briefly, it is a binary tree where each non-leaf node is a
	hash of its children. For CT, the number of children is at most two.
	Additional information can be found in the Introduction and Reference
	sections of <xref target="RFC8391" format="default" sectionFormat="of" derivedContent="RFC8391"/>.</t>
        <section anchor="mht_definition" numbered="true" toc="include" removeInRFC="false" pn="section-2.1.1">
          <name slugifiedName="name-definition-of-the-merkle-tr">Definition of the Merkle Tree</name>
          <t indent="0" pn="section-2.1.1-1">The log uses a binary Merkle Tree for efficient auditing. The hash
	  algorithm used is one of the log's parameters (see <xref target="log_parameters" format="default" sectionFormat="of" derivedContent="Section 4.1"/>). This document establishes a registry of acceptable hash
	  algorithms (see <xref target="hash_algorithms" format="default" sectionFormat="of" derivedContent="Section 10.2.1"/>). Throughout this
	  document, the hash algorithm in use is referred to as HASH and the size of its
	  output in bytes is referred to as HASH_SIZE. The input
	  to the Merkle Tree Hash is a list of data entries; these entries will be
	  hashed to form the leaves of the Merkle Tree. The output is a single
	  HASH_SIZE Merkle Tree Hash. Given an ordered list of n inputs, D_n =
	  {d[0], d[1], ..., d[n-1]}, the Merkle Tree Hash (MTH) is thus defined as
	  follows:</t>
          <t indent="0" pn="section-2.1.1-2">The hash of an empty list is the hash of an empty string:</t>
          <artwork name="" type="" align="left" alt="" pn="section-2.1.1-3">
MTH({}) = HASH().
</artwork>
          <t indent="0" pn="section-2.1.1-4">The hash of a list with one entry (also known as a leaf hash) is:</t>
          <artwork name="" type="" align="left" alt="" pn="section-2.1.1-5">
MTH({d[0]}) = HASH(0x00 || d[0]).
</artwork>
          <t indent="0" pn="section-2.1.1-6">For n &gt; 1, let k be the largest power of two smaller than n
	  (i.e., k &lt; n &lt;= 2k).
	  The Merkle Tree Hash of an n-element list D_n is then defined recursively as:</t>
          <artwork name="" type="" align="left" alt="" pn="section-2.1.1-7">
MTH(D_n) = HASH(0x01 || MTH(D[0:k]) || MTH(D[k:n])),
</artwork>
          <t indent="0" pn="section-2.1.1-8">where:</t>
          <ul spacing="normal" bare="false" empty="false" indent="3" pn="section-2.1.1-9">
            <li pn="section-2.1.1-9.1">|| denotes concatenation</li>
            <li pn="section-2.1.1-9.2">: denotes concatenation of lists</li>
            <li pn="section-2.1.1-9.3">D[k1:k2] = D'_(k2-k1) denotes the list {d'[0] = d[k1], d'[1] = d[k1+1],
	    ..., d'[k2-k1-1] = d[k2-1]} of length (k2 - k1).</li>
          </ul>
          <t indent="0" pn="section-2.1.1-10">Note that the hash calculations for leaves and nodes differ; this domain
separation is required to give second preimage resistance.</t>
          <t indent="0" pn="section-2.1.1-11">Note that we do not require the length of the input list to be a power of two.
The resulting Merkle Tree may thus not be balanced; however, its shape is
uniquely determined by the number of leaves. (Note: This Merkle Tree is
essentially the same as the history tree proposed by <xref target="CrosbyWallach" format="default" sectionFormat="of" derivedContent="CrosbyWallach"/>, except our
definition handles non-full trees differently.)</t>
        </section>
        <section anchor="verify_hash" numbered="true" toc="include" removeInRFC="false" pn="section-2.1.2">
          <name slugifiedName="name-verifying-a-tree-head-given">Verifying a Tree Head Given Entries</name>
          <t indent="0" pn="section-2.1.2-1">When a client has a complete list of <tt>entries</tt> from <tt>0</tt> up to
<tt>tree_size - 1</tt> and wishes to verify this list against a tree head <tt>root_hash</tt>
returned by the log for the same <tt>tree_size</tt>, the following algorithm may be
used:</t>
          <ol spacing="normal" type="1" indent="adaptive" start="1" pn="section-2.1.2-2">
	    <li pn="section-2.1.2-2.1" derivedCounter="1.">Set <tt>stack</tt> to an empty stack.</li>
            <li pn="section-2.1.2-2.2" derivedCounter="2.">
              <t indent="0" pn="section-2.1.2-2.2.1">For each <tt>i</tt> from <tt>0</tt> up to <tt>tree_size - 1</tt>:</t>
              <ol spacing="normal" type="a" indent="adaptive" start="1" pn="section-2.1.2-2.2.2">
		<li pn="section-2.1.2-2.2.2.1" derivedCounter="a.">Push <tt>HASH(0x00 || entries[i])</tt> to <tt>stack</tt>.</li>
                <li pn="section-2.1.2-2.2.2.2" derivedCounter="b.">Set <tt>merge_count</tt> to the lowest value (<tt>0</tt> included)
		such that <tt>LSB(i &gt;&gt; merge_count)</tt> is not set, where
		<tt>LSB</tt> means the least significant
		bit. In other words, set <tt>merge_count</tt> to the number
		of consecutive <tt>1</tt>s found starting at the least significant bit of
		<tt>i</tt>.</li>
                <li pn="section-2.1.2-2.2.2.3" derivedCounter="c.">
                  <t indent="0" pn="section-2.1.2-2.2.2.3.1">Repeat <tt>merge_count</tt> times:</t>
                  <ol spacing="normal" type="i" indent="adaptive" start="1" pn="section-2.1.2-2.2.2.3.2">
		    <li pn="section-2.1.2-2.2.2.3.2.1" derivedCounter="i.">Pop <tt>right</tt> from <tt>stack</tt>.</li>
                    <li pn="section-2.1.2-2.2.2.3.2.2" derivedCounter="ii.">Pop <tt>left</tt> from <tt>stack</tt>.</li>
                    <li pn="section-2.1.2-2.2.2.3.2.3" derivedCounter="iii.">Push <tt>HASH(0x01 || left || right)</tt> to <tt>stack</tt>.</li>
                  </ol>
                </li>
              </ol>
            </li>
            <li pn="section-2.1.2-2.3" derivedCounter="3.">If there is more than one element in the <tt>stack</tt>, repeat the same merge
procedure (the sub-items of Step 2(c) above) until only a single element
remains.</li>
            <li pn="section-2.1.2-2.4" derivedCounter="4.">The remaining element in <tt>stack</tt> is the Merkle Tree Hash for the given
<tt>tree_size</tt> and should be compared by equality against the supplied
<tt>root_hash</tt>.</li>
          </ol>
        </section>
        <section anchor="merkle_inclusion_proof" numbered="true" toc="include" removeInRFC="false" pn="section-2.1.3">
          <name slugifiedName="name-merkle-inclusion-proofs">Merkle Inclusion Proofs</name>
          <t indent="0" pn="section-2.1.3-1">A Merkle inclusion proof for a leaf in a Merkle Tree is the shortest list
of additional nodes in the Merkle Tree required to compute the Merkle Tree Hash
for that tree. Each node in the tree is either a leaf node or is computed from
the two nodes immediately below it (i.e., towards the leaves). At each step up
the tree (towards the root), a node from the inclusion proof is combined with
the node computed so far. In other words, the inclusion proof consists of the
list of missing nodes required to compute the nodes leading from a leaf to the
root of the tree. If the root computed from the inclusion proof matches the true
root, then the inclusion proof proves that the leaf exists in the tree.</t>
          <section anchor="generating-an-inclusion-proof" numbered="true" toc="exclude" removeInRFC="false" pn="section-2.1.3.1">
            <name slugifiedName="name-generating-an-inclusion-pro">Generating an Inclusion Proof</name>
            <t indent="0" pn="section-2.1.3.1-1">Given an ordered list of n inputs to the tree, D_n = {d[0], d[1], ...,
d[n-1]}, the Merkle inclusion proof PATH(m, D_n) for the (m+1)th input d[m],
0 &lt;= m &lt; n, is defined as follows:</t>
            <t indent="0" pn="section-2.1.3.1-2">The proof for the single leaf in a tree with a one-element input list D[1] =
{d[0]} is empty:</t>
            <artwork name="" type="" align="left" alt="" pn="section-2.1.3.1-3">
PATH(0, {d[0]}) = {}
</artwork>
            <t indent="0" pn="section-2.1.3.1-4">For n &gt; 1, let k be the largest power of two smaller than n. The proof for the
(m+1)th element d[m] in a list of n &gt; m elements is then defined recursively as:</t>
            <artwork name="" type="" align="left" alt="" pn="section-2.1.3.1-5">
PATH(m, D_n) = PATH(m, D[0:k]) : MTH(D[k:n]) for m &lt; k; and

PATH(m, D_n) = PATH(m - k, D[k:n]) : MTH(D[0:k]) for m &gt;= k,
</artwork>
            <t indent="0" pn="section-2.1.3.1-6">The : operator and D[k1:k2] are defined the same as in <xref target="mht_definition" format="default" sectionFormat="of" derivedContent="Section 2.1.1"/>.</t>
          </section>
          <section anchor="verify_inclusion" numbered="true" toc="exclude" removeInRFC="false" pn="section-2.1.3.2">
            <name slugifiedName="name-verifying-an-inclusion-proo">Verifying an Inclusion Proof</name>
            <t indent="0" pn="section-2.1.3.2-1">When a client has received an inclusion proof (e.g., in a <tt>TransItem</tt> of type
<tt>inclusion_proof_v2</tt>) and wishes to verify inclusion of an input <tt>hash</tt> for a
given <tt>tree_size</tt> and <tt>root_hash</tt>, the following algorithm may be used to prove
the <tt>hash</tt> was included in the <tt>root_hash</tt>:</t>
            <ol spacing="normal" type="1" indent="adaptive" start="1" pn="section-2.1.3.2-2">
	      <li pn="section-2.1.3.2-2.1" derivedCounter="1.">Compare <tt>leaf_index</tt> from the <tt>inclusion_proof_v2</tt> structure
	      against <tt>tree_size</tt>. If <tt>leaf_index</tt> is greater than or
	      equal to <tt>tree_size</tt>, then fail the proof verification.</li>
              <li pn="section-2.1.3.2-2.2" derivedCounter="2.">Set <tt>fn</tt> to <tt>leaf_index</tt> and <tt>sn</tt> to <tt>tree_size -
	      1</tt>.</li>
              <li pn="section-2.1.3.2-2.3" derivedCounter="3.">Set <tt>r</tt> to <tt>hash</tt>.</li>
              <li pn="section-2.1.3.2-2.4" derivedCounter="4.">
                <t indent="0" pn="section-2.1.3.2-2.4.1">For each value <tt>p</tt> in the <tt>inclusion_path</tt> array:</t>
                <ol spacing="normal" type="a" indent="adaptive" start="1" pn="section-2.1.3.2-2.4.2">
                  <li pn="section-2.1.3.2-2.4.2.1" derivedCounter="a.">If <tt>sn</tt> is 0, then stop the iteration and fail the proof verification.</li>
                  <li pn="section-2.1.3.2-2.4.2.2" derivedCounter="b.">
                    <t indent="0" pn="section-2.1.3.2-2.4.2.2.1">If <tt>LSB(fn)</tt> is set, or if <tt>fn</tt> is equal to <tt>sn</tt>, then:</t>
                    <ol spacing="normal" type="i" indent="adaptive" start="1" pn="section-2.1.3.2-2.4.2.2.2">
                      <li pn="section-2.1.3.2-2.4.2.2.2.1" derivedCounter="i.">Set <tt>r</tt> to <tt>HASH(0x01 || p || r)</tt>.</li>
                      <li pn="section-2.1.3.2-2.4.2.2.2.2" derivedCounter="ii.">If <tt>LSB(fn)</tt> is not set, then right-shift both <tt>fn</tt> and
                        <tt>sn</tt> equally until either <tt>LSB(fn)</tt> is set or <tt>fn</tt> is <tt>0</tt>.</li>
                    </ol>
                    <t indent="0" pn="section-2.1.3.2-2.4.2.2.3">Otherwise:</t>
                    <ol spacing="normal" type="i" indent="adaptive" start="1" pn="section-2.1.3.2-2.4.2.2.4">
                      <li pn="section-2.1.3.2-2.4.2.2.4.1" derivedCounter="i.">Set <tt>r</tt> to <tt>HASH(0x01 || r || p)</tt>.</li>
                    </ol>
                  </li>
                  <li pn="section-2.1.3.2-2.4.2.3" derivedCounter="c.">Finally, right-shift both <tt>fn</tt> and <tt>sn</tt> one time.</li>
                </ol>
              </li>
              <li pn="section-2.1.3.2-2.5" derivedCounter="5.">Compare <tt>sn</tt> to 0. Compare <tt>r</tt> against the
	      <tt>root_hash</tt>. If <tt>sn</tt> is equal to
	      0 and <tt>r</tt> and the <tt>root_hash</tt> are equal, then the log has proven
	      the inclusion of <tt>hash</tt>. Otherwise, fail the proof verification.</li>
            </ol>
          </section>
        </section>
        <section anchor="consistency" numbered="true" toc="include" removeInRFC="false" pn="section-2.1.4">
          <name slugifiedName="name-merkle-consistency-proofs">Merkle Consistency Proofs</name>
          <t indent="0" pn="section-2.1.4-1">Merkle consistency proofs prove the append-only property of the tree. A Merkle
consistency proof for a Merkle Tree Hash MTH(D_n) and a previously advertised
hash MTH(D[0:m]) of the first m leaves, m &lt;= n, is the list of nodes in the
Merkle Tree required to verify that the first m inputs D[0:m] are equal in both
trees. Thus, a consistency proof must contain a set of intermediate nodes (i.e.,
commitments to inputs) sufficient to verify MTH(D_n), such that (a subset of)
the same nodes can be used to verify MTH(D[0:m]). We define an algorithm that
outputs the (unique) minimal consistency proof.</t>
          <section anchor="generating-a-consistency-proof" numbered="true" toc="exclude" removeInRFC="false" pn="section-2.1.4.1">
            <name slugifiedName="name-generating-a-consistency-pr">Generating a Consistency Proof</name>
            <t indent="0" pn="section-2.1.4.1-1">Given an ordered list of n inputs to the tree, D_n = {d[0], d[1], ...,
d[n-1]}, the Merkle consistency proof PROOF(m, D_n) for a previous Merkle Tree
Hash MTH(D[0:m]), 0 &lt; m &lt; n, is defined as:</t>
            <artwork name="" type="" align="left" alt="" pn="section-2.1.4.1-2">
PROOF(m, D_n) = SUBPROOF(m, D_n, true)
</artwork>
            <t indent="0" pn="section-2.1.4.1-3">In SUBPROOF, the boolean value represents whether the subtree created from
	    D[0:m] is a complete subtree of the Merkle Tree created from D_n and,
	    consequently, whether the subtree Merkle Tree Hash MTH(D[0:m]) is known. The
	    initial call to SUBPROOF sets this to be true, and SUBPROOF is then defined as
	    follows:</t>
            <t indent="0" pn="section-2.1.4.1-4">The subproof for m = n is empty if m is the value for which PROOF was
	    originally requested (meaning that the subtree created from D[0:m] is a complete
	    subtree of the Merkle Tree created from the original D_n for which PROOF was
	    requested and the subtree Merkle Tree Hash MTH(D[0:m]) is known):</t>
            <artwork name="" type="" align="left" alt="" pn="section-2.1.4.1-5">
SUBPROOF(m, D_m, true) = {}
</artwork>
            <t indent="0" pn="section-2.1.4.1-6">Otherwise, the subproof for m = n is the Merkle Tree Hash committing inputs
	    D[0:m]:</t>
            <artwork name="" type="" align="left" alt="" pn="section-2.1.4.1-7">
SUBPROOF(m, D_m, false) = {MTH(D_m)}
</artwork>
            <t indent="0" pn="section-2.1.4.1-8">For m &lt; n, let k be the largest power of two smaller than n. The subproof is
	    then defined recursively, using the appropriate step below:</t>
            <t indent="0" pn="section-2.1.4.1-9">If m &lt;= k, the right subtree entries D[k:n] only exist in the current tree.
	    We prove that the left subtree entries D[0:k] are consistent and add a
	    commitment to D[k:n]:</t>
            <artwork name="" type="" align="left" alt="" pn="section-2.1.4.1-10">
SUBPROOF(m, D_n, b) = SUBPROOF(m, D[0:k], b) : MTH(D[k:n])
</artwork>
            <t indent="0" pn="section-2.1.4.1-11">If m &gt; k, the left subtree entries D[0:k] are identical in both trees. We
	     prove that the right subtree entries D[k:n] are consistent and add a commitment
	     to D[0:k]:</t>
            <artwork name="" type="" align="left" alt="" pn="section-2.1.4.1-12">
SUBPROOF(m, D_n, b) = SUBPROOF(m - k, D[k:n], false) : MTH(D[0:k])
</artwork>
            <t indent="0" pn="section-2.1.4.1-13">The number of nodes in the resulting proof is bounded above by ceil(log2(n)) +
1.</t>
            <t indent="0" pn="section-2.1.4.1-14">The : operator and D[k1:k2] are defined the same as in <xref target="mht_definition" format="default" sectionFormat="of" derivedContent="Section 2.1.1"/>.</t>
          </section>
          <section anchor="verify_consistency" numbered="true" toc="exclude" removeInRFC="false" pn="section-2.1.4.2">
            <name slugifiedName="name-verifying-consistency-betwe">Verifying Consistency between Two Tree Heads</name>
            <t indent="0" pn="section-2.1.4.2-1">When a client has a tree head <tt>first_hash</tt> for tree size
	    <tt>first</tt>, has a tree head
	    <tt>second_hash</tt> for tree size <tt>second</tt> where <tt>0 &lt; first &lt;
	    second</tt>, and has received a consistency proof between the two (e.g., in a
	    <tt>TransItem</tt> of type
	    <tt>consistency_proof_v2</tt>), the following algorithm may be used to verify the
	    consistency proof:</t>
            <ol spacing="normal" type="1" indent="adaptive" start="1" pn="section-2.1.4.2-2">
	      <li pn="section-2.1.4.2-2.1" derivedCounter="1.">If <tt>consistency_path</tt> is an empty array, stop and fail the proof
	      verification.</li>
              <li pn="section-2.1.4.2-2.2" derivedCounter="2.">If <tt>first</tt> is an exact power of 2, then prepend <tt>first_hash</tt>
	      to the <tt>consistency_path</tt> array.</li>
              <li pn="section-2.1.4.2-2.3" derivedCounter="3.">Set <tt>fn</tt> to <tt>first - 1</tt> and <tt>sn</tt> to <tt>second -
	      1</tt>.</li>
              <li pn="section-2.1.4.2-2.4" derivedCounter="4.">If <tt>LSB(fn)</tt> is set, then right-shift both <tt>fn</tt> and
	      <tt>sn</tt> equally until <tt>LSB(fn)</tt> is not set.</li>
              <li pn="section-2.1.4.2-2.5" derivedCounter="5.">Set both <tt>fr</tt> and <tt>sr</tt> to the first value in the
	      <tt>consistency_path</tt> array.</li>
              <li pn="section-2.1.4.2-2.6" derivedCounter="6.">
                <t indent="0" pn="section-2.1.4.2-2.6.1">For each subsequent value <tt>c</tt> in the <tt>consistency_path</tt> array:</t>
                <ol spacing="normal" type="a" indent="adaptive" start="1" pn="section-2.1.4.2-2.6.2">
                  <li pn="section-2.1.4.2-2.6.2.1" derivedCounter="a.">If <tt>sn</tt> is 0, then stop the iteration and fail the proof verification.</li>
                  <li pn="section-2.1.4.2-2.6.2.2" derivedCounter="b.">
                    <t indent="0" pn="section-2.1.4.2-2.6.2.2.1">If <tt>LSB(fn)</tt> is set, or if <tt>fn</tt> is equal to <tt>sn</tt>, then:</t>
                    <ol spacing="normal" type="i" indent="adaptive" start="1" pn="section-2.1.4.2-2.6.2.2.2">
                      <li pn="section-2.1.4.2-2.6.2.2.2.1" derivedCounter="i.">Set <tt>fr</tt> to <tt>HASH(0x01 || c || fr)</tt>.</li>
                      <li pn="section-2.1.4.2-2.6.2.2.2.2" derivedCounter="ii.">Set <tt>sr</tt> to <tt>HASH(0x01 || c || sr)</tt>.</li>
                      <li pn="section-2.1.4.2-2.6.2.2.2.3" derivedCounter="iii.">If <tt>LSB(fn)</tt> is not set, then right-shift both <tt>fn</tt> and <tt>sn</tt>
                        equally until either <tt>LSB(fn)</tt> is set or <tt>fn</tt> is <tt>0</tt>.</li>
                    </ol>
                    <t indent="0" pn="section-2.1.4.2-2.6.2.2.3">Otherwise:</t>
                    <ol spacing="normal" type="i" indent="adaptive" start="1" pn="section-2.1.4.2-2.6.2.2.4">
                      <li pn="section-2.1.4.2-2.6.2.2.4.1" derivedCounter="i.">Set <tt>sr</tt> to <tt>HASH(0x01 || sr || c)</tt>.</li>
                    </ol>
                  </li>
                  <li pn="section-2.1.4.2-2.6.2.3" derivedCounter="c.">Finally, right-shift both <tt>fn</tt> and <tt>sn</tt> one time.</li>
                </ol>
              </li>
              <li pn="section-2.1.4.2-2.7" derivedCounter="7.">After completing iterating through the <tt>consistency_path</tt> array as
	      described above, verify that the <tt>fr</tt> calculated is equal to the
	      <tt>first_hash</tt> supplied, that the <tt>sr</tt> calculated is equal to the
	      <tt>second_hash</tt> supplied, and that <tt>sn</tt> is 0.</li>
            </ol>
          </section>
        </section>
        <section anchor="example" numbered="true" toc="include" removeInRFC="false" pn="section-2.1.5">
          <name slugifiedName="name-example">Example</name>
          <t indent="0" pn="section-2.1.5-1">The following is a binary Merkle Tree with 7 leaves:</t>
          <artwork name="" type="" align="left" alt="" pn="section-2.1.5-2">
            hash
           /    \
          /      \
         /        \
        /          \
       /            \
      k              l
     / \            / \
    /   \          /   \
   /     \        /     \
  g       h      i      j
 / \     / \    / \     |
 a b     c d    e f     d6
 | |     | |    | |
d0 d1   d2 d3  d4 d5
</artwork>
          <t indent="0" pn="section-2.1.5-3">The inclusion proof for <tt>d0</tt> is [<tt>b</tt>, <tt>h</tt>, <tt>l</tt>].</t>
          <t indent="0" pn="section-2.1.5-4">The inclusion proof for <tt>d3</tt> is [<tt>c</tt>, <tt>g</tt>, <tt>l</tt>].</t>
          <t indent="0" pn="section-2.1.5-5">The inclusion proof for <tt>d4</tt> is [<tt>f</tt>, <tt>j</tt>, <tt>k</tt>].</t>
          <t indent="0" pn="section-2.1.5-6">The inclusion proof for <tt>d6</tt> is [<tt>i</tt>, <tt>k</tt>].</t>
          <t indent="0" pn="section-2.1.5-7">The same tree, built incrementally in four steps:</t>
          <artwork name="" type="" align="left" alt="" pn="section-2.1.5-8">
    hash0          hash1=k
    / \              /  \
   /   \            /    \
  /     \          /      \
  g      c         g       h
 / \     |        / \     / \
 a b     d2       a b     c d
 | |              | |     | |
d0 d1            d0 d1   d2 d3

          hash2                    hash
          /  \                    /    \
         /    \                  /      \
        /      \                /        \
       /        \              /          \
      /          \            /            \
     k            i          k              l
    / \          / \        / \            / \
   /   \         e f       /   \          /   \
  /     \        | |      /     \        /     \
 g       h      d4 d5    g       h      i      j
/ \     / \             / \     / \    / \     |
a b     c d             a b     c d    e f     d6
| |     | |             | |     | |    | |
d0 d1   d2 d3           d0 d1   d2 d3  d4 d5
</artwork>
          <t indent="0" pn="section-2.1.5-9">The consistency proof between <tt>hash0</tt> and <tt>hash</tt> is PROOF(3, D[7]) = [<tt>c</tt>, <tt>d</tt>, <tt>g</tt>, <tt>l</tt>].
Non-leaf nodes <tt>c</tt>, <tt>g</tt> are used to verify <tt>hash0</tt>, and non-leaf nodes <tt>d</tt>, <tt>l</tt> are additionally used to show <tt>hash</tt> is
consistent with <tt>hash0</tt>.</t>
          <t indent="0" pn="section-2.1.5-10">The consistency proof between <tt>hash1</tt> and <tt>hash</tt> is PROOF(4, D[7]) = [<tt>l</tt>]. <tt>hash</tt> can
be verified using <tt>hash1</tt>=<tt>k</tt> and <tt>l</tt>.</t>
          <t indent="0" pn="section-2.1.5-11">The consistency proof between <tt>hash2</tt> and <tt>hash</tt> is PROOF(6, D[7]) = [<tt>i</tt>, <tt>j</tt>, <tt>k</tt>].
Non-leaf nodes <tt>k</tt>, <tt>i</tt> are used to verify <tt>hash2</tt>, and non-leaf node <tt>j</tt> is additionally used to show <tt>hash</tt> is
consistent with <tt>hash2</tt>.</t>
        </section>
      </section>
      <section anchor="signatures" numbered="true" toc="include" removeInRFC="false" pn="section-2.2">
        <name slugifiedName="name-signatures">Signatures</name>
        <t indent="0" pn="section-2.2-1">When signing data structures, a log <bcp14>MUST</bcp14> use one of
the signature algorithms from the IANA "Signature Algorithms" registry,
described in <xref target="signature_algorithms" format="default" sectionFormat="of" derivedContent="Section 10.2.2"/>.</t>
      </section>
    </section>
    <section anchor="submitters" numbered="true" toc="include" removeInRFC="false" pn="section-3">
      <name slugifiedName="name-submitters">Submitters</name>
      <t indent="0" pn="section-3-1">Submitters submit certificates or preannouncements of certificates prior to
issuance (precertificates) to logs for public auditing, as described below. In
order to enable attribution of each logged certificate or precertificate to its
issuer, each submission <bcp14>MUST</bcp14> be accompanied by all additional certificates
required to verify the chain up to an accepted trust anchor (<xref target="get-anchors" format="default" sectionFormat="of" derivedContent="Section 5.7"/>).
The trust anchor (a root or intermediate CA certificate) <bcp14>MAY</bcp14> be omitted from the
submission.</t>
      <t indent="0" pn="section-3-2">If a log accepts a submission, it will return a Signed Certificate Timestamp
(SCT) (see <xref target="sct" format="default" sectionFormat="of" derivedContent="Section 4.8"/>). The submitter <bcp14>SHOULD</bcp14> validate the returned SCT, as described
in <xref target="tls_clients" format="default" sectionFormat="of" derivedContent="Section 8.1"/>, if they understand its format and they intend to use it
directly in a TLS handshake or to construct a certificate. If the submitter does
not need the SCT (for example, the certificate is being submitted simply to make
it available in the log), it <bcp14>MAY</bcp14> validate the SCT.</t>
      <section anchor="certificates" numbered="true" toc="include" removeInRFC="false" pn="section-3.1">
        <name slugifiedName="name-certificates">Certificates</name>
        <t indent="0" pn="section-3.1-1">Any entity can submit a certificate (<xref target="submit-entry" format="default" sectionFormat="of" derivedContent="Section 5.1"/>) to a log. Since it is
anticipated that TLS clients will reject certificates that are not logged, it is
expected that certificate issuers and subjects will be strongly motivated to
submit them.</t>
      </section>
      <section anchor="precertificates" numbered="true" toc="include" removeInRFC="false" pn="section-3.2">
        <name slugifiedName="name-precertificates">Precertificates</name>
        <t indent="0" pn="section-3.2-1">CAs may preannounce a certificate prior to issuance by submitting a
precertificate (<xref target="submit-entry" format="default" sectionFormat="of" derivedContent="Section 5.1"/>) that the log can use to create an entry that
will be valid against the issued certificate. The CA <bcp14>MAY</bcp14> incorporate the
returned SCT in the issued certificate. One example of where the returned SCT is
not incorporated in the issued certificate is when a CA sends the precertificate
to multiple logs but only incorporates the SCTs that are returned first.</t>
        <t indent="0" pn="section-3.2-2">A precertificate is a CMS <xref target="RFC5652" format="default" sectionFormat="of" derivedContent="RFC5652"/> <tt>signed-data</tt> object that conforms to the
following profile:</t>
        <ul spacing="normal" bare="false" empty="false" indent="3" pn="section-3.2-3">
          <li pn="section-3.2-3.1">It <bcp14>MUST</bcp14> be DER encoded, as described in <xref target="X690" format="default" sectionFormat="of" derivedContent="X690"/>.</li>
          <li pn="section-3.2-3.2">
            <tt>SignedData.version</tt> <bcp14>MUST</bcp14> be v3(3).</li>
          <li pn="section-3.2-3.3">
            <tt>SignedData.digestAlgorithms</tt> <bcp14>MUST</bcp14> be the same as the
	  <tt>SignerInfo.digestAlgorithm</tt> OID value (see below).</li>
          <li pn="section-3.2-3.4">
            <t indent="0" pn="section-3.2-3.4.1"><tt>SignedData.encapContentInfo</tt>:</t>
            <ul spacing="normal" bare="false" empty="false" indent="3" pn="section-3.2-3.4.2">
              <li pn="section-3.2-3.4.2.1">
                <tt>eContentType</tt> <bcp14>MUST</bcp14> be the OID 1.3.101.78.</li>
              <li pn="section-3.2-3.4.2.2">
                <tt>eContent</tt> <bcp14>MUST</bcp14> contain a TBSCertificate <xref target="RFC5280" format="default" sectionFormat="of" derivedContent="RFC5280"/> that will be identical to
	      the TBSCertificate in the issued certificate, except that the Transparency
	      Information (<xref target="x509v3_transinfo_extension" format="default" sectionFormat="of" derivedContent="Section 7.1"/>)
	      extension <bcp14>MUST</bcp14> be omitted.</li>
            </ul>
          </li>
          <li pn="section-3.2-3.5">
            <tt>SignedData.certificates</tt> <bcp14>MUST</bcp14> be omitted.</li>
          <li pn="section-3.2-3.6">
            <tt>SignedData.crls</tt> <bcp14>MUST</bcp14> be omitted.</li>
          <li pn="section-3.2-3.7">
            <t indent="0" pn="section-3.2-3.7.1"><tt>SignedData.signerInfos</tt> <bcp14>MUST</bcp14> contain one
	  <tt>SignerInfo</tt>:</t>
            <ul spacing="normal" bare="false" empty="false" indent="3" pn="section-3.2-3.7.2">
              <li pn="section-3.2-3.7.2.1">
                <tt>version</tt> <bcp14>MUST</bcp14> be v3(3).</li>
              <li pn="section-3.2-3.7.2.2">
                <tt>sid</tt> <bcp14>MUST</bcp14> use the <tt>subjectKeyIdentifier</tt>
	      option.</li>
              <li pn="section-3.2-3.7.2.3">
                <tt>digestAlgorithm</tt> <bcp14>MUST</bcp14> be one of the hash algorithm
	      OIDs listed in the IANA "Hash Algorithms" registry, described in
	      <xref target="hash_algorithms" format="default" sectionFormat="of" derivedContent="Section 10.2.1"/>.</li>
              <li pn="section-3.2-3.7.2.4">
                <t indent="0" pn="section-3.2-3.7.2.4.1"><tt>signedAttrs</tt> <bcp14>MUST</bcp14> be present and
		<bcp14>MUST</bcp14> contain two attributes:</t>
                <ul spacing="normal" bare="false" empty="false" indent="3" pn="section-3.2-3.7.2.4.2">
                  <li pn="section-3.2-3.7.2.4.2.1">a content-type attribute whose value is the same as
		  <tt>SignedData.encapContentInfo.eContentType</tt> and</li>
                  <li pn="section-3.2-3.7.2.4.2.2">a message-digest attribute whose value is the message digest of
		  <tt>SignedData.encapContentInfo.eContent</tt>.</li>
                </ul>
              </li>
              <li pn="section-3.2-3.7.2.5">
                <tt>signatureAlgorithm</tt> <bcp14>MUST</bcp14> be the same OID as
	      <tt>TBSCertificate.signature</tt>.</li>
              <li pn="section-3.2-3.7.2.6">
                <tt>signature</tt> <bcp14>MUST</bcp14> be from the same (root or
	      intermediate) CA that intends to
	      issue the corresponding certificate (see <xref target="binding_intent_to_issue" format="default" sectionFormat="of" derivedContent="Section 3.2.1"/>).</li>
              <li pn="section-3.2-3.7.2.7">
                <tt>unsignedAttrs</tt> <bcp14>MUST</bcp14> be omitted.</li>
            </ul>
          </li>
        </ul>
        <t indent="0" pn="section-3.2-4"><tt>SignerInfo.signedAttrs</tt> is included in the message digest calculation process
(see <xref target="RFC5652" sectionFormat="of" section="5.4" format="default" derivedLink="https://rfc-editor.org/rfc/rfc5652#section-5.4" derivedContent="RFC5652"/>), which ensures that the <tt>SignerInfo.signature</tt>
value will not be a valid X.509v3 signature that could be used in conjunction
with the TBSCertificate (from <tt>SignedData.encapContentInfo.eContent</tt>) to
construct a valid certificate.</t>
        <section anchor="binding_intent_to_issue" numbered="true" toc="include" removeInRFC="false" pn="section-3.2.1">
          <name slugifiedName="name-binding-intent-to-issue">Binding Intent to Issue</name>
          <t indent="0" pn="section-3.2.1-1">Under normal circumstances, there will be a short delay between precertificate
submission and issuance of the corresponding certificate. Longer delays are to
be expected occasionally (e.g., due to log server downtime); in some cases,
the CA might not actually issue the corresponding certificate. Nevertheless, a
precertificate's <tt>signature</tt> indicates the CA's binding intent to issue the
corresponding certificate, which means that:</t>
          <ul spacing="normal" bare="false" empty="false" indent="3" pn="section-3.2.1-2">
            <li pn="section-3.2.1-2.1">Misissuance of a precertificate is considered equivalent to misissuance of
	    the corresponding certificate. The CA should expect to be held accountable,
	    even if the corresponding certificate has not actually been issued.</li>
            <li pn="section-3.2.1-2.2">Upon observing a precertificate, a client can reasonably presume that the
	    corresponding certificate has been issued. A client may wish to obtain status
	    information (e.g., by using the Online Certificate Status Protocol <xref target="RFC6960" format="default" sectionFormat="of" derivedContent="RFC6960"/>
	    or by checking a Certificate Revocation List <xref target="RFC5280" format="default" sectionFormat="of" derivedContent="RFC5280"/>) about a certificate
	    that is presumed to exist, especially if there is evidence or suspicion that
	    the corresponding precertificate was misissued.</li>
            <li pn="section-3.2.1-2.3">TLS clients may have policies that require CAs to be able to revoke and to
	    provide certificate status services for each certificate that is presumed to
	    exist based on the existence of a corresponding precertificate.</li>
          </ul>
        </section>
      </section>
    </section>
    <section anchor="log-format-and-operation" numbered="true" toc="include" removeInRFC="false" pn="section-4">
      <name slugifiedName="name-log-format-and-operation">Log Format and Operation</name>
      <t indent="0" pn="section-4-1">A log is a single, append-only Merkle Tree of submitted certificate and
precertificate entries.</t>
      <t indent="0" pn="section-4-2">When it receives and accepts a valid submission, the log <bcp14>MUST</bcp14> return an SCT that
corresponds to the submitted certificate or precertificate. If the log has
previously seen this valid submission, it <bcp14>SHOULD</bcp14> return the same SCT as it
returned before, as discussed in <xref target="misbehaving_logs" format="default" sectionFormat="of" derivedContent="Section 11.3"/>.
If different SCTs are produced for the same
submission, multiple log entries will have to be created, one for each SCT (as
the timestamp is a part of the leaf structure). Note that if a certificate was
previously logged as a precertificate, then the precertificate's SCT of type
<tt>precert_sct_v2</tt> would not be appropriate; instead, a fresh SCT of type
<tt>x509_sct_v2</tt> should be generated.</t>
      <t indent="0" pn="section-4-3">An SCT is the log's promise to append to its Merkle Tree an entry for the
      accepted submission. Upon producing an SCT, the log <bcp14>MUST</bcp14> fulfill this
      promise by performing the following actions within a fixed amount of time known as the
      Maximum Merge Delay (MMD), which is one of the log's parameters (see
      <xref target="log_parameters" format="default" sectionFormat="of" derivedContent="Section 4.1"/>):</t>
      <ul spacing="normal" bare="false" empty="false" indent="3" pn="section-4-4">
        <li pn="section-4-4.1">Allocate a tree index to the entry representing the accepted submission.</li>
        <li pn="section-4-4.2">Calculate the root of the tree.</li>
        <li pn="section-4-4.3">Sign the root of the tree (see <xref target="sth" format="default" sectionFormat="of" derivedContent="Section 4.10"/>).</li>
      </ul>
      <t indent="0" pn="section-4-5">The log may append multiple entries before signing the root of the tree.</t>
      <t indent="0" pn="section-4-6">Log operators <bcp14>SHOULD NOT</bcp14> impose any conditions on retrieving or sharing data
from the log.</t>
      <section anchor="log_parameters" numbered="true" toc="include" removeInRFC="false" pn="section-4.1">
        <name slugifiedName="name-log-parameters">Log Parameters</name>
        <t indent="0" pn="section-4.1-1">A log is defined by a collection of immutable parameters, which are used by
clients to communicate with the log and to verify log artifacts. Except for the
Final STH, each of these parameters <bcp14>MUST</bcp14> be established
before the log operator begins to operate the log.</t>
        <dl newline="false" spacing="normal" indent="3" pn="section-4.1-2">
          <dt pn="section-4.1-2.1">Base URL:</dt>
          <dd pn="section-4.1-2.2">The prefix used to construct URLs <xref target="RFC3986" format="default" sectionFormat="of" derivedContent="RFC3986"/>
	  for client messages (see <xref target="client_messages" format="default" sectionFormat="of" derivedContent="Section 5"/>). The
	  base URL <bcp14>MUST</bcp14> be an "https" URL, <bcp14>MAY</bcp14> contain a port,
	  and <bcp14>MAY</bcp14> contain a path with any number of path segments but
	  <bcp14>MUST NOT</bcp14> contain a query string, fragment, or trailing "/".
	  Example: https://ct.example.org/blue.</dd>
          <dt pn="section-4.1-2.3">Hash Algorithm:</dt>
          <dd pn="section-4.1-2.4">The hash algorithm used for the Merkle Tree (see <xref target="hash_algorithms" format="default" sectionFormat="of" derivedContent="Section 10.2.1"/>).</dd>
          <dt pn="section-4.1-2.5">Signature Algorithm:</dt>
          <dd pn="section-4.1-2.6">The signature algorithm used (see <xref target="signatures" format="default" sectionFormat="of" derivedContent="Section 2.2"/>).</dd>
          <dt pn="section-4.1-2.7">Public Key:</dt>
          <dd pn="section-4.1-2.8">The public key used to verify signatures generated by the log. A log
	  <bcp14>MUST NOT</bcp14> use the same keypair as any other log.</dd>
          <dt pn="section-4.1-2.9">Log ID:</dt>
          <dd pn="section-4.1-2.10">The OID that uniquely identifies the log.</dd>
          <dt pn="section-4.1-2.11">Maximum Merge Delay:</dt>
          <dd pn="section-4.1-2.12">The MMD the log has committed to. This document deliberately does not specify
	  any limits on the value to allow for experimentation.</dd>
          <dt pn="section-4.1-2.13">Version:</dt>
          <dd pn="section-4.1-2.14">The version of the protocol supported by the log (currently 1 or 2).</dd>
          <dt pn="section-4.1-2.15">Maximum Chain Length:</dt>
          <dd pn="section-4.1-2.16">The longest certificate chain submission the log is willing to accept, if the
	  log imposes any limit.</dd>
          <dt pn="section-4.1-2.17">STH Frequency Count:</dt>
          <dd pn="section-4.1-2.18">The maximum number of STHs the log may produce in any period equal to the
	  <tt>Maximum Merge Delay</tt> (see <xref target="sth" format="default" sectionFormat="of" derivedContent="Section 4.10"/>).</dd>
          <dt pn="section-4.1-2.19">Final STH:</dt>
          <dd pn="section-4.1-2.20">If a log has been closed down (i.e., no longer accepts new entries), existing
	  entries may still be valid. In this case, the client should know the final
	  valid STH in the log to ensure no new entries can be added without detection.
	  This value <bcp14>MUST</bcp14> be provided in the form of a <tt>TransItem</tt> of
	  type <tt>signed_tree_head_v2</tt>.
	  If a log is still accepting entries, this value should not be provided.</dd>
        </dl>
        <t indent="0" pn="section-4.1-3"><xref target="JSON.Metadata" format="default" sectionFormat="of" derivedContent="JSON.Metadata"/> is an example of a metadata format
	that includes the above	elements.</t>
      </section>
      <section anchor="evaluating-submissions" numbered="true" toc="include" removeInRFC="false" pn="section-4.2">
        <name slugifiedName="name-evaluating-submissions">Evaluating Submissions</name>
        <t indent="0" pn="section-4.2-1">A log determines whether to accept or reject a submission by evaluating it
against the minimum acceptance criteria (see <xref target="minimum_criteria" format="default" sectionFormat="of" derivedContent="Section 4.2.1"/>) and against
the log's discretionary acceptance criteria (see <xref target="discretionary_criteria" format="default" sectionFormat="of" derivedContent="Section 4.2.2"/>).</t>
        <t indent="0" pn="section-4.2-2">If the acceptance criteria are met, the log <bcp14>SHOULD</bcp14> accept the submission. (A log
may decide, for example, to temporarily reject acceptable submissions to protect
itself against denial-of-service attacks.)</t>
        <t indent="0" pn="section-4.2-3">The log <bcp14>SHALL</bcp14> allow retrieval of its list of accepted trust anchors (see
<xref target="get-anchors" format="default" sectionFormat="of" derivedContent="Section 5.7"/>), each of which is a root or intermediate CA certificate. This
list might usefully be the union of root certificates trusted by major browser
vendors.</t>
        <section anchor="minimum_criteria" numbered="true" toc="include" removeInRFC="false" pn="section-4.2.1">
          <name slugifiedName="name-minimum-acceptance-criteria">Minimum Acceptance Criteria</name>
          <t indent="0" pn="section-4.2.1-1">To ensure that logged certificates and precertificates are attributable to an
accepted trust anchor, to set clear expectations for what monitors would
find in the log, and to avoid being overloaded by invalid submissions, the log
<bcp14>MUST</bcp14> reject a submission if any of the following conditions are not met:</t>
          <ul spacing="normal" bare="false" empty="false" indent="3" pn="section-4.2.1-2">
            <li pn="section-4.2.1-2.1">The <tt>submission</tt>, <tt>type</tt>, and <tt>chain</tt> inputs
	    <bcp14>MUST</bcp14> be set as described in
	    <xref target="submit-entry" format="default" sectionFormat="of" derivedContent="Section 5.1"/>. The log <bcp14>MUST NOT</bcp14>
	    accommodate misordered CA certificates or
	    use any other source of intermediate CA certificates to attempt certification
	    path construction.</li>
            <li pn="section-4.2.1-2.2">
              <t indent="0" pn="section-4.2.1-2.2.1">Each of the zero or more intermediate CA certificates in the chain
	      <bcp14>MUST</bcp14> have one or both of the following features:</t>
              <ul spacing="normal" bare="false" empty="false" indent="3" pn="section-4.2.1-2.2.2">
                <li pn="section-4.2.1-2.2.2.1">The Basic Constraints extension with the cA boolean asserted.</li>
                <li pn="section-4.2.1-2.2.2.2">The Key Usage extension with the keyCertSign bit asserted.</li>
              </ul>
            </li>
            <li pn="section-4.2.1-2.3">Each certificate in the chain <bcp14>MUST</bcp14> fall within the limits
	    imposed by the zero
	    or more Basic Constraints pathLenConstraint values found higher up the chain.</li>
            <li pn="section-4.2.1-2.4">Precertificate submissions <bcp14>MUST</bcp14> conform to all of the
	    requirements in
	    <xref target="precertificates" format="default" sectionFormat="of" derivedContent="Section 3.2"/>.</li>
          </ul>
        </section>
        <section anchor="discretionary_criteria" numbered="true" toc="include" removeInRFC="false" pn="section-4.2.2">
          <name slugifiedName="name-discretionary-acceptance-cr">Discretionary Acceptance Criteria</name>
          <t indent="0" pn="section-4.2.2-1">If the minimum acceptance criteria are met but the submission is not fully
	  valid according to <xref target="RFC5280" format="default" sectionFormat="of" derivedContent="RFC5280"/> verification rules
	  (e.g., the certificate or
	  precertificate has expired, is not yet valid, has been revoked, exhibits ASN.1
	  DER encoding errors but the log can still parse it, etc.), then the acceptability
	  of the submission is left to the log's discretion. It is useful for logs to
	  accept such submissions in order to accommodate quirks of CA certificate-issuing
	  software and to facilitate monitoring of CA compliance with applicable policies
	  and technical standards. However, it is impractical for this document to
	  enumerate, and for logs to consider, all of the ways that a submission might
	  fail to comply with <xref target="RFC5280" format="default" sectionFormat="of" derivedContent="RFC5280"/>.</t>
          <t indent="0" pn="section-4.2.2-2">Logs <bcp14>SHOULD</bcp14> limit the length of chain they will accept. The
	  maximum chain length is one of the log's parameters (see <xref target="log_parameters" format="default" sectionFormat="of" derivedContent="Section 4.1"/>).</t>
        </section>
      </section>
      <section anchor="log_entries" numbered="true" toc="include" removeInRFC="false" pn="section-4.3">
        <name slugifiedName="name-log-entries">Log Entries</name>
        <t indent="0" pn="section-4.3-1">If a submission is accepted and an SCT is issued, the accepting log <bcp14>MUST</bcp14> store the
entire chain used for verification. This chain <bcp14>MUST</bcp14> include the certificate or
precertificate itself, the zero or more intermediate CA certificates provided by
the submitter, and the trust anchor used to verify the chain (even if it was
omitted from the submission). The log <bcp14>MUST</bcp14> provide this chain for auditing upon
request (see <xref target="get-entries" format="default" sectionFormat="of" derivedContent="Section 5.6"/>) so that the CA cannot avoid blame by
logging a partial or empty chain.
Each log entry is a <tt>TransItem</tt> structure of type <tt>x509_entry_v2</tt> or
<tt>precert_entry_v2</tt>. However, a log may store its entries in any format. If a
log does not store this <tt>TransItem</tt> in full, it must store the <tt>timestamp</tt>
and <tt>sct_extensions</tt> of the corresponding <tt>TimestampedCertificateEntryDataV2</tt>
structure. The <tt>TransItem</tt> can be reconstructed from these fields and the entire
chain that the log used to verify the submission.</t>
      </section>
      <section anchor="log_id" numbered="true" toc="include" removeInRFC="false" pn="section-4.4">
        <name slugifiedName="name-log-id">Log ID</name>
        <t indent="0" pn="section-4.4-1">Each log is identified by an OID, which is one of the log's parameters (see
<xref target="log_parameters" format="default" sectionFormat="of" derivedContent="Section 4.1"/>) and which <bcp14>MUST NOT</bcp14> be used to identify any other log. A
log's operator <bcp14>MUST</bcp14> either allocate the OID themselves or request an OID from
the Log ID registry (see <xref target="log_id_registry" format="default" sectionFormat="of" derivedContent="Section 10.2.5"/>).
One way to get an OID arc, from which OIDs can be allocated, is to request
a Private Enterprise Number from IANA by completing the
<eref target="https://pen.iana.org/pen/PenApplication.page" brackets="none">registration form</eref>.
The only advantage of the registry is that the DER encoding can be small.
(Recall that OID allocations do not require a central registration, although
logs will most likely want to make themselves known to potential clients
through out-of-band means.)
Various data structures include
the DER encoding of this OID, excluding the ASN.1 tag and length bytes, in an
opaque vector:</t>
        <sourcecode type="tls-presentation" markers="false" pn="section-4.4-2">
    opaque LogID&lt;2..127&gt;;
</sourcecode>
        <t indent="0" pn="section-4.4-3">Note that the ASN.1 length and the opaque vector length are identical in size (1
byte) and value, so the full DER encoding (including the tag and length)
of the OID can be reproduced simply by
prepending an OBJECT IDENTIFIER tag (0x06) to the opaque vector length and
contents.</t>
        <t indent="0" pn="section-4.4-4">The OID used to identify a log is limited such that the DER encoding of its
value, excluding the tag and length, <bcp14>MUST</bcp14> be no longer than 127 octets.</t>
      </section>
      <section anchor="transitem-structure" numbered="true" toc="include" removeInRFC="false" pn="section-4.5">
        <name slugifiedName="name-transitem-structure">TransItem Structure</name>
        <t indent="0" pn="section-4.5-1">Various data structures are encapsulated in the <tt>TransItem</tt> structure to ensure
that the type and version of each one is identified in a common fashion:</t>
        <sourcecode type="tls-presentation" markers="false" pn="section-4.5-2">
    enum {
        x509_entry_v2(0x0100), precert_entry_v2(0x0101),
        x509_sct_v2(0x0102), precert_sct_v2(0x0103),
        signed_tree_head_v2(0x0104), consistency_proof_v2(0x0105),
        inclusion_proof_v2(0x0106),

        /* Reserved Code Points */
        reserved_rfc6962(0x0000..0x00FF),
        reserved_experimentaluse(0xE000..0xEFFF),
        reserved_privateuse(0xF000..0xFFFF),
        (0xFFFF)
    } VersionedTransType;

    struct {
        VersionedTransType versioned_type;
        select (versioned_type) {
            case x509_entry_v2: TimestampedCertificateEntryDataV2;
            case precert_entry_v2: TimestampedCertificateEntryDataV2;
            case x509_sct_v2: SignedCertificateTimestampDataV2;
            case precert_sct_v2: SignedCertificateTimestampDataV2;
            case signed_tree_head_v2: SignedTreeHeadDataV2;
            case consistency_proof_v2: ConsistencyProofDataV2;
            case inclusion_proof_v2: InclusionProofDataV2;
        } data;
    } TransItem;
</sourcecode>
        <t indent="0" pn="section-4.5-3"><tt>versioned_type</tt> is a value from the IANA registry in <xref target="versioned_trans_types" format="default" sectionFormat="of" derivedContent="Section 10.2.3"/>
that identifies the type of the encapsulated data structure and the earliest
version of this protocol to which it conforms. This document is v2.</t>
        <t indent="0" pn="section-4.5-4"><tt>data</tt> is the encapsulated data structure. The various structures named with the
<tt>DataV2</tt> suffix are defined in later sections of this document.</t>
        <t indent="0" pn="section-4.5-5">Note that <tt>VersionedTransType</tt> combines the v1 type enumerations
<tt>Version</tt>, <tt>LogEntryType</tt>, <tt>SignatureType</tt>, and <tt>MerkleLeafType</tt> <xref target="RFC6962" format="default" sectionFormat="of" derivedContent="RFC6962"/>. Note also that
v1 did not define <tt>TransItem</tt>, but this document provides guidelines (see
<xref target="v1_coexistence" format="default" sectionFormat="of" derivedContent="Appendix A"/>) on how v2 implementations can coexist with v1
implementations.</t>
        <t indent="0" pn="section-4.5-6">Future versions of this protocol may reuse <tt>VersionedTransType</tt> values defined
in this document as long as the corresponding data structures are not modified
and may add new <tt>VersionedTransType</tt> values for new or modified data structures.</t>
      </section>
      <section anchor="log-artifact-extensions" numbered="true" toc="include" removeInRFC="false" pn="section-4.6">
        <name slugifiedName="name-log-artifact-extensions">Log Artifact Extensions</name>
        <sourcecode type="tls-presentation" markers="false" pn="section-4.6-1">
    enum {
        reserved(65535)
    } ExtensionType;

    struct {
        ExtensionType extension_type;
        opaque extension_data&lt;0..2^16-1&gt;;
    } Extension;
</sourcecode>
        <t indent="0" pn="section-4.6-2">The <tt>Extension</tt> structure provides a generic extensibility for log artifacts,
including SCTs (<xref target="sct" format="default" sectionFormat="of" derivedContent="Section 4.8"/>) and STHs
(<xref target="sth" format="default" sectionFormat="of" derivedContent="Section 4.10"/>). The interpretation of the <tt>extension_data</tt> field is determined solely
by the value of the <tt>extension_type</tt> field.</t>
        <t indent="0" pn="section-4.6-3">This document does not define any extensions, but it does establish a registry
for future <tt>ExtensionType</tt> values (see <xref target="log_artifact_extension_registry" format="default" sectionFormat="of" derivedContent="Section 10.2.4"/>).
Each document that registers a new <tt>ExtensionType</tt> must specify the context in
which it may be used (e.g., SCT, STH, or both) and describe how to interpret the
corresponding <tt>extension_data</tt>.</t>
      </section>
      <section anchor="tree_leaves" numbered="true" toc="include" removeInRFC="false" pn="section-4.7">
        <name slugifiedName="name-merkle-tree-leaves">Merkle Tree Leaves</name>
        <t indent="0" pn="section-4.7-1">The leaves of a log's Merkle Tree correspond to the log's entries (see
<xref target="log_entries" format="default" sectionFormat="of" derivedContent="Section 4.3"/>). Each leaf is the leaf hash (<xref target="mht" format="default" sectionFormat="of" derivedContent="Section 2.1"/>) of a <tt>TransItem</tt>
structure of type <tt>x509_entry_v2</tt> or <tt>precert_entry_v2</tt>, which encapsulates a
<tt>TimestampedCertificateEntryDataV2</tt> structure. Note that leaf hashes are
calculated as <tt>HASH(0x00 || TransItem)</tt>, where the hash algorithm is one of the
log's parameters.</t>
        <sourcecode type="tls-presentation" markers="false" pn="section-4.7-2">
    opaque TBSCertificate&lt;1..2^24-1&gt;;

    struct {
        uint64 timestamp;
        opaque issuer_key_hash&lt;32..2^8-1&gt;;
        TBSCertificate tbs_certificate;
        Extension sct_extensions&lt;0..2^16-1&gt;;
    } TimestampedCertificateEntryDataV2;
</sourcecode>
        <t indent="0" pn="section-4.7-3"><tt>timestamp</tt> is the date and time at which the certificate or precertificate
	was accepted by the log, in the form of a 64-bit unsigned number of milliseconds
	elapsed since the Unix Epoch (1 January 1970 00:00:00 UTC -- see <xref target="UNIXTIME" format="default" sectionFormat="of" derivedContent="UNIXTIME"/>),
	ignoring leap seconds, in network byte order. Note that the leaves of a log's
	Merkle Tree are not required to be in strict chronological order.</t>
        <t indent="0" pn="section-4.7-4"><tt>issuer_key_hash</tt> is the HASH of the public key of the CA that issued the
certificate or precertificate, calculated over the DER encoding of the key
represented as SubjectPublicKeyInfo <xref target="RFC5280" format="default" sectionFormat="of" derivedContent="RFC5280"/>. This is needed to bind the CA to
the certificate or precertificate, making it impossible for the corresponding
SCT to be valid for any other certificate or precertificate whose TBSCertificate
matches <tt>tbs_certificate</tt>. The length of the <tt>issuer_key_hash</tt> <bcp14>MUST</bcp14> match
HASH_SIZE.</t>
        <t indent="0" pn="section-4.7-5"><tt>tbs_certificate</tt> is the DER-encoded TBSCertificate from the submission.
	(Note that a precertificate's TBSCertificate can be reconstructed from the
	corresponding certificate, as described in <xref target="reconstructing_tbscertificate" format="default" sectionFormat="of" derivedContent="Section 8.1.2"/>).</t>
        <t indent="0" pn="section-4.7-6"><tt>sct_extensions</tt> is byte-for-byte identical to the SCT extensions of the
	corresponding SCT.</t>
        <t indent="0" pn="section-4.7-7">The type of the <tt>TransItem</tt> corresponds to the value of the <tt>type</tt> parameter
supplied in the <xref target="submit-entry" format="default" sectionFormat="of" derivedContent="Section 5.1"/> call.</t>
      </section>
      <section anchor="sct" numbered="true" toc="include" removeInRFC="false" pn="section-4.8">
        <name slugifiedName="name-signed-certificate-timestam">Signed Certificate Timestamp (SCT)</name>
        <t indent="0" pn="section-4.8-1">An SCT is a <tt>TransItem</tt> structure of type <tt>x509_sct_v2</tt> or <tt>precert_sct_v2</tt>,
which encapsulates a <tt>SignedCertificateTimestampDataV2</tt> structure:</t>
        <sourcecode type="tls-presentation" markers="false" pn="section-4.8-2">
    struct {
        LogID log_id;
        uint64 timestamp;
        Extension sct_extensions&lt;0..2^16-1&gt;;
        opaque signature&lt;1..2^16-1&gt;;
    } SignedCertificateTimestampDataV2;
</sourcecode>
        <t indent="0" pn="section-4.8-3"><tt>log_id</tt> is this log's unique ID, encoded in an opaque vector, as described
	in <xref target="log_id" format="default" sectionFormat="of" derivedContent="Section 4.4"/>.</t>
        <t indent="0" pn="section-4.8-4"><tt>timestamp</tt> is equal to the timestamp from the corresponding
	<tt>TimestampedCertificateEntryDataV2</tt> structure.</t>
        <t indent="0" pn="section-4.8-5"><tt>sct_extensions</tt> is a vector of 0 or more SCT extensions. This vector
	<bcp14>MUST NOT</bcp14> include more than one extension with the same
	<tt>extension_type</tt>. The
	extensions in the vector <bcp14>MUST</bcp14> be ordered by the value of the
	<tt>extension_type</tt> field, smallest value first.
	All SCT extensions are similar to noncritical X.509v3 extensions (i.e.,
	the <tt>mustUnderstand</tt> field is not set), and a recipient <bcp14>SHOULD</bcp14>
	ignore any extension it does not understand.
	Furthermore, an implementation <bcp14>MAY</bcp14> choose to ignore any extension(s)
	that it does understand.</t>
        <t indent="0" pn="section-4.8-6"><tt>signature</tt> is computed over a <tt>TransItem</tt> structure of type
	<tt>x509_entry_v2</tt> or <tt>precert_entry_v2</tt> (see <xref target="tree_leaves" format="default" sectionFormat="of" derivedContent="Section 4.7"/>) using the signature algorithm
	declared in the log's parameters (see <xref target="log_parameters" format="default" sectionFormat="of" derivedContent="Section 4.1"/>).</t>
      </section>
      <section anchor="tree_head" numbered="true" toc="include" removeInRFC="false" pn="section-4.9">
        <name slugifiedName="name-merkle-tree-head">Merkle Tree Head</name>
        <t indent="0" pn="section-4.9-1">The log stores information about its Merkle Tree in a <tt>TreeHeadDataV2</tt>:</t>
        <sourcecode type="tls-presentation" markers="false" pn="section-4.9-2">
    opaque NodeHash&lt;32..2^8-1&gt;;

    struct {
        uint64 timestamp;
        uint64 tree_size;
        NodeHash root_hash;
        Extension sth_extensions&lt;0..2^16-1&gt;;
    } TreeHeadDataV2;
</sourcecode>
        <t indent="0" pn="section-4.9-3">The length of NodeHash <bcp14>MUST</bcp14> match HASH_SIZE of the log.</t>
        <t indent="0" pn="section-4.9-4"><tt>timestamp</tt> is the current date and time, using the format defined in
<xref target="tree_leaves" format="default" sectionFormat="of" derivedContent="Section 4.7"/>.</t>
        <t indent="0" pn="section-4.9-5"><tt>tree_size</tt> is the number of entries currently in the log's Merkle Tree.</t>
        <t indent="0" pn="section-4.9-6"><tt>root_hash</tt> is the root of the Merkle Tree.</t>
        <t indent="0" pn="section-4.9-7"><tt>sth_extensions</tt> is a vector of 0 or more STH extensions. This vector <bcp14>MUST NOT</bcp14>
include more than one extension with the same <tt>extension_type</tt>. The
extensions in the vector <bcp14>MUST</bcp14> be ordered by the value of the
<tt>extension_type</tt> field, smallest value first. If an implementation sees an
extension that it does not understand, it <bcp14>SHOULD</bcp14> ignore that extension.
Furthermore, an implementation <bcp14>MAY</bcp14> choose to ignore any extension(s) that it
does understand.</t>
      </section>
      <section anchor="sth" numbered="true" toc="include" removeInRFC="false" pn="section-4.10">
        <name slugifiedName="name-signed-tree-head-sth">Signed Tree Head (STH)</name>
        <t indent="0" pn="section-4.10-1">Periodically, each log <bcp14>SHOULD</bcp14> sign its current tree head
	information (see <xref target="tree_head" format="default" sectionFormat="of" derivedContent="Section 4.9"/>) to produce an STH. When
	a client requests a log's latest STH (see
	<xref target="get-sth" format="default" sectionFormat="of" derivedContent="Section 5.2"/>), the log <bcp14>MUST</bcp14> return an STH
	that is no older than the log's MMD.
	However, since STHs could be used to mark individual clients (by producing a new
	STH for each query), a log <bcp14>MUST NOT</bcp14> produce STHs more frequently than
	its parameters declare (see <xref target="log_parameters" format="default" sectionFormat="of" derivedContent="Section 4.1"/>). In
	general, there is no need to
	produce a new STH unless there are new entries in the log; however, in the event
	that a log does not accept any submissions during an MMD period, the log
	<bcp14>MUST</bcp14> sign the same Merkle Tree Hash with a fresh timestamp.</t>
        <t indent="0" pn="section-4.10-2">An STH is a <tt>TransItem</tt> structure of type <tt>signed_tree_head_v2</tt>,
	which encapsulates a <tt>SignedTreeHeadDataV2</tt> structure:</t>
        <sourcecode type="tls-presentation" markers="false" pn="section-4.10-3">
    struct {
        LogID log_id;
        TreeHeadDataV2 tree_head;
        opaque signature&lt;1..2^16-1&gt;;
    } SignedTreeHeadDataV2;
</sourcecode>
        <t indent="0" pn="section-4.10-4"><tt>log_id</tt> is this log's unique ID encoded in an opaque vector, as described
	in <xref target="log_id" format="default" sectionFormat="of" derivedContent="Section 4.4"/>.</t>
        <t indent="0" pn="section-4.10-5">The <tt>timestamp</tt> in <tt>tree_head</tt> <bcp14>MUST</bcp14> be at least as
	recent as the most recent SCT
	timestamp in the tree. Each subsequent timestamp <bcp14>MUST</bcp14> be more recent
	than the timestamp of the previous update.</t>
        <t indent="0" pn="section-4.10-6"><tt>tree_head</tt> contains the latest tree head information (see <xref target="tree_head" format="default" sectionFormat="of" derivedContent="Section 4.9"/>).</t>
        <t indent="0" pn="section-4.10-7"><tt>signature</tt> is computed over the <tt>tree_head</tt> field using the signature algorithm
declared in the log's parameters (see <xref target="log_parameters" format="default" sectionFormat="of" derivedContent="Section 4.1"/>).</t>
      </section>
      <section anchor="merkle-consistency-proofs" numbered="true" toc="include" removeInRFC="false" pn="section-4.11">
        <name slugifiedName="name-merkle-consistency-proofs-2">Merkle Consistency Proofs</name>
        <t indent="0" pn="section-4.11-1">To prepare a Merkle consistency proof for distribution to clients, the log
produces a <tt>TransItem</tt> structure of type <tt>consistency_proof_v2</tt>, which
encapsulates a <tt>ConsistencyProofDataV2</tt> structure:</t>
        <sourcecode type="tls-presentation" markers="false" pn="section-4.11-2">
    struct {
        LogID log_id;
        uint64 tree_size_1;
        uint64 tree_size_2;
        NodeHash consistency_path&lt;0..2^16-1&gt;;
    } ConsistencyProofDataV2;
</sourcecode>
        <t indent="0" pn="section-4.11-3"><tt>log_id</tt> is this log's unique ID encoded in an opaque vector, as described
	in <xref target="log_id" format="default" sectionFormat="of" derivedContent="Section 4.4"/>.</t>
        <t indent="0" pn="section-4.11-4"><tt>tree_size_1</tt> is the size of the older tree.</t>
        <t indent="0" pn="section-4.11-5"><tt>tree_size_2</tt> is the size of the newer tree.</t>
        <t indent="0" pn="section-4.11-6"><tt>consistency_path</tt> is a vector of Merkle Tree nodes proving the consistency
	of two STHs, as described in <xref target="consistency" format="default" sectionFormat="of" derivedContent="Section 2.1.4"/>.</t>
      </section>
      <section anchor="merkle-inclusion-proofs" numbered="true" toc="include" removeInRFC="false" pn="section-4.12">
        <name slugifiedName="name-merkle-inclusion-proofs-2">Merkle Inclusion Proofs</name>
        <t indent="0" pn="section-4.12-1">To prepare a Merkle inclusion proof for distribution to clients, the log
produces a <tt>TransItem</tt> structure of type <tt>inclusion_proof_v2</tt>, which
encapsulates an <tt>InclusionProofDataV2</tt> structure:</t>
        <sourcecode type="tls-presentation" markers="false" pn="section-4.12-2">
    struct {
        LogID log_id;
        uint64 tree_size;
        uint64 leaf_index;
        NodeHash inclusion_path&lt;0..2^16-1&gt;;
    } InclusionProofDataV2;
</sourcecode>
        <t indent="0" pn="section-4.12-3"><tt>log_id</tt> is this log's unique ID encoded in an opaque vector, as described
	in <xref target="log_id" format="default" sectionFormat="of" derivedContent="Section 4.4"/>.</t>
        <t indent="0" pn="section-4.12-4"><tt>tree_size</tt> is the size of the tree on which this inclusion proof is
	based.</t>
        <t indent="0" pn="section-4.12-5"><tt>leaf_index</tt> is the 0-based index of the log entry corresponding to this
inclusion proof.</t>
        <t indent="0" pn="section-4.12-6"><tt>inclusion_path</tt> is a vector of Merkle Tree nodes proving the inclusion of the
chosen certificate or precertificate, as described in <xref target="merkle_inclusion_proof" format="default" sectionFormat="of" derivedContent="Section 2.1.3"/>.</t>
      </section>
      <section anchor="log_shutdown" numbered="true" toc="include" removeInRFC="false" pn="section-4.13">
        <name slugifiedName="name-shutting-down-a-log">Shutting Down a Log</name>
        <t indent="0" pn="section-4.13-1">Log operators may decide to shut down a log for various reasons, such as
deprecation of the signature algorithm. If there are entries in the log for
certificates that have not yet expired, simply making TLS clients stop
recognizing that log will have the effect of invalidating SCTs from that log.
In order to avoid that, the following actions <bcp14>SHOULD</bcp14> be taken:</t>
        <ul spacing="normal" bare="false" empty="false" indent="3" pn="section-4.13-2">
          <li pn="section-4.13-2.1">Make it known to clients and monitors that the log will be frozen.
	  This is not part of the API, so it will have to be done via a relevant
	  out-of-band mechanism.</li>
          <li pn="section-4.13-2.2">Stop accepting new submissions (the error code "shutdown" should be returned
	  for such requests).</li>
          <li pn="section-4.13-2.3">Once MMD from the last accepted submission has passed and all pending
	  submissions are incorporated, issue a final STH and publish it as one of the
	  log's parameters. Having an STH with a timestamp that is after the MMD has
	  passed from the last SCT issuance allows clients to audit this log regularly
	  without special handling for the final STH. At this point, the log's private
	  key is no longer needed and can be destroyed.</li>
          <li pn="section-4.13-2.4">Keep the log running until the certificates in all of its entries have expired
	  or exist in other logs (this can be determined by scanning other logs or
	  connecting to domains mentioned in the certificates and inspecting the SCTs
	  served).</li>
        </ul>
      </section>
    </section>
    <section anchor="client_messages" numbered="true" toc="include" removeInRFC="false" pn="section-5">
      <name slugifiedName="name-log-client-messages">Log Client Messages</name>
      <t indent="0" pn="section-5-1">Messages are sent as HTTPS GET or POST requests. Parameters for POSTs and all
responses are encoded as JavaScript Object Notation (JSON) objects <xref target="RFC8259" format="default" sectionFormat="of" derivedContent="RFC8259"/>.
Parameters for GETs are encoded as order-independent key/value URL parameters,
using the "application/x-www-form-urlencoded" format described in the "HTML 4.01
Specification" <xref target="HTML401" format="default" sectionFormat="of" derivedContent="HTML401"/>. Binary data is base64 encoded according to
<xref target="RFC4648" sectionFormat="of" section="4" format="default" derivedLink="https://rfc-editor.org/rfc/rfc4648#section-4" derivedContent="RFC4648"/>, as specified
in the individual messages.</t>
      <t indent="0" pn="section-5-2">Clients are configured with a log's base URL, which is one of the log's
parameters. Clients construct URLs for requests by appending suffixes to this
base URL. This structure places some degree of restriction on how log operators
can deploy these services, as noted in <xref target="RFC8820" format="default" sectionFormat="of" derivedContent="RFC8820"/>. However, operational
experience with version 1 of this protocol has not indicated that these
restrictions are a problem in practice.</t>
      <t indent="0" pn="section-5-3">Note that JSON objects and URL parameters may contain fields not specified here
to allow for experimentation. Any fields that are not understood <bcp14>SHOULD</bcp14>
be ignored.</t>
      <t indent="0" pn="section-5-4">In practice, log servers may include multiple front-end machines. Since it is
impractical to keep these machines in perfect sync, errors that are 
caused by skew between the machines may occur. Where such errors are possible, the
front end will return additional information (as specified below), making it
possible for clients to make progress, if progress is possible. Front ends <bcp14>MUST</bcp14>
only serve data that is free of gaps (that is, for example, no front end will
respond with an STH unless it is also able to prove consistency from all log
entries logged within that STH).</t>
      <t indent="0" pn="section-5-5">For example, when a consistency proof between two STHs is requested, the
front end reached may not yet be aware of one or both STHs. In the case where it
is unaware of both, it will return the latest STH it is aware of. Where it is
aware of the first but not the second, it will return the latest STH it is aware
of and a consistency proof from the first STH to the returned STH. The case
where it knows the second but not the first should not arise (see the "no gaps"
requirement above).</t>
      <t indent="0" pn="section-5-6">If the log is unable to process a client's request, it <bcp14>MUST</bcp14> return an HTTP
response code of 4xx/5xx (see <xref target="RFC7231" format="default" sectionFormat="of" derivedContent="RFC7231"/>), and, in place of the responses
outlined in the subsections below, the body <bcp14>SHOULD</bcp14> be a JSON problem details
object (see <xref target="RFC7807" sectionFormat="of" section="3" format="default" derivedLink="https://rfc-editor.org/rfc/rfc7807#section-3" derivedContent="RFC7807"/>) containing:</t>
      <dl newline="false" spacing="normal" indent="3" pn="section-5-7">
        <dt pn="section-5-7.1">type:</dt>
        <dd pn="section-5-7.2">A URN reference identifying the problem. To facilitate automated response
	to errors, this document defines a set of standard tokens for use in the
	<tt>type</tt> field within the URN namespace of: "urn:ietf:params:trans:error:".</dd>
        <dt pn="section-5-7.3">detail:</dt>
        <dd pn="section-5-7.4">A human-readable string describing the error that prevented the log from
	processing the request, ideally with sufficient detail to enable the error to
	be rectified.</dd>
      </dl>
      <t indent="0" pn="section-5-8">For example, in response to a request of
<tt>&lt;Base URL&gt;/ct/v2/get-entries?start=100&amp;end=99</tt>, the log would return a
<tt>400 Bad Request</tt> response code with a body similar to the following:</t>
      <sourcecode type="json" markers="false" pn="section-5-9">
    {
        "type": "urn:ietf:params:trans:error:endBeforeStart",
        "detail": "'start' cannot be greater than 'end'"
    }
</sourcecode>
      <t indent="0" pn="section-5-10">Most error types are specific to the type of request and are defined in the
respective subsections below. The one exception is the "malformed" error type,
which indicates that the log server could not parse the client's request because
it did not comply with this document:</t>
      <table align="center" pn="table-1">
        <thead>
          <tr>
            <th align="left" colspan="1" rowspan="1">type</th>
            <th align="left" colspan="1" rowspan="1">detail</th>
          </tr>
        </thead>
        <tbody>
          <tr>
            <td align="left" colspan="1" rowspan="1">malformed</td>
            <td align="left" colspan="1" rowspan="1">The request could not be parsed.</td>
          </tr>
        </tbody>
      </table>
      <t indent="0" pn="section-5-12">Clients <bcp14>SHOULD</bcp14> treat <tt>500 Internal Server Error</tt> and <tt>503
      Service Unavailable</tt>
      responses as transient failures and <bcp14>MAY</bcp14> retry the same request without
      modification at a later date. Note that in the case of a 503 response, the log 
      <bcp14>MAY</bcp14> include a <tt>Retry-After</tt> header field per <xref target="RFC7231" format="default" sectionFormat="of" derivedContent="RFC7231"/> in
      order to request a minimum time for the client to wait before retrying the request.
      In the absence of this header field, this document does not specify a minimum.</t>
      <t indent="0" pn="section-5-13">Clients <bcp14>SHOULD</bcp14> treat any 4xx error as a problem with the request and
      not attempt to resubmit without some modification to the request. The full
      status code <bcp14>MAY</bcp14> provide additional details.</t>
      <t indent="0" pn="section-5-14">This document deliberately does not provide more specific guidance
      on the use of HTTP status codes.</t>
      <section anchor="submit-entry" numbered="true" toc="include" removeInRFC="false" pn="section-5.1">
        <name slugifiedName="name-submit-entry-to-log">Submit Entry to Log</name>
        <t indent="0" pn="section-5.1-1">POST &lt;Base URL&gt;/ct/v2/submit-entry</t>
        <dl newline="true" spacing="normal" indent="3" pn="section-5.1-2">
          <dt pn="section-5.1-2.1">Inputs:</dt>
          <dd pn="section-5.1-2.2">
            <dl newline="false" spacing="normal" indent="3" pn="section-5.1-2.2.1">
              <dt pn="section-5.1-2.2.1.1">submission:</dt>
              <dd pn="section-5.1-2.2.1.2">The base64-encoded certificate or precertificate.</dd>
              <dt pn="section-5.1-2.2.1.3">type:</dt>
              <dd pn="section-5.1-2.2.1.4">The <tt>VersionedTransType</tt> integer value that indicates the type of the
	      <tt>submission</tt>: 1 for <tt>x509_entry_v2</tt> or 2 for
	      <tt>precert_entry_v2</tt>.</dd>
              <dt pn="section-5.1-2.2.1.5">chain:</dt>
              <dd pn="section-5.1-2.2.1.6">An array of zero or more JSON strings,
	      each of which is a base64-encoded CA certificate. The first element
	      is the certifier of the <tt>submission</tt>, the second certifies the first,
	      etc. The last element of <tt>chain</tt> (or, if <tt>chain</tt> is an empty
	      array, the <tt>submission</tt>) is certified by an accepted trust anchor.</dd>
            </dl>
          </dd>
          <dt pn="section-5.1-2.3">Outputs:</dt>
          <dd pn="section-5.1-2.4">
            <dl newline="false" spacing="normal" indent="3" pn="section-5.1-2.4.1">
              <dt pn="section-5.1-2.4.1.1">sct:</dt>
              <dd pn="section-5.1-2.4.1.2">
                <t indent="0" pn="section-5.1-2.4.1.2.1">A base64-encoded <tt>TransItem</tt> of type <tt>x509_sct_v2</tt> or
	      <tt>precert_sct_v2</tt>, signed by this log, that corresponds to the
	      <tt>submission</tt>.</t>
              </dd>
            </dl>
            <t indent="0" pn="section-5.1-2.4.2">If the submitted entry is immediately appended to (or already exists in) this
	      log's tree, then the log <bcp14>SHOULD</bcp14> also output:</t>
            <dl newline="false" spacing="normal" indent="3" pn="section-5.1-2.4.3">
              <dt pn="section-5.1-2.4.3.1">sth:</dt>
              <dd pn="section-5.1-2.4.3.2">A base64-encoded <tt>TransItem</tt> of type <tt>signed_tree_head_v2</tt>
	      signed by this log.</dd>
              <dt pn="section-5.1-2.4.3.3">inclusion:</dt>
              <dd pn="section-5.1-2.4.3.4">A base64-encoded <tt>TransItem</tt> of type <tt>inclusion_proof_v2</tt>
	      whose <tt>inclusion_path</tt> array of Merkle Tree nodes proves the inclusion
	      of the <tt>submission</tt> in the returned <tt>sth</tt>.</dd>
            </dl>
          </dd>
        </dl>
        <t indent="0" pn="section-5.1-3">Error codes:</t>
        <table align="center" pn="table-2">
          <thead>
            <tr>
              <th align="left" colspan="1" rowspan="1">type</th>
              <th align="left" colspan="1" rowspan="1">detail</th>
            </tr>
          </thead>
          <tbody>
            <tr>
              <td align="left" colspan="1" rowspan="1">badSubmission</td>
              <td align="left" colspan="1" rowspan="1">
                <tt>submission</tt> is neither a valid certificate nor a valid precertificate.</td>
            </tr>
            <tr>
              <td align="left" colspan="1" rowspan="1">badType</td>
              <td align="left" colspan="1" rowspan="1">
                <tt>type</tt> is neither 1 nor 2.</td>
            </tr>
            <tr>
              <td align="left" colspan="1" rowspan="1">badChain</td>
              <td align="left" colspan="1" rowspan="1">The first element of <tt>chain</tt> is not the certifier of the <tt>submission</tt>, or the second element does not certify the first, etc.</td>
            </tr>
            <tr>
              <td align="left" colspan="1" rowspan="1">badCertificate</td>
              <td align="left" colspan="1" rowspan="1">One or more certificates in <tt>chain</tt> are not valid (e.g., not properly encoded).</td>
            </tr>
            <tr>
              <td align="left" colspan="1" rowspan="1">unknownAnchor</td>
              <td align="left" colspan="1" rowspan="1">The last element of <tt>chain</tt> (or, if <tt>chain</tt> is an empty array, the <tt>submission</tt>) is not, nor is it certified by, an accepted trust anchor.</td>
            </tr>
            <tr>
              <td align="left" colspan="1" rowspan="1">shutdown</td>
              <td align="left" colspan="1" rowspan="1">The log is no longer accepting submissions.</td>
            </tr>
          </tbody>
        </table>
        <t indent="0" pn="section-5.1-5">If the version of <tt>sct</tt> is not v2, then a v2 client may be unable to verify the
signature. It <bcp14>MUST NOT</bcp14> construe this as an error. This is to avoid forcing an
upgrade of compliant v2 clients that do not use the returned SCTs.</t>
        <t indent="0" pn="section-5.1-6">If a log detects bad encoding in a chain that otherwise verifies correctly, then
the log <bcp14>MUST</bcp14> either log the certificate or return the "badCertificate" error.
If the certificate is logged, an SCT <bcp14>MUST</bcp14> be issued. Logging the certificate is
useful, because monitors (<xref target="monitor" format="default" sectionFormat="of" derivedContent="Section 8.2"/>) can then detect these encoding errors,
which may be accepted by some TLS clients.</t>
        <t indent="0" pn="section-5.1-7">If <tt>submission</tt> is an accepted trust anchor whose certifier is neither an
accepted trust anchor nor the first element of <tt>chain</tt>, then the log <bcp14>MUST</bcp14> return
the "unknownAnchor" error. A log is not able to generate an SCT for a
submission if it
does not have access to the issuer's public key.</t>
        <t indent="0" pn="section-5.1-8">If the returned <tt>sct</tt> is intended to be provided to TLS clients, then <tt>sth</tt> and
<tt>inclusion</tt> (if returned) <bcp14>SHOULD</bcp14> also be provided to TLS clients. For
example, if
<tt>type</tt> was 2 (indicating <tt>precert_sct_v2</tt>), then all three <tt>TransItem</tt>s could be
embedded in the certificate.</t>
      </section>
      <section anchor="get-sth" numbered="true" toc="include" removeInRFC="false" pn="section-5.2">
        <name slugifiedName="name-retrieve-latest-sth">Retrieve Latest STH</name>
        <t indent="0" pn="section-5.2-1">GET &lt;Base URL&gt;/ct/v2/get-sth</t>
        <t indent="0" pn="section-5.2-2">No inputs.</t>
        <dl newline="true" spacing="normal" indent="3" pn="section-5.2-3">
          <dt pn="section-5.2-3.1">Outputs:</dt>
          <dd pn="section-5.2-3.2">
            <dl newline="false" spacing="normal" indent="3" pn="section-5.2-3.2.1">
              <dt pn="section-5.2-3.2.1.1">sth:</dt>
              <dd pn="section-5.2-3.2.1.2">A base64-encoded <tt>TransItem</tt> of type <tt>signed_tree_head_v2</tt>
	      signed by this log that is no older than the log's MMD.</dd>
            </dl>
          </dd>
        </dl>
      </section>
      <section anchor="get-sth-consistency" numbered="true" toc="include" removeInRFC="false" pn="section-5.3">
        <name slugifiedName="name-retrieve-merkle-consistency">Retrieve Merkle Consistency Proof between Two STHs</name>
        <t indent="0" pn="section-5.3-1">GET &lt;Base URL&gt;/ct/v2/get-sth-consistency</t>
        <dl newline="true" spacing="normal" indent="3" pn="section-5.3-2">
          <dt pn="section-5.3-2.1">Inputs:</dt>
          <dd pn="section-5.3-2.2">
            <dl newline="false" spacing="normal" indent="3" pn="section-5.3-2.2.1">
              <dt pn="section-5.3-2.2.1.1">first:</dt>
              <dd pn="section-5.3-2.2.1.2">The <tt>tree_size</tt> of the older tree, in decimal.</dd>
              <dt pn="section-5.3-2.2.1.3">second:</dt>
              <dd pn="section-5.3-2.2.1.4">The <tt>tree_size</tt> of the newer tree, in decimal (optional).</dd>
            </dl>
            <t indent="0" pn="section-5.3-2.2.2">Both tree sizes must be from existing v2 STHs. However, because of skew, the
	  receiving front end may not know one or both of the existing STHs. If both are
	  known, then only the <tt>consistency</tt> output is returned. If the first is known
	  but the second is not (or has been omitted), then the latest known STH is
	  returned, along with a consistency proof between the first STH and the latest.
	  If neither are known, then the latest known STH is returned without a
	  consistency proof.</t>
          </dd>
        </dl>
        <dl newline="true" spacing="normal" indent="3" pn="section-5.3-3">
          <dt pn="section-5.3-3.1">Outputs:</dt>
          <dd pn="section-5.3-3.2">
            <dl newline="false" spacing="normal" indent="3" pn="section-5.3-3.2.1">
              <dt pn="section-5.3-3.2.1.1">consistency:</dt>
              <dd pn="section-5.3-3.2.1.2">A base64-encoded <tt>TransItem</tt> of type <tt>consistency_proof_v2</tt>
	      whose <tt>tree_size_1</tt> <bcp14>MUST</bcp14> match the <tt>first</tt> input.
	      If the <tt>sth</tt> output is omitted,
	      then <tt>tree_size_2</tt> <bcp14>MUST</bcp14> match the <tt>second</tt> input.
	      If <tt>first</tt> and <tt>second</tt> are equal and correspond to a known STH,
	      the returned consistency proof <bcp14>MUST</bcp14> be empty (a
	      <tt>consistency_path</tt> array with zero elements).</dd>
              <dt pn="section-5.3-3.2.1.3">sth:</dt>
              <dd pn="section-5.3-3.2.1.4">A base64-encoded <tt>TransItem</tt> of type <tt>signed_tree_head_v2</tt>,
	      signed by this log.</dd>
            </dl>
            <t indent="0" pn="section-5.3-3.2.2">Note that no signature is required for the <tt>consistency</tt> output, as it is
	  used to verify the consistency between two signed STHs.</t>
          </dd>
        </dl>
        <t indent="0" pn="section-5.3-4">Error codes:</t>
        <table align="center" pn="table-3">
          <thead>
            <tr>
              <th align="left" colspan="1" rowspan="1">type</th>
              <th align="left" colspan="1" rowspan="1">detail</th>
            </tr>
          </thead>
          <tbody>
            <tr>
              <td align="left" colspan="1" rowspan="1">firstUnknown</td>
              <td align="left" colspan="1" rowspan="1">
                <tt>first</tt> is before the latest known STH but is not from
	      an existing STH.</td>
            </tr>
            <tr>
              <td align="left" colspan="1" rowspan="1">secondUnknown</td>
              <td align="left" colspan="1" rowspan="1">
                <tt>second</tt> is before the latest known STH but is not from
	      an existing STH.</td>
            </tr>
            <tr>
              <td align="left" colspan="1" rowspan="1">secondBeforeFirst</td>
              <td align="left" colspan="1" rowspan="1">
                <tt>second</tt> is smaller than <tt>first</tt>.</td>
            </tr>
          </tbody>
        </table>
        <t indent="0" pn="section-5.3-6">See <xref target="verify_consistency" format="default" sectionFormat="of" derivedContent="Section 2.1.4.2"/> for an outline of how to use the <tt>consistency</tt>
output.</t>
      </section>
      <section anchor="get-proof-by-hash" numbered="true" toc="include" removeInRFC="false" pn="section-5.4">
        <name slugifiedName="name-retrieve-merkle-inclusion-p">Retrieve Merkle Inclusion Proof from Log by Leaf Hash</name>
        <t indent="0" pn="section-5.4-1">GET &lt;Base URL&gt;/ct/v2/get-proof-by-hash</t>
        <dl newline="true" spacing="normal" indent="3" pn="section-5.4-2">
          <dt pn="section-5.4-2.1">Inputs:</dt>
          <dd pn="section-5.4-2.2">
            <dl newline="false" spacing="normal" indent="3" pn="section-5.4-2.2.1">
              <dt pn="section-5.4-2.2.1.1">hash:</dt>
              <dd pn="section-5.4-2.2.1.2">A base64-encoded v2 leaf hash.</dd>
              <dt pn="section-5.4-2.2.1.3">tree_size:</dt>
              <dd pn="section-5.4-2.2.1.4">The <tt>tree_size</tt> of the tree on which to base the proof, in decimal.</dd>
            </dl>
            <t indent="0" pn="section-5.4-2.2.2">The <tt>hash</tt> must be calculated as defined in <xref target="tree_leaves" format="default" sectionFormat="of" derivedContent="Section 4.7"/>. A v2 STH must
	  exist for the <tt>tree_size</tt>.  Because of skew, the front end may not know
	  the requested tree head. In that case, it will return the latest STH it knows, along
	  with an inclusion proof to that STH. If the front end knows the requested tree head,
	  then only <tt>inclusion</tt> is returned.</t>
          </dd>
        </dl>
        <dl newline="true" spacing="normal" indent="3" pn="section-5.4-3">
          <dt pn="section-5.4-3.1">Outputs:</dt>
          <dd pn="section-5.4-3.2">
            <dl newline="false" spacing="normal" indent="3" pn="section-5.4-3.2.1">
              <dt pn="section-5.4-3.2.1.1">inclusion:</dt>
              <dd pn="section-5.4-3.2.1.2">A base64-encoded <tt>TransItem</tt> of type <tt>inclusion_proof_v2</tt>
	      whose <tt>inclusion_path</tt> array of Merkle Tree nodes proves the inclusion
	      of the certificate (as specified by the <tt>hash</tt> parameter) in the
	      selected STH.</dd>
              <dt pn="section-5.4-3.2.1.3">sth:</dt>
              <dd pn="section-5.4-3.2.1.4">A base64-encoded <tt>TransItem</tt> of type <tt>signed_tree_head_v2</tt>,
	      signed by this log.</dd>
            </dl>
            <t indent="0" pn="section-5.4-3.2.2">Note that no signature is required for the <tt>inclusion</tt> output, as it is
	    used to verify inclusion in the selected STH, which is signed.</t>
          </dd>
        </dl>
        <t indent="0" pn="section-5.4-4">Error codes:</t>
        <table align="center" pn="table-4">
          <thead>
            <tr>
              <th align="left" colspan="1" rowspan="1">type</th>
              <th align="left" colspan="1" rowspan="1">detail</th>
            </tr>
          </thead>
          <tbody>
            <tr>
              <td align="left" colspan="1" rowspan="1">hashUnknown</td>
              <td align="left" colspan="1" rowspan="1">
                <tt>hash</tt> is not the hash of a known leaf (may be caused by skew or by a known certificate not yet merged).</td>
            </tr>
            <tr>
              <td align="left" colspan="1" rowspan="1">treeSizeUnknown</td>
              <td align="left" colspan="1" rowspan="1">
                <tt>hash</tt> is before the latest known STH but is not from an existing STH.</td>
            </tr>
          </tbody>
        </table>
        <t indent="0" pn="section-5.4-6">See <xref target="verify_inclusion" format="default" sectionFormat="of" derivedContent="Section 2.1.3.2"/> for an outline of how to use the <tt>inclusion</tt> output.</t>
      </section>
      <section anchor="get-all-by-hash" numbered="true" toc="include" removeInRFC="false" pn="section-5.5">
        <name slugifiedName="name-retrieve-merkle-inclusion-pr">Retrieve Merkle Inclusion Proof, STH, and Consistency Proof by Leaf Hash</name>
        <t indent="0" pn="section-5.5-1">GET &lt;Base URL&gt;/ct/v2/get-all-by-hash</t>
        <dl newline="true" spacing="normal" indent="3" pn="section-5.5-2">
          <dt pn="section-5.5-2.1">Inputs:</dt>
          <dd pn="section-5.5-2.2">
            <dl newline="false" spacing="normal" indent="3" pn="section-5.5-2.2.1">
              <dt pn="section-5.5-2.2.1.1">hash:</dt>
              <dd pn="section-5.5-2.2.1.2">A base64-encoded v2 leaf hash.</dd>
              <dt pn="section-5.5-2.2.1.3">tree_size:</dt>
              <dd pn="section-5.5-2.2.1.4">The <tt>tree_size</tt> of the tree on which to base the proofs, in decimal.</dd>
            </dl>
            <t indent="0" pn="section-5.5-2.2.2">The <tt>hash</tt> must be calculated as defined in <xref target="tree_leaves" format="default" sectionFormat="of" derivedContent="Section 4.7"/>. A v2 STH must exist for the <tt>tree_size</tt>.</t>
          </dd>
        </dl>
        <t indent="0" pn="section-5.5-3">Because of skew, the front end may not know the requested tree head or the
	requested hash, which leads to a number of cases:</t>
        <table align="center" pn="table-5">
          <thead>
            <tr>
              <th align="left" colspan="1" rowspan="1">Case</th>
              <th align="left" colspan="1" rowspan="1">Response</th>
            </tr>
          </thead>
          <tbody>
            <tr>
              <td align="left" colspan="1" rowspan="1">latest STH &lt; requested tree head</td>
              <td align="left" colspan="1" rowspan="1">Return latest STH.</td>
            </tr>
            <tr>
              <td align="left" colspan="1" rowspan="1">latest STH &gt; requested tree head</td>
              <td align="left" colspan="1" rowspan="1">Return latest STH and a consistency proof between it and the requested tree head (see <xref target="get-sth-consistency" format="default" sectionFormat="of" derivedContent="Section 5.3"/>).</td>
            </tr>
            <tr>
              <td align="left" colspan="1" rowspan="1">index of requested hash &lt; latest STH</td>
              <td align="left" colspan="1" rowspan="1">Return <tt>inclusion</tt>.</td>
            </tr>
          </tbody>
        </table>
        <t indent="0" pn="section-5.5-5">Note that more than one case can be true; in which case, the returned data is
their union. It is also possible for none to be true; in which case, the
front end <bcp14>MUST</bcp14> return an empty response.</t>
        <dl newline="true" spacing="normal" indent="3" pn="section-5.5-6">
          <dt pn="section-5.5-6.1">Outputs:</dt>
          <dd pn="section-5.5-6.2">
            <dl newline="false" spacing="normal" indent="3" pn="section-5.5-6.2.1">
              <dt pn="section-5.5-6.2.1.1">inclusion:</dt>
              <dd pn="section-5.5-6.2.1.2">A base64-encoded <tt>TransItem</tt> of type <tt>inclusion_proof_v2</tt>
	      whose <tt>inclusion_path</tt> array of Merkle Tree nodes proves the inclusion
	      of the certificate (as specified by the <tt>hash</tt> parameter) in the
	      selected STH.</dd>
              <dt pn="section-5.5-6.2.1.3">sth:</dt>
              <dd pn="section-5.5-6.2.1.4">A base64-encoded <tt>TransItem</tt> of type <tt>signed_tree_head_v2</tt>,
	      signed by this log.</dd>
              <dt pn="section-5.5-6.2.1.5">consistency:</dt>
              <dd pn="section-5.5-6.2.1.6">A base64-encoded <tt>TransItem</tt> of type <tt>consistency_proof_v2</tt>
	      that proves the consistency of the requested tree head and the returned
	      STH.</dd>
            </dl>
            <t indent="0" pn="section-5.5-6.2.2">Note that no signature is required for the <tt>inclusion</tt> or
	    <tt>consistency</tt> outputs, as they are used to verify inclusion in and
	    consistency of signed STHs.</t>
          </dd>
        </dl>
        <t indent="0" pn="section-5.5-7">Errors are the same as in <xref target="get-proof-by-hash" format="default" sectionFormat="of" derivedContent="Section 5.4"/>.</t>
        <t indent="0" pn="section-5.5-8">See <xref target="verify_inclusion" format="default" sectionFormat="of" derivedContent="Section 2.1.3.2"/> for an outline of how to use the <tt>inclusion</tt> output,
and see <xref target="verify_consistency" format="default" sectionFormat="of" derivedContent="Section 2.1.4.2"/> for an outline of how to use the <tt>consistency</tt>
output.</t>
      </section>
      <section anchor="get-entries" numbered="true" toc="include" removeInRFC="false" pn="section-5.6">
        <name slugifiedName="name-retrieve-entries-and-sth-fr">Retrieve Entries and STH from Log</name>
        <t indent="0" pn="section-5.6-1">GET &lt;Base URL&gt;/ct/v2/get-entries</t>
        <dl newline="true" spacing="normal" indent="3" pn="section-5.6-2">
          <dt pn="section-5.6-2.1">Inputs:</dt>
          <dd pn="section-5.6-2.2">
            <dl newline="false" spacing="normal" indent="3" pn="section-5.6-2.2.1">
              <dt pn="section-5.6-2.2.1.1">start:</dt>
              <dd pn="section-5.6-2.2.1.2">0-based index of first entry to retrieve, in decimal.</dd>
              <dt pn="section-5.6-2.2.1.3">end:</dt>
              <dd pn="section-5.6-2.2.1.4">0-based index of last entry to retrieve, in decimal.</dd>
            </dl>
          </dd>
          <dt pn="section-5.6-2.3">Outputs:</dt>
          <dd pn="section-5.6-2.4">
            <dl newline="false" spacing="normal" indent="3" pn="section-5.6-2.4.1">
              <dt pn="section-5.6-2.4.1.1">entries:</dt>
              <dd pn="section-5.6-2.4.1.2">
                <t indent="0" pn="section-5.6-2.4.1.2.1">An array of objects, each consisting of:</t>
                <dl newline="false" spacing="normal" indent="3" pn="section-5.6-2.4.1.2.2">
                  <dt pn="section-5.6-2.4.1.2.2.1">log_entry:</dt>
                  <dd pn="section-5.6-2.4.1.2.2.2">The base64-encoded <tt>TransItem</tt> structure of type
		  <tt>x509_entry_v2</tt> or
		  <tt>precert_entry_v2</tt> (see <xref target="log_entries" format="default" sectionFormat="of" derivedContent="Section 4.3"/>).</dd>
                  <dt pn="section-5.6-2.4.1.2.2.3">submitted_entry:</dt>
                  <dd pn="section-5.6-2.4.1.2.2.4">JSON object equivalent to inputs that were submitted to
		  <tt>submit-entry</tt>, with the addition of the trust anchor to the
		  <tt>chain</tt> field if the submission did not include it.</dd>
                  <dt pn="section-5.6-2.4.1.2.2.5">sct:</dt>
                  <dd pn="section-5.6-2.4.1.2.2.6">The base64-encoded <tt>TransItem</tt> of type <tt>x509_sct_v2</tt> or
		  <tt>precert_sct_v2</tt>, corresponding to this log entry.</dd>
                  <dt pn="section-5.6-2.4.1.2.2.7">sth:</dt>
                  <dd pn="section-5.6-2.4.1.2.2.8">A base64-encoded <tt>TransItem</tt> of type
		  <tt>signed_tree_head_v2</tt>, signed by this log.</dd>
                </dl>
              </dd>
            </dl>
          </dd>
        </dl>
        <t indent="0" pn="section-5.6-3">Note that this message is not signed -- the <tt>entries</tt> data can be verified by
constructing the Merkle Tree Hash corresponding to a retrieved STH. All leaves
<bcp14>MUST</bcp14> be v2. However, a compliant v2 client <bcp14>MUST NOT</bcp14> construe an unrecognized
<tt>TransItem</tt> type as an error. This means it may be unable to parse some entries,
but note that each client can inspect the entries it does recognize as well as
verify the integrity of the data by treating unrecognized leaves as opaque input
to the tree.</t>
        <t indent="0" pn="section-5.6-4">The <tt>start</tt> and <tt>end</tt> parameters <bcp14>SHOULD</bcp14> be within the range 0 &lt;= x &lt; <tt>tree_size</tt>,
as returned by <tt>get-sth</tt> in <xref target="get-sth" format="default" sectionFormat="of" derivedContent="Section 5.2"/>.</t>
        <t indent="0" pn="section-5.6-5">The <tt>start</tt> parameter <bcp14>MUST</bcp14> be less than or equal to the <tt>end</tt> parameter.</t>
        <t indent="0" pn="section-5.6-6">Each <tt>submitted_entry</tt> output parameter <bcp14>MUST</bcp14> include the trust anchor that the
log used to verify the <tt>submission</tt>, even if that trust anchor was not provided
to <tt>submit-entry</tt> (see <xref target="submit-entry" format="default" sectionFormat="of" derivedContent="Section 5.1"/>). If the <tt>submission</tt> does not certify
itself, then the first element of <tt>chain</tt> <bcp14>MUST</bcp14> be present and <bcp14>MUST</bcp14> certify the
<tt>submission</tt>.</t>
        <t indent="0" pn="section-5.6-7">Log servers <bcp14>MUST</bcp14> honor requests where 0 &lt;= <tt>start</tt> &lt; <tt>tree_size</tt> and <tt>end</tt> &gt;=
<tt>tree_size</tt> by returning a partial response covering only the valid entries in
the specified range. <tt>end</tt> &gt;= <tt>tree_size</tt> could be caused by skew. Note that the
following restriction may also apply:</t>
        <t indent="0" pn="section-5.6-8">Logs <bcp14>MAY</bcp14> restrict the number of entries that can be retrieved per <tt>get-entries</tt>
request. If a client requests more than the permitted number of entries, the log
<bcp14>SHALL</bcp14> return the maximum number of entries permissible. These entries <bcp14>SHALL</bcp14> be
sequential beginning with the entry specified by <tt>start</tt>.
Note that a limit on the number of entries is not immutable, and therefore
the restriction may be changed or lifted at any time and is not listed
with the other Log Parameters in <xref target="log_parameters" format="default" sectionFormat="of" derivedContent="Section 4.1"/>.</t>
        <t indent="0" pn="section-5.6-9">Because of skew, it is possible the log server will not have any entries between
<tt>start</tt> and <tt>end</tt>. In this case, it <bcp14>MUST</bcp14> return an empty <tt>entries</tt> array.</t>
        <t indent="0" pn="section-5.6-10">In any case, the log server <bcp14>MUST</bcp14> return the latest STH it knows about.</t>
        <t indent="0" pn="section-5.6-11">See <xref target="verify_hash" format="default" sectionFormat="of" derivedContent="Section 2.1.2"/> for an outline of how to use a complete list of <tt>log_entry</tt>
entries to verify the <tt>root_hash</tt>.</t>
        <t indent="0" pn="section-5.6-12">Error codes:</t>
        <table align="center" pn="table-6">
          <thead>
            <tr>
              <th align="left" colspan="1" rowspan="1">type</th>
              <th align="left" colspan="1" rowspan="1">detail</th>
            </tr>
          </thead>
          <tbody>
            <tr>
              <td align="left" colspan="1" rowspan="1">startUnknown</td>
              <td align="left" colspan="1" rowspan="1">
                <tt>start</tt> is greater than the number of entries in the Merkle Tree.</td>
            </tr>
            <tr>
              <td align="left" colspan="1" rowspan="1">endBeforeStart</td>
              <td align="left" colspan="1" rowspan="1">
                <tt>start</tt> cannot be greater than <tt>end</tt>.</td>
            </tr>
          </tbody>
        </table>
      </section>
      <section anchor="get-anchors" numbered="true" toc="include" removeInRFC="false" pn="section-5.7">
        <name slugifiedName="name-retrieve-accepted-trust-anc">Retrieve Accepted Trust Anchors</name>
        <t indent="0" pn="section-5.7-1">GET &lt;Base URL&gt;/ct/v2/get-anchors</t>
        <t indent="0" pn="section-5.7-2">No inputs.</t>
        <dl newline="true" spacing="normal" indent="3" pn="section-5.7-3">
          <dt pn="section-5.7-3.1">Outputs:</dt>
          <dd pn="section-5.7-3.2">
            <dl newline="false" spacing="normal" indent="3" pn="section-5.7-3.2.1">
              <dt pn="section-5.7-3.2.1.1">certificates:</dt>
              <dd pn="section-5.7-3.2.1.2">An array of JSON strings, each of which
	      is a base64-encoded CA certificate that is acceptable to the log.</dd>
              <dt pn="section-5.7-3.2.1.3">max_chain_length:</dt>
              <dd pn="section-5.7-3.2.1.4">If the server has chosen to limit the length of chains it accepts, this is
	      the maximum number of certificates in the chain, in decimal. If there is no
	      limit, this is omitted.</dd>
            </dl>
            <t indent="0" pn="section-5.7-3.2.2">This data is not signed, and the protocol depends on the security guarantees
	    of TLS to ensure correctness.</t>
          </dd>
        </dl>
      </section>
    </section>
    <section anchor="tls_servers" numbered="true" toc="include" removeInRFC="false" pn="section-6">
      <name slugifiedName="name-tls-servers">TLS Servers</name>
      <t indent="0" pn="section-6-1">CT-using TLS servers <bcp14>MUST</bcp14> use at least one of the mechanisms described below
to present one or more SCTs from one or more logs to each TLS client during full
TLS handshakes, when requested by the client, where each SCT corresponds to the server certificate.
(Of course, a server can only send a TLS extension if the client has
specified it first.)
Servers
<bcp14>SHOULD</bcp14> also present corresponding inclusion proofs and STHs.</t>
      <t indent="0" pn="section-6-2">A server can provide SCTs using
a TLS 1.3 extension (<xref target="RFC8446" sectionFormat="of" section="4.2" format="default" derivedLink="https://rfc-editor.org/rfc/rfc8446#section-4.2" derivedContent="RFC8446"/>) with type <tt>transparency_info</tt>
(see <xref target="tls_transinfo_extension" format="default" sectionFormat="of" derivedContent="Section 6.5"/>). This mechanism allows TLS servers to
participate in CT without the cooperation of CAs, unlike the other two
mechanisms. It also allows SCTs and inclusion proofs to be updated on the fly.</t>
      <t indent="0" pn="section-6-3">The server may also use an Online Certificate Status Protocol (OCSP)
<xref target="RFC6960" format="default" sectionFormat="of" derivedContent="RFC6960"/> response extension (see <xref target="ocsp_transinfo_extension" format="default" sectionFormat="of" derivedContent="Section 7.1.1"/>),
providing the OCSP response as part of the TLS handshake. Providing
a response during a TLS handshake is popularly known as "OCSP stapling".
For TLS
1.3, the information is encoded as an extension in the <tt>status_request</tt>
extension data; see <xref target="RFC8446" sectionFormat="of" section="4.4.2.1" format="default" derivedLink="https://rfc-editor.org/rfc/rfc8446#section-4.4.2.1" derivedContent="RFC8446"/>. For TLS 1.2 <xref target="RFC5246" format="default" sectionFormat="of" derivedContent="RFC5246"/>, the information
is encoded in the <tt>CertificateStatus</tt> message; see <xref target="RFC6066" sectionFormat="of" section="8" format="default" derivedLink="https://rfc-editor.org/rfc/rfc6066#section-8" derivedContent="RFC6066"/>.  Using stapling also
allows SCTs and inclusion proofs to be updated on the fly.</t>
      <t indent="0" pn="section-6-4">CT information can also be encoded as an extension in the X.509v3 certificate
(see <xref target="cert_transinfo_extension" format="default" sectionFormat="of" derivedContent="Section 7.1.2"/>). This
mechanism allows the use of unmodified TLS servers, but the SCTs and inclusion
proofs cannot be updated on the fly. Since the logs from which the SCTs and
inclusion proofs originated won't necessarily be accepted by TLS clients for
the full lifetime of the certificate, there is a risk that TLS clients may
subsequently consider the certificate to be noncompliant. In such an event, one of
the other two mechanisms will need to be used to deliver CT information, or, if this is
not possible, the certificate will need to be reissued.</t>
      <section anchor="tls-client-authentication" numbered="true" toc="include" removeInRFC="false" pn="section-6.1">
        <name slugifiedName="name-tls-client-authentication">TLS Client Authentication</name>
        <t indent="0" pn="section-6.1-1">This specification includes no description of how a TLS server can
use CT for TLS client certificates.
While this may be useful, it is not documented here for the following
reasons:</t>
        <ul spacing="normal" bare="false" empty="false" indent="3" pn="section-6.1-2">
          <li pn="section-6.1-2.1">The greater security exposure is for clients to end up interacting with an
	  illegitimate server.</li>
          <li pn="section-6.1-2.2">In general, TLS client certificates are not expected to be submitted to
	  CT logs, particularly those intended for general public use.</li>
        </ul>
        <t indent="0" pn="section-6.1-3">A future version could include such information.</t>
      </section>
      <section anchor="multiple-scts" numbered="true" toc="include" removeInRFC="false" pn="section-6.2">
        <name slugifiedName="name-multiple-scts">Multiple SCTs</name>
        <t indent="0" pn="section-6.2-1">CT-using TLS servers <bcp14>SHOULD</bcp14> send SCTs from multiple logs because:</t>
        <ul spacing="normal" bare="false" empty="false" indent="3" pn="section-6.2-2">
          <li pn="section-6.2-2.1">The set of logs trusted by TLS clients is neither unified nor static; each
          client vendor may maintain an independent list of trusted logs, and, over time, new logs
          may become trusted and current logs may become distrusted.
	  Note that client discovery, trust, and distrust of logs are expected to
	  be handled out of band and are out of scope of this document.</li>
          <li pn="section-6.2-2.2">If a CA and a log collude, it is possible to temporarily hide misissuance from
	  clients. When a TLS client requires SCTs from multiple logs to be provided, it
	  is more difficult to mount this attack.</li>
          <li pn="section-6.2-2.3">If a log misbehaves or suffers a key compromise, a consequence may be that
	  clients cease to trust it. Since the time an SCT may be in use can be
	  considerable (several years is common in current practice when embedded in a
	  certificate), including SCTs from multiple logs reduces the probability of the
	  certificate being rejected by TLS clients.</li>
          <li pn="section-6.2-2.4">TLS clients may have policies related to the above risks requiring TLS servers
	  to present multiple SCTs. For example, at the time of writing, Chromium
	  <xref target="Chromium.Log.Policy" format="default" sectionFormat="of" derivedContent="Chromium.Log.Policy"/> requires multiple SCTs to be
	  presented with Extended Validation (EV)
	  certificates in order for the EV indicator to be shown.</li>
        </ul>
        <t indent="0" pn="section-6.2-3">To select the logs from which to obtain SCTs, a TLS server can, for example,
examine the set of logs popular TLS clients accept and recognize.</t>
      </section>
      <section anchor="transitemlist-structure" numbered="true" toc="include" removeInRFC="false" pn="section-6.3">
        <name slugifiedName="name-transitemlist-structure">TransItemList Structure</name>
        <t indent="0" pn="section-6.3-1">Multiple SCTs, inclusion proofs, and indeed <tt>TransItem</tt> structures of any
	type are combined into a list as follows:</t>
        <sourcecode type="tls-presentation" markers="false" pn="section-6.3-2">
      opaque SerializedTransItem&lt;1..2^16-1&gt;;

      struct {
          SerializedTransItem trans_item_list&lt;1..2^16-1&gt;;
      } TransItemList;
</sourcecode>
        <t indent="0" pn="section-6.3-3">Here, <tt>SerializedTransItem</tt> is an opaque byte string that contains the
	serialized <tt>TransItem</tt> structure. This encoding ensures that TLS clients can
	decode each <tt>TransItem</tt> individually (so, for example, if there is a version
	upgrade, out-of-date clients can still parse old <tt>TransItem</tt> structures while
	skipping over new <tt>TransItem</tt> structures whose versions they don't
	understand).</t>
      </section>
      <section anchor="presenting_transitems" numbered="true" toc="include" removeInRFC="false" pn="section-6.4">
        <name slugifiedName="name-presenting-scts-inclusions-">Presenting SCTs, Inclusions Proofs, and STHs</name>
        <t indent="0" pn="section-6.4-1">In each <tt>TransItemList</tt> that is sent during a TLS handshake, the TLS
server <bcp14>MUST</bcp14> include a <tt>TransItem</tt> structure of type <tt>x509_sct_v2</tt> or
<tt>precert_sct_v2</tt>.</t>
        <t indent="0" pn="section-6.4-2">Presenting inclusion proofs and STHs in the TLS handshake helps to protect the
client's privacy (see <xref target="fetching_inclusion_proofs" format="default" sectionFormat="of" derivedContent="Section 8.1.4"/>) and reduces load on log
servers. Therefore, if the TLS server can obtain them, it <bcp14>SHOULD</bcp14> also include
<tt>TransItem</tt>s of type <tt>inclusion_proof_v2</tt> and <tt>signed_tree_head_v2</tt> in the
<tt>TransItemList</tt>.</t>
      </section>
      <section anchor="tls_transinfo_extension" numbered="true" toc="include" removeInRFC="false" pn="section-6.5">
        <name slugifiedName="name-transparency_info-tls-exten">transparency_info TLS Extension</name>
        <t indent="0" pn="section-6.5-1">Provided that a TLS client includes the <tt>transparency_info</tt> extension type in
the ClientHello and the TLS server supports the <tt>transparency_info</tt> extension:</t>
        <ul spacing="normal" bare="false" empty="false" indent="3" pn="section-6.5-2">
          <li pn="section-6.5-2.1">The TLS server <bcp14>MUST</bcp14> verify that the received
	  <tt>extension_data</tt> is empty.</li>
          <li pn="section-6.5-2.2">The TLS server <bcp14>MUST</bcp14> construct a <tt>TransItemList</tt> of
	  relevant <tt>TransItem</tt>s (see
	  <xref target="presenting_transitems" format="default" sectionFormat="of" derivedContent="Section 6.4"/>), which
	  <bcp14>SHOULD</bcp14> omit any <tt>TransItem</tt>s that are
	  already embedded in the server certificate or the stapled OCSP response (see
	  <xref target="x509v3_transinfo_extension" format="default" sectionFormat="of" derivedContent="Section 7.1"/>). If the constructed
	  <tt>TransItemList</tt> is not
	  empty, then the TLS server <bcp14>MUST</bcp14> include the
	  <tt>transparency_info</tt> extension with
	  the <tt>extension_data</tt> set to this <tt>TransItemList</tt>. If the list is
	  empty, then the server <bcp14>SHOULD</bcp14> omit the <tt>extension_data</tt>
	  element but <bcp14>MAY</bcp14> send it with an empty array.</li>
        </ul>
        <t indent="0" pn="section-6.5-3">TLS servers <bcp14>MUST</bcp14> only include this extension in the following messages:</t>
        <ul spacing="normal" bare="false" empty="false" indent="3" pn="section-6.5-4">
          <li pn="section-6.5-4.1">the ServerHello message (for TLS 1.2 or earlier)</li>
          <li pn="section-6.5-4.2">the Certificate or CertificateRequest message (for TLS 1.3)</li>
        </ul>
        <t indent="0" pn="section-6.5-5">TLS servers <bcp14>MUST NOT</bcp14> process or include this extension when a TLS session is
resumed, since session resumption uses the original session information.</t>
      </section>
    </section>
    <section anchor="certification-authorities" numbered="true" toc="include" removeInRFC="false" pn="section-7">
      <name slugifiedName="name-certification-authorities">Certification Authorities</name>
      <section anchor="x509v3_transinfo_extension" numbered="true" toc="include" removeInRFC="false" pn="section-7.1">
        <name slugifiedName="name-transparency-information-x5">Transparency Information X.509v3 Extension</name>
        <t indent="0" pn="section-7.1-1">The Transparency Information X.509v3 extension, which has OID 1.3.101.75 and
	<bcp14>SHOULD</bcp14> be noncritical, contains one or more <tt>TransItem</tt>
	structures in a <tt>TransItemList</tt>. This extension <bcp14>MAY</bcp14> be
	included in OCSP responses (see
	<xref target="ocsp_transinfo_extension" format="default" sectionFormat="of" derivedContent="Section 7.1.1"/>) and certificates (see
	<xref target="cert_transinfo_extension" format="default" sectionFormat="of" derivedContent="Section 7.1.2"/>). Since <xref target="RFC5280" format="default" sectionFormat="of" derivedContent="RFC5280"/> requires the <tt>extnValue</tt> field (an
	OCTET STRING) of each X.509v3 extension to include the DER encoding of an ASN.1
	value, a <tt>TransItemList</tt> <bcp14>MUST NOT</bcp14> be included directly.
	Instead, it <bcp14>MUST</bcp14> be
	wrapped inside an additional OCTET STRING, which is then put into the
	<tt>extnValue</tt> field:</t>
        <sourcecode type="asn.1" markers="false" pn="section-7.1-2">
    TransparencyInformationSyntax ::= OCTET STRING
</sourcecode>
        <t indent="0" pn="section-7.1-3"><tt>TransparencyInformationSyntax</tt> contains a <tt>TransItemList</tt>.</t>
        <section anchor="ocsp_transinfo_extension" numbered="true" toc="include" removeInRFC="false" pn="section-7.1.1">
          <name slugifiedName="name-ocsp-response-extension">OCSP Response Extension</name>
          <t indent="0" pn="section-7.1.1-1">A certification authority <bcp14>MAY</bcp14> include a Transparency Information
	  X.509v3 extension in the <tt>singleExtensions</tt> of a <tt>SingleResponse</tt> in
	  an OCSP response. All included SCTs and inclusion proofs <bcp14>MUST</bcp14> be for
	  the certificate identified by the <tt>certID</tt> of that <tt>SingleResponse</tt>
	  or for a precertificate that corresponds to that certificate.</t>
        </section>
        <section anchor="cert_transinfo_extension" numbered="true" toc="include" removeInRFC="false" pn="section-7.1.2">
          <name slugifiedName="name-certificate-extension">Certificate Extension</name>
          <t indent="0" pn="section-7.1.2-1">A certification authority <bcp14>MAY</bcp14> include a Transparency Information X.509v3
extension in a certificate. All included SCTs and inclusion proofs <bcp14>MUST</bcp14> be for a
precertificate that corresponds to this certificate.</t>
        </section>
      </section>
      <section anchor="tls-feature-x509v3-extension" numbered="true" toc="include" removeInRFC="false" pn="section-7.2">
        <name slugifiedName="name-tls-feature-x509v3-extensio">TLS Feature X.509v3 Extension</name>
        <t indent="0" pn="section-7.2-1">A certification authority <bcp14>SHOULD NOT</bcp14> issue any certificate that identifies the
<tt>transparency_info</tt> TLS extension in a TLS feature extension <xref target="RFC7633" format="default" sectionFormat="of" derivedContent="RFC7633"/>, because
TLS servers are not required to support the <tt>transparency_info</tt> TLS extension in
order to participate in CT (see <xref target="tls_servers" format="default" sectionFormat="of" derivedContent="Section 6"/>).</t>
      </section>
    </section>
    <section anchor="clients" numbered="true" toc="include" removeInRFC="false" pn="section-8">
      <name slugifiedName="name-clients">Clients</name>
      <t indent="0" pn="section-8-1">There are various different functions clients of logs might perform. We describe
      here some typical clients and how they should function. Any inconsistency may be
      used as evidence that a log has not behaved correctly, and the signatures on the
      data structures prevent the log from denying that misbehavior.</t>
      <t indent="0" pn="section-8-2">All clients need various parameters in order to communicate with logs and verify
      their responses. These parameters are described in <xref target="log_parameters" format="default" sectionFormat="of" derivedContent="Section 4.1"/>, but note
      that this document does not describe how the parameters are obtained, which is
      implementation dependent (for example, see <xref target="Chromium.Policy" format="default" sectionFormat="of" derivedContent="Chromium.Policy"/>).</t>
      <section anchor="tls_clients" numbered="true" toc="include" removeInRFC="false" pn="section-8.1">
        <name slugifiedName="name-tls-client">TLS Client</name>
        <section anchor="receiving_transitems" numbered="true" toc="include" removeInRFC="false" pn="section-8.1.1">
          <name slugifiedName="name-receiving-scts-and-inclusio">Receiving SCTs and Inclusion Proofs</name>
          <t indent="0" pn="section-8.1.1-1">TLS clients receive SCTs and inclusion proofs alongside or in certificates.
	  CT-using TLS clients <bcp14>MUST</bcp14> implement all of the three mechanisms by
	  which TLS servers may present SCTs (see <xref target="tls_servers" format="default" sectionFormat="of" derivedContent="Section 6"/>).</t>
          <t indent="0" pn="section-8.1.1-2">TLS clients that support the <tt>transparency_info</tt> TLS extension
	  (see <xref target="tls_transinfo_extension" format="default" sectionFormat="of" derivedContent="Section 6.5"/>)
	  <bcp14>SHOULD</bcp14> include it in ClientHello messages,
	  with empty <tt>extension_data</tt>. If a TLS server includes the
	  <tt>transparency_info</tt> TLS extension when resuming a TLS session, the TLS
	  client <bcp14>MUST</bcp14> abort the handshake.</t>
        </section>
        <section anchor="reconstructing_tbscertificate" numbered="true" toc="include" removeInRFC="false" pn="section-8.1.2">
          <name slugifiedName="name-reconstructing-the-tbscerti">Reconstructing the TBSCertificate</name>
          <t indent="0" pn="section-8.1.2-1">Validation of an SCT for a certificate (where the <tt>type</tt> of the <tt>TransItem</tt> is
<tt>x509_sct_v2</tt>) uses the unmodified TBSCertificate component of the certificate.</t>
          <t indent="0" pn="section-8.1.2-2">Before an SCT for a precertificate (where the <tt>type</tt> of the <tt>TransItem</tt> is
<tt>precert_sct_v2</tt>) can be validated, the TBSCertificate component of the
precertificate needs to be reconstructed from the TBSCertificate component of
the certificate as follows:</t>
          <ul spacing="normal" bare="false" empty="false" indent="3" pn="section-8.1.2-3">
            <li pn="section-8.1.2-3.1">Remove the Transparency Information extension
	    (see <xref target="x509v3_transinfo_extension" format="default" sectionFormat="of" derivedContent="Section 7.1"/>).</li>
            <li pn="section-8.1.2-3.2">Remove embedded v1 SCTs, identified by OID 1.3.6.1.4.1.11129.2.4.2 (see
	    <xref target="RFC6962" sectionFormat="of" section="3.3" format="default" derivedLink="https://rfc-editor.org/rfc/rfc6962#section-3.3" derivedContent="RFC6962"/>). This allows embedded
	    v1 and v2 SCTs to co-exist in
	    a certificate (see <xref target="v1_coexistence" format="default" sectionFormat="of" derivedContent="Appendix A"/>).</li>
          </ul>
        </section>
        <section anchor="validating-scts" numbered="true" toc="include" removeInRFC="false" pn="section-8.1.3">
          <name slugifiedName="name-validating-scts">Validating SCTs</name>
          <t indent="0" pn="section-8.1.3-1">In order to make use of a received SCT, the TLS client <bcp14>MUST</bcp14> first validate it as
follows:</t>
          <ul spacing="normal" bare="false" empty="false" indent="3" pn="section-8.1.3-2">
            <li pn="section-8.1.3-2.1">
              <t indent="0" pn="section-8.1.3-2.1.1">Compute the signature input by constructing a <tt>TransItem</tt> of type
	      <tt>x509_entry_v2</tt> or <tt>precert_entry_v2</tt>, depending on the SCT's
	      <tt>TransItem</tt>
	      type. The <tt>TimestampedCertificateEntryDataV2</tt> structure is constructed
	      in the following manner:
              </t>
              <ul spacing="normal" bare="false" empty="false" indent="3" pn="section-8.1.3-2.1.2">
                <li pn="section-8.1.3-2.1.2.1">
                  <tt>timestamp</tt> is copied from the SCT.</li>
                <li pn="section-8.1.3-2.1.2.2">
                  <tt>tbs_certificate</tt> is the reconstructed TBSCertificate portion of
		the server certificate, as described in <xref target="reconstructing_tbscertificate" format="default" sectionFormat="of" derivedContent="Section 8.1.2"/>.</li>
                <li pn="section-8.1.3-2.1.2.3">
                  <tt>issuer_key_hash</tt> is computed as described in <xref target="tree_leaves" format="default" sectionFormat="of" derivedContent="Section 4.7"/>.</li>
                <li pn="section-8.1.3-2.1.2.4">
                  <tt>sct_extensions</tt> is copied from the SCT.</li>
              </ul>
            </li>
            <li pn="section-8.1.3-2.2">Verify the SCT's <tt>signature</tt> against the computed signature input using the
public key of the corresponding log, which is identified by the <tt>log_id</tt>. The
required signature algorithm is one of the log's parameters.</li>
          </ul>
          <t indent="0" pn="section-8.1.3-3">If the TLS client does not have the corresponding log's parameters, it cannot
attempt to validate the SCT. When evaluating compliance (see
<xref target="evaluating_compliance" format="default" sectionFormat="of" derivedContent="Section 8.1.6"/>), the TLS client will consider only those SCTs that it
was able to validate.</t>
          <t indent="0" pn="section-8.1.3-4">Note that SCT validation is not a substitute for the normal validation of the
server certificate and its chain.</t>
        </section>
        <section anchor="fetching_inclusion_proofs" numbered="true" toc="include" removeInRFC="false" pn="section-8.1.4">
          <name slugifiedName="name-fetching-inclusion-proofs">Fetching Inclusion Proofs</name>
          <t indent="0" pn="section-8.1.4-1">When a TLS client has validated a received SCT but does not yet possess
a corresponding inclusion proof, the TLS client <bcp14>MAY</bcp14> request the inclusion
proof directly from a log using <tt>get-proof-by-hash</tt> (<xref target="get-proof-by-hash" format="default" sectionFormat="of" derivedContent="Section 5.4"/>) or
<tt>get-all-by-hash</tt> (<xref target="get-all-by-hash" format="default" sectionFormat="of" derivedContent="Section 5.5"/>).</t>
          <t indent="0" pn="section-8.1.4-2">Note that fetching inclusion proofs directly from a log will disclose to the
log which TLS server the client has been communicating with. This may be
regarded as a significant privacy concern, and so it is preferable for the TLS
server to send the inclusion proofs (see <xref target="presenting_transitems" format="default" sectionFormat="of" derivedContent="Section 6.4"/>).</t>
        </section>
        <section anchor="validating_inclusion_proofs" numbered="true" toc="include" removeInRFC="false" pn="section-8.1.5">
          <name slugifiedName="name-validating-inclusion-proofs">Validating Inclusion Proofs</name>
          <t indent="0" pn="section-8.1.5-1">When a TLS client has received, or fetched, an inclusion proof (and an STH),
it <bcp14>SHOULD</bcp14> proceed to verify the inclusion proof to the provided STH.
The TLS client <bcp14>SHOULD</bcp14> also verify consistency between the provided STH
and an STH it knows about.</t>
          <t indent="0" pn="section-8.1.5-2">If the TLS client holds an STH that predates the SCT, it <bcp14>MAY</bcp14>, in the process of
auditing, request a new STH from the log (<xref target="get-sth" format="default" sectionFormat="of" derivedContent="Section 5.2"/>) and then verify it by
requesting a consistency proof (<xref target="get-sth-consistency" format="default" sectionFormat="of" derivedContent="Section 5.3"/>). Note that if the TLS
client uses <tt>get-all-by-hash</tt>, then it will already have the new STH.</t>
        </section>
        <section anchor="evaluating_compliance" numbered="true" toc="include" removeInRFC="false" pn="section-8.1.6">
          <name slugifiedName="name-evaluating-compliance">Evaluating Compliance</name>
          <t indent="0" pn="section-8.1.6-1">It is up to a client's local policy to specify the quantity and form of
evidence (SCTs, inclusion proofs, or a combination) needed to achieve
compliance and how to handle noncompliance.</t>
          <t indent="0" pn="section-8.1.6-2">A TLS client can only evaluate compliance if it has given the TLS server the
opportunity to send SCTs and inclusion proofs by any of the three mechanisms
that are mandatory to implement for CT-using TLS clients (see
<xref target="receiving_transitems" format="default" sectionFormat="of" derivedContent="Section 8.1.1"/>). Therefore, a TLS client <bcp14>MUST NOT</bcp14> evaluate compliance
if it did not include both the <tt>transparency_info</tt> and <tt>status_request</tt> TLS
extensions in the ClientHello.</t>
        </section>
      </section>
      <section anchor="monitor" numbered="true" toc="include" removeInRFC="false" pn="section-8.2">
        <name slugifiedName="name-monitor">Monitor</name>
        <t indent="0" pn="section-8.2-1">Monitors watch logs to check for correct behavior, for certificates of
interest, or for both. For example, a monitor may be configured to report on all
certificates that apply to a specific domain name when fetching new entries for
consistency validation.</t>
        <t indent="0" pn="section-8.2-2">A monitor <bcp14>MUST</bcp14> at least inspect every new entry in every log it watches, and it
<bcp14>MAY</bcp14> also choose to keep copies of entire logs.</t>
        <t indent="0" pn="section-8.2-3">To inspect all of the existing entries, the monitor <bcp14>SHOULD</bcp14> follow these steps
once for each log:</t>
        <ol spacing="normal" type="1" indent="adaptive" start="1" pn="section-8.2-4">
	  <li pn="section-8.2-4.1" derivedCounter="1.">Fetch the current STH (<xref target="get-sth" format="default" sectionFormat="of" derivedContent="Section 5.2"/>).</li>
          <li pn="section-8.2-4.2" derivedCounter="2.">Verify the STH signature.</li>
          <li pn="section-8.2-4.3" derivedCounter="3.">Fetch all the entries in the tree corresponding to the STH (<xref target="get-entries" format="default" sectionFormat="of" derivedContent="Section 5.6"/>).</li>
          <li pn="section-8.2-4.4" derivedCounter="4.">If applicable, check each entry to see if it's a certificate of interest.</li>
          <li pn="section-8.2-4.5" derivedCounter="5.">Confirm that the tree made from the fetched entries produces the same hash as
	  that in the STH.</li>
        </ol>
        <t indent="0" pn="section-8.2-5">To inspect new entries, the monitor <bcp14>SHOULD</bcp14> follow these steps
	repeatedly for each log:</t>
        <ol spacing="normal" type="1" indent="adaptive" start="1" pn="section-8.2-6">
	  <li pn="section-8.2-6.1" derivedCounter="1.">Fetch the current STH (<xref target="get-sth" format="default" sectionFormat="of" derivedContent="Section 5.2"/>). Repeat until
	  the STH changes. To allow for experimentation, this document does not specify the polling frequency.</li>
          <li pn="section-8.2-6.2" derivedCounter="2.">Verify the STH signature.</li>
          <li pn="section-8.2-6.3" derivedCounter="3.">Fetch all the new entries in the tree corresponding to the STH
	  (<xref target="get-entries" format="default" sectionFormat="of" derivedContent="Section 5.6"/>). If they remain unavailable for an
	  extended period, then this should be viewed as misbehavior on the part of the
	  log.</li>
          <li pn="section-8.2-6.4" derivedCounter="4.">If applicable, check each entry to see if it's a certificate of interest.</li>
          <li pn="section-8.2-6.5" derivedCounter="5.">
            <t indent="0" pn="section-8.2-6.5.1">Either:</t>
            <ol spacing="normal" type="a" indent="adaptive" start="1" pn="section-8.2-6.5.2">
	      <li pn="section-8.2-6.5.2.1" derivedCounter="a.">Verify that the updated list of all entries generates a tree with the
	      same hash as the new STH.</li>
            </ol>
            <t indent="0" pn="section-8.2-6.5.3">Or, if it is not keeping all log entries:</t>
            <ol spacing="normal" type="a" indent="adaptive" start="1" pn="section-8.2-6.5.4">
	      <li pn="section-8.2-6.5.4.1" derivedCounter="a.">Fetch a consistency proof for the new STH with the previous STH
	      (<xref target="get-sth-consistency" format="default" sectionFormat="of" derivedContent="Section 5.3"/>).</li>
              <li pn="section-8.2-6.5.4.2" derivedCounter="b.">Verify the consistency proof.</li>
              <li pn="section-8.2-6.5.4.3" derivedCounter="c.">Verify that the new entries generate the corresponding elements in the
	      consistency proof.</li>
            </ol>
          </li>
          <li pn="section-8.2-6.6" derivedCounter="6.">Repeat from Step 1.</li>
        </ol>
      </section>
      <section anchor="auditing" numbered="true" toc="include" removeInRFC="false" pn="section-8.3">
        <name slugifiedName="name-auditing">Auditing</name>
        <t indent="0" pn="section-8.3-1">Auditing ensures that the current published state of a log is reachable from
previously published states that are known to be good and that the promises
made by the log, in the form of SCTs, have been kept. Audits are performed by
monitors or TLS clients.</t>
        <t indent="0" pn="section-8.3-2">In particular, there are four properties of log behavior that should be checked:</t>
        <ul spacing="normal" bare="false" empty="false" indent="3" pn="section-8.3-3">
          <li pn="section-8.3-3.1">the Maximum Merge Delay (MMD)</li>
          <li pn="section-8.3-3.2">the STH Frequency Count</li>
          <li pn="section-8.3-3.3">the append-only property</li>
          <li pn="section-8.3-3.4">the consistency of the log view presented to all query sources</li>
        </ul>
        <t indent="0" pn="section-8.3-4">A benign, conformant log publishes a series of STHs over time, each derived from
the previous STH and the submitted entries incorporated into the log since
publication of the previous STH. This can be proven through auditing of STHs.
SCTs returned to TLS clients can be audited by verifying against the
accompanying certificate and using Merkle inclusion proofs against the log's
Merkle Tree.</t>
        <t indent="0" pn="section-8.3-5">The action taken by the auditor, if an audit fails, is not specified, but note
that in general, if an audit fails, the auditor is in possession of signed proof of
the log's misbehavior.</t>
        <t indent="0" pn="section-8.3-6">A monitor (<xref target="monitor" format="default" sectionFormat="of" derivedContent="Section 8.2"/>) can audit by verifying the consistency of STHs it
receives, ensuring that each entry can be fetched and that the STH is indeed the
result of making a tree from all fetched entries.</t>
        <t indent="0" pn="section-8.3-7">A TLS client (<xref target="tls_clients" format="default" sectionFormat="of" derivedContent="Section 8.1"/>) can audit by verifying an SCT against any STH
dated after the SCT timestamp + the Maximum Merge Delay by requesting a Merkle
inclusion proof (<xref target="get-proof-by-hash" format="default" sectionFormat="of" derivedContent="Section 5.4"/>). It can also verify that the SCT
corresponds to the server certificate it arrived with (i.e., the log entry is
that certificate or is a precertificate corresponding to that certificate).</t>
        <t indent="0" pn="section-8.3-8">Checking of the consistency of the log view presented to all entities is more
difficult to perform because it requires a way to share log responses among a
set of CT-using entities and is discussed in <xref target="misbehaving_logs" format="default" sectionFormat="of" derivedContent="Section 11.3"/>.</t>
      </section>
    </section>
    <section anchor="algorithm-agility" numbered="true" toc="include" removeInRFC="false" pn="section-9">
      <name slugifiedName="name-algorithm-agility">Algorithm Agility</name>
      <t indent="0" pn="section-9-1">It is not possible for a log to change either of its algorithms part way through
its lifetime:</t>
      <dl newline="false" spacing="normal" indent="3" pn="section-9-2">
        <dt pn="section-9-2.1">Signature algorithm:</dt>
        <dd pn="section-9-2.2">SCT signatures must remain valid so signature algorithms can only be added,
	not removed.</dd>
        <dt pn="section-9-2.3">Hash algorithm:</dt>
        <dd pn="section-9-2.4">A log would have to support the old and new hash algorithms to allow
	backwards compatibility with clients that are not aware of a hash algorithm
	change.</dd>
      </dl>
      <t indent="0" pn="section-9-3">Allowing multiple signature or hash algorithms for a log would require that all
data structures support it and would significantly complicate client
implementation, which is why it is not supported by this document.</t>
      <t indent="0" pn="section-9-4">If it should become necessary to deprecate an algorithm used by a live log, then
the log <bcp14>MUST</bcp14> be frozen, as specified in <xref target="log_shutdown" format="default" sectionFormat="of" derivedContent="Section 4.13"/>, and a new log <bcp14>SHOULD</bcp14> be
started. Certificates in the frozen log that have not yet expired and require
new SCTs <bcp14>SHOULD</bcp14> be submitted to the new log and the SCTs from that log used
instead.</t>
    </section>
    <section anchor="iana-considerations" numbered="true" toc="include" removeInRFC="false" pn="section-10">
      <name slugifiedName="name-iana-considerations">IANA Considerations</name>
      <t indent="0" pn="section-10-1">The assignment policy criteria mentioned in this section refer to the policies
outlined in <xref target="RFC8126" format="default" sectionFormat="of" derivedContent="RFC8126"/>.</t>
      <section anchor="additions-to-existing-registries" numbered="true" toc="include" removeInRFC="false" pn="section-10.1">
        <name slugifiedName="name-additions-to-existing-regis">Additions to Existing Registries</name>
        <t indent="0" pn="section-10.1-1">This subsection defines additions to existing registries.</t>
        <section anchor="new-entry-to-the-tls-extensiontype-registry" numbered="true" toc="include" removeInRFC="false" pn="section-10.1.1">
          <name slugifiedName="name-new-entry-to-the-tls-extens">New Entry to the TLS ExtensionType Registry</name>
          <t indent="0" pn="section-10.1.1-1">IANA has added the following entry
to the "TLS ExtensionType Values" registry defined in <xref target="RFC8446" format="default" sectionFormat="of" derivedContent="RFC8446"/>,
with an assigned Value:</t>
          <table align="center" pn="table-7">
            <thead>
              <tr>
                <th align="left" colspan="1" rowspan="1">Value</th>
                <th align="left" colspan="1" rowspan="1">Extension Name</th>
                <th align="left" colspan="1" rowspan="1">TLS 1.3</th>
                <th align="left" colspan="1" rowspan="1">DTLS-Only</th>
                <th align="left" colspan="1" rowspan="1">Recommended</th>
                <th align="left" colspan="1" rowspan="1">Reference</th>
              </tr>
            </thead>
            <tbody>
              <tr>
                <td align="left" colspan="1" rowspan="1">52</td>
                <td align="left" colspan="1" rowspan="1">transparency_info</td>
                <td align="left" colspan="1" rowspan="1">CH, CR, CT</td>
                <td align="left" colspan="1" rowspan="1">N</td>
                <td align="left" colspan="1" rowspan="1">Y</td>
                <td align="left" colspan="1" rowspan="1">RFC 9162</td>
              </tr>
            </tbody>
          </table>
        </section>
        <section anchor="urn-sub-namespace-for-trans-urnietfparamstrans" numbered="true" toc="include" removeInRFC="false" pn="section-10.1.2">
          <name slugifiedName="name-urn-sub-namespace-for-trans">URN Sub-namespace for TRANS (urn:ietf:params:trans)</name>
          <t indent="0" pn="section-10.1.2-1">IANA has added a new entry in the
	  "IETF URN Sub-namespace for Registered Protocol Parameter Identifiers"
	  registry, following the template in <xref target="RFC3553" format="default" sectionFormat="of" derivedContent="RFC3553"/>:</t>
          <dl newline="false" spacing="compact" indent="3" pn="section-10.1.2-2">
            <dt pn="section-10.1.2-2.1">Registry name:</dt>
            <dd pn="section-10.1.2-2.2">trans</dd>
            <dt pn="section-10.1.2-2.3">Specification:</dt>
            <dd pn="section-10.1.2-2.4">RFC 9162</dd>
            <dt pn="section-10.1.2-2.5">Repository:</dt>
            <dd pn="section-10.1.2-2.6">
              <eref brackets="angle" target="https://www.iana.org/assignments/trans"/></dd>
            <dt pn="section-10.1.2-2.7">Index value:</dt>
            <dd pn="section-10.1.2-2.8">No transformation needed.</dd>
          </dl>
        </section>
      </section>
      <section anchor="new-ct-related-registries" numbered="true" toc="include" removeInRFC="false" pn="section-10.2">
        <name slugifiedName="name-new-ct-related-registries">New CT-Related Registries</name>
        <t indent="0" pn="section-10.2-1">IANA has added a new protocol registry, "Public Notary
Transparency", to the list that appears at
<eref brackets="angle" target="https://www.iana.org/assignments/"/></t>
        <t indent="0" pn="section-10.2-2">The rest of this section defines the subregistries that have been created within the new "Public Notary Transparency" registry.</t>
        <section anchor="hash_algorithms" numbered="true" toc="include" removeInRFC="false" pn="section-10.2.1">
          <name slugifiedName="name-hash-algorithms">Hash Algorithms</name>
          <t indent="0" pn="section-10.2.1-1">IANA has established a registry of hash algorithm values, named
"Hash Algorithms", with the following registration procedures:</t>
          <table align="center" pn="table-8">
            <thead>
              <tr>
                <th align="left" colspan="1" rowspan="1">Range</th>
                <th align="left" colspan="1" rowspan="1">Registration Procedures</th>
              </tr>
            </thead>
            <tbody>
              <tr>
                <td align="left" colspan="1" rowspan="1">0x00-0xDF</td>
                <td align="left" colspan="1" rowspan="1">Specification Required</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">0xE0-0xEF</td>
                <td align="left" colspan="1" rowspan="1">Experimental Use</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">0xF0-0xFF</td>
                <td align="left" colspan="1" rowspan="1">Private Use</td>
              </tr>
            </tbody>
          </table>
          <t indent="0" pn="section-10.2.1-3">The "Hash Algorithms" registry initially consists of:</t>
          <table align="center" pn="table-9">
            <thead>
              <tr>
                <th align="left" colspan="1" rowspan="1">Value</th>
                <th align="left" colspan="1" rowspan="1">Hash Algorithm</th>
                <th align="left" colspan="1" rowspan="1">OID</th>
                <th align="left" colspan="1" rowspan="1">Reference</th>
              </tr>
            </thead>
            <tbody>
              <tr>
                <td align="left" colspan="1" rowspan="1">0x00</td>
                <td align="left" colspan="1" rowspan="1">SHA-256</td>
                <td align="left" colspan="1" rowspan="1">2.16.840.1.101.3.4.2.1</td>
                <td align="left" colspan="1" rowspan="1">
                  <xref target="RFC6234" format="default" sectionFormat="of" derivedContent="RFC6234"/></td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">0x01 - 0xDF</td>
                <td align="left" colspan="1" rowspan="1">Unassigned</td>
                <td align="left" colspan="1" rowspan="1"> </td>
                <td align="left" colspan="1" rowspan="1">RFC 9162</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">0xE0 - 0xEF</td>
                <td align="left" colspan="1" rowspan="1">Reserved for Experimental Use</td>
                <td align="left" colspan="1" rowspan="1"> </td>
                <td align="left" colspan="1" rowspan="1">RFC 9162</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">0xF0 - 0xFF</td>
                <td align="left" colspan="1" rowspan="1">Reserved for Private Use</td>
                <td align="left" colspan="1" rowspan="1"> </td>
                <td align="left" colspan="1" rowspan="1">RFC 9162</td>
              </tr>
            </tbody>
          </table>
          <t indent="0" pn="section-10.2.1-5">The designated expert(s) should ensure that the proposed algorithm has a public
specification and is suitable for use as a cryptographic hash algorithm with no
known preimage or collision attacks. These attacks can damage the integrity of
the log.</t>
        </section>
        <section anchor="signature_algorithms" numbered="true" toc="include" removeInRFC="false" pn="section-10.2.2">
          <name slugifiedName="name-signature-algorithms">Signature Algorithms</name>
          <t indent="0" pn="section-10.2.2-1">IANA has established a registry of signature algorithm values, named
"Signature Algorithms".</t>
          <t indent="0" pn="section-10.2.2-2">The following notes have been added to the registry:</t>
          <blockquote pn="section-10.2.2-3">
            <dl newline="true" indent="3" spacing="normal" pn="section-10.2.2-3.1">
              <dt pn="section-10.2.2-3.1.1"><strong>Note:</strong></dt>
              <dd pn="section-10.2.2-3.1.2">This is a subset of the "TLS SignatureScheme" registry, limited to those
	    algorithms that are appropriate for CT. A major advantage of this is
	    leveraging the expertise of the TLS Working Group and its designated
	    expert(s).</dd>
            </dl>
          </blockquote>
          <blockquote pn="section-10.2.2-4">
            <dl newline="true" indent="3" spacing="normal" pn="section-10.2.2-4.1">
              <dt pn="section-10.2.2-4.1.1"><strong>Note:</strong></dt>
              <dd pn="section-10.2.2-4.1.2">The value <tt>0x0403</tt> appears twice. While this may be confusing,
	    it is okay because the verification
	    process is the same for both algorithms, and the choice of which to use
	    when generating a signature is purely internal to the log server.</dd>
            </dl>
          </blockquote>
          <t indent="0" pn="section-10.2.2-5">The "Signature Algorithms" registry has the following registration procedures:</t>
          <table align="center" pn="table-10">
            <thead>
              <tr>
                <th align="left" colspan="1" rowspan="1">Range</th>
                <th align="left" colspan="1" rowspan="1">Registration Procedures</th>
              </tr>
            </thead>
            <tbody>
              <tr>
                <td align="left" colspan="1" rowspan="1">0x0000-0x0807</td>
                <td align="left" colspan="1" rowspan="1">Specification Required</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">0x0808-0xFDFF</td>
                <td align="left" colspan="1" rowspan="1">Expert Review</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">0xFE00-0xFEFF</td>
                <td align="left" colspan="1" rowspan="1">Experimental Use</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">0xFF00-0xFFFF</td>
                <td align="left" colspan="1" rowspan="1">Private Use</td>
              </tr>
            </tbody>
          </table>
          <t indent="0" pn="section-10.2.2-7">The "Signature Algorithms" registry initially consists of:</t>
          <table align="center" pn="table-11">
            <thead>
              <tr>
                <th align="left" colspan="1" rowspan="1">SignatureScheme Value</th>
                <th align="left" colspan="1" rowspan="1">Signature Algorithm</th>
                <th align="left" colspan="1" rowspan="1">Reference</th>
              </tr>
            </thead>
            <tbody>
              <tr>
                <td align="left" colspan="1" rowspan="1">0x0000 - 0x0402</td>
                <td align="left" colspan="1" rowspan="1">Unassigned</td>
                <td align="left" colspan="1" rowspan="1"> </td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">ecdsa_secp256r1_sha256 (0x0403)</td>
                <td align="left" colspan="1" rowspan="1">ECDSA (NIST P-256) with SHA-256</td>
                <td align="left" colspan="1" rowspan="1">
                  <xref target="FIPS186-4" format="default" sectionFormat="of" derivedContent="FIPS186-4"/></td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">ecdsa_secp256r1_sha256 (0x0403)</td>
                <td align="left" colspan="1" rowspan="1">Deterministic ECDSA (NIST P-256) with HMAC-SHA256</td>
                <td align="left" colspan="1" rowspan="1">
                  <xref target="RFC6979" format="default" sectionFormat="of" derivedContent="RFC6979"/></td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">0x0404 - 0x0806</td>
                <td align="left" colspan="1" rowspan="1">Unassigned</td>
                <td align="left" colspan="1" rowspan="1"> </td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">ed25519 (0x0807)</td>
                <td align="left" colspan="1" rowspan="1">Ed25519 (PureEdDSA with the edwards25519 curve)</td>
                <td align="left" colspan="1" rowspan="1">
                  <xref target="RFC8032" format="default" sectionFormat="of" derivedContent="RFC8032"/></td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">0x0808 - 0xFDFF</td>
                <td align="left" colspan="1" rowspan="1">Unassigned</td>
                <td align="left" colspan="1" rowspan="1"> </td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">0xFE00 - 0xFEFF</td>
                <td align="left" colspan="1" rowspan="1">Reserved for Experimental Use</td>
                <td align="left" colspan="1" rowspan="1">RFC 9162</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">0xFF00 - 0xFFFF</td>
                <td align="left" colspan="1" rowspan="1">Reserved for Private Use</td>
                <td align="left" colspan="1" rowspan="1">RFC 9162</td>
              </tr>
            </tbody>
          </table>
          <t indent="0" pn="section-10.2.2-9">The designated expert(s) should ensure that the proposed algorithm has a public
specification, has a value assigned to it in the "TLS SignatureScheme" registry
(which was established by <xref target="RFC8446" format="default" sectionFormat="of" derivedContent="RFC8446"/>), and is suitable for use as a
cryptographic signature algorithm.</t>
        </section>
        <section anchor="versioned_trans_types" numbered="true" toc="include" removeInRFC="false" pn="section-10.2.3">
          <name slugifiedName="name-versionedtranstypes">VersionedTransTypes</name>
          <t indent="0" pn="section-10.2.3-1">IANA has established a registry of <tt>VersionedTransType</tt> values, named
"VersionedTransTypes".</t>
          <t indent="0" pn="section-10.2.3-2">The following note has been added:</t>
          <blockquote pn="section-10.2.3-3">
            <dl newline="true" indent="3" spacing="normal" pn="section-10.2.3-3.1">
              <dt pn="section-10.2.3-3.1.1"><strong>Note:</strong></dt>
              <dd pn="section-10.2.3-3.1.2">The range 0x0000..0x00FF is reserved so that v1 SCTs are distinguishable from
	    v2 SCTs and other <tt>TransItem</tt> structures.</dd>
            </dl>
          </blockquote>
          <t indent="0" pn="section-10.2.3-4">The registration procedures for the "VersionedTransTypes" registry are the following:</t>
          <table align="center" pn="table-12">
            <thead>
              <tr>
                <th align="left" colspan="1" rowspan="1">Range</th>
                <th align="left" colspan="1" rowspan="1">Registration Procedures</th>
              </tr>
            </thead>
            <tbody>
              <tr>
                <td align="left" colspan="1" rowspan="1">0x0100-0xDFFF</td>
                <td align="left" colspan="1" rowspan="1">Specification Required</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">0xE000-0xEFFF</td>
                <td align="left" colspan="1" rowspan="1">Experimental Use</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">0xF000-0xFFFF</td>
                <td align="left" colspan="1" rowspan="1">Private Use</td>
              </tr>
            </tbody>
          </table>
          <t indent="0" pn="section-10.2.3-6">The "VersionedTransTypes" registry initially consists of:</t>
          <table align="center" pn="table-13">
            <thead>
              <tr>
                <th align="left" colspan="1" rowspan="1">Value</th>
                <th align="left" colspan="1" rowspan="1">Type and Version</th>
                <th align="left" colspan="1" rowspan="1">Reference</th>
              </tr>
            </thead>
            <tbody>
              <tr>
                <td align="left" colspan="1" rowspan="1">0x0000 - 0x00FF</td>
                <td align="left" colspan="1" rowspan="1">Reserved</td>
                <td align="left" colspan="1" rowspan="1">
                  <xref target="RFC6962" format="default" sectionFormat="of" derivedContent="RFC6962"/></td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">0x0100</td>
                <td align="left" colspan="1" rowspan="1">x509_entry_v2</td>
                <td align="left" colspan="1" rowspan="1">RFC 9162</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">0x0101</td>
                <td align="left" colspan="1" rowspan="1">precert_entry_v2</td>
                <td align="left" colspan="1" rowspan="1">RFC 9162</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">0x0102</td>
                <td align="left" colspan="1" rowspan="1">x509_sct_v2</td>
                <td align="left" colspan="1" rowspan="1">RFC 9162</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">0x0103</td>
                <td align="left" colspan="1" rowspan="1">precert_sct_v2</td>
                <td align="left" colspan="1" rowspan="1">RFC 9162</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">0x0104</td>
                <td align="left" colspan="1" rowspan="1">signed_tree_head_v2</td>
                <td align="left" colspan="1" rowspan="1">RFC 9162</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">0x0105</td>
                <td align="left" colspan="1" rowspan="1">consistency_proof_v2</td>
                <td align="left" colspan="1" rowspan="1">RFC 9162</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">0x0106</td>
                <td align="left" colspan="1" rowspan="1">inclusion_proof_v2</td>
                <td align="left" colspan="1" rowspan="1">RFC 9162</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">0x0107 - 0xDFFF</td>
                <td align="left" colspan="1" rowspan="1">Unassigned</td>
                <td align="left" colspan="1" rowspan="1"> </td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">0xE000 - 0xEFFF</td>
                <td align="left" colspan="1" rowspan="1">Reserved for Experimental Use</td>
                <td align="left" colspan="1" rowspan="1">RFC 9162</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">0xF000 - 0xFFFF</td>
                <td align="left" colspan="1" rowspan="1">Reserved for Private Use</td>
                <td align="left" colspan="1" rowspan="1">RFC 9162</td>
              </tr>
            </tbody>
          </table>
          <t indent="0" pn="section-10.2.3-8">The designated expert(s) should review the public specification to ensure that it is
detailed enough to ensure implementation interoperability.</t>
        </section>
        <section anchor="log_artifact_extension_registry" numbered="true" toc="include" removeInRFC="false" pn="section-10.2.4">
          <name slugifiedName="name-log-artifact-extensions-2">Log Artifact Extensions</name>
          <t indent="0" pn="section-10.2.4-1">IANA has established a registry of <tt>ExtensionType</tt> values, named "Log
Artifact Extensions".</t>
          <t indent="0" pn="section-10.2.4-2">The registration procedures for the "Log Artifact Extensions" registry are the following:</t>
          <table align="center" pn="table-14">
            <thead>
              <tr>
                <th align="left" colspan="1" rowspan="1">Range</th>
                <th align="left" colspan="1" rowspan="1">Registration Procedures</th>
              </tr>
            </thead>
            <tbody>
              <tr>
                <td align="left" colspan="1" rowspan="1">0x0000-0xDFFF</td>
                <td align="left" colspan="1" rowspan="1">Specification Required</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">0xE000-0xEFFF</td>
                <td align="left" colspan="1" rowspan="1">Experimental Use</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">0xF000-0xFFFF</td>
                <td align="left" colspan="1" rowspan="1">Private Use</td>
              </tr>
            </tbody>
          </table>
          <t indent="0" pn="section-10.2.4-4">The "Log Artifact Extensions" registry initially consists of:</t>
          <table align="center" pn="table-15">
            <thead>
              <tr>
                <th align="left" colspan="1" rowspan="1">ExtensionType</th>
                <th align="left" colspan="1" rowspan="1">Status</th>
                <th align="left" colspan="1" rowspan="1">Use</th>
                <th align="left" colspan="1" rowspan="1">Reference</th>
              </tr>
            </thead>
            <tbody>
              <tr>
                <td align="left" colspan="1" rowspan="1">0x0000 - 0xDFFF</td>
                <td align="left" colspan="1" rowspan="1">Unassigned</td>
                <td align="left" colspan="1" rowspan="1">n/a</td>
                <td align="left" colspan="1" rowspan="1"> </td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">0xE000 - 0xEFFF</td>
                <td align="left" colspan="1" rowspan="1">Reserved for Experimental Use</td>
                <td align="left" colspan="1" rowspan="1">n/a</td>
                <td align="left" colspan="1" rowspan="1">RFC 9162</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">0xF000 - 0xFFFF</td>
                <td align="left" colspan="1" rowspan="1">Reserved for Private Use</td>
                <td align="left" colspan="1" rowspan="1">n/a</td>
                <td align="left" colspan="1" rowspan="1">RFC 9162</td>
              </tr>
            </tbody>
          </table>
          <t indent="0" pn="section-10.2.4-6">The "Use" column should contain one or both of the following values:</t>
          <ul spacing="normal" bare="false" empty="false" indent="3" pn="section-10.2.4-7">
            <li pn="section-10.2.4-7.1">"SCT", for extensions specified for use in Signed Certificate Timestamps.</li>
            <li pn="section-10.2.4-7.2">"STH", for extensions specified for use in Signed Tree Heads.</li>
          </ul>
          <t indent="0" pn="section-10.2.4-8">The designated expert(s) should review the public specification to ensure that it is
detailed enough to ensure implementation interoperability. They should
also verify that the extension is appropriate to the contexts in which it is
specified to be used (SCT, STH, or both).</t>
        </section>
        <section anchor="log_id_registry" numbered="true" toc="include" removeInRFC="false" pn="section-10.2.5">
          <name slugifiedName="name-log-ids">Log IDs</name>
          <t indent="0" pn="section-10.2.5-1">IANA has established a registry of Log IDs, named "Log IDs".</t>
          <t indent="0" pn="section-10.2.5-2">The registry's registration procedure is First Come First Served.</t>
          <t indent="0" pn="section-10.2.5-3">The "Log IDs" registry initially consists of:</t>
          <table align="center" pn="table-16">
            <thead>
              <tr>
                <th align="left" colspan="1" rowspan="1">Log ID</th>
                <th align="left" colspan="1" rowspan="1">Log Base URL</th>
                <th align="left" colspan="1" rowspan="1">Log Operator</th>
                <th align="left" colspan="1" rowspan="1">Reference</th>
              </tr>
            </thead>
            <tbody>
              <tr>
                <td align="left" colspan="1" rowspan="1">1.3.101.8192 - 1.3.101.16383</td>
                <td align="left" colspan="1" rowspan="1">Unassigned</td>
                <td align="left" colspan="1" rowspan="1">Unassigned</td>
                <td align="left" colspan="1" rowspan="1"> </td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">1.3.101.80.0 - 1.3.101.80.*</td>
                <td align="left" colspan="1" rowspan="1">Unassigned</td>
                <td align="left" colspan="1" rowspan="1">Unassigned</td>
                <td align="left" colspan="1" rowspan="1"> </td>
              </tr>
            </tbody>
          </table>
          <t indent="0" pn="section-10.2.5-5">The following notes have been added to the registry:</t>
          <blockquote pn="section-10.2.5-6">
            <dl newline="true" indent="3" spacing="normal" pn="section-10.2.5-6.1">
              <dt pn="section-10.2.5-6.1.1"><strong>Note:</strong></dt>
              <dd pn="section-10.2.5-6.1.2">All OIDs in the range from 1.3.101.8192 to 1.3.101.16383 have been set aside
for Log IDs.
This is a limited resource of 8,192 OIDs, each of which has an encoded length of
4 octets.</dd>
            </dl>
          </blockquote>
          <blockquote pn="section-10.2.5-7">
            <dl newline="true" indent="3" spacing="normal" pn="section-10.2.5-7.1">
              <dt pn="section-10.2.5-7.1.1"><strong>Note:</strong></dt>
              <dd pn="section-10.2.5-7.1.2">The 1.3.101.80 arc has also been set aside for Log IDs.
This is an unlimited resource, but only
the 128 OIDs from 1.3.101.80.0 to 1.3.101.80.127 have an encoded length of only
4 octets.</dd>
            </dl>
          </blockquote>
          <t indent="0" pn="section-10.2.5-8">Each application for the allocation of a Log ID <bcp14>MUST</bcp14> be accompanied by:</t>
          <ul spacing="normal" bare="false" empty="false" indent="3" pn="section-10.2.5-9">
            <li pn="section-10.2.5-9.1">the Log's Base URL (see <xref target="log_parameters" format="default" sectionFormat="of" derivedContent="Section 4.1"/>) and</li>
            <li pn="section-10.2.5-9.2">the Log Operator's contact details.</li>
          </ul>
          <t indent="0" pn="section-10.2.5-10">IANA is asked to reject any request to update a Log ID or Log Base URL in this
registry because these fields are immutable (see <xref target="log_parameters" format="default" sectionFormat="of" derivedContent="Section 4.1"/>).</t>
          <t indent="0" pn="section-10.2.5-11">IANA is asked to accept requests from log operators to update their contact
details in this registry.</t>
          <t indent="0" pn="section-10.2.5-12">Since log operators can choose to not use this registry (see <xref target="log_id" format="default" sectionFormat="of" derivedContent="Section 4.4"/>), it is
not expected to be a global directory of all logs.</t>
        </section>
        <section anchor="error-types-registry" numbered="true" toc="include" removeInRFC="false" pn="section-10.2.6">
          <name slugifiedName="name-error-types">Error Types</name>
          <t indent="0" pn="section-10.2.6-1">IANA has created a new registry for errors,
the "Error Types" registry.</t>
          <t indent="0" pn="section-10.2.6-2">The registration procedure for this registry is Specification Required.</t>
          <t indent="0" pn="section-10.2.6-3">This registry has the following three fields:</t>
          <table align="center" pn="table-17">
            <thead>
              <tr>
                <th align="left" colspan="1" rowspan="1">Field Name</th>
                <th align="left" colspan="1" rowspan="1">Type</th>
                <th align="left" colspan="1" rowspan="1">Reference</th>
              </tr>
            </thead>
            <tbody>
              <tr>
                <td align="left" colspan="1" rowspan="1">Identifier</td>
                <td align="left" colspan="1" rowspan="1">string</td>
                <td align="left" colspan="1" rowspan="1">RFC 9162</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">Meaning</td>
                <td align="left" colspan="1" rowspan="1">string</td>
                <td align="left" colspan="1" rowspan="1">RFC 9162</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">Reference</td>
                <td align="left" colspan="1" rowspan="1">string</td>
                <td align="left" colspan="1" rowspan="1">RFC 9162</td>
              </tr>
            </tbody>
          </table>
          <t indent="0" pn="section-10.2.6-5">The initial values of the "Error Types" registry, which are taken from the text in <xref target="client_messages" format="default" sectionFormat="of" derivedContent="Section 5"/>, are as follows:</t>
          <table align="center" pn="table-18">
            <thead>
              <tr>
                <th align="left" colspan="1" rowspan="1">Identifier</th>
                <th align="left" colspan="1" rowspan="1">Meaning</th>
                <th align="left" colspan="1" rowspan="1">Reference</th>
              </tr>
            </thead>
            <tbody>
              <tr>
                <td align="left" colspan="1" rowspan="1">malformed</td>
                <td align="left" colspan="1" rowspan="1">The request could not be parsed.</td>
                <td align="left" colspan="1" rowspan="1">RFC 9162</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">badSubmission</td>
                <td align="left" colspan="1" rowspan="1">
                  <tt>submission</tt> is neither a valid certificate nor a
		valid precertificate.</td>
                <td align="left" colspan="1" rowspan="1">RFC 9162</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">badType</td>
                <td align="left" colspan="1" rowspan="1">
                  <tt>type</tt> is neither 1 nor 2.</td>
                <td align="left" colspan="1" rowspan="1">RFC 9162</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">badChain</td>
                <td align="left" colspan="1" rowspan="1">The first element of <tt>chain</tt> is not the certifier of
		the <tt>submission</tt>, or the second element does not certify the first,
		etc.</td>
                <td align="left" colspan="1" rowspan="1">RFC 9162</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">badCertificate</td>
                <td align="left" colspan="1" rowspan="1">One or more certificates in <tt>chain</tt> are not valid
		(e.g., not properly encoded).</td>
                <td align="left" colspan="1" rowspan="1">RFC 9162</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">unknownAnchor</td>
                <td align="left" colspan="1" rowspan="1">The last element of <tt>chain</tt> (or, if <tt>chain</tt> is
		an empty array, the <tt>submission</tt>) is not, nor is it certified
		by, an accepted trust anchor.</td>
                <td align="left" colspan="1" rowspan="1">RFC 9162</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">shutdown</td>
                <td align="left" colspan="1" rowspan="1">The log is no longer accepting submissions.</td>
                <td align="left" colspan="1" rowspan="1">RFC 9162</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">firstUnknown</td>
                <td align="left" colspan="1" rowspan="1">
                  <tt>first</tt> is before the latest known STH but is not
		from an existing STH.</td>
                <td align="left" colspan="1" rowspan="1">RFC 9162</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">secondUnknown</td>
                <td align="left" colspan="1" rowspan="1">
                  <tt>second</tt> is before the latest known STH but is not
		from an existing STH.</td>
                <td align="left" colspan="1" rowspan="1">RFC 9162</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">secondBeforeFirst</td>
                <td align="left" colspan="1" rowspan="1">
                  <tt>second</tt> is smaller than <tt>first</tt>.</td>
                <td align="left" colspan="1" rowspan="1">RFC 9162</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">hashUnknown</td>
                <td align="left" colspan="1" rowspan="1">
                  <tt>hash</tt> is not the hash of a known leaf (may be caused
		by skew or by a known certificate not yet merged).</td>
                <td align="left" colspan="1" rowspan="1">RFC 9162</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">treeSizeUnknown</td>
                <td align="left" colspan="1" rowspan="1">
                  <tt>hash</tt> is before the latest known STH but is not from
		an existing STH.</td>
                <td align="left" colspan="1" rowspan="1">RFC 9162</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">startUnknown</td>
                <td align="left" colspan="1" rowspan="1">
                  <tt>start</tt> is greater than the number of entries in the
		Merkle Tree.</td>
                <td align="left" colspan="1" rowspan="1">RFC 9162</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">endBeforeStart</td>
                <td align="left" colspan="1" rowspan="1">
                  <tt>start</tt> cannot be greater than <tt>end</tt>.</td>
                <td align="left" colspan="1" rowspan="1">RFC 9162</td>
              </tr>
            </tbody>
          </table>
        </section>
      </section>
      <section anchor="oid-assignment" numbered="true" toc="include" removeInRFC="false" pn="section-10.3">
        <name slugifiedName="name-oid-assignment">OID Assignment</name>
        <t indent="0" pn="section-10.3-1">IANA has assigned an object identifier from the "SMI
Security for PKIX Module Identifier" registry to identify the
ASN.1 module in <xref target="asn1_module" format="default" sectionFormat="of" derivedContent="Appendix B"/> of this document.</t>
        <table align="center" pn="table-19">
          <thead>
            <tr>
              <th align="left" colspan="1" rowspan="1">Decimal</th>
              <th align="left" colspan="1" rowspan="1">Description</th>
              <th align="left" colspan="1" rowspan="1">References</th>
            </tr>
          </thead>
          <tbody>
            <tr>
              <td align="left" colspan="1" rowspan="1">102</td>
              <td align="left" colspan="1" rowspan="1">id-mod-public-notary-v2</td>
              <td align="left" colspan="1" rowspan="1">RFC 9162</td>
            </tr>
          </tbody>
        </table>
      </section>
    </section>
    <section anchor="security-considerations" numbered="true" toc="include" removeInRFC="false" pn="section-11">
      <name slugifiedName="name-security-considerations">Security Considerations</name>
      <t indent="0" pn="section-11-1">With CAs, logs, and servers performing the actions described here, TLS clients
can use logs and signed timestamps to reduce the likelihood that they will
accept misissued certificates. If a server presents a valid signed timestamp for
a certificate, then the client knows that a log has committed to publishing the
certificate. From this, the client knows that monitors acting for the subject of
the certificate have had some time to notice the misissuance and take some
action, such as asking a CA to revoke a misissued certificate. A signed
timestamp does not guarantee this, though, since appropriate monitors might not
have checked the logs or the CA might have refused to revoke the certificate.</t>
      <t indent="0" pn="section-11-2">In addition, if TLS clients will not accept unlogged certificates, then site
owners will have a greater incentive to submit certificates to logs, possibly
with the assistance of their CA, increasing the overall transparency of the
system.</t>
      <section anchor="misissued-certificates" numbered="true" toc="include" removeInRFC="false" pn="section-11.1">
        <name slugifiedName="name-misissued-certificates">Misissued Certificates</name>
        <t indent="0" pn="section-11.1-1">Misissued certificates that have not been publicly logged, and thus do not have
a valid SCT, are not considered compliant. Misissued certificates that do have
an SCT from a log will appear in that public log within the Maximum Merge Delay,
assuming the log is operating correctly. Since a log is allowed to serve an STH
of any age up to the MMD, the maximum period of time during which a misissued
certificate can be used without being available for audit is twice the MMD.</t>
      </section>
      <section anchor="detection-of-misissue" numbered="true" toc="include" removeInRFC="false" pn="section-11.2">
        <name slugifiedName="name-detection-of-misissue">Detection of Misissue</name>
        <t indent="0" pn="section-11.2-1">The logs do not themselves detect misissued certificates; they rely instead on
interested parties, such as domain owners, to monitor them and take corrective
action when a misissue is detected.</t>
      </section>
      <section anchor="misbehaving_logs" numbered="true" toc="include" removeInRFC="false" pn="section-11.3">
        <name slugifiedName="name-misbehaving-logs">Misbehaving Logs</name>
        <t indent="0" pn="section-11.3-1">A log can misbehave in several ways. Examples include the following: failing to incorporate a
certificate with an SCT in the Merkle Tree within the MMD; presenting different,
conflicting views of the Merkle Tree at different times and/or to different
parties; issuing STHs too frequently; mutating the signature of a logged
certificate; and failing to present a chain containing the certifier of a logged
certificate.</t>
        <t indent="0" pn="section-11.3-2">Violation of the MMD contract is detected by log clients requesting a Merkle
inclusion proof (<xref target="get-proof-by-hash" format="default" sectionFormat="of" derivedContent="Section 5.4"/>) for each observed SCT. These checks can
be asynchronous and need only be done once per certificate. However, note that
there may be privacy concerns (see <xref target="fetching_inclusion_proofs" format="default" sectionFormat="of" derivedContent="Section 8.1.4"/>).</t>
        <t indent="0" pn="section-11.3-3">Violation of the append-only property or the STH issuance rate limit can be
	detected by multiple clients comparing their instances of the STHs.
	This technique, known as "gossip", is an active area of research and not
	defined here.
	Proof of misbehavior in such cases would be either a series of STHs that were
	issued too closely together, proving violation of the STH issuance rate limit,
	or an STH with a root hash that does not match the one calculated from a copy of
	the log, proving violation of the append-only property.</t>
        <t indent="0" pn="section-11.3-4">Clients that report back SCTs can be tracked or traced if a log
produces multiple STHs or SCTs with the same timestamp and data but different
signatures. Logs <bcp14>SHOULD</bcp14> mitigate this risk by either:</t>
        <ul spacing="normal" bare="false" empty="false" indent="3" pn="section-11.3-5">
          <li pn="section-11.3-5.1">using deterministic signature schemes or</li>
          <li pn="section-11.3-5.2">producing no more than one SCT for each distinct submission and no more than one
	  STH for each distinct <tt>tree_size</tt>. Each of these SCTs and STHs can be stored by
	  the log and served to other clients that submit the same certificate or request
	  the same STH.</li>
        </ul>
      </section>
      <section anchor="requiring_multiple_scts" numbered="true" toc="include" removeInRFC="false" pn="section-11.4">
        <name slugifiedName="name-multiple-scts-2">Multiple SCTs</name>
        <t indent="0" pn="section-11.4-1">By requiring TLS servers to offer multiple SCTs, each from a different log, TLS
clients reduce the effectiveness of an attack where a CA and a log collude
(see <xref target="multiple-scts" format="default" sectionFormat="of" derivedContent="Section 6.2"/>).</t>
      </section>
      <section anchor="leakage-of-dns-information" numbered="true" toc="include" removeInRFC="false" pn="section-11.5">
        <name slugifiedName="name-leakage-of-dns-information">Leakage of DNS Information</name>
        <t indent="0" pn="section-11.5-1">Malicious monitors can use logs to learn about the existence of domain names
that might not otherwise be easy to discover. Some subdomain labels may reveal
information about the service and software for which the subdomain is used,
which in turn might facilitate targeted attacks.</t>
      </section>
    </section>
  </middle>
  <back>
    <references pn="section-12">
      <name slugifiedName="name-references">References</name>
      <references pn="section-12.1">
        <name slugifiedName="name-normative-references">Normative References</name>
        <reference anchor="FIPS186-4" target="http://nvlpubs.nist.gov/nistpubs/FIPS/NIST.FIPS.186-4.pdf" quoteTitle="true" derivedAnchor="FIPS186-4">
          <front>
            <title>Digital Signature Standard (DSS)</title>
            <author>
              <organization showOnFrontPage="true">National Institute of Standards and Technology</organization>
            </author>
            <date year="2013" month="July"/>
          </front>
          <seriesInfo name="FIPS PUB" value="186-4"/>
        </reference>
        <reference anchor="HTML401" target="https://www.w3.org/TR/2018/SPSD-html401-20180327" quoteTitle="true" derivedAnchor="HTML401">
          <front>
            <title>HTML 4.01 Specification</title>
            <author initials="D." surname="Raggett" fullname="David Raggett">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="A." surname="Le Hors" fullname="Arnaud Le Hors">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="I." surname="Jacobs" fullname="Ian Jacobs">
              <organization showOnFrontPage="true"/>
            </author>
            <date year="2018" month="March"/>
          </front>
          <seriesInfo name="W3C Recommendation" value="SPSD-html401-20180327"/>
        </reference>
        <reference anchor="RFC2119" target="https://www.rfc-editor.org/info/rfc2119" quoteTitle="true" derivedAnchor="RFC2119">
          <front>
            <title>Key words for use in RFCs to Indicate Requirement Levels</title>
            <author initials="S." surname="Bradner" fullname="S. Bradner">
              <organization showOnFrontPage="true"/>
            </author>
            <date year="1997" month="March"/>
            <abstract>
              <t indent="0">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="RFC3553" target="https://www.rfc-editor.org/info/rfc3553" quoteTitle="true" derivedAnchor="RFC3553">
          <front>
            <title>An IETF URN Sub-namespace for Registered Protocol Parameters</title>
            <author initials="M." surname="Mealling" fullname="M. Mealling">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="L." surname="Masinter" fullname="L. Masinter">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="T." surname="Hardie" fullname="T. Hardie">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="G." surname="Klyne" fullname="G. Klyne">
              <organization showOnFrontPage="true"/>
            </author>
            <date year="2003" month="June"/>
            <abstract>
              <t indent="0">This document describes a new sub-delegation for the 'ietf' URN namespace for registered protocol items.  The 'ietf' URN namespace is defined in RFC 2648 as a root for persistent URIs that refer to IETF- defined resources.  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="73"/>
          <seriesInfo name="RFC" value="3553"/>
          <seriesInfo name="DOI" value="10.17487/RFC3553"/>
        </reference>
        <reference anchor="RFC3986" target="https://www.rfc-editor.org/info/rfc3986" quoteTitle="true" derivedAnchor="RFC3986">
          <front>
            <title>Uniform Resource Identifier (URI): Generic Syntax</title>
            <author initials="T." surname="Berners-Lee" fullname="T. Berners-Lee">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="R." surname="Fielding" fullname="R. Fielding">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="L." surname="Masinter" fullname="L. Masinter">
              <organization showOnFrontPage="true"/>
            </author>
            <date year="2005" month="January"/>
            <abstract>
              <t indent="0">A Uniform Resource Identifier (URI) is a compact sequence of characters that identifies an abstract or physical resource.  This specification defines the generic URI syntax and a process for resolving URI references that might be in relative form, along with guidelines and security considerations for the use of URIs on the Internet.  The URI syntax defines a grammar that is a superset of all valid URIs, allowing an implementation to parse the common components of a URI reference without knowing the scheme-specific requirements of every possible identifier.  This specification does not define a generative grammar for URIs; that task is performed by the individual specifications of each URI scheme.  [STANDARDS-TRACK]</t>
            </abstract>
          </front>
          <seriesInfo name="STD" value="66"/>
          <seriesInfo name="RFC" value="3986"/>
          <seriesInfo name="DOI" value="10.17487/RFC3986"/>
        </reference>
        <reference anchor="RFC4648" target="https://www.rfc-editor.org/info/rfc4648" quoteTitle="true" derivedAnchor="RFC4648">
          <front>
            <title>The Base16, Base32, and Base64 Data Encodings</title>
            <author initials="S." surname="Josefsson" fullname="S. Josefsson">
              <organization showOnFrontPage="true"/>
            </author>
            <date year="2006" month="October"/>
            <abstract>
              <t indent="0">This document describes the commonly used base 64, base 32, and base 16 encoding schemes.  It also discusses the use of line-feeds in encoded data, use of padding in encoded data, use of non-alphabet characters in encoded data, use of different encoding alphabets, and canonical encodings.  [STANDARDS-TRACK]</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="4648"/>
          <seriesInfo name="DOI" value="10.17487/RFC4648"/>
        </reference>
        <reference anchor="RFC5246" target="https://www.rfc-editor.org/info/rfc5246" quoteTitle="true" derivedAnchor="RFC5246">
          <front>
            <title>The Transport Layer Security (TLS) Protocol Version 1.2</title>
            <author initials="T." surname="Dierks" fullname="T. Dierks">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="E." surname="Rescorla" fullname="E. Rescorla">
              <organization showOnFrontPage="true"/>
            </author>
            <date year="2008" month="August"/>
            <abstract>
              <t indent="0">This document specifies Version 1.2 of the Transport Layer Security (TLS) protocol.  The TLS protocol provides communications security over the Internet.  The protocol allows client/server applications to communicate in a way that is designed to prevent eavesdropping, tampering, or message forgery.  [STANDARDS-TRACK]</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="5246"/>
          <seriesInfo name="DOI" value="10.17487/RFC5246"/>
        </reference>
        <reference anchor="RFC5280" target="https://www.rfc-editor.org/info/rfc5280" quoteTitle="true" derivedAnchor="RFC5280">
          <front>
            <title>Internet X.509 Public Key Infrastructure Certificate and Certificate Revocation List (CRL) Profile</title>
            <author initials="D." surname="Cooper" fullname="D. Cooper">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="S." surname="Santesson" fullname="S. Santesson">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="S." surname="Farrell" fullname="S. Farrell">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="S." surname="Boeyen" fullname="S. Boeyen">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="R." surname="Housley" fullname="R. Housley">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="W." surname="Polk" fullname="W. Polk">
              <organization showOnFrontPage="true"/>
            </author>
            <date year="2008" month="May"/>
            <abstract>
              <t indent="0">This memo profiles the X.509 v3 certificate and X.509 v2 certificate revocation list (CRL) for use in the Internet.  An overview of this approach and model is provided as an introduction.  The X.509 v3 certificate format is described in detail, with additional information regarding the format and semantics of Internet name forms.  Standard certificate extensions are described and two Internet-specific extensions are defined.  A set of required certificate extensions is specified.  The X.509 v2 CRL format is described in detail along with standard and Internet-specific extensions.  An algorithm for X.509 certification path validation is described.  An ASN.1 module and examples are provided in the appendices.  [STANDARDS-TRACK]</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="5280"/>
          <seriesInfo name="DOI" value="10.17487/RFC5280"/>
        </reference>
        <reference anchor="RFC5652" target="https://www.rfc-editor.org/info/rfc5652" quoteTitle="true" derivedAnchor="RFC5652">
          <front>
            <title>Cryptographic Message Syntax (CMS)</title>
            <author initials="R." surname="Housley" fullname="R. Housley">
              <organization showOnFrontPage="true"/>
            </author>
            <date year="2009" month="September"/>
            <abstract>
              <t indent="0">This document describes the Cryptographic Message Syntax (CMS).  This syntax is used to digitally sign, digest, authenticate, or encrypt arbitrary message content.  [STANDARDS-TRACK]</t>
            </abstract>
          </front>
          <seriesInfo name="STD" value="70"/>
          <seriesInfo name="RFC" value="5652"/>
          <seriesInfo name="DOI" value="10.17487/RFC5652"/>
        </reference>
        <reference anchor="RFC6066" target="https://www.rfc-editor.org/info/rfc6066" quoteTitle="true" derivedAnchor="RFC6066">
          <front>
            <title>Transport Layer Security (TLS) Extensions: Extension Definitions</title>
            <author initials="D." surname="Eastlake 3rd" fullname="D. Eastlake 3rd">
              <organization showOnFrontPage="true"/>
            </author>
            <date year="2011" month="January"/>
            <abstract>
              <t indent="0">This document provides specifications for existing TLS extensions.  It is a companion document for RFC 5246, "The Transport Layer Security (TLS) Protocol Version 1.2".  The extensions specified are server_name, max_fragment_length, client_certificate_url, trusted_ca_keys, truncated_hmac, and status_request.  [STANDARDS-TRACK]</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="6066"/>
          <seriesInfo name="DOI" value="10.17487/RFC6066"/>
        </reference>
        <reference anchor="RFC6234" target="https://www.rfc-editor.org/info/rfc6234" quoteTitle="true" derivedAnchor="RFC6234">
          <front>
            <title>US Secure Hash Algorithms (SHA and SHA-based HMAC and HKDF)</title>
            <author initials="D." surname="Eastlake 3rd" fullname="D. Eastlake 3rd">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="T." surname="Hansen" fullname="T. Hansen">
              <organization showOnFrontPage="true"/>
            </author>
            <date year="2011" month="May"/>
            <abstract>
              <t indent="0">Federal Information Processing Standard, FIPS</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="6234"/>
          <seriesInfo name="DOI" value="10.17487/RFC6234"/>
        </reference>
        <reference anchor="RFC6960" target="https://www.rfc-editor.org/info/rfc6960" quoteTitle="true" derivedAnchor="RFC6960">
          <front>
            <title>X.509 Internet Public Key Infrastructure Online Certificate Status Protocol - OCSP</title>
            <author initials="S." surname="Santesson" fullname="S. Santesson">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="M." surname="Myers" fullname="M. Myers">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="R." surname="Ankney" fullname="R. Ankney">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="A." surname="Malpani" fullname="A. Malpani">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="S." surname="Galperin" fullname="S. Galperin">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="C." surname="Adams" fullname="C. Adams">
              <organization showOnFrontPage="true"/>
            </author>
            <date year="2013" month="June"/>
            <abstract>
              <t indent="0">This document specifies a protocol useful in determining the current status of a digital certificate without requiring Certificate Revocation Lists (CRLs). Additional mechanisms addressing PKIX operational requirements are specified in separate documents.  This document obsoletes RFCs 2560 and 6277.  It also updates RFC 5912.</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="6960"/>
          <seriesInfo name="DOI" value="10.17487/RFC6960"/>
        </reference>
        <reference anchor="RFC6979" target="https://www.rfc-editor.org/info/rfc6979" quoteTitle="true" derivedAnchor="RFC6979">
          <front>
            <title>Deterministic Usage of the Digital Signature Algorithm (DSA) and Elliptic Curve Digital Signature Algorithm (ECDSA)</title>
            <author initials="T." surname="Pornin" fullname="T. Pornin">
              <organization showOnFrontPage="true"/>
            </author>
            <date year="2013" month="August"/>
            <abstract>
              <t indent="0">This document defines a deterministic digital signature generation procedure.  Such signatures are compatible with standard Digital Signature Algorithm (DSA) and Elliptic Curve Digital Signature Algorithm (ECDSA) digital signatures and can be processed with unmodified verifiers, which need not be aware of the procedure described therein.  Deterministic signatures retain the cryptographic security features associated with digital signatures but can be more easily implemented in various environments, since they do not need access to a source of high-quality randomness.</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="6979"/>
          <seriesInfo name="DOI" value="10.17487/RFC6979"/>
        </reference>
        <reference anchor="RFC7231" target="https://www.rfc-editor.org/info/rfc7231" quoteTitle="true" derivedAnchor="RFC7231">
          <front>
            <title>Hypertext Transfer Protocol (HTTP/1.1): Semantics and Content</title>
            <author initials="R." surname="Fielding" fullname="R. Fielding" role="editor">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="J." surname="Reschke" fullname="J. Reschke" role="editor">
              <organization showOnFrontPage="true"/>
            </author>
            <date year="2014" month="June"/>
            <abstract>
              <t indent="0">The Hypertext Transfer Protocol (HTTP) is a stateless \%application- level protocol for distributed, collaborative, hypertext information systems.  This document defines the semantics of HTTP/1.1 messages, as expressed by request methods, request header fields, response status codes, and response header fields, along with the payload of messages (metadata and body content) and mechanisms for content negotiation.</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="7231"/>
          <seriesInfo name="DOI" value="10.17487/RFC7231"/>
        </reference>
        <reference anchor="RFC7633" target="https://www.rfc-editor.org/info/rfc7633" quoteTitle="true" derivedAnchor="RFC7633">
          <front>
            <title>X.509v3 Transport Layer Security (TLS) Feature Extension</title>
            <author initials="P." surname="Hallam-Baker" fullname="P. Hallam-Baker">
              <organization showOnFrontPage="true"/>
            </author>
            <date year="2015" month="October"/>
            <abstract>
              <t indent="0">The purpose of the TLS feature extension is to prevent downgrade attacks that are not otherwise prevented by the TLS protocol.  In particular, the TLS feature extension may be used to mandate support for revocation checking features in the TLS protocol such as Online Certificate Status Protocol (OCSP) stapling.  Informing clients that an OCSP status response will always be stapled permits an immediate failure in the case that the response is not stapled.  This in turn prevents a denial-of-service attack that might otherwise be possible.</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="7633"/>
          <seriesInfo name="DOI" value="10.17487/RFC7633"/>
        </reference>
        <reference anchor="RFC7807" target="https://www.rfc-editor.org/info/rfc7807" quoteTitle="true" derivedAnchor="RFC7807">
          <front>
            <title>Problem Details for HTTP APIs</title>
            <author initials="M." surname="Nottingham" fullname="M. Nottingham">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="E." surname="Wilde" fullname="E. Wilde">
              <organization showOnFrontPage="true"/>
            </author>
            <date year="2016" month="March"/>
            <abstract>
              <t indent="0">This document defines a "problem detail" as a way to carry machine- readable details of errors in a HTTP response to avoid the need to define new error response formats for HTTP APIs.</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="7807"/>
          <seriesInfo name="DOI" value="10.17487/RFC7807"/>
        </reference>
        <reference anchor="RFC8032" target="https://www.rfc-editor.org/info/rfc8032" quoteTitle="true" derivedAnchor="RFC8032">
          <front>
            <title>Edwards-Curve Digital Signature Algorithm (EdDSA)</title>
            <author initials="S." surname="Josefsson" fullname="S. Josefsson">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="I." surname="Liusvaara" fullname="I. Liusvaara">
              <organization showOnFrontPage="true"/>
            </author>
            <date year="2017" month="January"/>
            <abstract>
              <t indent="0">This document describes elliptic curve signature scheme Edwards-curve Digital Signature Algorithm (EdDSA).  The algorithm is instantiated with recommended parameters for the edwards25519 and edwards448 curves.  An example implementation and test vectors are provided.</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="8032"/>
          <seriesInfo name="DOI" value="10.17487/RFC8032"/>
        </reference>
        <reference anchor="RFC8174" target="https://www.rfc-editor.org/info/rfc8174" quoteTitle="true" derivedAnchor="RFC8174">
          <front>
            <title>Ambiguity of Uppercase vs Lowercase in RFC 2119 Key Words</title>
            <author initials="B." surname="Leiba" fullname="B. Leiba">
              <organization showOnFrontPage="true"/>
            </author>
            <date year="2017" month="May"/>
            <abstract>
              <t indent="0">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>
        <reference anchor="RFC8259" target="https://www.rfc-editor.org/info/rfc8259" quoteTitle="true" derivedAnchor="RFC8259">
          <front>
            <title>The JavaScript Object Notation (JSON) Data Interchange Format</title>
            <author initials="T." surname="Bray" fullname="T. Bray" role="editor">
              <organization showOnFrontPage="true"/>
            </author>
            <date year="2017" month="December"/>
            <abstract>
              <t indent="0">JavaScript Object Notation (JSON) is a lightweight, text-based, language-independent data interchange format.  It was derived from the ECMAScript Programming Language Standard.  JSON defines a small set of formatting rules for the portable representation of structured data.</t>
              <t indent="0">This document removes inconsistencies with other specifications of JSON, repairs specification errors, and offers experience-based interoperability guidance.</t>
            </abstract>
          </front>
          <seriesInfo name="STD" value="90"/>
          <seriesInfo name="RFC" value="8259"/>
          <seriesInfo name="DOI" value="10.17487/RFC8259"/>
        </reference>
        <reference anchor="RFC8391" target="https://www.rfc-editor.org/info/rfc8391" quoteTitle="true" derivedAnchor="RFC8391">
          <front>
            <title>XMSS: eXtended Merkle Signature Scheme</title>
            <author initials="A." surname="Huelsing" fullname="A. Huelsing">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="D." surname="Butin" fullname="D. Butin">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="S." surname="Gazdag" fullname="S. Gazdag">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="J." surname="Rijneveld" fullname="J. Rijneveld">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="A." surname="Mohaisen" fullname="A. Mohaisen">
              <organization showOnFrontPage="true"/>
            </author>
            <date year="2018" month="May"/>
            <abstract>
              <t indent="0">This note describes the eXtended Merkle Signature Scheme (XMSS), a hash-based digital signature system that is based on existing descriptions in scientific literature.  This note specifies Winternitz One-Time Signature Plus (WOTS+), a one-time signature scheme; XMSS, a single-tree scheme; and XMSS^MT, a multi-tree variant of XMSS.  Both XMSS and XMSS^MT use WOTS+ as a main building block. XMSS provides cryptographic digital signatures without relying on the conjectured hardness of mathematical problems.  Instead, it is proven that it only relies on the properties of cryptographic hash functions.  XMSS provides strong security guarantees and is even secure when the collision resistance of the underlying hash function is broken.  It is suitable for compact implementations, is relatively simple to implement, and naturally resists side-channel attacks. Unlike most other signature systems, hash-based signatures can so far withstand known attacks using quantum computers.</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="8391"/>
          <seriesInfo name="DOI" value="10.17487/RFC8391"/>
        </reference>
        <reference anchor="RFC8446" target="https://www.rfc-editor.org/info/rfc8446" quoteTitle="true" derivedAnchor="RFC8446">
          <front>
            <title>The Transport Layer Security (TLS) Protocol Version 1.3</title>
            <author initials="E." surname="Rescorla" fullname="E. Rescorla">
              <organization showOnFrontPage="true"/>
            </author>
            <date year="2018" month="August"/>
            <abstract>
              <t indent="0">This document specifies version 1.3 of the Transport Layer Security (TLS) protocol.  TLS allows client/server applications to communicate over the Internet in a way that is designed to prevent eavesdropping, tampering, and message forgery.</t>
              <t indent="0">This document updates RFCs 5705 and 6066, and obsoletes RFCs 5077, 5246, and 6961.  This document also specifies new requirements for TLS 1.2 implementations.</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="8446"/>
          <seriesInfo name="DOI" value="10.17487/RFC8446"/>
        </reference>
        <reference anchor="UNIXTIME" target="http://pubs.opengroup.org/onlinepubs/9699919799.2016edition/basedefs/V1_chap04.html#tag_04_16" quoteTitle="true" derivedAnchor="UNIXTIME">
          <front>
            <title>The Open Group Base Specifications Issue 7</title>
            <author>
              <organization showOnFrontPage="true">IEEE</organization>
            </author>
            <date year="2016"/>
          </front>
          <seriesInfo name="IEEE Std" value="1003.1-2008"/>
          <refcontent>Section 4.16 Seconds Since the Epoch</refcontent>
        </reference>
        <reference anchor="X690" quoteTitle="true" derivedAnchor="X690">
          <front>
            <title>Information technology - ASN.1 encoding rules: Specification of Basic Encoding Rules (BER), Canonical Encoding Rules (CER) and Distinguished Encoding Rules (DER)</title>
            <author>
              <organization showOnFrontPage="true">ITU-T</organization>
            </author>
            <date year="2021" month="February"/>
          </front>
          <seriesInfo name="ITU-T Recommendation" value="X.690"/>
          <seriesInfo name="ISO/IEC" value="8825-1"/>
        </reference>
      </references>
      <references pn="section-12.2">
        <name slugifiedName="name-informative-references">Informative References</name>
        <reference anchor="CABBR" target="https://cabforum.org/wp-content/uploads/CA-Browser-Forum-BR-1.7.3.pdf" quoteTitle="true" derivedAnchor="CABBR">
          <front>
            <title>Baseline Requirements for the Issuance and Management of Publicly-Trusted Certificates</title>
            <author>
              <organization showOnFrontPage="true">CA/Browser Forum</organization>
            </author>
            <date month="October" year="2020"/>
          </front>
          <seriesInfo name="Version" value="1.7.3"/>
        </reference>
        <reference anchor="Chromium.Log.Policy" target="https://googlechrome.github.io/CertificateTransparency/log_policy.html" quoteTitle="true" derivedAnchor="Chromium.Log.Policy">
          <front>
            <title>Chromium Certificate Transparency Log Policy</title>
            <author>
              <organization showOnFrontPage="true">The Chromium Projects</organization>
            </author>
          </front>
        </reference>
        <reference anchor="Chromium.Policy" target="https://googlechrome.github.io/CertificateTransparency/ct_policy.html" quoteTitle="true" derivedAnchor="Chromium.Policy">
          <front>
            <title>Chromium Certificate Transparency Policy</title>
            <author>
              <organization showOnFrontPage="true">The Chromium Projects</organization>
            </author>
          </front>
        </reference>
        <reference anchor="CrosbyWallach" target="http://static.usenix.org/event/sec09/tech/full_papers/crosby.pdf" quoteTitle="true" derivedAnchor="CrosbyWallach">
          <front>
            <title>Efficient Data Structures for Tamper-Evident Logging</title>
            <author initials="S." surname="Crosby" fullname="Scott A. Crosby">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="D." surname="Wallach" fullname="Dan S. Wallach">
              <organization showOnFrontPage="true"/>
            </author>
            <date year="2009" month="August"/>
          </front>
          <refcontent>Proceedings of the 18th USENIX Security Symposium, Montreal</refcontent>
        </reference>
        <reference anchor="JSON.Metadata" target="https://www.gstatic.com/ct/log_list/log_list_schema.json" quoteTitle="true" derivedAnchor="JSON.Metadata">
          <front>
            <title>Chromium Log Metadata JSON Schema</title>
            <author>
              <organization showOnFrontPage="true">The Chromium Projects</organization>
            </author>
          </front>
        </reference>
        <reference anchor="RFC5912" target="https://www.rfc-editor.org/info/rfc5912" quoteTitle="true" derivedAnchor="RFC5912">
          <front>
            <title>New ASN.1 Modules for the Public Key Infrastructure Using X.509 (PKIX)</title>
            <author initials="P." surname="Hoffman" fullname="P. Hoffman">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="J." surname="Schaad" fullname="J. Schaad">
              <organization showOnFrontPage="true"/>
            </author>
            <date year="2010" month="June"/>
            <abstract>
              <t indent="0">The Public Key Infrastructure using X.509 (PKIX) certificate format, and many associated formats, are expressed using ASN.1.  The current ASN.1 modules conform to the 1988 version of ASN.1.  This document updates those ASN.1 modules to conform to the 2002 version of ASN.1. There are no bits-on-the-wire changes to any of the formats; this is simply a change to the syntax.  This document is not an Internet  Standards Track specification; it is published for informational  purposes.</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="5912"/>
          <seriesInfo name="DOI" value="10.17487/RFC5912"/>
        </reference>
        <reference anchor="RFC6268" target="https://www.rfc-editor.org/info/rfc6268" quoteTitle="true" derivedAnchor="RFC6268">
          <front>
            <title>Additional New ASN.1 Modules for the Cryptographic Message Syntax (CMS) and the Public Key Infrastructure Using X.509 (PKIX)</title>
            <author initials="J." surname="Schaad" fullname="J. Schaad">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="S." surname="Turner" fullname="S. Turner">
              <organization showOnFrontPage="true"/>
            </author>
            <date year="2011" month="July"/>
            <abstract>
              <t indent="0">The Cryptographic Message Syntax (CMS) format, and many associated formats, are expressed using ASN.1.  The current ASN.1 modules conform to the 1988 version of ASN.1.  This document updates some auxiliary ASN.1 modules to conform to the 2008 version of ASN.1; the 1988 ASN.1 modules remain the normative version.  There are no bits- on-the-wire changes to any of the formats; this is simply a change to the syntax.  This document is not an Internet Standards Track  specification; it is published for informational purposes.</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="6268"/>
          <seriesInfo name="DOI" value="10.17487/RFC6268"/>
        </reference>
        <reference anchor="RFC6962" target="https://www.rfc-editor.org/info/rfc6962" quoteTitle="true" derivedAnchor="RFC6962">
          <front>
            <title>Certificate Transparency</title>
            <author initials="B." surname="Laurie" fullname="B. Laurie">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="A." surname="Langley" fullname="A. Langley">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="E." surname="Kasper" fullname="E. Kasper">
              <organization showOnFrontPage="true"/>
            </author>
            <date year="2013" month="June"/>
            <abstract>
              <t indent="0">This document describes an experimental protocol for publicly logging the existence of Transport Layer Security (TLS) certificates as they are issued or observed, in a manner that allows anyone to audit certificate authority (CA) activity and notice the issuance of suspect certificates as well as to audit the certificate logs themselves.  The intent is that eventually clients would refuse to honor certificates that do not appear in a log, effectively forcing CAs to add all issued certificates to the logs.</t>
              <t indent="0">Logs are network services that implement the protocol operations for submissions and queries that are defined in this document.</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="6962"/>
          <seriesInfo name="DOI" value="10.17487/RFC6962"/>
        </reference>
        <reference anchor="RFC8126" target="https://www.rfc-editor.org/info/rfc8126" quoteTitle="true" derivedAnchor="RFC8126">
          <front>
            <title>Guidelines for Writing an IANA Considerations Section in RFCs</title>
            <author initials="M." surname="Cotton" fullname="M. Cotton">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="B." surname="Leiba" fullname="B. Leiba">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="T." surname="Narten" fullname="T. Narten">
              <organization showOnFrontPage="true"/>
            </author>
            <date year="2017" month="June"/>
            <abstract>
              <t indent="0">Many protocols make use of points of extensibility that use constants to identify various protocol parameters.  To ensure that the values in these fields do not have conflicting uses and to promote interoperability, their allocations are often coordinated by a central record keeper.  For IETF protocols, that role is filled by the Internet Assigned Numbers Authority (IANA).</t>
              <t indent="0">To make assignments in a given registry prudently, guidance describing the conditions under which new values should be assigned, as well as when and how modifications to existing values can be made, is needed.  This document defines a framework for the documentation of these guidelines by specification authors, in order to assure that the provided guidance for the IANA Considerations is clear and addresses the various issues that are likely in the operation of a registry.</t>
              <t indent="0">This is the third edition of this document; it obsoletes RFC 5226.</t>
            </abstract>
          </front>
          <seriesInfo name="BCP" value="26"/>
          <seriesInfo name="RFC" value="8126"/>
          <seriesInfo name="DOI" value="10.17487/RFC8126"/>
        </reference>
        <reference anchor="RFC8820" target="https://www.rfc-editor.org/info/rfc8820" quoteTitle="true" derivedAnchor="RFC8820">
          <front>
            <title>URI Design and Ownership</title>
            <author initials="M." surname="Nottingham" fullname="M. Nottingham">
              <organization showOnFrontPage="true"/>
            </author>
            <date year="2020" month="June"/>
            <abstract>
              <t indent="0">Section 1.1.1 of RFC 3986 defines URI syntax as "a federated and extensible naming system wherein each scheme's specification may further restrict the syntax and semantics of identifiers using that scheme."  In other words, the structure of a URI is defined by its scheme. While it is common for schemes to further delegate their substructure to the URI's owner, publishing independent standards that mandate particular forms of substructure in URIs is often problematic.</t>
              <t indent="0">This document provides guidance on the specification of URI substructure in standards.</t>
              <t indent="0">This document obsoletes RFC 7320 and updates RFC 3986.</t>
            </abstract>
          </front>
          <seriesInfo name="BCP" value="190"/>
          <seriesInfo name="RFC" value="8820"/>
          <seriesInfo name="DOI" value="10.17487/RFC8820"/>
        </reference>
        <reference anchor="X.680" quoteTitle="true" derivedAnchor="X.680">
          <front>
            <title>Information technology - Abstract Syntax Notation One (ASN.1): Specification of basic notation</title>
            <author>
              <organization showOnFrontPage="true">ITU-T</organization>
            </author>
            <date year="2021" month="February"/>
          </front>
          <seriesInfo name="ITU-T Recommendation" value="X.680"/>
        </reference>
      </references>
    </references>
    <section anchor="v1_coexistence" numbered="true" toc="include" removeInRFC="false" pn="section-appendix.a">
      <name slugifiedName="name-supporting-v1-and-v2-simult">Supporting v1 and v2 Simultaneously (Informative)</name>
      <t indent="0" pn="section-appendix.a-1">Certificate Transparency logs have to be either v1 (conforming to <xref target="RFC6962" format="default" sectionFormat="of" derivedContent="RFC6962"/>) or
v2 (conforming to this document), as the data structures are incompatible, and so
a v2 log could not issue a valid v1 SCT.</t>
      <t indent="0" pn="section-appendix.a-2">CT clients, however, can support v1 and v2 SCTs for the same certificate
simultaneously, as v1 SCTs are delivered in different TLS, X.509, and OCSP
extensions than v2 SCTs.</t>
      <t indent="0" pn="section-appendix.a-3">v1 and v2 SCTs for X.509 certificates can be validated independently. For
precertificates, v2 SCTs should be embedded in the TBSCertificate before
submission of the TBSCertificate (inside a v1 precertificate, as described in
<xref target="RFC6962" sectionFormat="of" section="3.1" format="default" derivedLink="https://rfc-editor.org/rfc/rfc6962#section-3.1" derivedContent="RFC6962"/>) to a v1 log so that TLS clients conforming to
<xref target="RFC6962" format="default" sectionFormat="of" derivedContent="RFC6962"/> but not this document are oblivious to the embedded v2 SCTs. An issuer
can follow these steps to produce an X.509 certificate with embedded v1 and v2
SCTs:</t>
      <ul spacing="normal" bare="false" empty="false" indent="3" pn="section-appendix.a-4">
        <li pn="section-appendix.a-4.1">Create a CMS precertificate, as described in <xref target="precertificates" format="default" sectionFormat="of" derivedContent="Section 3.2"/>, and submit it to v2 logs.</li>
        <li pn="section-appendix.a-4.2">Embed the obtained v2 SCTs in the TBSCertificate, as described in
	<xref target="cert_transinfo_extension" format="default" sectionFormat="of" derivedContent="Section 7.1.2"/>.</li>
        <li pn="section-appendix.a-4.3">Use that TBSCertificate to create a v1 precertificate, as described in
	<xref target="RFC6962" sectionFormat="of" section="3.1" format="default" derivedLink="https://rfc-editor.org/rfc/rfc6962#section-3.1" derivedContent="RFC6962"/>, and submit it to v1
	logs.</li>
        <li pn="section-appendix.a-4.4">Embed the v1 SCTs in the TBSCertificate, as described in
	<xref target="RFC6962" sectionFormat="of" section="3.3" format="default" derivedLink="https://rfc-editor.org/rfc/rfc6962#section-3.3" derivedContent="RFC6962"/>.</li>
        <li pn="section-appendix.a-4.5">Sign that TBSCertificate (which now contains v1 and v2 SCTs) to issue the
	final X.509 certificate.</li>
      </ul>
    </section>
    <section anchor="asn1_module" numbered="true" toc="include" removeInRFC="false" pn="section-appendix.b">
      <name slugifiedName="name-an-asn1-module-informative">An ASN.1 Module (Informative)</name>
      <t indent="0" pn="section-appendix.b-1">The following ASN.1 <xref target="X.680" format="default" sectionFormat="of" derivedContent="X.680"/> module may be useful to implementors. This module references <xref target="RFC5912" format="default" sectionFormat="of" derivedContent="RFC5912"/> and <xref target="RFC6268" format="default" sectionFormat="of" derivedContent="RFC6268"/>.</t>
      <sourcecode type="asn.1" markers="false" pn="section-appendix.b-2">
CertificateTransparencyV2Module-2021
 -- { id-mod-public-notary-v2 from above, in
        iso(1) identified-organization(3) ...
    form }
DEFINITIONS IMPLICIT TAGS ::= BEGIN

-- EXPORTS ALL --

IMPORTS
  EXTENSION
  FROM PKIX-CommonTypes-2009 -- RFC 5912
    { iso(1) identified-organization(3) dod(6) internet(1)
      security(5) mechanisms(5) pkix(7) id-mod(0)
      id-mod-pkixCommon-02(57) }

  CONTENT-TYPE
  FROM CryptographicMessageSyntax-2010  -- RFC 6268
    { iso(1) member-body(2) us(840) rsadsi(113549) pkcs(1)
      pkcs-9(9) smime(16) modules(0) id-mod-cms-2009(58) }

  TBSCertificate
  FROM PKIX1Explicit-2009 -- RFC 5912
    { iso(1) identified-organization(3) dod(6) internet(1)
      security(5) mechanisms(5) pkix(7) id-mod(0)
      id-mod-pkix1-explicit-02(51) }
;

--
-- Section 3.2.  Precertificates
--

ct-tbsCertificate CONTENT-TYPE ::= {
  TYPE TBSCertificate
  IDENTIFIED BY id-ct-tbsCertificate }

id-ct-tbsCertificate OBJECT IDENTIFIER ::= { 1 3 101 78 }

--
-- Section 7.1.  Transparency Information X.509v3 Extension
--

ext-transparencyInfo EXTENSION ::= {
   SYNTAX TransparencyInformationSyntax
   IDENTIFIED BY id-ce-transparencyInfo
   CRITICALITY { FALSE } }

id-ce-transparencyInfo OBJECT IDENTIFIER ::= { 1 3 101 75 }

TransparencyInformationSyntax ::= OCTET STRING

--
-- Section 7.1.1.  OCSP Response Extension
--

ext-ocsp-transparencyInfo EXTENSION ::= {
   SYNTAX TransparencyInformationSyntax
   IDENTIFIED BY id-pkix-ocsp-transparencyInfo
   CRITICALITY { FALSE } }

id-pkix-ocsp-transparencyInfo OBJECT IDENTIFIER ::=
   id-ce-transparencyInfo

--
-- Section 8.1.2.  Reconstructing the TBSCertificate
--

ext-embeddedSCT-CTv1 EXTENSION ::= {
   SYNTAX SignedCertificateTimestampList
   IDENTIFIED BY id-ce-embeddedSCT-CTv1
   CRITICALITY { FALSE } }

id-ce-embeddedSCT-CTv1 OBJECT IDENTIFIER ::= {
   1 3 6 1 4 1 11129 2 4 2 }

SignedCertificateTimestampList ::= OCTET STRING

END

</sourcecode>
    </section>
    <section anchor="acknowledgements" numbered="false" toc="include" removeInRFC="false" pn="section-appendix.c">
      <name slugifiedName="name-acknowledgements">Acknowledgements</name>
      <t indent="0" pn="section-appendix.c-1">The authors would like to thank <contact fullname="Erwann Abelea"/>, <contact fullname="Robin Alden"/>, <contact fullname="Andrew Ayer"/>, <contact fullname="Richard       Barnes"/>, <contact fullname="Al Cutter"/>, <contact fullname="David Drysdale"/>,
      <contact fullname="Francis Dupont"/>, <contact fullname="Adam Eijdenberg"/>, <contact fullname="Stephen Farrell"/>, <contact fullname="Daniel Kahn Gillmor"/>, <contact fullname="Paul Hadfield"/>, <contact fullname="Brad Hill"/>, <contact fullname="Jeff       Hodges"/>, <contact fullname="Paul       Hoffman"/>, <contact fullname="Jeffrey Hutzelman"/>, <contact fullname="Kat Joyce"/>,
      <contact fullname="Emilia Kasper"/>, <contact fullname="Stephen Kent"/>, <contact fullname="Adam Langley"/>, <contact fullname="SM"/>, <contact fullname="Alexey       Melnikov"/>, <contact fullname="Linus       Nordberg"/>, <contact fullname="Chris Palmer"/>, <contact fullname="Trevor Perrin"/>,
      <contact fullname="Pierre Phaneuf"/>, <contact fullname="Eric Rescorla"/>, <contact fullname="Rich Salz"/>, <contact fullname="Melinda Shore"/>, <contact fullname="Ryan       Sleevi"/>, <contact fullname="Martin Smith"/>, <contact fullname="Carl Wallace"/>,
      and <contact fullname="Paul Wouters"/> for their valuable contributions.</t>
      <t indent="0" pn="section-appendix.c-2">A big thank you to Symantec for kindly donating the OIDs from the 1.3.101 arc
      that are used in this document.</t>
    </section>
    <section anchor="authors-addresses" numbered="false" removeInRFC="false" toc="include" pn="section-appendix.d">
      <name slugifiedName="name-authors-addresses">Authors' Addresses</name>
      <author initials="B." surname="Laurie" fullname="Ben Laurie">
        <organization abbrev="Google" showOnFrontPage="true">Google UK Ltd.</organization>
        <address>
          <email>benl@google.com</email>
        </address>
      </author>
      <author initials="E." surname="Messeri" fullname="Eran Messeri">
        <organization abbrev="Google" showOnFrontPage="true">Google UK Ltd.</organization>
        <address>
          <email>eranm@google.com</email>
        </address>
      </author>
      <author initials="R." surname="Stradling" fullname="Rob Stradling">
        <organization abbrev="Sectigo" showOnFrontPage="true">Sectigo Ltd.</organization>
        <address>
          <email>rob@sectigo.com</email>
        </address>
      </author>
    </section>
  </back>
</rfc>
