<?xml version='1.0' encoding='utf-8'?>
<rfc xmlns:xi="http://www.w3.org/2001/XInclude" version="3" ipr="trust200902" docName="draft-ietf-httpbis-message-signatures-19" number="9421" submissionType="IETF" category="std" consensus="true" tocInclude="true" sortRefs="true" symRefs="true" updates="" obsoletes="" xml:lang="en" prepTime="2024-02-14T10:01:44" indexInclude="true" scripts="Common,Latin" tocDepth="3">
  <link href="https://datatracker.ietf.org/doc/draft-ietf-httpbis-message-signatures-19" rel="prev"/>
  <link href="https://dx.doi.org/10.17487/rfc9421" rel="alternate"/>
  <link href="urn:issn:2070-1721" rel="alternate"/>
  <front>
    <title>HTTP Message Signatures</title>
    <seriesInfo name="RFC" value="9421" stream="IETF"/>
    <author initials="A." surname="Backman" fullname="Annabelle Backman" role="editor">
      <organization showOnFrontPage="true">Amazon</organization>
      <address>
        <postal>
          <street>P.O. Box 81226</street>
          <city>Seattle</city>
          <region>WA</region>
          <code>98108-1226</code>
          <country>United States of America</country>
        </postal>
        <email>richanna@amazon.com</email>
        <uri>https://www.amazon.com/</uri>
      </address>
    </author>
    <author initials="J." surname="Richer" fullname="Justin Richer" role="editor">
      <organization showOnFrontPage="true">Bespoke Engineering</organization>
      <address>
        <email>ietf@justin.richer.org</email>
        <uri>https://bspk.io/</uri>
      </address>
    </author>
    <author initials="M." surname="Sporny" fullname="Manu Sporny">
      <organization showOnFrontPage="true">Digital Bazaar</organization>
      <address>
        <postal>
          <street>203 Roanoke Street W.</street>
          <city>Blacksburg</city>
          <region>VA</region>
          <code>24060</code>
          <country>United States of America</country>
        </postal>
        <email>msporny@digitalbazaar.com</email>
      </address>
    </author>
    <date month="02" year="2024"/>
    <area>art</area>
    <workgroup>httpbis</workgroup>
    <keyword>PKI</keyword>
    <abstract pn="section-abstract">
      <t indent="0" pn="section-abstract-1">This document describes a mechanism for creating, encoding, and verifying digital signatures or message authentication codes over components of an HTTP message. This mechanism supports use cases where the full HTTP message may not be known to the signer and where the message may be transformed (e.g., by intermediaries) before reaching the verifier.
This document also describes a means for requesting that a signature be applied to a subsequent HTTP message in an ongoing HTTP exchange.</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 is an Internet Standards Track document.
        </t>
        <t indent="0" pn="section-boilerplate.1-2">
            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).  Further
            information on Internet Standards is available in 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/rfc9421" 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) 2024 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-conventions-and-terminology">Conventions and Terminology</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-requirements">Requirements</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-http-message-transformation">HTTP Message Transformations</xref></t>
              </li>
              <li pn="section-toc.1-1.1.2.4">
                <t indent="0" pn="section-toc.1-1.1.2.4.1"><xref derivedContent="1.4" format="counter" sectionFormat="of" target="section-1.4"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-application-of-http-message">Application of HTTP Message Signatures</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-http-message-components">HTTP Message 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-http-fields">HTTP Fields</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-strict-serialization-of-htt">Strict Serialization of HTTP Structured Fields</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-dictionary-structured-field">Dictionary Structured Field Members</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-binary-wrapped-http-fields">Binary-Wrapped HTTP Fields</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-trailer-fields">Trailer Fields</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-derived-components">Derived Components</xref></t>
                <ul bare="true" empty="true" indent="2" spacing="compact" pn="section-toc.1-1.2.2.2.2">
                  <li pn="section-toc.1-1.2.2.2.2.1">
                    <t indent="0" pn="section-toc.1-1.2.2.2.2.1.1"><xref derivedContent="2.2.1" format="counter" sectionFormat="of" target="section-2.2.1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-method">Method</xref></t>
                  </li>
                  <li pn="section-toc.1-1.2.2.2.2.2">
                    <t indent="0" pn="section-toc.1-1.2.2.2.2.2.1"><xref derivedContent="2.2.2" format="counter" sectionFormat="of" target="section-2.2.2"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-target-uri">Target URI</xref></t>
                  </li>
                  <li pn="section-toc.1-1.2.2.2.2.3">
                    <t indent="0" pn="section-toc.1-1.2.2.2.2.3.1"><xref derivedContent="2.2.3" format="counter" sectionFormat="of" target="section-2.2.3"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-authority">Authority</xref></t>
                  </li>
                  <li pn="section-toc.1-1.2.2.2.2.4">
                    <t indent="0" pn="section-toc.1-1.2.2.2.2.4.1"><xref derivedContent="2.2.4" format="counter" sectionFormat="of" target="section-2.2.4"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-scheme">Scheme</xref></t>
                  </li>
                  <li pn="section-toc.1-1.2.2.2.2.5">
                    <t indent="0" pn="section-toc.1-1.2.2.2.2.5.1"><xref derivedContent="2.2.5" format="counter" sectionFormat="of" target="section-2.2.5"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-request-target">Request Target</xref></t>
                  </li>
                  <li pn="section-toc.1-1.2.2.2.2.6">
                    <t indent="0" pn="section-toc.1-1.2.2.2.2.6.1"><xref derivedContent="2.2.6" format="counter" sectionFormat="of" target="section-2.2.6"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-path">Path</xref></t>
                  </li>
                  <li pn="section-toc.1-1.2.2.2.2.7">
                    <t indent="0" pn="section-toc.1-1.2.2.2.2.7.1"><xref derivedContent="2.2.7" format="counter" sectionFormat="of" target="section-2.2.7"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-query">Query</xref></t>
                  </li>
                  <li pn="section-toc.1-1.2.2.2.2.8">
                    <t indent="0" pn="section-toc.1-1.2.2.2.2.8.1"><xref derivedContent="2.2.8" format="counter" sectionFormat="of" target="section-2.2.8"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-query-parameters">Query Parameters</xref></t>
                  </li>
                  <li pn="section-toc.1-1.2.2.2.2.9">
                    <t indent="0" pn="section-toc.1-1.2.2.2.2.9.1"><xref derivedContent="2.2.9" format="counter" sectionFormat="of" target="section-2.2.9"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-status-code">Status Code</xref></t>
                  </li>
                </ul>
              </li>
              <li pn="section-toc.1-1.2.2.3">
                <t indent="0" pn="section-toc.1-1.2.2.3.1"><xref derivedContent="2.3" format="counter" sectionFormat="of" target="section-2.3"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-signature-parameters">Signature Parameters</xref></t>
              </li>
              <li pn="section-toc.1-1.2.2.4">
                <t indent="0" pn="section-toc.1-1.2.2.4.1"><xref derivedContent="2.4" format="counter" sectionFormat="of" target="section-2.4"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-signing-request-components-">Signing Request Components in a Response Message</xref></t>
              </li>
              <li pn="section-toc.1-1.2.2.5">
                <t indent="0" pn="section-toc.1-1.2.2.5.1"><xref derivedContent="2.5" format="counter" sectionFormat="of" target="section-2.5"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-creating-the-signature-base">Creating the Signature Base</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-http-message-signatures">HTTP Message Signatures</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-creating-a-signature">Creating a Signature</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-verifying-a-signature">Verifying a Signature</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-enforcing-application-requi">Enforcing Application Requirements</xref></t>
                  </li>
                </ul>
              </li>
              <li pn="section-toc.1-1.3.2.3">
                <t indent="0" pn="section-toc.1-1.3.2.3.1"><xref derivedContent="3.3" format="counter" sectionFormat="of" target="section-3.3"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-signature-algorithms">Signature Algorithms</xref></t>
                <ul bare="true" empty="true" indent="2" spacing="compact" pn="section-toc.1-1.3.2.3.2">
                  <li pn="section-toc.1-1.3.2.3.2.1">
                    <t indent="0" pn="section-toc.1-1.3.2.3.2.1.1"><xref derivedContent="3.3.1" format="counter" sectionFormat="of" target="section-3.3.1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-rsassa-pss-using-sha-512">RSASSA-PSS Using SHA-512</xref></t>
                  </li>
                  <li pn="section-toc.1-1.3.2.3.2.2">
                    <t indent="0" pn="section-toc.1-1.3.2.3.2.2.1"><xref derivedContent="3.3.2" format="counter" sectionFormat="of" target="section-3.3.2"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-rsassa-pkcs1-v1_5-using-sha">RSASSA-PKCS1-v1_5 Using SHA-256</xref></t>
                  </li>
                  <li pn="section-toc.1-1.3.2.3.2.3">
                    <t indent="0" pn="section-toc.1-1.3.2.3.2.3.1"><xref derivedContent="3.3.3" format="counter" sectionFormat="of" target="section-3.3.3"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-hmac-using-sha-256">HMAC Using SHA-256</xref></t>
                  </li>
                  <li pn="section-toc.1-1.3.2.3.2.4">
                    <t indent="0" pn="section-toc.1-1.3.2.3.2.4.1"><xref derivedContent="3.3.4" format="counter" sectionFormat="of" target="section-3.3.4"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-ecdsa-using-curve-p-256-dss">ECDSA Using Curve P-256 DSS and SHA-256</xref></t>
                  </li>
                  <li pn="section-toc.1-1.3.2.3.2.5">
                    <t indent="0" pn="section-toc.1-1.3.2.3.2.5.1"><xref derivedContent="3.3.5" format="counter" sectionFormat="of" target="section-3.3.5"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-ecdsa-using-curve-p-384-dss">ECDSA Using Curve P-384 DSS and SHA-384</xref></t>
                  </li>
                  <li pn="section-toc.1-1.3.2.3.2.6">
                    <t indent="0" pn="section-toc.1-1.3.2.3.2.6.1"><xref derivedContent="3.3.6" format="counter" sectionFormat="of" target="section-3.3.6"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-eddsa-using-curve-edwards25">EdDSA Using Curve edwards25519</xref></t>
                  </li>
                  <li pn="section-toc.1-1.3.2.3.2.7">
                    <t indent="0" pn="section-toc.1-1.3.2.3.2.7.1"><xref derivedContent="3.3.7" format="counter" sectionFormat="of" target="section-3.3.7"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-json-web-signature-jws-algo">JSON Web Signature (JWS) Algorithms</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-including-a-message-signatu">Including a Message Signature in a Message</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-the-signature-input-http-fi">The Signature-Input HTTP Field</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-the-signature-http-field">The Signature HTTP Field</xref></t>
              </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-multiple-signatures">Multiple Signatures</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-requesting-signatures">Requesting Signatures</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-the-accept-signature-field">The Accept-Signature Field</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-processing-an-accept-signat">Processing an Accept-Signature</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-iana-considerations">IANA Considerations</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-http-field-name-registratio">HTTP Field Name Registration</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-http-signature-algorithms-r">HTTP Signature Algorithms Registry</xref></t>
                <ul bare="true" empty="true" indent="2" spacing="compact" pn="section-toc.1-1.6.2.2.2">
                  <li pn="section-toc.1-1.6.2.2.2.1">
                    <t indent="0" pn="section-toc.1-1.6.2.2.2.1.1"><xref derivedContent="6.2.1" format="counter" sectionFormat="of" target="section-6.2.1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-registration-template">Registration Template</xref></t>
                  </li>
                  <li pn="section-toc.1-1.6.2.2.2.2">
                    <t indent="0" pn="section-toc.1-1.6.2.2.2.2.1"><xref derivedContent="6.2.2" format="counter" sectionFormat="of" target="section-6.2.2"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-initial-contents">Initial Contents</xref></t>
                  </li>
                </ul>
              </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-http-signature-metadata-par">HTTP Signature Metadata Parameters Registry</xref></t>
                <ul bare="true" empty="true" indent="2" spacing="compact" pn="section-toc.1-1.6.2.3.2">
                  <li pn="section-toc.1-1.6.2.3.2.1">
                    <t indent="0" pn="section-toc.1-1.6.2.3.2.1.1"><xref derivedContent="6.3.1" format="counter" sectionFormat="of" target="section-6.3.1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-registration-template-2">Registration Template</xref></t>
                  </li>
                  <li pn="section-toc.1-1.6.2.3.2.2">
                    <t indent="0" pn="section-toc.1-1.6.2.3.2.2.1"><xref derivedContent="6.3.2" format="counter" sectionFormat="of" target="section-6.3.2"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-initial-contents-2">Initial Contents</xref></t>
                  </li>
                </ul>
              </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-http-signature-derived-comp">HTTP Signature Derived Component Names Registry</xref></t>
                <ul bare="true" empty="true" indent="2" spacing="compact" pn="section-toc.1-1.6.2.4.2">
                  <li pn="section-toc.1-1.6.2.4.2.1">
                    <t indent="0" pn="section-toc.1-1.6.2.4.2.1.1"><xref derivedContent="6.4.1" format="counter" sectionFormat="of" target="section-6.4.1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-registration-template-3">Registration Template</xref></t>
                  </li>
                  <li pn="section-toc.1-1.6.2.4.2.2">
                    <t indent="0" pn="section-toc.1-1.6.2.4.2.2.1"><xref derivedContent="6.4.2" format="counter" sectionFormat="of" target="section-6.4.2"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-initial-contents-3">Initial Contents</xref></t>
                  </li>
                </ul>
              </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-http-signature-component-pa">HTTP Signature Component Parameters Registry</xref></t>
                <ul bare="true" empty="true" indent="2" spacing="compact" pn="section-toc.1-1.6.2.5.2">
                  <li pn="section-toc.1-1.6.2.5.2.1">
                    <t indent="0" pn="section-toc.1-1.6.2.5.2.1.1"><xref derivedContent="6.5.1" format="counter" sectionFormat="of" target="section-6.5.1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-registration-template-4">Registration Template</xref></t>
                  </li>
                  <li pn="section-toc.1-1.6.2.5.2.2">
                    <t indent="0" pn="section-toc.1-1.6.2.5.2.2.1"><xref derivedContent="6.5.2" format="counter" sectionFormat="of" target="section-6.5.2"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-initial-contents-4">Initial Contents</xref></t>
                  </li>
                </ul>
              </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-security-considerations">Security Considerations</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-general-considerations">General Considerations</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-skipping-signature-verifica">Skipping Signature Verification</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-use-of-tls">Use of TLS</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-message-processing-and-sele">Message Processing and Selection</xref></t>
                <ul bare="true" empty="true" indent="2" spacing="compact" pn="section-toc.1-1.7.2.2.2">
                  <li pn="section-toc.1-1.7.2.2.2.1">
                    <t indent="0" pn="section-toc.1-1.7.2.2.2.1.1"><xref derivedContent="7.2.1" format="counter" sectionFormat="of" target="section-7.2.1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-insufficient-coverage">Insufficient Coverage</xref></t>
                  </li>
                  <li pn="section-toc.1-1.7.2.2.2.2">
                    <t indent="0" pn="section-toc.1-1.7.2.2.2.2.1"><xref derivedContent="7.2.2" format="counter" sectionFormat="of" target="section-7.2.2"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-signature-replay">Signature Replay</xref></t>
                  </li>
                  <li pn="section-toc.1-1.7.2.2.2.3">
                    <t indent="0" pn="section-toc.1-1.7.2.2.2.3.1"><xref derivedContent="7.2.3" format="counter" sectionFormat="of" target="section-7.2.3"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-choosing-message-components">Choosing Message Components</xref></t>
                  </li>
                  <li pn="section-toc.1-1.7.2.2.2.4">
                    <t indent="0" pn="section-toc.1-1.7.2.2.2.4.1"><xref derivedContent="7.2.4" format="counter" sectionFormat="of" target="section-7.2.4"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-choosing-signature-paramete">Choosing Signature Parameters and Derived Components over HTTP Fields</xref></t>
                  </li>
                  <li pn="section-toc.1-1.7.2.2.2.5">
                    <t indent="0" pn="section-toc.1-1.7.2.2.2.5.1"><xref derivedContent="7.2.5" format="counter" sectionFormat="of" target="section-7.2.5"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-signature-labels">Signature Labels</xref></t>
                  </li>
                  <li pn="section-toc.1-1.7.2.2.2.6">
                    <t indent="0" pn="section-toc.1-1.7.2.2.2.6.1"><xref derivedContent="7.2.6" format="counter" sectionFormat="of" target="section-7.2.6"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-multiple-signature-confusio">Multiple Signature Confusion</xref></t>
                  </li>
                  <li pn="section-toc.1-1.7.2.2.2.7">
                    <t indent="0" pn="section-toc.1-1.7.2.2.2.7.1"><xref derivedContent="7.2.7" format="counter" sectionFormat="of" target="section-7.2.7"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-collision-of-application-sp">Collision of Application-Specific Signature Tag</xref></t>
                  </li>
                  <li pn="section-toc.1-1.7.2.2.2.8">
                    <t indent="0" pn="section-toc.1-1.7.2.2.2.8.1"><xref derivedContent="7.2.8" format="counter" sectionFormat="of" target="section-7.2.8"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-message-content">Message Content</xref></t>
                  </li>
                </ul>
              </li>
              <li pn="section-toc.1-1.7.2.3">
                <t indent="0" pn="section-toc.1-1.7.2.3.1"><xref derivedContent="7.3" format="counter" sectionFormat="of" target="section-7.3"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-cryptographic-consideration">Cryptographic Considerations</xref></t>
                <ul bare="true" empty="true" indent="2" spacing="compact" pn="section-toc.1-1.7.2.3.2">
                  <li pn="section-toc.1-1.7.2.3.2.1">
                    <t indent="0" pn="section-toc.1-1.7.2.3.2.1.1"><xref derivedContent="7.3.1" format="counter" sectionFormat="of" target="section-7.3.1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-cryptography-and-signature-">Cryptography and Signature Collision</xref></t>
                  </li>
                  <li pn="section-toc.1-1.7.2.3.2.2">
                    <t indent="0" pn="section-toc.1-1.7.2.3.2.2.1"><xref derivedContent="7.3.2" format="counter" sectionFormat="of" target="section-7.3.2"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-key-theft">Key Theft</xref></t>
                  </li>
                  <li pn="section-toc.1-1.7.2.3.2.3">
                    <t indent="0" pn="section-toc.1-1.7.2.3.2.3.1"><xref derivedContent="7.3.3" format="counter" sectionFormat="of" target="section-7.3.3"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-symmetric-cryptography">Symmetric Cryptography</xref></t>
                  </li>
                  <li pn="section-toc.1-1.7.2.3.2.4">
                    <t indent="0" pn="section-toc.1-1.7.2.3.2.4.1"><xref derivedContent="7.3.4" format="counter" sectionFormat="of" target="section-7.3.4"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-key-specification-mixup">Key Specification Mixup</xref></t>
                  </li>
                  <li pn="section-toc.1-1.7.2.3.2.5">
                    <t indent="0" pn="section-toc.1-1.7.2.3.2.5.1"><xref derivedContent="7.3.5" format="counter" sectionFormat="of" target="section-7.3.5"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-non-deterministic-signature">Non-deterministic Signature Primitives</xref></t>
                  </li>
                  <li pn="section-toc.1-1.7.2.3.2.6">
                    <t indent="0" pn="section-toc.1-1.7.2.3.2.6.1"><xref derivedContent="7.3.6" format="counter" sectionFormat="of" target="section-7.3.6"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-key-and-algorithm-specifica">Key and Algorithm Specification Downgrades</xref></t>
                  </li>
                  <li pn="section-toc.1-1.7.2.3.2.7">
                    <t indent="0" pn="section-toc.1-1.7.2.3.2.7.1"><xref derivedContent="7.3.7" format="counter" sectionFormat="of" target="section-7.3.7"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-signing-signature-values">Signing Signature Values</xref></t>
                  </li>
                </ul>
              </li>
              <li pn="section-toc.1-1.7.2.4">
                <t indent="0" pn="section-toc.1-1.7.2.4.1"><xref derivedContent="7.4" format="counter" sectionFormat="of" target="section-7.4"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-matching-signature-paramete">Matching Signature Parameters to the Target Message</xref></t>
                <ul bare="true" empty="true" indent="2" spacing="compact" pn="section-toc.1-1.7.2.4.2">
                  <li pn="section-toc.1-1.7.2.4.2.1">
                    <t indent="0" pn="section-toc.1-1.7.2.4.2.1.1"><xref derivedContent="7.4.1" format="counter" sectionFormat="of" target="section-7.4.1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-modification-of-required-me">Modification of Required Message Parameters</xref></t>
                  </li>
                  <li pn="section-toc.1-1.7.2.4.2.2">
                    <t indent="0" pn="section-toc.1-1.7.2.4.2.2.1"><xref derivedContent="7.4.2" format="counter" sectionFormat="of" target="section-7.4.2"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-matching-values-of-covered-">Matching Values of Covered Components to Values in the Target Message</xref></t>
                  </li>
                  <li pn="section-toc.1-1.7.2.4.2.3">
                    <t indent="0" pn="section-toc.1-1.7.2.4.2.3.1"><xref derivedContent="7.4.3" format="counter" sectionFormat="of" target="section-7.4.3"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-message-component-source-an">Message Component Source and Context</xref></t>
                  </li>
                  <li pn="section-toc.1-1.7.2.4.2.4">
                    <t indent="0" pn="section-toc.1-1.7.2.4.2.4.1"><xref derivedContent="7.4.4" format="counter" sectionFormat="of" target="section-7.4.4"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-multiple-message-component-">Multiple Message Component Contexts</xref></t>
                  </li>
                </ul>
              </li>
              <li pn="section-toc.1-1.7.2.5">
                <t indent="0" pn="section-toc.1-1.7.2.5.1"><xref derivedContent="7.5" format="counter" sectionFormat="of" target="section-7.5"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-http-processing">HTTP Processing</xref></t>
                <ul bare="true" empty="true" indent="2" spacing="compact" pn="section-toc.1-1.7.2.5.2">
                  <li pn="section-toc.1-1.7.2.5.2.1">
                    <t indent="0" pn="section-toc.1-1.7.2.5.2.1.1"><xref derivedContent="7.5.1" format="counter" sectionFormat="of" target="section-7.5.1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-processing-invalid-http-fie">Processing Invalid HTTP Field Names as Derived Component Names</xref></t>
                  </li>
                  <li pn="section-toc.1-1.7.2.5.2.2">
                    <t indent="0" pn="section-toc.1-1.7.2.5.2.2.1"><xref derivedContent="7.5.2" format="counter" sectionFormat="of" target="section-7.5.2"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-semantically-equivalent-fie">Semantically Equivalent Field Values</xref></t>
                  </li>
                  <li pn="section-toc.1-1.7.2.5.2.3">
                    <t indent="0" pn="section-toc.1-1.7.2.5.2.3.1"><xref derivedContent="7.5.3" format="counter" sectionFormat="of" target="section-7.5.3"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-parsing-structured-field-va">Parsing Structured Field Values</xref></t>
                  </li>
                  <li pn="section-toc.1-1.7.2.5.2.4">
                    <t indent="0" pn="section-toc.1-1.7.2.5.2.4.1"><xref derivedContent="7.5.4" format="counter" sectionFormat="of" target="section-7.5.4"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-http-versions-and-component">HTTP Versions and Component Ambiguity</xref></t>
                  </li>
                  <li pn="section-toc.1-1.7.2.5.2.5">
                    <t indent="0" pn="section-toc.1-1.7.2.5.2.5.1"><xref derivedContent="7.5.5" format="counter" sectionFormat="of" target="section-7.5.5"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-canonicalization-attacks">Canonicalization Attacks</xref></t>
                  </li>
                  <li pn="section-toc.1-1.7.2.5.2.6">
                    <t indent="0" pn="section-toc.1-1.7.2.5.2.6.1"><xref derivedContent="7.5.6" format="counter" sectionFormat="of" target="section-7.5.6"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-non-list-field-values">Non-List Field Values</xref></t>
                  </li>
                  <li pn="section-toc.1-1.7.2.5.2.7">
                    <t indent="0" pn="section-toc.1-1.7.2.5.2.7.1"><xref derivedContent="7.5.7" format="counter" sectionFormat="of" target="section-7.5.7"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-padding-attacks-with-multip">Padding Attacks with Multiple Field Values</xref></t>
                  </li>
                  <li pn="section-toc.1-1.7.2.5.2.8">
                    <t indent="0" pn="section-toc.1-1.7.2.5.2.8.1"><xref derivedContent="7.5.8" format="counter" sectionFormat="of" target="section-7.5.8"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-ambiguous-handling-of-query">Ambiguous Handling of Query Elements</xref></t>
                  </li>
                </ul>
              </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-privacy-considerations">Privacy Considerations</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-identification-through-keys">Identification through Keys</xref></t>
              </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-signatures-do-not-provide-c">Signatures do not provide confidentiality</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-oracles">Oracles</xref></t>
              </li>
              <li pn="section-toc.1-1.8.2.4">
                <t indent="0" pn="section-toc.1-1.8.2.4.1"><xref derivedContent="8.4" format="counter" sectionFormat="of" target="section-8.4"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-required-content">Required Content</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-references">References</xref></t>
            <ul bare="true" empty="true" indent="2" spacing="compact" pn="section-toc.1-1.9.2">
              <li pn="section-toc.1-1.9.2.1">
                <t indent="0" pn="section-toc.1-1.9.2.1.1"><xref derivedContent="9.1" format="counter" sectionFormat="of" target="section-9.1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-normative-references">Normative References</xref></t>
              </li>
              <li pn="section-toc.1-1.9.2.2">
                <t indent="0" pn="section-toc.1-1.9.2.2.1"><xref derivedContent="9.2" format="counter" sectionFormat="of" target="section-9.2"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-informative-references">Informative References</xref></t>
              </li>
            </ul>
          </li>
          <li pn="section-toc.1-1.10">
            <t indent="0" pn="section-toc.1-1.10.1"><xref derivedContent="Appendix A" format="default" sectionFormat="of" target="section-appendix.a"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-detecting-http-message-sign">Detecting HTTP Message Signatures</xref></t>
          </li>
          <li pn="section-toc.1-1.11">
            <t indent="0" pn="section-toc.1-1.11.1"><xref derivedContent="Appendix B" format="default" sectionFormat="of" target="section-appendix.b"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-examples">Examples</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="B.1" format="counter" sectionFormat="of" target="section-appendix.b.1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-example-keys">Example Keys</xref></t>
                <ul bare="true" empty="true" indent="2" spacing="compact" pn="section-toc.1-1.11.2.1.2">
                  <li pn="section-toc.1-1.11.2.1.2.1">
                    <t indent="0" pn="section-toc.1-1.11.2.1.2.1.1"><xref derivedContent="B.1.1" format="counter" sectionFormat="of" target="section-appendix.b.1.1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-example-rsa-key">Example RSA Key</xref></t>
                  </li>
                  <li pn="section-toc.1-1.11.2.1.2.2">
                    <t indent="0" pn="section-toc.1-1.11.2.1.2.2.1"><xref derivedContent="B.1.2" format="counter" sectionFormat="of" target="section-appendix.b.1.2"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-example-rsa-pss-key">Example RSA-PSS Key</xref></t>
                  </li>
                  <li pn="section-toc.1-1.11.2.1.2.3">
                    <t indent="0" pn="section-toc.1-1.11.2.1.2.3.1"><xref derivedContent="B.1.3" format="counter" sectionFormat="of" target="section-appendix.b.1.3"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-example-ecc-p-256-test-key">Example ECC P-256 Test Key</xref></t>
                  </li>
                  <li pn="section-toc.1-1.11.2.1.2.4">
                    <t indent="0" pn="section-toc.1-1.11.2.1.2.4.1"><xref derivedContent="B.1.4" format="counter" sectionFormat="of" target="section-appendix.b.1.4"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-example-ed25519-test-key">Example Ed25519 Test Key</xref></t>
                  </li>
                  <li pn="section-toc.1-1.11.2.1.2.5">
                    <t indent="0" pn="section-toc.1-1.11.2.1.2.5.1"><xref derivedContent="B.1.5" format="counter" sectionFormat="of" target="section-appendix.b.1.5"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-example-shared-secret">Example Shared Secret</xref></t>
                  </li>
                </ul>
              </li>
              <li pn="section-toc.1-1.11.2.2">
                <t indent="0" pn="section-toc.1-1.11.2.2.1"><xref derivedContent="B.2" format="counter" sectionFormat="of" target="section-appendix.b.2"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-test-cases">Test Cases</xref></t>
                <ul bare="true" empty="true" indent="2" spacing="compact" pn="section-toc.1-1.11.2.2.2">
                  <li pn="section-toc.1-1.11.2.2.2.1">
                    <t indent="0" pn="section-toc.1-1.11.2.2.2.1.1"><xref derivedContent="B.2.1" format="counter" sectionFormat="of" target="section-appendix.b.2.1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-minimal-signature-using-rsa">Minimal Signature Using rsa-pss-sha512</xref></t>
                  </li>
                  <li pn="section-toc.1-1.11.2.2.2.2">
                    <t indent="0" pn="section-toc.1-1.11.2.2.2.2.1"><xref derivedContent="B.2.2" format="counter" sectionFormat="of" target="section-appendix.b.2.2"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-selective-covered-component">Selective Covered Components Using rsa-pss-sha512</xref></t>
                  </li>
                  <li pn="section-toc.1-1.11.2.2.2.3">
                    <t indent="0" pn="section-toc.1-1.11.2.2.2.3.1"><xref derivedContent="B.2.3" format="counter" sectionFormat="of" target="section-appendix.b.2.3"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-full-coverage-using-rsa-pss">Full Coverage Using rsa-pss-sha512</xref></t>
                  </li>
                  <li pn="section-toc.1-1.11.2.2.2.4">
                    <t indent="0" pn="section-toc.1-1.11.2.2.2.4.1"><xref derivedContent="B.2.4" format="counter" sectionFormat="of" target="section-appendix.b.2.4"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-signing-a-response-using-ec">Signing a Response Using ecdsa-p256-sha256</xref></t>
                  </li>
                  <li pn="section-toc.1-1.11.2.2.2.5">
                    <t indent="0" pn="section-toc.1-1.11.2.2.2.5.1"><xref derivedContent="B.2.5" format="counter" sectionFormat="of" target="section-appendix.b.2.5"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-signing-a-request-using-hma">Signing a Request Using hmac-sha256</xref></t>
                  </li>
                  <li pn="section-toc.1-1.11.2.2.2.6">
                    <t indent="0" pn="section-toc.1-1.11.2.2.2.6.1"><xref derivedContent="B.2.6" format="counter" sectionFormat="of" target="section-appendix.b.2.6"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-signing-a-request-using-ed2">Signing a Request Using ed25519</xref></t>
                  </li>
                </ul>
              </li>
              <li pn="section-toc.1-1.11.2.3">
                <t indent="0" pn="section-toc.1-1.11.2.3.1"><xref derivedContent="B.3" format="counter" sectionFormat="of" target="section-appendix.b.3"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-tls-terminating-proxies">TLS-Terminating Proxies</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="B.4" format="counter" sectionFormat="of" target="section-appendix.b.4"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-http-message-transformations">HTTP Message Transformations</xref></t>
              </li>
            </ul>
          </li>
          <li pn="section-toc.1-1.12">
            <t indent="0" pn="section-toc.1-1.12.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.13">
            <t indent="0" pn="section-toc.1-1.13.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="intro" numbered="true" removeInRFC="false" toc="include" pn="section-1">
      <name slugifiedName="name-introduction">Introduction</name>
      <t indent="0" pn="section-1-1">Message integrity and authenticity are security properties that are critical to the secure operation of many HTTP applications.
Application developers typically rely on the transport layer to provide these properties, by operating their application over TLS <xref target="RFC8446" format="default" sectionFormat="of" derivedContent="TLS"/>. However, TLS only guarantees these properties over a single TLS connection, and the path between the client and application may be composed of multiple independent TLS connections (for example, if the application is hosted behind a TLS-terminating gateway or if the client is behind a TLS Inspection appliance). In such cases, TLS cannot guarantee end-to-end message integrity or authenticity between the client and application. Additionally, some operating environments present obstacles that make it impractical to use TLS (such as the presentation of client certificates from a browser) or to use features necessary to provide message authenticity. Furthermore, some applications require the binding of a higher-level application-specific key to the HTTP message, separate from any TLS certificates in use. Consequently, while TLS can meet message integrity and authenticity needs for many HTTP-based applications, it is not a universal solution.</t>
      <t indent="0" pn="section-1-2">Additionally, many applications need to be able to generate and verify signatures despite incomplete knowledge of the HTTP message as seen on the wire, due to the use of libraries, proxies, or application frameworks that alter or hide portions of the message from the application at the time of signing or verification. These applications need a means to protect the parts of the message that are most relevant to the application without having to violate layering and abstraction.</t>
      <t indent="0" pn="section-1-3">Finally, object-based signature mechanisms such as JSON Web Signature <xref target="RFC7515" format="default" sectionFormat="of" derivedContent="JWS"/> require the intact conveyance of the exact information that was signed. When applying such technologies to an HTTP message, elements of the HTTP message need to be duplicated in the object payload either directly or through the inclusion of a hash. This practice introduces complexity, since the repeated information needs to be carefully checked for consistency when the signature is verified.</t>
      <t indent="0" pn="section-1-4">This document defines a mechanism for providing end-to-end integrity and authenticity for components of an HTTP message by using a detached signature on HTTP messages. The mechanism allows applications to create digital signatures or message authentication codes (MACs) over only the components of the message that are meaningful and appropriate for the application. Strict canonicalization rules ensure that the verifier can verify the signature even if the message has been transformed in many of the ways permitted by HTTP.</t>
      <t indent="0" pn="section-1-5">The signing mechanism described in this document consists of three parts:</t>
      <ul spacing="normal" bare="false" empty="false" indent="3" pn="section-1-6">
        <li pn="section-1-6.1">A common nomenclature and canonicalization rule set for the different protocol elements and other components of HTTP messages, used to create the signature base (<xref target="covered-components" format="default" sectionFormat="of" derivedContent="Section 2"/>).</li>
        <li pn="section-1-6.2">Algorithms for generating and verifying signatures over HTTP message components using this signature base through the application of cryptographic primitives (<xref target="message-signatures" format="default" sectionFormat="of" derivedContent="Section 3"/>).</li>
        <li pn="section-1-6.3">A mechanism for attaching a signature and related metadata to an HTTP message and for parsing attached signatures and metadata from HTTP messages. To facilitate this, this document defines the "Signature-Input" and "Signature" fields (<xref target="attach-signature" format="default" sectionFormat="of" derivedContent="Section 4"/>).</li>
      </ul>
      <t indent="0" pn="section-1-7">This document also provides a mechanism for negotiating the use of signatures in one or more subsequent messages via the "Accept-Signature" field (<xref target="request-signature" format="default" sectionFormat="of" derivedContent="Section 5"/>). This optional negotiation mechanism can be used along with opportunistic or application-driven message signatures by either party.</t>
      <t indent="0" pn="section-1-8">The mechanisms defined in this document are important tools that can be used to build an overall security mechanism for an application. This toolkit provides some powerful capabilities but is not sufficient in creating an overall security story. In particular, the requirements listed in <xref target="application" format="default" sectionFormat="of" derivedContent="Section 1.4"/> and the security considerations discussed in <xref target="security" format="default" sectionFormat="of" derivedContent="Section 7"/> are of high importance to all implementors of this specification. For example, this specification does not define a means to directly cover HTTP message content (defined in <xref section="6.4" sectionFormat="of" target="RFC9110" format="default" derivedLink="https://rfc-editor.org/rfc/rfc9110#section-6.4" derivedContent="HTTP"/>); rather, it relies on the Digest specification <xref target="RFC9530" format="default" sectionFormat="of" derivedContent="DIGEST"/> to provide a hash of the message content, as discussed in <xref target="security-message-content" format="default" sectionFormat="of" derivedContent="Section 7.2.8"/>.</t>
      <section anchor="definitions" numbered="true" removeInRFC="false" toc="include" pn="section-1.1">
        <name slugifiedName="name-conventions-and-terminology">Conventions and Terminology</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>
        <t indent="0" pn="section-1.1-2">The terms "HTTP message", "HTTP request", "HTTP response",
"target URI", "gateway", "header field", "intermediary", "request target",
"trailer field", "sender", "method", and "recipient" are used as defined in <xref target="RFC9110" format="default" sectionFormat="of" derivedContent="HTTP"/>.</t>
        <t indent="0" pn="section-1.1-3">For brevity, the term "signature" on its own is used in this document to refer to both digital signatures (which use asymmetric cryptography) and keyed MACs (which use symmetric cryptography). Similarly, the verb "sign" refers to the generation of either a digital signature or keyed MAC over a given signature base. The qualified term "digital signature" refers specifically to the output of an asymmetric cryptographic signing operation.</t>
        <t indent="0" pn="section-1.1-4">This document uses the following terminology from <xref section="3" sectionFormat="of" target="RFC8941" format="default" derivedLink="https://rfc-editor.org/rfc/rfc8941#section-3" derivedContent="STRUCTURED-FIELDS"/>
to specify data types: List, Inner List, Dictionary, Item, String, Integer, Byte Sequence, and Boolean.</t>
        <t indent="0" pn="section-1.1-5">This document defines several string constructions using ABNF <xref target="RFC5234" format="default" sectionFormat="of" derivedContent="ABNF"/> and uses the following ABNF rules: <tt>VCHAR</tt>, <tt>SP</tt>, <tt>DQUOTE</tt>, and <tt>LF</tt>. This document uses the following ABNF rules from <xref target="RFC8941" format="default" sectionFormat="of" derivedContent="STRUCTURED-FIELDS"/>: <tt>sf-string</tt>, <tt>inner-list</tt>, and <tt>parameters</tt>. This document uses the following ABNF rules from <xref target="RFC9110" format="default" sectionFormat="of" derivedContent="HTTP"/> and <xref target="RFC9112" format="default" sectionFormat="of" derivedContent="HTTP/1.1"/>: <tt>field-content</tt>, <tt>obs-fold</tt>, and <tt>obs-text</tt>.</t>
        <t indent="0" pn="section-1.1-6">In addition to those listed above, this document uses the following terms:</t>
        <dl newline="true" indent="3" spacing="normal" pn="section-1.1-7">
          <dt pn="section-1.1-7.1">HTTP Message Signature:</dt>
          <dd pn="section-1.1-7.2">
            <t indent="0" pn="section-1.1-7.2.1">A digital signature or keyed MAC that covers one or more portions of an HTTP message. Note that a given HTTP message can contain multiple HTTP message signatures.</t>
          </dd>
          <dt pn="section-1.1-7.3">Signer:</dt>
          <dd pn="section-1.1-7.4">
            <t indent="0" pn="section-1.1-7.4.1">The entity that is generating or has generated an HTTP message signature. Note that multiple entities can act as signers and apply separate HTTP message signatures to a given HTTP message.</t>
          </dd>
          <dt pn="section-1.1-7.5">Verifier:</dt>
          <dd pn="section-1.1-7.6">
            <t indent="0" pn="section-1.1-7.6.1">An entity that is verifying or has verified an HTTP message signature against an HTTP message. Note that an HTTP message signature may be verified multiple times, potentially by different entities.</t>
          </dd>
          <dt pn="section-1.1-7.7">HTTP Message Component:</dt>
          <dd pn="section-1.1-7.8">
            <t indent="0" pn="section-1.1-7.8.1">A portion of an HTTP message that is capable of being covered by an HTTP message signature.</t>
          </dd>
          <dt pn="section-1.1-7.9">Derived Component:</dt>
          <dd pn="section-1.1-7.10">
            <t indent="0" pn="section-1.1-7.10.1">An HTTP message component derived from the HTTP message through the use of a specified algorithm or process. See <xref target="derived-components" format="default" sectionFormat="of" derivedContent="Section 2.2"/>.</t>
          </dd>
          <dt pn="section-1.1-7.11">HTTP Message Component Name:</dt>
          <dd pn="section-1.1-7.12">
            <t indent="0" pn="section-1.1-7.12.1">A String that identifies an HTTP message component's source, such as a field name or derived component name.</t>
          </dd>
          <dt pn="section-1.1-7.13">HTTP Message Component Identifier:</dt>
          <dd pn="section-1.1-7.14">
            <t indent="0" pn="section-1.1-7.14.1">The combination of an HTTP message component name and any parameters. This combination uniquely identifies a specific HTTP message component with respect to a particular HTTP message signature and the HTTP message it applies to.</t>
          </dd>
          <dt pn="section-1.1-7.15">HTTP Message Component Value:</dt>
          <dd pn="section-1.1-7.16">
            <t indent="0" pn="section-1.1-7.16.1">The value associated with a given component identifier within the context of a particular HTTP message. Component values are derived from the HTTP message and are usually subject to a canonicalization process.</t>
          </dd>
          <dt pn="section-1.1-7.17">Covered Components:</dt>
          <dd pn="section-1.1-7.18">
            <t indent="0" pn="section-1.1-7.18.1">An ordered set of HTTP message component identifiers for fields (<xref target="http-fields" format="default" sectionFormat="of" derivedContent="Section 2.1"/>) and derived components (<xref target="derived-components" format="default" sectionFormat="of" derivedContent="Section 2.2"/>) that indicates the set of message components covered by the signature, never including the <tt>@signature-params</tt> identifier itself. The order of this set is preserved and communicated between the signer and verifier to facilitate reconstruction of the signature base.</t>
          </dd>
          <dt pn="section-1.1-7.19">Signature Base:</dt>
          <dd pn="section-1.1-7.20">
            <t indent="0" pn="section-1.1-7.20.1">The sequence of bytes generated by the signer and verifier using the covered components set and the HTTP message. The signature base is processed by the cryptographic algorithm to produce or verify the HTTP message signature.</t>
          </dd>
          <dt pn="section-1.1-7.21">HTTP Message Signature Algorithm:</dt>
          <dd pn="section-1.1-7.22">
            <t indent="0" pn="section-1.1-7.22.1">A cryptographic algorithm that describes the signing and verification process for the signature, defined in terms of the <tt>HTTP_SIGN</tt> and <tt>HTTP_VERIFY</tt> primitives described in <xref target="signature-methods" format="default" sectionFormat="of" derivedContent="Section 3.3"/>.</t>
          </dd>
          <dt pn="section-1.1-7.23">Key Material:</dt>
          <dd pn="section-1.1-7.24">
            <t indent="0" pn="section-1.1-7.24.1">The key material required to create or verify the signature. The key material is often identified with an explicit key identifier, allowing the signer to indicate to the verifier which key was used.</t>
          </dd>
          <dt pn="section-1.1-7.25">Creation Time:</dt>
          <dd pn="section-1.1-7.26">
            <t indent="0" pn="section-1.1-7.26.1">A timestamp representing the point in time that the signature was generated, as asserted by the signer.</t>
          </dd>
          <dt pn="section-1.1-7.27">Expiration Time:</dt>
          <dd pn="section-1.1-7.28">
            <t indent="0" pn="section-1.1-7.28.1">A timestamp representing the point in time after which the signature should no longer be accepted by the verifier, as asserted by the signer.</t>
          </dd>
          <dt pn="section-1.1-7.29">Target Message:</dt>
          <dd pn="section-1.1-7.30">
            <t indent="0" pn="section-1.1-7.30.1">The HTTP message to which an HTTP message signature is applied.</t>
          </dd>
          <dt pn="section-1.1-7.31">Signature Context:</dt>
          <dd pn="section-1.1-7.32">
            <t indent="0" pn="section-1.1-7.32.1">The data source from which the HTTP message component values are drawn. The context includes the target message and any additional information the signer or verifier might have, such as the full target URI of a request or the related request message for a response.</t>
          </dd>
        </dl>
        <t indent="0" pn="section-1.1-8">The term "UNIX timestamp" refers to what Section 4.16 of <xref target="POSIX" format="default" sectionFormat="of" derivedContent="POSIX.1"/> calls "seconds since the Epoch".</t>
        <t indent="0" pn="section-1.1-9">This document contains non-normative examples of partial and complete HTTP messages. Some examples use a single trailing backslash (<tt>\</tt>) to indicate line wrapping for long values, as per <xref target="RFC8792" format="default" sectionFormat="of" derivedContent="RFC8792"/>. The <tt>\</tt> character and leading spaces on wrapped lines are not part of the value.</t>
      </section>
      <section anchor="requirements" numbered="true" removeInRFC="false" toc="include" pn="section-1.2">
        <name slugifiedName="name-requirements">Requirements</name>
        <t indent="0" pn="section-1.2-1">HTTP permits, and sometimes requires, intermediaries to transform messages in a variety of ways. This can result in a recipient receiving a message that is not bitwise-equivalent to the message that was originally sent. In such a case, the recipient will be unable to verify integrity protections over the raw bytes of the sender's HTTP message, as verifying digital signatures or MACs requires both signer and verifier to have the exact same signature base. Since the exact raw bytes of the message cannot be relied upon as a reliable source for a signature base, the signer and verifier have to independently create the signature base from their respective versions of the message, via a mechanism that is resilient to safe changes that do not alter the meaning of the message.</t>
        <t indent="0" pn="section-1.2-2">For a variety of reasons, it is impractical to strictly define what constitutes a safe change versus an unsafe one. Applications use HTTP in a wide variety of ways and may disagree on whether a particular piece of information in a message (e.g., the message content, the method, or a particular header field) is relevant. Thus, a general-purpose solution needs to provide signers with some degree of control over which message components are signed.</t>
        <t indent="0" pn="section-1.2-3">HTTP applications may be running in environments that do not provide complete access to or control over HTTP messages (such as a web browser's JavaScript environment) or may be using libraries that abstract away the details of the protocol (such as <eref target="https://openjdk.java.net/groups/net/httpclient/intro.html" brackets="none">the Java HTTP Client (HttpClient) library</eref>). These applications need to be able to generate and verify signatures despite incomplete knowledge of the HTTP message.</t>
      </section>
      <section anchor="transforms" numbered="true" removeInRFC="false" toc="include" pn="section-1.3">
        <name slugifiedName="name-http-message-transformation">HTTP Message Transformations</name>
        <t indent="0" pn="section-1.3-1">As mentioned earlier, HTTP explicitly permits, and in some cases requires, implementations to transform messages in a variety of ways. Implementations are required to tolerate many of these transformations. What follows is a non-normative and non-exhaustive list of transformations that could occur under HTTP, provided as context:</t>
        <ul spacing="normal" bare="false" empty="false" indent="3" pn="section-1.3-2">
          <li pn="section-1.3-2.1">Reordering of fields with different field names (<xref section="5.3" sectionFormat="of" target="RFC9110" format="default" derivedLink="https://rfc-editor.org/rfc/rfc9110#section-5.3" derivedContent="HTTP"/>).</li>
          <li pn="section-1.3-2.2">Combination of fields with the same field name (<xref section="5.2" sectionFormat="of" target="RFC9110" format="default" derivedLink="https://rfc-editor.org/rfc/rfc9110#section-5.2" derivedContent="HTTP"/>).</li>
          <li pn="section-1.3-2.3">Removal of fields listed in the Connection header field (<xref section="7.6.1" sectionFormat="of" target="RFC9110" format="default" derivedLink="https://rfc-editor.org/rfc/rfc9110#section-7.6.1" derivedContent="HTTP"/>).</li>
          <li pn="section-1.3-2.4">Addition of fields that indicate control options (<xref section="7.6.1" sectionFormat="of" target="RFC9110" format="default" derivedLink="https://rfc-editor.org/rfc/rfc9110#section-7.6.1" derivedContent="HTTP"/>).</li>
          <li pn="section-1.3-2.5">Addition or removal of a transfer coding (<xref section="7.7" sectionFormat="of" target="RFC9110" format="default" derivedLink="https://rfc-editor.org/rfc/rfc9110#section-7.7" derivedContent="HTTP"/>).</li>
          <li pn="section-1.3-2.6">Addition of fields such as Via (<xref section="7.6.3" sectionFormat="of" target="RFC9110" format="default" derivedLink="https://rfc-editor.org/rfc/rfc9110#section-7.6.3" derivedContent="HTTP"/>) and Forwarded (<xref section="4" sectionFormat="of" target="RFC7239" format="default" derivedLink="https://rfc-editor.org/rfc/rfc7239#section-4" derivedContent="RFC7239"/>).</li>
          <li pn="section-1.3-2.7">Conversion between different versions of HTTP (e.g., HTTP/1.x to HTTP/2, or vice versa).</li>
          <li pn="section-1.3-2.8">Changes in case (e.g., "Origin" to "origin") of any case-insensitive components such as field names, request URI scheme, or host.</li>
          <li pn="section-1.3-2.9">Changes to the request target and authority that, when applied together, do not
  result in a change to the message's target URI, as defined in <xref section="7.1" sectionFormat="of" target="RFC9110" format="default" derivedLink="https://rfc-editor.org/rfc/rfc9110#section-7.1" derivedContent="HTTP"/>.</li>
        </ul>
        <t indent="0" pn="section-1.3-3">Additionally, there are some transformations that are either deprecated or otherwise not allowed but that could still occur in the wild. These transformations can still be handled without breaking the signature; they include
such actions as:</t>
        <ul spacing="normal" bare="false" empty="false" indent="3" pn="section-1.3-4">
          <li pn="section-1.3-4.1">Use, addition, or removal of leading or trailing whitespace in a field value.</li>
          <li pn="section-1.3-4.2">Use, addition, or removal of <tt>obs-fold</tt> in field values (<xref section="5.2" sectionFormat="of" target="RFC9112" format="default" derivedLink="https://rfc-editor.org/rfc/rfc9112#section-5.2" derivedContent="HTTP/1.1"/>).</li>
        </ul>
        <t indent="0" pn="section-1.3-5">We can identify these types of transformations as transformations that should not prevent signature verification, even when performed on message components covered by the signature. Additionally, all changes to components not covered by the signature should not prevent signature verification.</t>
        <t indent="0" pn="section-1.3-6">Some examples of these kinds of transformations, and the effect they have on the message signature, are found in <xref target="example-transform" format="default" sectionFormat="of" derivedContent="Appendix B.4"/>.</t>
        <t indent="0" pn="section-1.3-7">Other transformations, such as parsing and reserializing the field values of a covered component or changing the value of a derived component, can cause a signature to no longer validate against a target message. Applications of this specification need to take care to ensure that the transformations expected by the application are adequately handled by the choice of covered components.</t>
      </section>
      <section anchor="application" numbered="true" removeInRFC="false" toc="include" pn="section-1.4">
        <name slugifiedName="name-application-of-http-message">Application of HTTP Message Signatures</name>
        <t indent="0" pn="section-1.4-1">HTTP message signatures are designed to be a general-purpose tool applicable in a wide variety of circumstances and applications. In order to properly and safely apply HTTP message signatures, an application or profile of this specification <bcp14>MUST</bcp14> specify, at a minimum, all of the following items:</t>
        <ul spacing="normal" bare="false" empty="false" indent="3" pn="section-1.4-2">
          <li pn="section-1.4-2.1">The set of <xref target="covered-components" format="default" sectionFormat="of" derivedContent="Section 2">component identifiers</xref> and <xref target="signature-params" format="default" sectionFormat="of" derivedContent="Section 2.3">signature parameters</xref> that are expected and required to be included in the covered components list. For example, an authorization protocol could mandate that the Authorization field be covered to protect the authorization credentials and mandate that the signature parameters contain a <tt>created</tt> parameter (<xref target="signature-params" format="default" sectionFormat="of" derivedContent="Section 2.3"/>), while an API expecting semantically relevant HTTP message content could require the Content-Digest field defined in <xref target="RFC9530" format="default" sectionFormat="of" derivedContent="DIGEST"/> to be present and covered as well as mandate a value for the <tt>tag</tt> parameter (<xref target="signature-params" format="default" sectionFormat="of" derivedContent="Section 2.3"/>) that is specific to the API being protected.</li>
          <li pn="section-1.4-2.2">The expected Structured Field types <xref target="RFC8941" format="default" sectionFormat="of" derivedContent="STRUCTURED-FIELDS"/> of any required or expected covered component fields or parameters.</li>
          <li pn="section-1.4-2.3">A means of retrieving the key material used to verify the signature. An application will usually use the <tt>keyid</tt> parameter of the signature parameters (<xref target="signature-params" format="default" sectionFormat="of" derivedContent="Section 2.3"/>) and define rules for resolving a key from there, though the appropriate key could be known from other means such as preregistration of a signer's key.</li>
          <li pn="section-1.4-2.4">The set of allowable signature algorithms to be used by signers and accepted by verifiers.</li>
          <li pn="section-1.4-2.5">A means of determining that the signature algorithm used to verify the signature is appropriate for the key material and context of the message. For example, the process could use the <tt>alg</tt> parameter of the signature parameters (<xref target="signature-params" format="default" sectionFormat="of" derivedContent="Section 2.3"/>) to state the algorithm explicitly, derive the algorithm from the key material, or use some preconfigured algorithm agreed upon by the signer and verifier.</li>
          <li pn="section-1.4-2.6">A means of determining that a given key and algorithm used for a signature are appropriate for the context of the message. For example, a server expecting only ECDSA signatures should know to reject any RSA signatures, or a server expecting asymmetric cryptography should know to reject any symmetric cryptography.</li>
          <li pn="section-1.4-2.7">A means of determining the context for derivation of message components from an HTTP message and its application context. While this is normally the target HTTP message itself, the context could include additional information known to the application through configuration, such as an external hostname.</li>
          <li pn="section-1.4-2.8">If binding between a request and response is needed using the mechanism provided in <xref target="content-request-response" format="default" sectionFormat="of" derivedContent="Section 2.4"/>, all elements of the request message and the response message that would be required to provide properties of such a binding.</li>
          <li pn="section-1.4-2.9">The error messages and codes that are returned from the verifier to the signer when the signature is invalid, the key material is inappropriate, the validity time window is out of specification, a component value cannot be calculated, or any other errors occur during the signature verification process. For example, if a signature is being used as an authentication mechanism, an HTTP status code of 401 (Unauthorized) or 403 (Forbidden) could be appropriate. If the response is from an HTTP API, a response with an HTTP status code such as 400 (Bad Request) could include more details <xref target="RFC7807" format="default" sectionFormat="of" derivedContent="RFC7807"/> <xref target="RFC9457" format="default" sectionFormat="of" derivedContent="RFC9457"/>, such as an indicator that the wrong key material was used.</li>
        </ul>
        <t indent="0" pn="section-1.4-3">When choosing these parameters, an application of HTTP message signatures has to ensure that the verifier will have access to all required information needed to recreate the signature base. For example, a server behind a reverse proxy would need to know the original request URI to make use of the derived component <tt>@target-uri</tt>, even though the apparent target URI would be changed by the reverse proxy (see also <xref target="security-message-component-context" format="default" sectionFormat="of" derivedContent="Section 7.4.3"/>). Additionally, an application using signatures in responses would need to ensure that clients receiving signed responses have access to all the signed portions of the message, including any portions of the request that were signed by the server using the <tt>req</tt> ("request-response") parameter (<xref target="content-request-response" format="default" sectionFormat="of" derivedContent="Section 2.4"/>).</t>
        <t indent="0" pn="section-1.4-4">Details regarding this kind of profiling are within the purview of the application and outside the scope of this specification; however, some additional considerations are discussed in <xref target="security" format="default" sectionFormat="of" derivedContent="Section 7"/>. In particular, when choosing the required set of component identifiers, care has to be taken to make sure that the coverage is sufficient for the application, as discussed in
Sections <xref target="security-coverage" format="counter" sectionFormat="of" derivedContent="7.2.1"/> and  <xref target="security-message-content" format="counter" sectionFormat="of" derivedContent="7.2.8"/>. This specification defines only part of a full security system for an application. When building a complete security system based on this tool, it is important to perform a security analysis of the entire system, of which HTTP message signatures is a part. Historical systems, such as AWS Signature Version 4 <xref target="AWS-SIGv4" format="default" sectionFormat="of" derivedContent="AWS-SIGv4"/>, can provide inspiration and examples of how to apply similar mechanisms to an application, though review of such historical systems does not negate the need for a security analysis of an application of HTTP message signatures.</t>
      </section>
    </section>
    <section anchor="covered-components" numbered="true" removeInRFC="false" toc="include" pn="section-2">
      <name slugifiedName="name-http-message-components">HTTP Message Components</name>
      <t indent="0" pn="section-2-1">In order to allow signers and verifiers to establish which components are covered by a signature, this document defines component identifiers for components covered by an HTTP message signature, a set of rules for deriving and canonicalizing the values associated with these component identifiers from the HTTP message, and the means for combining these canonicalized values into a signature base.</t>
      <t indent="0" pn="section-2-2">The signature context for deriving these values <bcp14>MUST</bcp14> be accessible to both the signer and the verifier of the message. The context <bcp14>MUST</bcp14> be the same across all components in a given signature. For example, it would be an error to use the raw query string for the <tt>@query</tt> derived component but combined query and form parameters for the <tt>@query-param</tt> derived component. For more considerations regarding the message component context, see <xref target="security-message-component-context" format="default" sectionFormat="of" derivedContent="Section 7.4.3"/>.</t>
      <t indent="0" pn="section-2-3">A component identifier is composed of a component name and any parameters associated with that name. Each component name is either an HTTP field name (<xref target="http-fields" format="default" sectionFormat="of" derivedContent="Section 2.1"/>) or a registered derived component name (<xref target="derived-components" format="default" sectionFormat="of" derivedContent="Section 2.2"/>). The possible parameters for a component identifier are dependent on the component identifier. The "HTTP Signature Component Parameters" registry, which catalogs all possible parameters, is defined in <xref target="component-param-registry" format="default" sectionFormat="of" derivedContent="Section 6.5"/>.</t>
      <t indent="0" pn="section-2-4">Within a single list of covered components, each component identifier <bcp14>MUST</bcp14> occur only once. One component identifier is distinct from another if the component name differs or if any of the parameters differ for the same component name. Multiple component identifiers having the same component name <bcp14>MAY</bcp14> be included if they have parameters that make them distinct, such as <tt>"foo";bar</tt> and <tt>"foo";baz</tt>. The order of parameters <bcp14>MUST</bcp14> be preserved when processing a component identifier (such as when parsing during verification), but the order of parameters is not significant when comparing two component identifiers for equality checks. That is to say, <tt>"foo";bar;baz</tt> cannot be in the same message as <tt>"foo";baz;bar</tt>, since these two component identifiers are equivalent, but a system processing one form is not allowed to transform it into the other form.</t>
      <t indent="0" pn="section-2-5">The component value associated with a component identifier is defined by the identifier itself. Component values <bcp14>MUST NOT</bcp14> contain newline (<tt>\n</tt>) characters. Some HTTP message components can undergo transformations that change the bitwise value without altering the meaning of the component's value (for example, when combining field values). Message component values therefore need to be canonicalized before they are signed, to ensure that a signature can be verified despite such intermediary transformations. This document defines rules for each component identifier that transform the identifier's associated component value into such a canonical form.</t>
      <t indent="0" pn="section-2-6">The following sections define component identifier names, their parameters, their associated values, and the canonicalization rules for their values. The method for combining message components into the signature base is defined in <xref target="create-sig-input" format="default" sectionFormat="of" derivedContent="Section 2.5"/>.</t>
      <section anchor="http-fields" numbered="true" removeInRFC="false" toc="include" pn="section-2.1">
        <name slugifiedName="name-http-fields">HTTP Fields</name>
        <t indent="0" pn="section-2.1-1">The component name for an HTTP field is the lowercased form of its field name as defined in <xref section="5.1" sectionFormat="of" target="RFC9110" format="default" derivedLink="https://rfc-editor.org/rfc/rfc9110#section-5.1" derivedContent="HTTP"/>. While HTTP field names are case insensitive, implementations <bcp14>MUST</bcp14> use lowercased field names (e.g., <tt>content-type</tt>, <tt>date</tt>, <tt>etag</tt>) when using them as component names.</t>
        <t indent="0" pn="section-2.1-2">The component value for an HTTP field is the field value for the named field as defined in <xref section="5.5" sectionFormat="of" target="RFC9110" format="default" derivedLink="https://rfc-editor.org/rfc/rfc9110#section-5.5" derivedContent="HTTP"/>. The field value <bcp14>MUST</bcp14> be taken from the named header field of the target message unless this behavior is overridden by additional parameters and rules, such as the <tt>req</tt> and <tt>tr</tt> flags, below. For most fields, the field value is an ASCII string as recommended by <xref target="RFC9110" format="default" sectionFormat="of" derivedContent="HTTP"/>, and the component value is exactly that string. Other encodings could exist in some implementations, and all non-ASCII field values <bcp14>MUST</bcp14> be encoded to ASCII before being added to the signature base. The <tt>bs</tt> parameter, as described in <xref target="http-field-byte-sequence" format="default" sectionFormat="of" derivedContent="Section 2.1.3"/>, provides a method for wrapping such problematic field values.</t>
        <t indent="0" pn="section-2.1-3">Unless overridden by additional parameters and rules, HTTP field values <bcp14>MUST</bcp14> be combined into a single value as defined in <xref section="5.2" sectionFormat="of" target="RFC9110" format="default" derivedLink="https://rfc-editor.org/rfc/rfc9110#section-5.2" derivedContent="HTTP"/> to create the component value. Specifically, HTTP fields sent as multiple fields <bcp14>MUST</bcp14> be combined by concatenating the values using a single comma and a single space as a separator ("," + " "). Note that intermediaries are allowed to combine values of HTTP fields with any amount of whitespace between the commas, and if this behavior is not accounted for by the verifier, the signature can fail, since the signer and verifier will see a different component value in their respective signature bases. For robustness, it is <bcp14>RECOMMENDED</bcp14> that signed messages include only a single instance of any field covered under the signature, particularly with the value for any list-based fields serialized using the algorithm below. This approach increases the chances of the field value remaining untouched through intermediaries. Where that approach is not possible and multiple instances of a field need to be sent separately, it is <bcp14>RECOMMENDED</bcp14> that signers and verifiers process any list-based fields taking all individual field values and combining them based on the strict algorithm below, to counter possible intermediary behavior. When the field in question is a Structured Field of type List or Dictionary, this effect can be accomplished more directly by requiring the strict Structured Field serialization of the field value, as described in <xref target="http-field-structured" format="default" sectionFormat="of" derivedContent="Section 2.1.1"/>.</t>
        <t indent="0" pn="section-2.1-4">Note that some HTTP fields, such as Set-Cookie <xref target="RFC6265" format="default" sectionFormat="of" derivedContent="COOKIE"/>, do not follow a syntax that allows for the combination of field values in this manner (such that the combined output is unambiguous from multiple inputs). Even though the component value is never parsed by the message signature process and is used only as part of the signature base (<xref target="create-sig-input" format="default" sectionFormat="of" derivedContent="Section 2.5"/>), caution needs to be taken when including such fields in signatures, since the combined value could be ambiguous. The <tt>bs</tt> parameter, as described in <xref target="http-field-byte-sequence" format="default" sectionFormat="of" derivedContent="Section 2.1.3"/>, provides a method for wrapping such problematic fields. See <xref target="security-non-list" format="default" sectionFormat="of" derivedContent="Section 7.5.6"/> for more discussion regarding this issue.</t>
        <t indent="0" pn="section-2.1-5">If the correctly combined value is not directly available for a given field by an implementation, the following algorithm will produce canonicalized results for list-based fields:</t>
        <ol spacing="normal" type="1" indent="adaptive" start="1" pn="section-2.1-6"><li pn="section-2.1-6.1" derivedCounter="1.">Create an ordered list of the field values of each instance of the field in the message, in the order they occur (or will occur) in the message.</li>
          <li pn="section-2.1-6.2" derivedCounter="2.">Strip leading and trailing whitespace from each item in the list. Note that since HTTP field values are not allowed to contain leading and trailing whitespace, this would be a no-op in a compliant implementation.</li>
          <li pn="section-2.1-6.3" derivedCounter="3.">Remove any obsolete line folding within the line, and replace it with a single space (" "), as discussed in <xref section="5.2" sectionFormat="of" target="RFC9112" format="default" derivedLink="https://rfc-editor.org/rfc/rfc9112#section-5.2" derivedContent="HTTP/1.1"/>. Note that this behavior is specific to HTTP/1.1 and does not apply to other versions of the HTTP specification, which do not allow internal line folding.</li>
          <li pn="section-2.1-6.4" derivedCounter="4.">Concatenate the list of values with a single comma (",") and a single space (" ") between each item.</li>
        </ol>
        <t indent="0" pn="section-2.1-7">The resulting string is the component value for the field.</t>
        <t indent="0" pn="section-2.1-8">Note that some HTTP fields have values with multiple valid serializations that have equivalent semantics, such as allowing case-insensitive values that intermediaries could change. Applications signing and processing such fields <bcp14>MUST</bcp14> consider how to handle the values of such fields to ensure that the signer and verifier can derive the same value, as discussed in <xref target="security-field-values" format="default" sectionFormat="of" derivedContent="Section 7.5.2"/>.</t>
        <t indent="0" pn="section-2.1-9">The following are non-normative examples of component values for header fields, given the following example HTTP message fragment:</t>
        <sourcecode type="http-message" markers="false" pn="section-2.1-10">
Host: www.example.com
Date: Tue, 20 Apr 2021 02:07:56 GMT
X-OWS-Header:   Leading and trailing whitespace.
X-Obs-Fold-Header: Obsolete
    line folding.
Cache-Control: max-age=60
Cache-Control:    must-revalidate
Example-Dict:  a=1,    b=2;x=1;y=2,   c=(a   b   c)
</sourcecode>
        <t indent="0" pn="section-2.1-11">The following example shows the component values for these example header fields, presented using the signature base format defined in <xref target="create-sig-input" format="default" sectionFormat="of" derivedContent="Section 2.5"/>:</t>
        <artwork align="left" pn="section-2.1-12">
"host": www.example.com
"date": Tue, 20 Apr 2021 02:07:56 GMT
"x-ows-header": Leading and trailing whitespace.
"x-obs-fold-header": Obsolete line folding.
"cache-control": max-age=60, must-revalidate
"example-dict": a=1,    b=2;x=1;y=2,   c=(a   b   c)
</artwork>
        <t indent="0" pn="section-2.1-13">Empty HTTP fields can also be signed when present in a message. The canonicalized value is the empty string. This means that the following empty header field, with (SP) indicating a single trailing space character before the empty field value:</t>
        <artwork align="left" pn="section-2.1-14">
X-Empty-Header:(SP)
</artwork>
        <t indent="0" pn="section-2.1-15">is serialized by the <xref target="create-sig-input" format="default" sectionFormat="of" derivedContent="Section 2.5">signature base generation algorithm</xref> with an empty string value following the colon and space added after the component identifier.</t>
        <artwork align="left" pn="section-2.1-16">
"x-empty-header":(SP)
</artwork>
        <t indent="0" pn="section-2.1-17">Any HTTP field component identifiers <bcp14>MAY</bcp14> have the following parameters in specific circumstances, each described in detail in their own sections:</t>
        <dl indent="3" newline="false" spacing="normal" pn="section-2.1-18">
          <dt pn="section-2.1-18.1"><tt>sf</tt></dt>
          <dd pn="section-2.1-18.2">
            <t indent="0" pn="section-2.1-18.2.1">A Boolean flag indicating that the component value is serialized using strict encoding
of the Structured Field value (<xref target="http-field-structured" format="default" sectionFormat="of" derivedContent="Section 2.1.1"/>).</t>
          </dd>
          <dt pn="section-2.1-18.3"><tt>key</tt></dt>
          <dd pn="section-2.1-18.4">
            <t indent="0" pn="section-2.1-18.4.1">A String parameter used to select a single member value from a Dictionary Structured Field (<xref target="http-field-dictionary" format="default" sectionFormat="of" derivedContent="Section 2.1.2"/>).</t>
          </dd>
          <dt pn="section-2.1-18.5"><tt>bs</tt></dt>
          <dd pn="section-2.1-18.6">
            <t indent="0" pn="section-2.1-18.6.1">A Boolean flag indicating that individual field values are encoded using Byte Sequence data structures before being combined into the component value (<xref target="http-field-byte-sequence" format="default" sectionFormat="of" derivedContent="Section 2.1.3"/>).</t>
          </dd>
          <dt pn="section-2.1-18.7"><tt>req</tt></dt>
          <dd pn="section-2.1-18.8">
            <t indent="0" pn="section-2.1-18.8.1">A Boolean flag for signed responses indicating that the component value is derived from the request that triggered this response message and not from the response message directly. Note that this parameter can also be applied to any derived component identifiers that target the request (<xref target="content-request-response" format="default" sectionFormat="of" derivedContent="Section 2.4"/>).</t>
          </dd>
          <dt pn="section-2.1-18.9"><tt>tr</tt></dt>
          <dd pn="section-2.1-18.10">
            <t indent="0" pn="section-2.1-18.10.1">A Boolean flag indicating that the field value is taken from the trailers of the message as defined in <xref section="6.5" sectionFormat="of" target="RFC9110" format="default" derivedLink="https://rfc-editor.org/rfc/rfc9110#section-6.5" derivedContent="HTTP"/>. If this flag is absent, the field value is taken from the header fields of the message as defined in <xref section="6.3" sectionFormat="of" target="RFC9110" format="default" derivedLink="https://rfc-editor.org/rfc/rfc9110#section-6.3" derivedContent="HTTP"/> (<xref target="http-trailer" format="default" sectionFormat="of" derivedContent="Section 2.1.4"/>).</t>
          </dd>
        </dl>
        <t indent="0" pn="section-2.1-19">Multiple parameters <bcp14>MAY</bcp14> be specified together, though some combinations are redundant or incompatible. For example, the <tt>sf</tt> parameter's functionality is already covered when the <tt>key</tt> parameter is used on a Dictionary item, since <tt>key</tt> requires strict serialization of the value. The <tt>bs</tt> parameter, which requires the raw bytes of the field values from the message, is not compatible with the use of the <tt>sf</tt> or <tt>key</tt> parameters, which require the parsed data structures of the field values after combination.</t>
        <t indent="0" pn="section-2.1-20">Additional parameters can be defined in the "HTTP Signature Component Parameters" registry established in <xref target="component-param-registry" format="default" sectionFormat="of" derivedContent="Section 6.5"/>.</t>
        <section anchor="http-field-structured" numbered="true" removeInRFC="false" toc="include" pn="section-2.1.1">
          <name slugifiedName="name-strict-serialization-of-htt">Strict Serialization of HTTP Structured Fields</name>
          <t indent="0" pn="section-2.1.1-1">If the value of an HTTP field is known by the application to be a Structured Field type (as defined in <xref target="RFC8941" format="default" sectionFormat="of" derivedContent="STRUCTURED-FIELDS"/> or its extensions or updates) and the expected type of the Structured Field is known, the signer <bcp14>MAY</bcp14> include the <tt>sf</tt> parameter in the component identifier.
If this parameter is included with a component identifier, the HTTP field value <bcp14>MUST</bcp14> be serialized using the formal serialization rules specified in <xref section="4" sectionFormat="of" target="RFC8941" format="default" derivedLink="https://rfc-editor.org/rfc/rfc8941#section-4" derivedContent="STRUCTURED-FIELDS"/> (or the
applicable formal serialization section of its extensions or updates) applicable to
the type of the HTTP field. Note that this process
will replace any optional internal whitespace with a single space character, among other potential transformations of the value.</t>
          <t indent="0" pn="section-2.1.1-2">If multiple field values occur within a message, these values <bcp14>MUST</bcp14> be combined into a single List or Dictionary structure before serialization.</t>
          <t indent="0" pn="section-2.1.1-3">If the application does not know the type of the field or does not know how to serialize the type of the field, the use of this flag will produce an error. As a consequence, the signer can only reliably sign fields using this flag when the verifier's system knows the type as well.</t>
          <t indent="0" pn="section-2.1.1-4">For example, the following Dictionary field is a valid serialization:</t>
          <sourcecode type="http-message" markers="false" pn="section-2.1.1-5">
Example-Dict:  a=1,    b=2;x=1;y=2,   c=(a   b   c)
</sourcecode>
          <t indent="0" pn="section-2.1.1-6">If included in the signature base without parameters, its value would be:</t>
          <artwork align="left" pn="section-2.1.1-7">
"example-dict": a=1,    b=2;x=1;y=2,   c=(a   b   c)
</artwork>
          <t indent="0" pn="section-2.1.1-8">However, if the <tt>sf</tt> parameter is added, the value is reserialized as follows:</t>
          <artwork align="left" pn="section-2.1.1-9">
"example-dict";sf: a=1, b=2;x=1;y=2, c=(a b c)
</artwork>
          <t indent="0" pn="section-2.1.1-10">The resulting string is used as the component value; see <xref target="http-fields" format="default" sectionFormat="of" derivedContent="Section 2.1"/>.</t>
        </section>
        <section anchor="http-field-dictionary" numbered="true" removeInRFC="false" toc="include" pn="section-2.1.2">
          <name slugifiedName="name-dictionary-structured-field">Dictionary Structured Field Members</name>
          <t indent="0" pn="section-2.1.2-1">If a given field is known by the application to be a Dictionary Structured Field, an individual member in the value of that Dictionary is identified by using the parameter <tt>key</tt> and the Dictionary member key as a String value.</t>
          <t indent="0" pn="section-2.1.2-2">If multiple field values occur within a message, these values <bcp14>MUST</bcp14> be combined into a single Dictionary structure before serialization.</t>
          <t indent="0" pn="section-2.1.2-3">An individual member value of a Dictionary Structured Field is canonicalized by applying the serialization algorithm described in <xref section="4.1.2" sectionFormat="of" target="RFC8941" format="default" derivedLink="https://rfc-editor.org/rfc/rfc8941#section-4.1.2" derivedContent="STRUCTURED-FIELDS"/> on the <tt>member_value</tt> and its parameters, not including the Dictionary key itself. Specifically, the value is serialized as an Item or Inner List (the two possible values of a Dictionary member), with all parameters and possible subfields serialized using the strict serialization rules defined in <xref section="4" sectionFormat="of" target="RFC8941" format="default" derivedLink="https://rfc-editor.org/rfc/rfc8941#section-4" derivedContent="STRUCTURED-FIELDS"/> (or the applicable section of its extensions or updates).</t>
          <t indent="0" pn="section-2.1.2-4">Each parameterized key for a given field <bcp14>MUST NOT</bcp14> appear more than once in the signature base. Parameterized keys <bcp14>MAY</bcp14> appear in any order in the signature base, regardless of the order they occur in the source Dictionary.</t>
          <t indent="0" pn="section-2.1.2-5">If a Dictionary key is named as a covered component but it does not occur in the Dictionary, this <bcp14>MUST</bcp14> cause an error in the signature base generation.</t>
          <t indent="0" pn="section-2.1.2-6">The following are non-normative examples of canonicalized values for Dictionary Structured Field members, given the following example header field, whose value is known by the application to be a Dictionary:</t>
          <sourcecode type="http-message" markers="false" pn="section-2.1.2-7">
Example-Dict:  a=1, b=2;x=1;y=2, c=(a   b    c), d
</sourcecode>
          <t indent="0" pn="section-2.1.2-8">The following example shows canonicalized values for different component identifiers of this field, presented using the signature base format discussed in <xref target="create-sig-input" format="default" sectionFormat="of" derivedContent="Section 2.5"/>:</t>
          <artwork align="left" pn="section-2.1.2-9">
"example-dict";key="a": 1
"example-dict";key="d": ?1
"example-dict";key="b": 2;x=1;y=2
"example-dict";key="c": (a b c)
</artwork>
          <t indent="0" pn="section-2.1.2-10">Note that the value for <tt>key="c"</tt> has been reserialized according to the strict <tt>member_value</tt> algorithm, and the value for <tt>key="d"</tt> has been serialized as a Boolean value.</t>
        </section>
        <section anchor="http-field-byte-sequence" numbered="true" removeInRFC="false" toc="include" pn="section-2.1.3">
          <name slugifiedName="name-binary-wrapped-http-fields">Binary-Wrapped HTTP Fields</name>
          <t indent="0" pn="section-2.1.3-1">If the value of the HTTP field in question is known by the application to cause problems with serialization, particularly with the combination of multiple values into a single line as discussed in <xref target="security-non-list" format="default" sectionFormat="of" derivedContent="Section 7.5.6"/>, the signer <bcp14>SHOULD</bcp14> include the <tt>bs</tt> parameter in a component identifier to indicate that the values of the field need to be wrapped as binary structures before being combined.</t>
          <t indent="0" pn="section-2.1.3-2">If this parameter is included with a component identifier, the component value <bcp14>MUST</bcp14> be calculated using the following algorithm:</t>
          <ol spacing="normal" type="1" indent="adaptive" start="1" pn="section-2.1.3-3"><li pn="section-2.1.3-3.1" derivedCounter="1.">Let the input be the ordered set of values for a field, in the order they appear in the message.</li>
            <li pn="section-2.1.3-3.2" derivedCounter="2.">Create an empty List for accumulating processed field values.</li>
            <li pn="section-2.1.3-3.3" derivedCounter="3.">
              <t indent="0" pn="section-2.1.3-3.3.1">For each field value in the set:
              </t>
              <ol spacing="normal" type="%p%d." indent="adaptive" start="1" pn="section-2.1.3-3.3.2"><li pn="section-2.1.3-3.3.2.1" derivedCounter="3.1.">Strip leading and trailing whitespace from the field value. Note that since HTTP field values are not allowed to contain leading and trailing whitespace, this would be a no-op in a compliant implementation.</li>
                <li pn="section-2.1.3-3.3.2.2" derivedCounter="3.2.">Remove any obsolete line folding within the line, and replace it with a single space (" "), as discussed in <xref section="5.2" sectionFormat="of" target="RFC9112" format="default" derivedLink="https://rfc-editor.org/rfc/rfc9112#section-5.2" derivedContent="HTTP/1.1"/>. Note that this behavior is specific to <xref target="RFC9112" format="default" sectionFormat="of" derivedContent="HTTP/1.1"/> and does not apply to other versions of the HTTP specification.</li>
                <li pn="section-2.1.3-3.3.2.3" derivedCounter="3.3.">Encode the bytes of the resulting field value as a Byte Sequence. Note that most fields are restricted to ASCII characters, but other octets could be included in the value in some implementations.</li>
                <li pn="section-2.1.3-3.3.2.4" derivedCounter="3.4.">Add the Byte Sequence to the List accumulator.</li>
              </ol>
            </li>
            <li pn="section-2.1.3-3.4" derivedCounter="4.">The intermediate result is a List of Byte Sequence values.</li>
            <li pn="section-2.1.3-3.5" derivedCounter="5.">Follow the strict serialization of a List as described in <xref section="4.1.1" sectionFormat="of" target="RFC8941" format="default" derivedLink="https://rfc-editor.org/rfc/rfc8941#section-4.1.1" derivedContent="STRUCTURED-FIELDS"/>, and return this output.</li>
          </ol>
          <t indent="0" pn="section-2.1.3-4">For example, the following field with internal commas prevents the distinct field values from being safely combined:</t>
          <sourcecode type="http-message" markers="false" pn="section-2.1.3-5">
Example-Header: value, with, lots
Example-Header: of, commas
</sourcecode>
          <t indent="0" pn="section-2.1.3-6">In our example, the same field can be sent with a semantically different single value:</t>
          <sourcecode type="http-message" markers="false" pn="section-2.1.3-7">
Example-Header: value, with, lots, of, commas
</sourcecode>
          <t indent="0" pn="section-2.1.3-8">Both of these versions are treated differently by the application. However, if included in the signature base without parameters, the component value would be the same in both cases:</t>
          <artwork align="left" pn="section-2.1.3-9">
"example-header": value, with, lots, of, commas
</artwork>
          <t indent="0" pn="section-2.1.3-10">However, if the <tt>bs</tt> parameter is added, the two separate instances are encoded and serialized as follows:</t>
          <artwork align="left" pn="section-2.1.3-11">
"example-header";bs: :dmFsdWUsIHdpdGgsIGxvdHM=:, :b2YsIGNvbW1hcw==:
</artwork>
          <t indent="0" pn="section-2.1.3-12">For the single-instance field above, the encoding with the <tt>bs</tt> parameter is:</t>
          <artwork align="left" pn="section-2.1.3-13">
"example-header";bs: :dmFsdWUsIHdpdGgsIGxvdHMsIG9mLCBjb21tYXM=:
</artwork>
          <t indent="0" pn="section-2.1.3-14">This component value is distinct from the multiple-instance field above, preventing a collision that could potentially be exploited.</t>
        </section>
        <section anchor="http-trailer" numbered="true" removeInRFC="false" toc="include" pn="section-2.1.4">
          <name slugifiedName="name-trailer-fields">Trailer Fields</name>
          <t indent="0" pn="section-2.1.4-1">If the signer wants to include a trailer field in the signature, the signer <bcp14>MUST</bcp14> include the <tt>tr</tt> Boolean parameter to indicate that the value <bcp14>MUST</bcp14> be taken from the trailer fields and not from the header fields.</t>
          <t indent="0" pn="section-2.1.4-2">For example, given the following message:</t>
          <sourcecode type="http-message" markers="false" pn="section-2.1.4-3">
HTTP/1.1 200 OK
Content-Type: text/plain
Transfer-Encoding: chunked
Trailer: Expires

4
HTTP
7
Message
a
Signatures
0
Expires: Wed, 9 Nov 2022 07:28:00 GMT
</sourcecode>
          <t indent="0" pn="section-2.1.4-4">The signer decides to add both the Trailer header field and the Expires trailer field to the signature base, along with the status code derived component:</t>
          <artwork align="left" pn="section-2.1.4-5">
"@status": 200
"trailer": Expires
"expires";tr: Wed, 9 Nov 2022 07:28:00 GMT
</artwork>
          <t indent="0" pn="section-2.1.4-6">If a field is available as both a header and a trailer in a message, both values <bcp14>MAY</bcp14> be signed, but the values <bcp14>MUST</bcp14> be signed separately. The values of header fields and trailer fields of the same name <bcp14>MUST NOT</bcp14> be combined for purposes of the signature.</t>
          <t indent="0" pn="section-2.1.4-7">Since trailer fields could be merged into the header fields or dropped entirely by intermediaries as per <xref section="6.5.1" sectionFormat="of" target="RFC9110" format="default" derivedLink="https://rfc-editor.org/rfc/rfc9110#section-6.5.1" derivedContent="HTTP"/>, it is <bcp14>NOT RECOMMENDED</bcp14> to include trailers in the signature unless the signer knows that the verifier will have access to the values of the trailers as sent.</t>
        </section>
      </section>
      <section anchor="derived-components" numbered="true" removeInRFC="false" toc="include" pn="section-2.2">
        <name slugifiedName="name-derived-components">Derived Components</name>
        <t indent="0" pn="section-2.2-1">In addition to HTTP fields, there are a number of different components that can be derived from the control data, signature context, or other aspects of the HTTP message being signed. Such derived components can be included in the signature base by defining a component name, possible parameters, message targets, and the derivation method for its component value.</t>
        <t indent="0" pn="section-2.2-2">Derived component names <bcp14>MUST</bcp14> start with the "at" (<tt>@</tt>) character. This differentiates derived component names from HTTP field names, which cannot contain the <tt>@</tt> character as per <xref section="5.1" sectionFormat="of" target="RFC9110" format="default" derivedLink="https://rfc-editor.org/rfc/rfc9110#section-5.1" derivedContent="HTTP"/>. Processors of HTTP message signatures <bcp14>MUST</bcp14> treat derived component names separately from field names, as discussed in <xref target="security-lazy-header-parser" format="default" sectionFormat="of" derivedContent="Section 7.5.1"/>.</t>
        <t indent="0" pn="section-2.2-3">This specification defines the following derived components:</t>
        <dl indent="3" newline="false" spacing="normal" pn="section-2.2-4">
          <dt pn="section-2.2-4.1">@method</dt>
          <dd pn="section-2.2-4.2">
            <t indent="0" pn="section-2.2-4.2.1">The method used for a request (<xref target="content-request-method" format="default" sectionFormat="of" derivedContent="Section 2.2.1"/>).</t>
          </dd>
          <dt pn="section-2.2-4.3">@target-uri</dt>
          <dd pn="section-2.2-4.4">
            <t indent="0" pn="section-2.2-4.4.1">The full target URI for a request (<xref target="content-target-uri" format="default" sectionFormat="of" derivedContent="Section 2.2.2"/>).</t>
          </dd>
          <dt pn="section-2.2-4.5">@authority</dt>
          <dd pn="section-2.2-4.6">
            <t indent="0" pn="section-2.2-4.6.1">The authority of the target URI for a request (<xref target="content-request-authority" format="default" sectionFormat="of" derivedContent="Section 2.2.3"/>).</t>
          </dd>
          <dt pn="section-2.2-4.7">@scheme</dt>
          <dd pn="section-2.2-4.8">
            <t indent="0" pn="section-2.2-4.8.1">The scheme of the target URI for a request (<xref target="content-request-scheme" format="default" sectionFormat="of" derivedContent="Section 2.2.4"/>).</t>
          </dd>
          <dt pn="section-2.2-4.9">@request-target</dt>
          <dd pn="section-2.2-4.10">
            <t indent="0" pn="section-2.2-4.10.1">The request target (<xref target="content-request-target" format="default" sectionFormat="of" derivedContent="Section 2.2.5"/>).</t>
          </dd>
          <dt pn="section-2.2-4.11">@path</dt>
          <dd pn="section-2.2-4.12">
            <t indent="0" pn="section-2.2-4.12.1">The absolute path portion of the target URI for a request (<xref target="content-request-path" format="default" sectionFormat="of" derivedContent="Section 2.2.6"/>).</t>
          </dd>
          <dt pn="section-2.2-4.13">@query</dt>
          <dd pn="section-2.2-4.14">
            <t indent="0" pn="section-2.2-4.14.1">The query portion of the target URI for a request (<xref target="content-request-query" format="default" sectionFormat="of" derivedContent="Section 2.2.7"/>).</t>
          </dd>
          <dt pn="section-2.2-4.15">@query-param</dt>
          <dd pn="section-2.2-4.16">
            <t indent="0" pn="section-2.2-4.16.1">A parsed and encoded query parameter of the target URI for a request (<xref target="content-request-query-param" format="default" sectionFormat="of" derivedContent="Section 2.2.8"/>).</t>
          </dd>
          <dt pn="section-2.2-4.17">@status</dt>
          <dd pn="section-2.2-4.18">
            <t indent="0" pn="section-2.2-4.18.1">The status code for a response (<xref target="content-status-code" format="default" sectionFormat="of" derivedContent="Section 2.2.9"/>).</t>
          </dd>
        </dl>
        <t indent="0" pn="section-2.2-5">Additional derived component names are defined in the <xref target="content-registry" format="default" sectionFormat="of" derivedContent="Section 6.4">"HTTP Signature Derived Component Names" registry</xref>.</t>
        <t indent="0" pn="section-2.2-6">Derived component values are taken from the context of the target message for the signature. This context includes information about the message itself, such as its control data, as well as any additional state and context held by the signer or verifier. In particular, when signing a response, the signer can include any derived components from the originating request by using the <xref target="content-request-response" format="default" sectionFormat="of" derivedContent="Section 2.4"><tt>req</tt> parameter</xref>.</t>
        <dl indent="3" newline="false" spacing="normal" pn="section-2.2-7">
          <dt pn="section-2.2-7.1">request:</dt>
          <dd pn="section-2.2-7.2">
            <t indent="0" pn="section-2.2-7.2.1">Values derived from, and results applied to, an HTTP request message as described in <xref section="3.4" sectionFormat="of" target="RFC9110" format="default" derivedLink="https://rfc-editor.org/rfc/rfc9110#section-3.4" derivedContent="HTTP"/>. If the target message of the signature is a response, derived components that target request messages can be included by using the <tt>req</tt> parameter as defined in
<xref target="content-request-response" format="default" sectionFormat="of" derivedContent="Section 2.4"/>.</t>
          </dd>
          <dt pn="section-2.2-7.3">response:</dt>
          <dd pn="section-2.2-7.4">
            <t indent="0" pn="section-2.2-7.4.1">Values derived from, and results applied to, an HTTP response message as described in <xref section="3.4" sectionFormat="of" target="RFC9110" format="default" derivedLink="https://rfc-editor.org/rfc/rfc9110#section-3.4" derivedContent="HTTP"/>.</t>
          </dd>
          <dt pn="section-2.2-7.5">request, response:</dt>
          <dd pn="section-2.2-7.6">Values derived from, and results applied to, either a request message or a response message.</dd>
        </dl>
        <t indent="0" pn="section-2.2-8">A derived component definition <bcp14>MUST</bcp14> define all target message types to which it can be applied.</t>
        <t indent="0" pn="section-2.2-9">Derived component values <bcp14>MUST</bcp14> be limited to printable characters and spaces and <bcp14>MUST NOT</bcp14> contain any newline characters. Derived component values <bcp14>MUST NOT</bcp14> start or end with whitespace characters.</t>
        <section anchor="content-request-method" numbered="true" removeInRFC="false" toc="include" pn="section-2.2.1">
          <name slugifiedName="name-method">Method</name>
          <t indent="0" pn="section-2.2.1-1">The <tt>@method</tt> derived component refers to the HTTP method of a request message. The component value is canonicalized by taking the value of the method as a string. Note that the method name is case sensitive as per <xref section="9.1" sectionFormat="comma" target="RFC9110" format="default" derivedLink="https://rfc-editor.org/rfc/rfc9110#section-9.1" derivedContent="HTTP"/>. While conventionally standardized method names are uppercase <xref target="RFC0020" format="default" sectionFormat="of" derivedContent="ASCII"/>, no transformation to the input method value's case is performed.</t>
          <t indent="0" pn="section-2.2.1-2">For example, the following request message:</t>
          <sourcecode type="http-message" markers="false" pn="section-2.2.1-3">
POST /path?param=value HTTP/1.1
Host: www.example.com
</sourcecode>
          <t indent="0" pn="section-2.2.1-4">would result in the following <tt>@method</tt> component value:</t>
          <artwork align="left" pn="section-2.2.1-5">
POST
</artwork>
          <t indent="0" pn="section-2.2.1-6">and the following signature base line:</t>
          <artwork align="left" pn="section-2.2.1-7">
"@method": POST
</artwork>
        </section>
        <section anchor="content-target-uri" numbered="true" removeInRFC="false" toc="include" pn="section-2.2.2">
          <name slugifiedName="name-target-uri">Target URI</name>
          <t indent="0" pn="section-2.2.2-1">The <tt>@target-uri</tt> derived component refers to the target URI of a request message. The component value is the target URI of the request (<xref section="7.1" sectionFormat="comma" target="RFC9110" format="default" derivedLink="https://rfc-editor.org/rfc/rfc9110#section-7.1" derivedContent="HTTP"/>), assembled from all available URI components, including the authority.</t>
          <t indent="0" pn="section-2.2.2-2">For example, the following message sent over HTTPS:</t>
          <sourcecode type="http-message" markers="false" pn="section-2.2.2-3">
POST /path?param=value HTTP/1.1
Host: www.example.com
</sourcecode>
          <t indent="0" pn="section-2.2.2-4">would result in the following <tt>@target-uri</tt> component value:</t>
          <artwork align="left" pn="section-2.2.2-5">
https://www.example.com/path?param=value
</artwork>
          <t indent="0" pn="section-2.2.2-6">and the following signature base line:</t>
          <artwork align="left" pn="section-2.2.2-7">
"@target-uri": https://www.example.com/path?param=value
</artwork>
        </section>
        <section anchor="content-request-authority" numbered="true" removeInRFC="false" toc="include" pn="section-2.2.3">
          <name slugifiedName="name-authority">Authority</name>
          <t indent="0" pn="section-2.2.3-1">The <tt>@authority</tt> derived component refers to the authority component of the target URI of the HTTP request message, as defined in <xref section="7.2" sectionFormat="comma" target="RFC9110" format="default" derivedLink="https://rfc-editor.org/rfc/rfc9110#section-7.2" derivedContent="HTTP"/>. In HTTP/1.1, this is usually conveyed using the Host header field, while in HTTP/2 and HTTP/3 it is conveyed using the :authority pseudo-header. The value is the fully qualified authority component of the request, comprised of the host and, optionally, port of the request target, as a string.
The component value <bcp14>MUST</bcp14> be normalized according to the rules provided in <xref section="4.2.3" sectionFormat="comma" target="RFC9110" format="default" derivedLink="https://rfc-editor.org/rfc/rfc9110#section-4.2.3" derivedContent="HTTP"/>. Namely, the hostname is normalized to lowercase, and the default port is omitted.</t>
          <t indent="0" pn="section-2.2.3-2">For example, the following request message:</t>
          <sourcecode type="http-message" markers="false" pn="section-2.2.3-3">
POST /path?param=value HTTP/1.1
Host: www.example.com
</sourcecode>
          <t indent="0" pn="section-2.2.3-4">would result in the following <tt>@authority</tt> component value:</t>
          <artwork align="left" pn="section-2.2.3-5">
www.example.com
</artwork>
          <t indent="0" pn="section-2.2.3-6">and the following signature base line:</t>
          <artwork align="left" pn="section-2.2.3-7">
"@authority": www.example.com
</artwork>
          <t indent="0" pn="section-2.2.3-8">The <tt>@authority</tt> derived component <bcp14>SHOULD</bcp14> be used instead of signing the Host header field directly.  See <xref target="security-not-fields" format="default" sectionFormat="of" derivedContent="Section 7.2.4"/>.</t>
        </section>
        <section anchor="content-request-scheme" numbered="true" removeInRFC="false" toc="include" pn="section-2.2.4">
          <name slugifiedName="name-scheme">Scheme</name>
          <t indent="0" pn="section-2.2.4-1">The <tt>@scheme</tt> derived component refers to the scheme of the target URL of the HTTP request message. The component value is the scheme as a lowercase string as defined in <xref section="4.2" sectionFormat="comma" target="RFC9110" format="default" derivedLink="https://rfc-editor.org/rfc/rfc9110#section-4.2" derivedContent="HTTP"/>.
While the scheme itself is case insensitive, it <bcp14>MUST</bcp14> be normalized to lowercase for
inclusion in the signature base.</t>
          <t indent="0" pn="section-2.2.4-2">For example, the following request message sent over plain HTTP:</t>
          <sourcecode type="http-message" markers="false" pn="section-2.2.4-3">
POST /path?param=value HTTP/1.1
Host: www.example.com
</sourcecode>
          <t indent="0" pn="section-2.2.4-4">would result in the following <tt>@scheme</tt> component value:</t>
          <artwork align="left" pn="section-2.2.4-5">
http
</artwork>
          <t indent="0" pn="section-2.2.4-6">and the following signature base line:</t>
          <artwork align="left" pn="section-2.2.4-7">
"@scheme": http
</artwork>
        </section>
        <section anchor="content-request-target" numbered="true" removeInRFC="false" toc="include" pn="section-2.2.5">
          <name slugifiedName="name-request-target">Request Target</name>
          <t indent="0" pn="section-2.2.5-1">The <tt>@request-target</tt> derived component refers to the full request target of the HTTP request message,
as defined in <xref section="7.1" sectionFormat="comma" target="RFC9110" format="default" derivedLink="https://rfc-editor.org/rfc/rfc9110#section-7.1" derivedContent="HTTP"/>. The component value of the request target can take different forms,
depending on the type of request, as described below.</t>
          <t indent="0" pn="section-2.2.5-2">For HTTP/1.1, the component value is equivalent to the request target
portion of the request line. However, this value is more difficult to reliably construct in
other versions of HTTP. Therefore, it is <bcp14>NOT RECOMMENDED</bcp14> that this component be used
when versions of HTTP other than 1.1 might be in use.</t>
          <t indent="0" pn="section-2.2.5-3">The origin form value is a combination of the absolute path and query components of the request URL.</t>
          <t indent="0" pn="section-2.2.5-4">For example, the following request message:</t>
          <sourcecode type="http-message" markers="false" pn="section-2.2.5-5">
POST /path?param=value HTTP/1.1
Host: www.example.com
</sourcecode>
          <t indent="0" pn="section-2.2.5-6">would result in the following <tt>@request-target</tt> component value:</t>
          <artwork align="left" pn="section-2.2.5-7">
/path?param=value
</artwork>
          <t indent="0" pn="section-2.2.5-8">and the following signature base line:</t>
          <artwork align="left" pn="section-2.2.5-9">
"@request-target": /path?param=value
</artwork>
          <t indent="0" pn="section-2.2.5-10">The following request to an HTTP proxy with the absolute-form value, containing the fully qualified target URI:</t>
          <sourcecode type="http-message" markers="false" pn="section-2.2.5-11">
GET https://www.example.com/path?param=value HTTP/1.1
</sourcecode>
          <t indent="0" pn="section-2.2.5-12">would result in the following <tt>@request-target</tt> component value:</t>
          <artwork align="left" pn="section-2.2.5-13">
https://www.example.com/path?param=value
</artwork>
          <t indent="0" pn="section-2.2.5-14">and the following signature base line:</t>
          <artwork align="left" pn="section-2.2.5-15">
"@request-target": https://www.example.com/path?param=value
</artwork>
          <t indent="0" pn="section-2.2.5-16">The following CONNECT request with an authority-form value, containing the host and port of the target:</t>
          <sourcecode type="http-message" markers="false" pn="section-2.2.5-17">
CONNECT www.example.com:80 HTTP/1.1
Host: www.example.com
</sourcecode>
          <t indent="0" pn="section-2.2.5-18">would result in the following <tt>@request-target</tt> component value:</t>
          <artwork align="left" pn="section-2.2.5-19">
www.example.com:80
</artwork>
          <t indent="0" pn="section-2.2.5-20">and the following signature base line:</t>
          <artwork align="left" pn="section-2.2.5-21">
"@request-target": www.example.com:80
</artwork>
          <t indent="0" pn="section-2.2.5-22">The following OPTIONS request message with the asterisk-form value, containing a single asterisk (<tt>*</tt>) character:</t>
          <sourcecode type="http-message" markers="false" pn="section-2.2.5-23">
OPTIONS * HTTP/1.1
Host: www.example.com
</sourcecode>
          <t indent="0" pn="section-2.2.5-24">would result in the following <tt>@request-target</tt> component value:</t>
          <artwork align="left" pn="section-2.2.5-25">
*
</artwork>
          <t indent="0" pn="section-2.2.5-26">and the following signature base line:</t>
          <artwork align="left" pn="section-2.2.5-27">
"@request-target": *
</artwork>
        </section>
        <section anchor="content-request-path" numbered="true" removeInRFC="false" toc="include" pn="section-2.2.6">
          <name slugifiedName="name-path">Path</name>
          <t indent="0" pn="section-2.2.6-1">The <tt>@path</tt> derived component refers to the target path of the HTTP request message. The component value is the absolute path of the request target defined by <xref target="RFC3986" format="default" sectionFormat="of" derivedContent="URI"/>, with no query component and no trailing question mark (<tt>?</tt>) character. The value is normalized according to the rules provided in <xref section="4.2.3" sectionFormat="comma" target="RFC9110" format="default" derivedLink="https://rfc-editor.org/rfc/rfc9110#section-4.2.3" derivedContent="HTTP"/>. Namely, an empty path string is normalized as a single slash (<tt>/</tt>) character. Path components are represented by their values before decoding any percent-encoded octets, as described in the simple string comparison rules provided in <xref section="6.2.1" sectionFormat="of" target="RFC3986" format="default" derivedLink="https://rfc-editor.org/rfc/rfc3986#section-6.2.1" derivedContent="URI"/>.</t>
          <t indent="0" pn="section-2.2.6-2">For example, the following request message:</t>
          <sourcecode type="http-message" markers="false" pn="section-2.2.6-3">
GET /path?param=value HTTP/1.1
Host: www.example.com
</sourcecode>
          <t indent="0" pn="section-2.2.6-4">would result in the following <tt>@path</tt> component value:</t>
          <artwork align="left" pn="section-2.2.6-5">
/path
</artwork>
          <t indent="0" pn="section-2.2.6-6">and the following signature base line:</t>
          <artwork align="left" pn="section-2.2.6-7">
"@path": /path
</artwork>
        </section>
        <section anchor="content-request-query" numbered="true" removeInRFC="false" toc="include" pn="section-2.2.7">
          <name slugifiedName="name-query">Query</name>
          <t indent="0" pn="section-2.2.7-1">The <tt>@query</tt> derived component refers to the query component of the HTTP request message. The component value is the entire normalized query string defined by <xref target="RFC3986" format="default" sectionFormat="of" derivedContent="URI"/>, including the leading <tt>?</tt> character. The value is read using the simple string comparison rules provided in <xref section="6.2.1" sectionFormat="of" target="RFC3986" format="default" derivedLink="https://rfc-editor.org/rfc/rfc3986#section-6.2.1" derivedContent="URI"/>. Namely, percent-encoded octets are not decoded.</t>
          <t indent="0" pn="section-2.2.7-2">For example, the following request message:</t>
          <sourcecode type="http-message" markers="false" pn="section-2.2.7-3">
GET /path?param=value&amp;foo=bar&amp;baz=bat%2Dman HTTP/1.1
Host: www.example.com
</sourcecode>
          <t indent="0" pn="section-2.2.7-4">would result in the following <tt>@query</tt> component value:</t>
          <artwork align="left" pn="section-2.2.7-5">
?param=value&amp;foo=bar&amp;baz=bat%2Dman
</artwork>
          <t indent="0" pn="section-2.2.7-6">and the following signature base line:</t>
          <artwork align="left" pn="section-2.2.7-7">
"@query": ?param=value&amp;foo=bar&amp;baz=bat%2Dman
</artwork>
          <t indent="0" pn="section-2.2.7-8">The following request message:</t>
          <sourcecode type="http-message" markers="false" pn="section-2.2.7-9">
POST /path?queryString HTTP/1.1
Host: www.example.com
</sourcecode>
          <t indent="0" pn="section-2.2.7-10">would result in the following <tt>@query</tt> component value:</t>
          <artwork align="left" pn="section-2.2.7-11">
?queryString
</artwork>
          <t indent="0" pn="section-2.2.7-12">and the following signature base line:</t>
          <artwork align="left" pn="section-2.2.7-13">
"@query": ?queryString
</artwork>
          <t indent="0" pn="section-2.2.7-14">Just like including an empty path component, the signer can include an empty query component to indicate that this component is not used in the message. If the query string is absent from the request message, the component value is the leading <tt>?</tt> character alone:</t>
          <artwork align="left" pn="section-2.2.7-15">
?
</artwork>
          <t indent="0" pn="section-2.2.7-16">resulting in the following signature base line:</t>
          <artwork align="left" pn="section-2.2.7-17">
"@query": ?
</artwork>
        </section>
        <section anchor="content-request-query-param" numbered="true" removeInRFC="false" toc="include" pn="section-2.2.8">
          <name slugifiedName="name-query-parameters">Query Parameters</name>
          <t indent="0" pn="section-2.2.8-1">If the query portion of a request target URI uses HTML form parameters in the format defined in Section <xref target="HTMLURL" section="5" relative="https://url.spec.whatwg.org/#application/x-www-form-urlencoded" sectionFormat="bare" format="default" derivedLink="https://url.spec.whatwg.org/#application/x-www-form-urlencoded" derivedContent="HTMLURL">"application/x-www-form-urlencoded"</xref> of
<xref target="HTMLURL" format="default" sectionFormat="of" derivedContent="HTMLURL"/>,
the <tt>@query-param</tt> derived component allows addressing of these individual query parameters. The query parameters <bcp14>MUST</bcp14> be parsed according to
Section <xref target="HTMLURL" section="5.1" relative="https://url.spec.whatwg.org/#urlencoded-parsing" sectionFormat="bare" format="default" derivedLink="https://url.spec.whatwg.org/#urlencoded-parsing" derivedContent="HTMLURL">"application/x-www-form-urlencoded parsing"</xref>
of <xref target="HTMLURL" format="default" sectionFormat="of" derivedContent="HTMLURL"/>, resulting in a list of (<tt>nameString</tt>, <tt>valueString</tt>) tuples.
The <bcp14>REQUIRED</bcp14> <tt>name</tt> parameter of each component identifier contains the encoded <tt>nameString</tt> of a single query parameter as a String value.
The component value of a single named parameter is the encoded <tt>valueString</tt> of that single query parameter.
Several different named query parameters <bcp14>MAY</bcp14> be included in the covered components.
Single named parameters <bcp14>MAY</bcp14> occur in any order in the covered components, regardless of the order they occur in the query string.</t>
          <t indent="0" pn="section-2.2.8-2">The value of the <tt>name</tt> parameter and the component value of a single named parameter are calculated via the following process:</t>
          <ol spacing="normal" type="1" indent="adaptive" start="1" pn="section-2.2.8-3"><li pn="section-2.2.8-3.1" derivedCounter="1.">Parse the <tt>nameString</tt> or <tt>valueString</tt> of the named query parameter defined by 
Section <xref target="HTMLURL" section="5.1" relative="https://url.spec.whatwg.org/#urlencoded-parsing" sectionFormat="bare" format="default" derivedLink="https://url.spec.whatwg.org/#urlencoded-parsing" derivedContent="HTMLURL">"application/x-www-form-urlencoded parsing"</xref>
of <xref target="HTMLURL" format="default" sectionFormat="of" derivedContent="HTMLURL"/>; this is the value after percent-encoded octets are decoded.</li>
            <li pn="section-2.2.8-3.2" derivedCounter="2.">Encode the <tt>nameString</tt> or <tt>valueString</tt> using the "percent-encode after encoding" process defined by 
Section <xref target="HTMLURL" section="5.2" relative="https://url.spec.whatwg.org/#urlencoded-serializing" sectionFormat="bare" format="default" derivedLink="https://url.spec.whatwg.org/#urlencoded-serializing" derivedContent="HTMLURL">"application/x-www-form-urlencoded serializing"</xref> of <xref target="HTMLURL" format="default" sectionFormat="of" derivedContent="HTMLURL"/>; this results in an ASCII string <xref target="RFC0020" format="default" sectionFormat="of" derivedContent="ASCII"/>.</li>
            <li pn="section-2.2.8-3.3" derivedCounter="3.">Output the ASCII string.</li>
          </ol>
          <t indent="0" pn="section-2.2.8-4">Note that the component value does not include any leading question mark (<tt>?</tt>) characters, equals sign (<tt>=</tt>) characters, or separating ampersand (<tt>&amp;</tt>) characters.
Named query parameters with an empty <tt>valueString</tt> have an empty string as the component value. Note that due to inconsistencies in implementations, some query parameter parsing libraries drop such empty values.</t>
          <t indent="0" pn="section-2.2.8-5">If a query parameter is named as a covered component but it does not occur in the query parameters, this <bcp14>MUST</bcp14> cause an error in the signature base generation.</t>
          <t indent="0" pn="section-2.2.8-6">For example, for the following request:</t>
          <sourcecode type="http-message" markers="false" pn="section-2.2.8-7">
GET /path?param=value&amp;foo=bar&amp;baz=batman&amp;qux= HTTP/1.1
Host: www.example.com
</sourcecode>
          <t indent="0" pn="section-2.2.8-8">Indicating the <tt>baz</tt>, <tt>qux</tt>, and <tt>param</tt> named query parameters would result in the following <tt>@query-param</tt> component values:</t>
          <t indent="0" pn="section-2.2.8-9"><em>baz</em>: <tt>batman</tt></t>
          <t indent="0" pn="section-2.2.8-10"><em>qux</em>: an empty string</t>
          <t indent="0" pn="section-2.2.8-11"><em>param</em>: <tt>value</tt></t>
          <t indent="0" pn="section-2.2.8-12">and the following signature base lines, with (SP) indicating a single trailing space character before the empty component value:</t>
          <artwork align="left" pn="section-2.2.8-13">
"@query-param";name="baz": batman
"@query-param";name="qux":(SP)
"@query-param";name="param": value
</artwork>
          <t indent="0" pn="section-2.2.8-14">This derived component has some limitations. Specifically, the algorithms provided in Section <xref target="HTMLURL" section="5" relative="https://url.spec.whatwg.org/#application/x-www-form-urlencoded" sectionFormat="bare" format="default" derivedLink="https://url.spec.whatwg.org/#application/x-www-form-urlencoded" derivedContent="HTMLURL">"application/x-www-form-urlencoded"</xref> of
<xref target="HTMLURL" format="default" sectionFormat="of" derivedContent="HTMLURL"/> only support query parameters using percent-escaped UTF-8 encoding. Other encodings are not supported.
Additionally, multiple instances of a named parameter are not reliably supported in the wild. If a parameter name occurs multiple times in a request, the named query parameter <bcp14>MUST NOT</bcp14> be included. If multiple parameters are common within an application, it is <bcp14>RECOMMENDED</bcp14> to sign the entire query string using the <tt>@query</tt> component identifier defined in <xref target="content-request-query" format="default" sectionFormat="of" derivedContent="Section 2.2.7"/>.</t>
          <t indent="0" pn="section-2.2.8-15">The encoding process allows query parameters that include newlines or other problematic characters in their values, or with alternative encodings such as using the plus (+) character to represent spaces. For the query parameters in this message:</t>
          <sourcecode type="http-message" markers="false" pn="section-2.2.8-16">
NOTE: '\' line wrapping per RFC 8792

GET /parameters?var=this%20is%20a%20big%0Amultiline%20value&amp;\
  bar=with+plus+whitespace&amp;fa%C3%A7ade%22%3A%20=something HTTP/1.1
Host: www.example.com
Date: Tue, 20 Apr 2021 02:07:56 GMT
</sourcecode>
          <t indent="0" pn="section-2.2.8-17">The resulting values are encoded as follows:</t>
          <artwork align="left" pn="section-2.2.8-18">
"@query-param";name="var": this%20is%20a%20big%0Amultiline%20value
"@query-param";name="bar": with%20plus%20whitespace
"@query-param";name="fa%C3%A7ade%22%3A%20": something
</artwork>
          <t indent="0" pn="section-2.2.8-19">If the encoding were not applied, the resultant values would be:</t>
          <artwork align="left" pn="section-2.2.8-20">
"@query-param";name="var": this is a big
multiline value
"@query-param";name="bar": with plus whitespace
"@query-param";name="façade\": ": something
</artwork>
          <t indent="0" pn="section-2.2.8-21">This base string contains characters that violate the constraints on component names and values and is therefore invalid.</t>
        </section>
        <section anchor="content-status-code" numbered="true" removeInRFC="false" toc="include" pn="section-2.2.9">
          <name slugifiedName="name-status-code">Status Code</name>
          <t indent="0" pn="section-2.2.9-1">The <tt>@status</tt> derived component refers to the three-digit numeric HTTP status code of a response message as defined in <xref section="15" sectionFormat="comma" target="RFC9110" format="default" derivedLink="https://rfc-editor.org/rfc/rfc9110#section-15" derivedContent="HTTP"/>. The component value is the serialized three-digit integer of the HTTP status code, with no descriptive text.</t>
          <t indent="0" pn="section-2.2.9-2">For example, the following response message:</t>
          <sourcecode type="http-message" markers="false" pn="section-2.2.9-3">
HTTP/1.1 200 OK
Date: Fri, 26 Mar 2010 00:05:00 GMT
</sourcecode>
          <t indent="0" pn="section-2.2.9-4">would result in the following <tt>@status</tt> component value:</t>
          <artwork align="left" pn="section-2.2.9-5">
200
</artwork>
          <t indent="0" pn="section-2.2.9-6">and the following signature base line:</t>
          <artwork align="left" pn="section-2.2.9-7">
"@status": 200
</artwork>
          <t indent="0" pn="section-2.2.9-8">The <tt>@status</tt> component identifier <bcp14>MUST NOT</bcp14> be used in a request message.</t>
        </section>
      </section>
      <section anchor="signature-params" numbered="true" removeInRFC="false" toc="include" pn="section-2.3">
        <name slugifiedName="name-signature-parameters">Signature Parameters</name>
        <t indent="0" pn="section-2.3-1">HTTP message signatures have metadata properties that provide information regarding the signature's generation and verification, consisting of the ordered set of covered components and the ordered set of parameters, where the parameters include a timestamp of signature creation, identifiers for verification key material, and other utilities. This metadata is represented by a special message component in the signature base for signature parameters; this special message component is treated slightly differently from other message components. Specifically, the signature parameters message component is <bcp14>REQUIRED</bcp14> as the last line of the <xref target="create-sig-input" format="default" sectionFormat="of" derivedContent="Section 2.5">signature base</xref>, and the component identifier <bcp14>MUST NOT</bcp14> be enumerated within the set of covered components for any signature, including itself.</t>
        <t indent="0" pn="section-2.3-2">The signature parameters component name is <tt>@signature-params</tt>.</t>
        <t indent="0" pn="section-2.3-3">The signature parameters component value is the serialization of the signature parameters for this signature, including the covered components ordered set with all associated parameters. These parameters include any of the following:</t>
        <dl spacing="normal" indent="3" newline="false" pn="section-2.3-4">
          <dt pn="section-2.3-4.1">
            <tt>created</tt>:
          </dt>
          <dd pn="section-2.3-4.2">Creation time as a UNIX timestamp value of type Integer. Sub-second precision is not supported. The inclusion of this parameter is <bcp14>RECOMMENDED</bcp14>.</dd>
          <dt pn="section-2.3-4.3">
            <tt>expires</tt>:
          </dt>
          <dd pn="section-2.3-4.4">Expiration time as a UNIX timestamp value of type Integer. Sub-second precision is not supported.</dd>
          <dt pn="section-2.3-4.5">
            <tt>nonce</tt>:
          </dt>
          <dd pn="section-2.3-4.6">A random unique value generated for this signature as a String value.</dd>
          <dt pn="section-2.3-4.7">
            <tt>alg</tt>:
          </dt>
          <dd pn="section-2.3-4.8">The HTTP message signature algorithm from the "HTTP Signature Algorithms" registry, as a String value.</dd>
          <dt pn="section-2.3-4.9">
            <tt>keyid</tt>:
          </dt>
          <dd pn="section-2.3-4.10">The identifier for the key material as a String value.</dd>
          <dt pn="section-2.3-4.11">
            <tt>tag</tt>:
          </dt>
          <dd pn="section-2.3-4.12">An application-specific tag for the signature as a String value. This value is used by applications to help identify signatures relevant for specific applications or protocols.</dd>
        </dl>
        <t indent="0" pn="section-2.3-5">Additional parameters can be defined in the <xref target="param-registry" format="default" sectionFormat="of" derivedContent="Section 6.3">"HTTP Signature Metadata Parameters" registry</xref>. Note that the parameters are not in any general order, but once an ordering is chosen for a given set of parameters, it cannot be changed without altering the signature parameters value.</t>
        <t indent="0" pn="section-2.3-6">The signature parameters component value is serialized as a parameterized Inner List using the rules provided in <xref section="4" sectionFormat="of" target="RFC8941" format="default" derivedLink="https://rfc-editor.org/rfc/rfc8941#section-4" derivedContent="STRUCTURED-FIELDS"/> as follows:</t>
        <ol spacing="normal" type="1" indent="adaptive" start="1" pn="section-2.3-7"><li pn="section-2.3-7.1" derivedCounter="1.">Let the output be an empty string.</li>
          <li pn="section-2.3-7.2" derivedCounter="2.">Determine an order for the component identifiers of the covered components, not including the <tt>@signature-params</tt> component identifier itself. Once this order is chosen, it cannot be changed. This order <bcp14>MUST</bcp14> be the same order as that used in creating the signature base
(<xref target="create-sig-input" format="default" sectionFormat="of" derivedContent="Section 2.5"/>).</li>
          <li pn="section-2.3-7.3" derivedCounter="3.">Serialize the component identifiers of the covered components, including all parameters, as an ordered Inner List of String values according to <xref section="4.1.1.1" sectionFormat="of" target="RFC8941" format="default" derivedLink="https://rfc-editor.org/rfc/rfc8941#section-4.1.1.1" derivedContent="STRUCTURED-FIELDS"/>; then, append this to the output. Note that the component identifiers can include their own parameters, and these parameters are ordered sets. Once an order is chosen for a component's parameters, the order cannot be changed.</li>
          <li pn="section-2.3-7.4" derivedCounter="4.">Determine an order for any signature parameters. Once this order is chosen, it cannot be changed.</li>
          <li pn="section-2.3-7.5" derivedCounter="5.">Append the parameters to the Inner List in order according to <xref section="4.1.1.2" sectionFormat="of" target="RFC8941" format="default" derivedLink="https://rfc-editor.org/rfc/rfc8941#section-4.1.1.2" derivedContent="STRUCTURED-FIELDS"/>,
 skipping parameters that are not available or not used for this message signature.</li>
          <li pn="section-2.3-7.6" derivedCounter="6.">The output contains the signature parameters component value.</li>
        </ol>
        <t indent="0" pn="section-2.3-8">Note that the Inner List serialization from <xref section="4.1.1.1" sectionFormat="of" target="RFC8941" format="default" derivedLink="https://rfc-editor.org/rfc/rfc8941#section-4.1.1.1" derivedContent="STRUCTURED-FIELDS"/> is used for the covered component value instead of the List serialization from <xref section="4.1.1" sectionFormat="of" target="RFC8941" format="default" derivedLink="https://rfc-editor.org/rfc/rfc8941#section-4.1.1" derivedContent="STRUCTURED-FIELDS"/>
in order to facilitate parallelism with this value's inclusion in the Signature-Input field,
as discussed in <xref target="signature-input-header" format="default" sectionFormat="of" derivedContent="Section 4.1"/>.</t>
        <t indent="0" pn="section-2.3-9">This example shows the serialized component value for the parameters of an example message signature:</t>
        <artwork align="left" pn="section-2.3-10">
NOTE: '\' line wrapping per RFC 8792

("@target-uri" "@authority" "date" "cache-control")\
  ;keyid="test-key-rsa-pss";alg="rsa-pss-sha512";\
  created=1618884475;expires=1618884775
</artwork>
        <t indent="0" pn="section-2.3-11">Note that an HTTP message could contain <xref target="signature-multiple" format="default" sectionFormat="of" derivedContent="Section 4.3">multiple signatures</xref>, but only the signature parameters used for a single signature are included in a given signature parameters entry.</t>
      </section>
      <section anchor="content-request-response" numbered="true" removeInRFC="false" toc="include" pn="section-2.4">
        <name slugifiedName="name-signing-request-components-">Signing Request Components in a Response Message</name>
        <t indent="0" pn="section-2.4-1">When a request message results in a signed response message, the signer can include portions of the request message in the signature base by adding the <tt>req</tt> parameter to the component identifier.</t>
        <dl indent="3" newline="false" spacing="normal" pn="section-2.4-2">
          <dt pn="section-2.4-2.1"><tt>req</tt></dt>
          <dd pn="section-2.4-2.2">
            <t indent="0" pn="section-2.4-2.2.1">A Boolean flag indicating that the component value is derived from the request that triggered this response message and not from the response message directly.</t>
          </dd>
        </dl>
        <t indent="0" pn="section-2.4-3">This parameter can be applied to both HTTP fields and derived components that target the request, with the same semantics. The component value for a message component using this parameter is calculated in the same manner as it is normally, but data is pulled from the request message instead of the target response message to which the signature is applied.</t>
        <t indent="0" pn="section-2.4-4">Note that the same component name <bcp14>MAY</bcp14> be included with and without the <tt>req</tt> parameter in a single signature base, indicating the same named component from both the request message and the response message.</t>
        <t indent="0" pn="section-2.4-5">The <tt>req</tt> parameter <bcp14>MAY</bcp14> be combined with other parameters as appropriate for the component identifier, such as the <tt>key</tt> parameter for a Dictionary field.</t>
        <t indent="0" pn="section-2.4-6">For example, when serving a response for this request:</t>
        <sourcecode type="http-message" markers="false" pn="section-2.4-7">
NOTE: '\' line wrapping per RFC 8792

POST /foo?param=Value&amp;Pet=dog HTTP/1.1
Host: example.com
Date: Tue, 20 Apr 2021 02:07:55 GMT
Content-Digest: sha-512=:WZDPaVn/7XgHaAy8pmojAkGWoRx2UFChF41A2svX+T\
  aPm+AbwAgBWnrIiYllu7BNNyealdVLvRwEmTHWXvJwew==:
Content-Type: application/json
Content-Length: 18

{"hello": "world"}
</sourcecode>
        <t indent="0" pn="section-2.4-8">This would result in the following unsigned response message:</t>
        <sourcecode type="http-message" markers="false" pn="section-2.4-9">
NOTE: '\' line wrapping per RFC 8792

HTTP/1.1 503 Service Unavailable
Date: Tue, 20 Apr 2021 02:07:56 GMT
Content-Type: application/json
Content-Length: 62
Content-Digest: sha-512=:0Y6iCBzGg5rZtoXS95Ijz03mslf6KAMCloESHObfwn\
  HJDbkkWWQz6PhhU9kxsTbARtY2PTBOzq24uJFpHsMuAg==:

{"busy": true, "message": "Your call is very important to us"}
</sourcecode>
        <t indent="0" pn="section-2.4-10">The server signs the response with its own key, including the <tt>@status</tt> code and several header fields in the covered components. While this covers a reasonable amount of the response for this application, the server additionally includes several components derived from the original request message that triggered this response. In this example, the server includes the method, authority, path, and content digest from the request in the covered components of the response. The Content-Digest for both the request and the response is included under the response signature. For the application in this example, the query is deemed not to be relevant to the response and is therefore not covered. Other applications would make different decisions based on application needs, as discussed in <xref target="application" format="default" sectionFormat="of" derivedContent="Section 1.4"/>.</t>
        <t indent="0" pn="section-2.4-11">The signature base for this example is:</t>
        <artwork align="left" pn="section-2.4-12">
NOTE: '\' line wrapping per RFC 8792

"@status": 503
"content-digest": sha-512=:0Y6iCBzGg5rZtoXS95Ijz03mslf6KAMCloESHObf\
  wnHJDbkkWWQz6PhhU9kxsTbARtY2PTBOzq24uJFpHsMuAg==:
"content-type": application/json
"@authority";req: example.com
"@method";req: POST
"@path";req: /foo
"content-digest";req: sha-512=:WZDPaVn/7XgHaAy8pmojAkGWoRx2UFChF41A\
  2svX+TaPm+AbwAgBWnrIiYllu7BNNyealdVLvRwEmTHWXvJwew==:
"@signature-params": ("@status" "content-digest" "content-type" \
  "@authority";req "@method";req "@path";req "content-digest";req)\
  ;created=1618884479;keyid="test-key-ecc-p256"
</artwork>
        <t indent="0" pn="section-2.4-13">The signed response message is:</t>
        <sourcecode type="http-message" markers="false" pn="section-2.4-14">
NOTE: '\' line wrapping per RFC 8792

HTTP/1.1 503 Service Unavailable
Date: Tue, 20 Apr 2021 02:07:56 GMT
Content-Type: application/json
Content-Length: 62
Content-Digest: sha-512=:0Y6iCBzGg5rZtoXS95Ijz03mslf6KAMCloESHObfwn\
  HJDbkkWWQz6PhhU9kxsTbARtY2PTBOzq24uJFpHsMuAg==:
Signature-Input: reqres=("@status" "content-digest" "content-type" \
  "@authority";req "@method";req "@path";req "content-digest";req)\
  ;created=1618884479;keyid="test-key-ecc-p256"
Signature: reqres=:dMT/A/76ehrdBTD/2Xx8QuKV6FoyzEP/I9hdzKN8LQJLNgzU\
  4W767HK05rx1i8meNQQgQPgQp8wq2ive3tV5Ag==:

{"busy": true, "message": "Your call is very important to us"}
</sourcecode>
        <t indent="0" pn="section-2.4-15">Note that the ECDSA signature algorithm in use here is non-deterministic, meaning that a different signature value will be created every time the algorithm is run. The signature value provided here can be validated against the given keys, but newly generated signature values are not expected to match the example. See <xref target="security-nondeterministic" format="default" sectionFormat="of" derivedContent="Section 7.3.5"/>.</t>
        <t indent="0" pn="section-2.4-16">Since the component values from the request are not repeated in the response message, the requester <bcp14>MUST</bcp14> keep the original message component values around long enough to validate the signature of the response that uses this component identifier parameter. In most cases, this means the requester needs to keep the original request message around, since the signer could choose to include any portions of the request in its response, according to the needs of the application. Since it is possible for an intermediary to alter a request message before it is processed by the server, applications need to take care not to sign such altered values, as the client would not be able to validate the resulting signature.</t>
        <t indent="0" pn="section-2.4-17">It is also possible for a server to create a signed response in response to a signed request.  For this example of a signed request:</t>
        <artwork align="left" pn="section-2.4-18">
NOTE: '\' line wrapping per RFC 8792

POST /foo?param=Value&amp;Pet=dog HTTP/1.1
Host: example.com
Date: Tue, 20 Apr 2021 02:07:55 GMT
Content-Digest: sha-512=:WZDPaVn/7XgHaAy8pmojAkGWoRx2UFChF41A2svX+T\
  aPm+AbwAgBWnrIiYllu7BNNyealdVLvRwEmTHWXvJwew==:
Content-Type: application/json
Content-Length: 18
Signature-Input: sig1=("@method" "@authority" "@path" "@query" \
  "content-digest" "content-type" "content-length")\
  ;created=1618884475;keyid="test-key-rsa-pss"
Signature: sig1=:e8UJ5wMiRaonlth5ERtE8GIiEH7Akcr493nQ07VPNo6y3qvjdK\
  t0fo8VHO8xXDjmtYoatGYBGJVlMfIp06eVMEyNW2I4vN7XDAz7m5v1108vGzaDljr\
  d0H8+SJ28g7bzn6h2xeL/8q+qUwahWA/JmC8aOC9iVnwbOKCc0WSrLgWQwTY6VLp4\
  2Qt7jjhYT5W7/wCvfK9A1VmHH1lJXsV873Z6hpxesd50PSmO+xaNeYvDLvVdZlhtw\
  5PCtUYzKjHqwmaQ6DEuM8udRjYsoNqp2xZKcuCO1nKc0V3RjpqMZLuuyVbHDAbCzr\
  0pg2d2VM/OC33JAU7meEjjaNz+d7LWPg==:

{"hello": "world"}
</artwork>
        <t indent="0" pn="section-2.4-19">The server could choose to sign portions of this response, including several portions of the request, resulting in this signature base:</t>
        <artwork align="left" pn="section-2.4-20">
NOTE: '\' line wrapping per RFC 8792

"@status": 503
"content-digest": sha-512=:0Y6iCBzGg5rZtoXS95Ijz03mslf6KAMCloESHObf\
  wnHJDbkkWWQz6PhhU9kxsTbARtY2PTBOzq24uJFpHsMuAg==:
"content-type": application/json
"@authority";req: example.com
"@method";req: POST
"@path";req: /foo
"@query";req: ?param=Value&amp;Pet=dog
"content-digest";req: sha-512=:WZDPaVn/7XgHaAy8pmojAkGWoRx2UFChF41A\
  2svX+TaPm+AbwAgBWnrIiYllu7BNNyealdVLvRwEmTHWXvJwew==:
"content-type";req: application/json
"content-length";req: 18
"@signature-params": ("@status" "content-digest" "content-type" \
  "@authority";req "@method";req "@path";req "@query";req \
  "content-digest";req "content-type";req "content-length";req)\
  ;created=1618884479;keyid="test-key-ecc-p256"
</artwork>
        <t indent="0" pn="section-2.4-21">and the following signed response:</t>
        <sourcecode type="http-message" markers="false" pn="section-2.4-22">
NOTE: '\' line wrapping per RFC 8792

HTTP/1.1 503 Service Unavailable
Date: Tue, 20 Apr 2021 02:07:56 GMT
Content-Type: application/json
Content-Length: 62
Content-Digest: sha-512=:0Y6iCBzGg5rZtoXS95Ijz03mslf6KAMCloESHObfwn\
  HJDbkkWWQz6PhhU9kxsTbARtY2PTBOzq24uJFpHsMuAg==:
Signature-Input: reqres=("@status" "content-digest" "content-type" \
  "@authority";req "@method";req "@path";req "@query";req \
  "content-digest";req "content-type";req "content-length";req)\
  ;created=1618884479;keyid="test-key-ecc-p256"
Signature: reqres=:C73J41GVKc+TYXbSobvZf0CmNcptRiWN+NY1Or0A36ISg6ym\
  dRN6ZgR2QfrtopFNzqAyv+CeWrMsNbcV2Ojsgg==:

{"busy": true, "message": "Your call is very important to us"}
</sourcecode>
        <t indent="0" pn="section-2.4-23">Note that the ECDSA signature algorithm in use here is non-deterministic, meaning that a different signature value will be created every time the algorithm is run. The signature value provided here can be validated against the given keys, but newly generated signature values are not expected to match the example. See <xref target="security-nondeterministic" format="default" sectionFormat="of" derivedContent="Section 7.3.5"/>.</t>
        <t indent="0" pn="section-2.4-24">Applications signing a response to a signed request <bcp14>SHOULD</bcp14> sign all of the components of the request signature value to provide sufficient coverage and protection against a class of collision attacks, as discussed in <xref target="security-sign-signature" format="default" sectionFormat="of" derivedContent="Section 7.3.7"/>. The server in this example has included all components listed in the Signature-Input field of the client's signature on the request in the response signature, in addition to components of the response.</t>
        <t indent="0" pn="section-2.4-25">While it is syntactically possible to include the Signature and Signature-Input fields of the request message in the signature components of a response to a message using this mechanism, this practice is <bcp14>NOT RECOMMENDED</bcp14>. This is because signatures of signatures do not provide transitive coverage of covered components as one might expect, and the practice is susceptible to several attacks as discussed in <xref target="security-sign-signature" format="default" sectionFormat="of" derivedContent="Section 7.3.7"/>. An application that needs to signal successful processing or receipt of a signature would need to carefully specify alternative mechanisms for sending such a signal securely.</t>
        <t indent="0" pn="section-2.4-26">The response signature can only ever cover what is included in the request message when using this flag. Consequently, if an application needs to include the message content of the request under the signature of its response, the client needs to include a means for covering that content, such as a Content-Digest field. See the discussion in <xref target="security-message-content" format="default" sectionFormat="of" derivedContent="Section 7.2.8"/> for more information.</t>
        <t indent="0" pn="section-2.4-27">The <tt>req</tt> parameter <bcp14>MUST NOT</bcp14> be used for any component in a signature that targets a request message.</t>
      </section>
      <section anchor="create-sig-input" numbered="true" removeInRFC="false" toc="include" pn="section-2.5">
        <name slugifiedName="name-creating-the-signature-base">Creating the Signature Base</name>
        <t indent="0" pn="section-2.5-1">The signature base is an ASCII string <xref target="RFC0020" format="default" sectionFormat="of" derivedContent="ASCII"/> containing the canonicalized HTTP message components covered by the signature. The input to the signature base creation algorithm is the ordered set of covered component identifiers and their associated values, along with any additional signature parameters discussed in <xref target="signature-params" format="default" sectionFormat="of" derivedContent="Section 2.3"/>.</t>
        <t indent="0" pn="section-2.5-2">Component identifiers are serialized using the strict serialization rules defined by <xref section="4" sectionFormat="comma" target="RFC8941" format="default" derivedLink="https://rfc-editor.org/rfc/rfc8941#section-4" derivedContent="STRUCTURED-FIELDS"/>.
The component identifier has a component name, which is a String Item value serialized using the <tt>sf-string</tt> ABNF rule. The component identifier <bcp14>MAY</bcp14> also include defined parameters that are serialized using the <tt>parameters</tt> ABNF rule. The signature parameters line defined in <xref target="signature-params" format="default" sectionFormat="of" derivedContent="Section 2.3"/> follows this same pattern, but the component identifier is a String Item with a fixed value and no parameters, and the component value is always an Inner List with optional parameters.</t>
        <t indent="0" pn="section-2.5-3">Note that this means the serialization of the component name itself is encased in double quotes, with parameters following as a semicolon-separated list, such as <tt>"cache-control"</tt>, <tt>"@authority"</tt>, <tt>"@signature-params"</tt>, or <tt>"example-dictionary";key="foo"</tt>.</t>
        <t indent="0" pn="section-2.5-4">The output is the ordered set of bytes that form the signature base, which conforms to the following ABNF:</t>
        <sourcecode type="abnf" markers="false" pn="section-2.5-5">
signature-base = *( signature-base-line LF ) signature-params-line
signature-base-line = component-identifier ":" SP
    ( derived-component-value / *field-content )
    ; no obs-fold nor obs-text
component-identifier = component-name parameters
component-name = sf-string
derived-component-value = *( VCHAR / SP )
signature-params-line = DQUOTE "@signature-params" DQUOTE
     ":" SP inner-list
</sourcecode>
        <t indent="0" pn="section-2.5-6">To create the signature base, the signer or verifier concatenates entries for each component identifier in the signature's covered components (including their parameters) using the following algorithm. All errors produced as described <bcp14>MUST</bcp14> fail the algorithm immediately, without outputting a signature base.</t>
        <ol spacing="normal" type="1" indent="adaptive" start="1" pn="section-2.5-7"><li pn="section-2.5-7.1" derivedCounter="1.">Let the output be an empty string.</li>
          <li pn="section-2.5-7.2" derivedCounter="2.">
            <t indent="0" pn="section-2.5-7.2.1">For each message component item in the covered components set (in order):  </t>
            <ol spacing="normal" type="%p%d." indent="adaptive" start="1" pn="section-2.5-7.2.2"><li pn="section-2.5-7.2.2.1" derivedCounter="2.1.">If the component identifier (including its parameters) has already been added to the signature base, produce an error.</li>
              <li pn="section-2.5-7.2.2.2" derivedCounter="2.2.">Append the component identifier for the covered component serialized according to the <tt>component-identifier</tt> ABNF rule. Note that this serialization places the component name in double quotes and appends any parameters outside of the quotes.</li>
              <li pn="section-2.5-7.2.2.3" derivedCounter="2.3.">Append a single colon (<tt>:</tt>).</li>
              <li pn="section-2.5-7.2.2.4" derivedCounter="2.4.">Append a single space (" ").</li>
              <li pn="section-2.5-7.2.2.5" derivedCounter="2.5.">
                <t indent="0" pn="section-2.5-7.2.2.5.1">Determine the component value for the component identifier.      </t>
                <ul spacing="normal" bare="false" empty="false" indent="3" pn="section-2.5-7.2.2.5.2">
                  <li pn="section-2.5-7.2.2.5.2.1">If the component identifier has a parameter that is not understood, produce an error.</li>
                  <li pn="section-2.5-7.2.2.5.2.2">If the component identifier has parameters that are mutually incompatible with one another, such as <tt>bs</tt> and <tt>sf</tt>, produce an error.</li>
                  <li pn="section-2.5-7.2.2.5.2.3">If the component identifier contains the <tt>req</tt> parameter and the target message is a request, produce an error.</li>
                  <li pn="section-2.5-7.2.2.5.2.4">If the component identifier contains the <tt>req</tt> parameter and the target message is a response, the context for the component value is the related request message of the target response message. Otherwise, the context for the component value is the target message.</li>
                  <li pn="section-2.5-7.2.2.5.2.5">If the component name starts with an "at" (<tt>@</tt>) character, derive the component's value from the message according to the specific rules defined for the derived component, as provided in <xref target="derived-components" format="default" sectionFormat="of" derivedContent="Section 2.2"/>, including processing of any known valid parameters. If the derived component name is unknown or the value cannot be derived, produce an error.</li>
                  <li pn="section-2.5-7.2.2.5.2.6">If the component name does not start with an "at" (<tt>@</tt>) character, canonicalize the HTTP field value as described in <xref target="http-fields" format="default" sectionFormat="of" derivedContent="Section 2.1"/>, including processing of any known valid parameters. If the field cannot be found in the message or the value cannot be obtained in the context, produce an error.</li>
                </ul>
              </li>
              <li pn="section-2.5-7.2.2.6" derivedCounter="2.6.">Append the covered component's canonicalized component value.</li>
              <li pn="section-2.5-7.2.2.7" derivedCounter="2.7.">Append a single newline (<tt>\n</tt>).</li>
            </ol>
          </li>
          <li pn="section-2.5-7.3" derivedCounter="3.">
            <t indent="0" pn="section-2.5-7.3.1">Append the signature parameters component (<xref target="signature-params" format="default" sectionFormat="of" derivedContent="Section 2.3"/>) according to the <tt>signature-params-line</tt> rule as follows:  </t>
            <ol spacing="normal" type="%p%d." indent="adaptive" start="1" pn="section-2.5-7.3.2"><li pn="section-2.5-7.3.2.1" derivedCounter="3.1.">Append the component identifier for the signature parameters serialized according to the <tt>component-identifier</tt> rule, i.e., the exact value <tt>"@signature-params"</tt> (including double quotes).</li>
              <li pn="section-2.5-7.3.2.2" derivedCounter="3.2.">Append a single colon (<tt>:</tt>).</li>
              <li pn="section-2.5-7.3.2.3" derivedCounter="3.3.">Append a single space (" ").</li>
              <li pn="section-2.5-7.3.2.4" derivedCounter="3.4.">Append the signature parameters' canonicalized component values as defined in <xref target="signature-params" format="default" sectionFormat="of" derivedContent="Section 2.3"/>, i.e., Inner List Structured Field values with parameters.</li>
            </ol>
          </li>
          <li pn="section-2.5-7.4" derivedCounter="4.">Produce an error if the output string contains any non-ASCII characters <xref target="RFC0020" format="default" sectionFormat="of" derivedContent="ASCII"/>.</li>
          <li pn="section-2.5-7.5" derivedCounter="5.">Return the output string.</li>
        </ol>
        <t indent="0" pn="section-2.5-8">If covered components reference a component identifier that cannot be resolved to a component value in the message, the implementation <bcp14>MUST</bcp14> produce an error and not create a signature base. Such situations include, but are not limited to, the following:</t>
        <ul spacing="normal" bare="false" empty="false" indent="3" pn="section-2.5-9">
          <li pn="section-2.5-9.1">The signer or verifier does not understand the derived component name.</li>
          <li pn="section-2.5-9.2">The component name identifies a field that is not present in the message or whose value is malformed.</li>
          <li pn="section-2.5-9.3">The component identifier includes a parameter that is unknown or does not apply to the component identifier to which it is attached.</li>
          <li pn="section-2.5-9.4">The component identifier indicates that a Structured Field serialization is used (via the <tt>sf</tt> parameter), but the field in question is known to not be a Structured Field or the type of Structured Field is not known to the implementation.</li>
          <li pn="section-2.5-9.5">The component identifier is a Dictionary member identifier that references a field that is not present in the message, that is not a Dictionary Structured Field, or whose value is malformed.</li>
          <li pn="section-2.5-9.6">The component identifier is a Dictionary member identifier or a named query parameter identifier that references a member that is not present in the component value or whose value is malformed. For example, the identifier is <tt>"example-dict";key="c"</tt>, and the value of the Example-Dict header field is <tt>a=1, b=2</tt>, which does not have the <tt>c</tt> value.</li>
        </ul>
        <t indent="0" pn="section-2.5-10">In the following non-normative example, the HTTP message being signed is the following request:</t>
        <sourcecode type="http-message" markers="false" pn="section-2.5-11">
NOTE: '\' line wrapping per RFC 8792

POST /foo?param=Value&amp;Pet=dog HTTP/1.1
Host: example.com
Date: Tue, 20 Apr 2021 02:07:55 GMT
Content-Type: application/json
Content-Digest: sha-512=:WZDPaVn/7XgHaAy8pmojAkGWoRx2UFChF41A2svX+T\
  aPm+AbwAgBWnrIiYllu7BNNyealdVLvRwEmTHWXvJwew==:
Content-Length: 18

{"hello": "world"}
</sourcecode>
        <t indent="0" pn="section-2.5-12">The covered components consist of the <tt>@method</tt>, <tt>@authority</tt>, and <tt>@path</tt> derived components followed by the <tt>Content-Digest</tt>, <tt>Content-Length</tt>, and <tt>Content-Type</tt> HTTP header fields, in order. The signature parameters consist of a creation timestamp of <tt>1618884473</tt> and a key identifier of <tt>test-key-rsa-pss</tt>. Note that no explicit <tt>alg</tt> parameter is given here, since the verifier is known by the application to use the RSA-PSS algorithm based on the identified key. The signature base for this message with these parameters is:</t>
        <figure anchor="example-sig-input" align="left" suppress-title="false" pn="figure-1">
          <name slugifiedName="name-non-normative-example-signa">Non-normative Example Signature Base</name>
          <sourcecode type="http-message" name="example-sig-input" markers="false" pn="section-2.5-13.1">
NOTE: '\' line wrapping per RFC 8792

"@method": POST
"@authority": example.com
"@path": /foo
"content-digest": sha-512=:WZDPaVn/7XgHaAy8pmojAkGWoRx2UFChF41A2svX\
  +TaPm+AbwAgBWnrIiYllu7BNNyealdVLvRwEmTHWXvJwew==:
"content-length": 18
"content-type": application/json
"@signature-params": ("@method" "@authority" "@path" \
  "content-digest" "content-length" "content-type")\
  ;created=1618884473;keyid="test-key-rsa-pss"
</sourcecode>
        </figure>
        <t indent="0" pn="section-2.5-14">Note that the example signature base above does not include the final newline that ends the displayed example, nor do other example signature bases displayed elsewhere in this specification.</t>
      </section>
    </section>
    <section anchor="message-signatures" numbered="true" removeInRFC="false" toc="include" pn="section-3">
      <name slugifiedName="name-http-message-signatures">HTTP Message Signatures</name>
      <t indent="0" pn="section-3-1">An HTTP message signature is a signature over a string generated from a subset of the components of an HTTP message in addition to metadata about the signature itself. When successfully verified against an HTTP message, an HTTP message signature provides cryptographic proof that the message is semantically equivalent to the message for which the signature was generated, with respect to the subset of message components that was signed.</t>
      <section anchor="sign" numbered="true" removeInRFC="false" toc="include" pn="section-3.1">
        <name slugifiedName="name-creating-a-signature">Creating a Signature</name>
        <t indent="0" pn="section-3.1-1">Creation of an HTTP message signature is a process that takes as its input the signature context (including the target message) and the requirements for the application. The output is a signature value and set of signature parameters that can be communicated to the verifier by adding them to the message.</t>
        <t indent="0" pn="section-3.1-2">In order to create a signature, a signer <bcp14>MUST</bcp14> apply the following algorithm:</t>
        <ol spacing="normal" type="1" indent="adaptive" start="1" pn="section-3.1-3"><li pn="section-3.1-3.1" derivedCounter="1.">The signer chooses an HTTP signature algorithm and key material for signing from the set of potential signing algorithms.
 The set of potential algorithms is determined by the application and is out of scope for this document.
 The signer <bcp14>MUST</bcp14> choose key material that is appropriate
 for the signature's algorithm and that conforms to any requirements defined by the algorithm, such as key size or format. The
 mechanism by which the signer chooses the algorithm and key material is out of scope for this document.</li>
          <li pn="section-3.1-3.2" derivedCounter="2.">The signer sets the signature's creation time to the current time.</li>
          <li pn="section-3.1-3.3" derivedCounter="3.">If applicable, the signer sets the signature's expiration time property to the time at which the signature is to expire. The expiration is a hint to the verifier, expressing the time at which the signer is no longer willing to vouch for the signature. An appropriate expiration length, and the processing requirements of this parameter, are application specific.</li>
          <li pn="section-3.1-3.4" derivedCounter="4.">
            <t indent="0" pn="section-3.1-3.4.1">The signer creates an ordered set of component identifiers representing the message components to be covered by the signature and attaches signature metadata parameters to this set. The serialized value of this set is later used as the value of the Signature-Input field as described in <xref target="signature-input-header" format="default" sectionFormat="of" derivedContent="Section 4.1"/>.</t>
            <ul spacing="normal" bare="false" empty="false" indent="3" pn="section-3.1-3.4.2">
              <li pn="section-3.1-3.4.2.1">Once an order of covered components is chosen, the order <bcp14>MUST NOT</bcp14> change for the life of the signature.</li>
              <li pn="section-3.1-3.4.2.2">Each covered component identifier <bcp14>MUST</bcp14> be either
(1) an HTTP field (<xref target="http-fields" format="default" sectionFormat="of" derivedContent="Section 2.1"/>) in the signature context or
(2) a derived component listed in <xref target="derived-components" format="default" sectionFormat="of" derivedContent="Section 2.2"/> or in the "HTTP Signature Derived Component Names" registry.</li>
              <li pn="section-3.1-3.4.2.3">Signers of a request <bcp14>SHOULD</bcp14> include some or all of the message control data in the covered components, such as the <tt>@method</tt>, <tt>@authority</tt>, <tt>@target-uri</tt>, or some combination thereof.</li>
              <li pn="section-3.1-3.4.2.4">Signers <bcp14>SHOULD</bcp14> include the <tt>created</tt> signature metadata parameter to indicate when the signature was created.</li>
              <li pn="section-3.1-3.4.2.5">The <tt>@signature-params</tt> derived component identifier <bcp14>MUST NOT</bcp14> be present in the list of covered component identifiers. The derived component is required to always be the last line in the signature base, ensuring that a signature always covers its own metadata and the metadata cannot be substituted.</li>
              <li pn="section-3.1-3.4.2.6">Further guidance on what to include in this set and in what order is out of scope for this document.</li>
            </ul>
          </li>
          <li pn="section-3.1-3.5" derivedCounter="5.">The signer creates the signature base using these parameters and the signature base creation algorithm (<xref target="create-sig-input" format="default" sectionFormat="of" derivedContent="Section 2.5"/>).</li>
          <li pn="section-3.1-3.6" derivedCounter="6.">The signer uses the <tt>HTTP_SIGN</tt> primitive function to sign the signature base with the chosen signing algorithm using the key material chosen by the signer. The <tt>HTTP_SIGN</tt> primitive and several concrete applications of signing algorithms are defined in <xref target="signature-methods" format="default" sectionFormat="of" derivedContent="Section 3.3"/>.</li>
          <li pn="section-3.1-3.7" derivedCounter="7.">The byte array output of the signature function is the HTTP message signature output value to be included in the Signature field as defined in <xref target="signature-header" format="default" sectionFormat="of" derivedContent="Section 4.2"/>.</li>
        </ol>
        <t indent="0" pn="section-3.1-4">For example, given the HTTP message and signature parameters in the example in <xref target="create-sig-input" format="default" sectionFormat="of" derivedContent="Section 2.5"/>, the example signature base is signed with the <tt>test-key-rsa-pss</tt> key (see <xref target="example-key-rsa-pss-test" format="default" sectionFormat="of" derivedContent="Appendix B.1.2"/>) and the RSASSA-PSS algorithm described in <xref target="method-rsa-pss-sha512" format="default" sectionFormat="of" derivedContent="Section 3.3.1"/>, giving the following message signature output value, encoded in Base64:</t>
        <figure anchor="example-sig-value" align="left" suppress-title="false" pn="figure-2">
          <name slugifiedName="name-non-normative-example-signat">Non-normative Example Signature Value</name>
          <artwork align="left" pn="section-3.1-5.1">
NOTE: '\' line wrapping per RFC 8792

HIbjHC5rS0BYaa9v4QfD4193TORw7u9edguPh0AW3dMq9WImrlFrCGUDih47vAxi4L2\
YRZ3XMJc1uOKk/J0ZmZ+wcta4nKIgBkKq0rM9hs3CQyxXGxHLMCy8uqK488o+9jrptQ\
+xFPHK7a9sRL1IXNaagCNN3ZxJsYapFj+JXbmaI5rtAdSfSvzPuBCh+ARHBmWuNo1Uz\
VVdHXrl8ePL4cccqlazIJdC4QEjrF+Sn4IxBQzTZsL9y9TP5FsZYzHvDqbInkTNigBc\
E9cKOYNFCn4D/WM7F6TNuZO9EgtzepLWcjTymlHzK7aXq6Am6sfOrpIC49yXjj3ae6H\
RalVc/g==
</artwork>
        </figure>
        <t indent="0" pn="section-3.1-6">Note that the RSA-PSS algorithm in use here is non-deterministic, meaning that a different signature value will be created every time the algorithm is run. The signature value provided here can be validated against the given keys, but newly generated signature values are not expected to match the example. See <xref target="security-nondeterministic" format="default" sectionFormat="of" derivedContent="Section 7.3.5"/>.</t>
      </section>
      <section anchor="verify" numbered="true" removeInRFC="false" toc="include" pn="section-3.2">
        <name slugifiedName="name-verifying-a-signature">Verifying a Signature</name>
        <t indent="0" pn="section-3.2-1">Verification of an HTTP message signature is a process that takes as its input the signature context (including the target message, particularly its Signature and Signature-Input fields) and the requirements for the application. The output of the verification is either a positive verification or an error.</t>
        <t indent="0" pn="section-3.2-2">In order to verify a signature, a verifier <bcp14>MUST</bcp14> apply the following algorithm:</t>
        <ol spacing="normal" type="1" indent="adaptive" start="1" pn="section-3.2-3"><li pn="section-3.2-3.1" derivedCounter="1.">
            <t indent="0" pn="section-3.2-3.1.1">Parse the Signature and Signature-Input fields as described in
Sections <xref target="signature-input-header" format="counter" sectionFormat="of" derivedContent="4.1"/> and <xref target="signature-header" format="counter" sectionFormat="of" derivedContent="4.2"/>, and extract the signatures to be verified and their labels.
            </t>
            <ol spacing="normal" type="%p%d." indent="adaptive" start="1" pn="section-3.2-3.1.2"><li pn="section-3.2-3.1.2.1" derivedCounter="1.1.">If there is more than one signature value present, determine which signature should be processed
 for this message based on the policy and configuration of the verifier. If an applicable signature is not found, produce an error.</li>
              <li pn="section-3.2-3.1.2.2" derivedCounter="1.2.">If the chosen Signature field value does not have a corresponding Signature-Input field value (i.e., one with the same label),
 produce an error.</li>
            </ol>
          </li>
          <li pn="section-3.2-3.2" derivedCounter="2.">Parse the values of the chosen Signature-Input field as a parameterized Inner List to get the ordered list of covered components and the signature parameters for the signature to be verified.</li>
          <li pn="section-3.2-3.3" derivedCounter="3.">Parse the value of the corresponding Signature field to get the byte array value of the signature
 to be verified.</li>
          <li pn="section-3.2-3.4" derivedCounter="4.">Examine the signature parameters to confirm that the signature meets the requirements described
 in this document, as well as any additional requirements defined by the application such as which
 message components are required to be covered by the signature (<xref target="verify-requirements" format="default" sectionFormat="of" derivedContent="Section 3.2.1"/>).</li>
          <li pn="section-3.2-3.5" derivedCounter="5.">Determine the verification key material for this signature. If the key material is known through external
 means such as static configuration or external protocol negotiation, the verifier will use the applicable technique to obtain the key material from this external knowledge. If the key is
 identified in the signature parameters, the verifier will dereference the key identifier to appropriate key material to use
 with the signature. The verifier has to determine the trustworthiness of the key material for the context
 in which the signature is presented. If a key is identified that the verifier does not know or trust for this request or that does not match something preconfigured, the verification <bcp14>MUST</bcp14> fail.</li>
          <li pn="section-3.2-3.6" derivedCounter="6.">
            <t indent="0" pn="section-3.2-3.6.1">Determine the algorithm to apply for verification:
            </t>
            <ol spacing="normal" type="%p%d." indent="adaptive" start="1" pn="section-3.2-3.6.2"><li pn="section-3.2-3.6.2.1" derivedCounter="6.1.">Start with the set of allowable algorithms known to the application. If any of the following steps select an algorithm that is not in this set, the signature validation fails.</li>
              <li pn="section-3.2-3.6.2.2" derivedCounter="6.2.">If the algorithm is known through external means such as static configuration or external protocol
 negotiation, the verifier will use that algorithm.</li>
              <li pn="section-3.2-3.6.2.3" derivedCounter="6.3.">If the algorithm can be determined from the keying material, such as through an algorithm field
 on the key value itself, the verifier will use that algorithm.</li>
              <li pn="section-3.2-3.6.2.4" derivedCounter="6.4.">If the algorithm is explicitly stated in the signature parameters using a value from the
 "HTTP Signature Algorithms" registry, the verifier will use the referenced algorithm.</li>
              <li pn="section-3.2-3.6.2.5" derivedCounter="6.5.">If the algorithm is specified in more than one location (e.g.,
a combination of static configuration, the algorithm signature parameter, and the
key material itself), the resolved algorithms <bcp14>MUST</bcp14> be the same. If the algorithms are
 not the same, the verifier <bcp14>MUST</bcp14> fail the verification.</li>
            </ol>
          </li>
          <li pn="section-3.2-3.7" derivedCounter="7.">Use the received HTTP message and the parsed signature parameters to recreate the signature base, using
 the algorithm defined in <xref target="create-sig-input" format="default" sectionFormat="of" derivedContent="Section 2.5"/>. The value of the <tt>@signature-params</tt> input is
 the value of the Signature-Input field for this signature serialized according to the rules described
 in <xref target="signature-params" format="default" sectionFormat="of" derivedContent="Section 2.3"/>. Note that this does not include the signature's label from the Signature-Input field.</li>
          <li pn="section-3.2-3.8" derivedCounter="8.">If the key material is appropriate for the algorithm, apply the appropriate <tt>HTTP_VERIFY</tt> cryptographic verification algorithm to the signature,
 recalculated signature base, key material, and signature value. The <tt>HTTP_VERIFY</tt> primitive and several concrete algorithms are defined in
 <xref target="signature-methods" format="default" sectionFormat="of" derivedContent="Section 3.3"/>.</li>
          <li pn="section-3.2-3.9" derivedCounter="9.">The results of the verification algorithm function are the final results of the cryptographic verification function.</li>
        </ol>
        <t indent="0" pn="section-3.2-4">If any of the above steps fail or produce an error, the signature validation fails.</t>
        <t indent="0" pn="section-3.2-5">For example, verifying the signature with the label <tt>sig1</tt> of the following message with the <tt>test-key-rsa-pss</tt> key (see <xref target="example-key-rsa-pss-test" format="default" sectionFormat="of" derivedContent="Appendix B.1.2"/>) and the RSASSA-PSS algorithm described in <xref target="method-rsa-pss-sha512" format="default" sectionFormat="of" derivedContent="Section 3.3.1"/>:</t>
        <sourcecode type="http-message" markers="false" pn="section-3.2-6">
NOTE: '\' line wrapping per RFC 8792

POST /foo?param=Value&amp;Pet=dog HTTP/1.1
Host: example.com
Date: Tue, 20 Apr 2021 02:07:55 GMT
Content-Type: application/json
Content-Digest: sha-512=:WZDPaVn/7XgHaAy8pmojAkGWoRx2UFChF41A2svX+T\
  aPm+AbwAgBWnrIiYllu7BNNyealdVLvRwEmTHWXvJwew==:
Content-Length: 18
Signature-Input: sig1=("@method" "@authority" "@path" \
  "content-digest" "content-length" "content-type")\
  ;created=1618884473;keyid="test-key-rsa-pss"
Signature: sig1=:HIbjHC5rS0BYaa9v4QfD4193TORw7u9edguPh0AW3dMq9WImrl\
  FrCGUDih47vAxi4L2YRZ3XMJc1uOKk/J0ZmZ+wcta4nKIgBkKq0rM9hs3CQyxXGxH\
  LMCy8uqK488o+9jrptQ+xFPHK7a9sRL1IXNaagCNN3ZxJsYapFj+JXbmaI5rtAdSf\
  SvzPuBCh+ARHBmWuNo1UzVVdHXrl8ePL4cccqlazIJdC4QEjrF+Sn4IxBQzTZsL9y\
  9TP5FsZYzHvDqbInkTNigBcE9cKOYNFCn4D/WM7F6TNuZO9EgtzepLWcjTymlHzK7\
  aXq6Am6sfOrpIC49yXjj3ae6HRalVc/g==:

{"hello": "world"}
</sourcecode>
        <t indent="0" pn="section-3.2-7">With the additional requirements that at least the method, authority, path, content-digest, content-length, and content-type entries be signed, and that the signature creation timestamp be recent enough at the time of verification, the verification passes.</t>
        <section anchor="verify-requirements" numbered="true" removeInRFC="false" toc="include" pn="section-3.2.1">
          <name slugifiedName="name-enforcing-application-requi">Enforcing Application Requirements</name>
          <t indent="0" pn="section-3.2.1-1">The verification requirements specified in this document are intended as a baseline set of restrictions that are generally applicable to all use cases. Applications using HTTP message signatures <bcp14>MAY</bcp14> impose requirements above and beyond those specified by this document, as appropriate for their use case.</t>
          <t indent="0" pn="section-3.2.1-2">Some non-normative examples of additional requirements an application might define are:</t>
          <ul spacing="normal" bare="false" empty="false" indent="3" pn="section-3.2.1-3">
            <li pn="section-3.2.1-3.1">Requiring a specific set of header fields to be signed (e.g., Authorization, Content-Digest).</li>
            <li pn="section-3.2.1-3.2">Enforcing a maximum signature age from the time of the <tt>created</tt> timestamp.</li>
            <li pn="section-3.2.1-3.3">Rejecting signatures past the expiration time in the <tt>expires</tt> timestamp. Note that the expiration time is a hint from the signer and that a verifier can always reject a signature ahead of its expiration time.</li>
            <li pn="section-3.2.1-3.4">Prohibiting certain signature metadata parameters, such as runtime algorithm signaling with the <tt>alg</tt> parameter when the algorithm is determined from the key information.</li>
            <li pn="section-3.2.1-3.5">Ensuring successful dereferencing of the <tt>keyid</tt> parameter to valid and appropriate key material.</li>
            <li pn="section-3.2.1-3.6">Prohibiting the use of certain algorithms or mandating the use of a specific algorithm.</li>
            <li pn="section-3.2.1-3.7">Requiring keys to be of a certain size (e.g., 2048 bits vs. 1024 bits).</li>
            <li pn="section-3.2.1-3.8">Enforcing uniqueness of the <tt>nonce</tt> parameter.</li>
            <li pn="section-3.2.1-3.9">Requiring an application-specific value for the <tt>tag</tt> parameter.</li>
          </ul>
          <t indent="0" pn="section-3.2.1-4">Application-specific requirements are expected and encouraged. When an application defines additional requirements, it <bcp14>MUST</bcp14> enforce them during the signature verification process, and signature verification <bcp14>MUST</bcp14> fail if the signature does not conform to the application's requirements.</t>
          <t indent="0" pn="section-3.2.1-5">Applications <bcp14>MUST</bcp14> enforce the requirements defined in this document. Regardless of use case, applications <bcp14>MUST NOT</bcp14> accept signatures that do not conform to these requirements.</t>
        </section>
      </section>
      <section anchor="signature-methods" numbered="true" removeInRFC="false" toc="include" pn="section-3.3">
        <name slugifiedName="name-signature-algorithms">Signature Algorithms</name>
        <t indent="0" pn="section-3.3-1">An HTTP message signature <bcp14>MUST</bcp14> use a cryptographic digital signature or MAC method that is
appropriate for the key material, environment, and needs of the signer and verifier. This specification does not strictly limit the available signature algorithms, and any signature algorithm that meets these basic requirements <bcp14>MAY</bcp14> be used by an application of HTTP message signatures.</t>
        <t indent="0" pn="section-3.3-2">For each signing method, <tt>HTTP_SIGN</tt> takes as its input the signature base defined in <xref target="create-sig-input" format="default" sectionFormat="of" derivedContent="Section 2.5"/> as a byte array (<tt>M</tt>) and the signing key material
(<tt>Ks</tt>), and outputs the resultant signature as a byte array (<tt>S</tt>):</t>
        <artwork align="left" pn="section-3.3-3">
HTTP_SIGN (M, Ks)  -&gt;  S
</artwork>
        <t indent="0" pn="section-3.3-4">For each verification method, <tt>HTTP_VERIFY</tt> takes as its input the regenerated signature base defined in <xref target="create-sig-input" format="default" sectionFormat="of" derivedContent="Section 2.5"/> as a byte array (<tt>M</tt>), the verification key
material (<tt>Kv</tt>), and the presented signature to be verified as a byte array (<tt>S</tt>), and outputs the verification result (<tt>V</tt>) as a Boolean:</t>
        <artwork align="left" pn="section-3.3-5">
HTTP_VERIFY (M, Kv, S) -&gt; V
</artwork>
        <t indent="0" pn="section-3.3-6">The following sections contain several common signature algorithms and demonstrate how these cryptographic primitives map to the <tt>HTTP_SIGN</tt> and <tt>HTTP_VERIFY</tt> definitions above. Which method to use can be communicated through the explicit algorithm (<tt>alg</tt>) signature parameter (<xref target="signature-params" format="default" sectionFormat="of" derivedContent="Section 2.3"/>), by reference to the key material, or through mutual agreement between the signer and verifier. Signature algorithms selected using the <tt>alg</tt> parameter <bcp14>MUST</bcp14> use values from the <xref target="hsa-registry" format="default" sectionFormat="of" derivedContent="Section 6.2">"HTTP Signature Algorithms" registry</xref>.</t>
        <section anchor="method-rsa-pss-sha512" numbered="true" removeInRFC="false" toc="include" pn="section-3.3.1">
          <name slugifiedName="name-rsassa-pss-using-sha-512">RSASSA-PSS Using SHA-512</name>
          <t indent="0" pn="section-3.3.1-1">To sign using this algorithm, the signer applies the <tt>RSASSA-PSS-SIGN (K, M)</tt> function defined in <xref target="RFC8017" format="default" sectionFormat="of" derivedContent="RFC8017"/> with the signer's private signing key (<tt>K</tt>) and the signature base (<tt>M</tt>)
(<xref target="create-sig-input" format="default" sectionFormat="of" derivedContent="Section 2.5"/>).
The mask generation function is <tt>MGF1</tt> as specified in <xref target="RFC8017" format="default" sectionFormat="of" derivedContent="RFC8017"/> with a hash function of SHA-512 <xref target="RFC6234" format="default" sectionFormat="of" derivedContent="RFC6234"/>.
The salt length (<tt>sLen</tt>) is 64 bytes.
The hash function (<tt>Hash</tt>) SHA-512 <xref target="RFC6234" format="default" sectionFormat="of" derivedContent="RFC6234"/> is applied to the signature base to create
the digest content to which the digital signature is applied.
The resulting signed content byte array (<tt>S</tt>) is the HTTP message signature output used in <xref target="sign" format="default" sectionFormat="of" derivedContent="Section 3.1"/>.</t>
          <t indent="0" pn="section-3.3.1-2">To verify using this algorithm, the verifier applies the <tt>RSASSA-PSS-VERIFY ((n, e), M, S)</tt> function <xref target="RFC8017" format="default" sectionFormat="of" derivedContent="RFC8017"/> using the public key portion of the verification key material (<tt>n, e</tt>) and the signature base (<tt>M</tt>) recreated as described in <xref target="verify" format="default" sectionFormat="of" derivedContent="Section 3.2"/>.
The mask generation function is <tt>MGF1</tt> as specified in <xref target="RFC8017" format="default" sectionFormat="of" derivedContent="RFC8017"/> with a hash function of SHA-512 <xref target="RFC6234" format="default" sectionFormat="of" derivedContent="RFC6234"/>.
The salt length (<tt>sLen</tt>) is 64 bytes.
The hash function (<tt>Hash</tt>) SHA-512 <xref target="RFC6234" format="default" sectionFormat="of" derivedContent="RFC6234"/> is applied to the signature base to create the digest content to which the verification function is applied.
The verifier extracts the HTTP message signature to be verified (<tt>S</tt>) as described in <xref target="verify" format="default" sectionFormat="of" derivedContent="Section 3.2"/>.
The results of the verification function indicate whether the signature presented is valid.</t>
          <t indent="0" pn="section-3.3.1-3">Note that the output of the RSASSA-PSS algorithm is non-deterministic; therefore, it is not correct to recalculate a new signature on the signature base and compare the results to an existing signature. Instead, the verification algorithm defined here needs to be used. See <xref target="security-nondeterministic" format="default" sectionFormat="of" derivedContent="Section 7.3.5"/>.</t>
          <t indent="0" pn="section-3.3.1-4">The use of this algorithm can be indicated at runtime using the <tt>rsa-pss-sha512</tt> value for the <tt>alg</tt> signature parameter.</t>
        </section>
        <section anchor="method-rsa-v1_5-sha256" numbered="true" removeInRFC="false" toc="include" pn="section-3.3.2">
          <name slugifiedName="name-rsassa-pkcs1-v1_5-using-sha">RSASSA-PKCS1-v1_5 Using SHA-256</name>
          <t indent="0" pn="section-3.3.2-1">To sign using this algorithm, the signer applies the <tt>RSASSA-PKCS1-V1_5-SIGN (K, M)</tt> function defined in <xref target="RFC8017" format="default" sectionFormat="of" derivedContent="RFC8017"/> with the signer's private signing key (<tt>K</tt>) and the
signature base (<tt>M</tt>) (<xref target="create-sig-input" format="default" sectionFormat="of" derivedContent="Section 2.5"/>).
The hash SHA-256 <xref target="RFC6234" format="default" sectionFormat="of" derivedContent="RFC6234"/> is applied to the signature base to create
the digest content to which the digital signature is applied.
The resulting signed content byte array (<tt>S</tt>) is the HTTP message signature output used in <xref target="sign" format="default" sectionFormat="of" derivedContent="Section 3.1"/>.</t>
          <t indent="0" pn="section-3.3.2-2">To verify using this algorithm, the verifier applies the <tt>RSASSA-PKCS1-V1_5-VERIFY ((n, e), M, S)</tt> function <xref target="RFC8017" format="default" sectionFormat="of" derivedContent="RFC8017"/> using the public key portion of the verification key material (<tt>n, e</tt>) and the signature base (<tt>M</tt>) recreated as described in <xref target="verify" format="default" sectionFormat="of" derivedContent="Section 3.2"/>.
The hash function SHA-256 <xref target="RFC6234" format="default" sectionFormat="of" derivedContent="RFC6234"/> is applied to the signature base to create the digest content to which the verification function is applied.
The verifier extracts the HTTP message signature to be verified (<tt>S</tt>) as described in <xref target="verify" format="default" sectionFormat="of" derivedContent="Section 3.2"/>.
The results of the verification function indicate whether the signature presented is valid.</t>
          <t indent="0" pn="section-3.3.2-3">The use of this algorithm can be indicated at runtime using the <tt>rsa-v1_5-sha256</tt> value for the <tt>alg</tt> signature parameter.</t>
        </section>
        <section anchor="method-hmac-sha256" numbered="true" removeInRFC="false" toc="include" pn="section-3.3.3">
          <name slugifiedName="name-hmac-using-sha-256">HMAC Using SHA-256</name>
          <t indent="0" pn="section-3.3.3-1">To sign and verify using this algorithm, the signer applies the <tt>HMAC</tt> function <xref target="RFC2104" format="default" sectionFormat="of" derivedContent="RFC2104"/> with the shared signing key (<tt>K</tt>) and the
signature base (<tt>text</tt>) (<xref target="create-sig-input" format="default" sectionFormat="of" derivedContent="Section 2.5"/>).
The hash function SHA-256 <xref target="RFC6234" format="default" sectionFormat="of" derivedContent="RFC6234"/> is applied to the signature base to create the digest content to which the HMAC is applied, giving the signature result.</t>
          <t indent="0" pn="section-3.3.3-2">For signing, the resulting value is the HTTP message signature output used in <xref target="sign" format="default" sectionFormat="of" derivedContent="Section 3.1"/>.</t>
          <t indent="0" pn="section-3.3.3-3">For verification, the verifier extracts the HTTP message signature to be verified (<tt>S</tt>) as described in <xref target="verify" format="default" sectionFormat="of" derivedContent="Section 3.2"/>.
The output of the HMAC function is compared bytewise to the value of the HTTP message signature, and the results of the comparison determine the validity of the signature presented.</t>
          <t indent="0" pn="section-3.3.3-4">The use of this algorithm can be indicated at runtime using the <tt>hmac-sha256</tt> value for the <tt>alg</tt> signature parameter.</t>
        </section>
        <section anchor="method-ecdsa-p256-sha256" numbered="true" removeInRFC="false" toc="include" pn="section-3.3.4">
          <name slugifiedName="name-ecdsa-using-curve-p-256-dss">ECDSA Using Curve P-256 DSS and SHA-256</name>
          <t indent="0" pn="section-3.3.4-1">To sign using this algorithm, the signer applies the <tt>ECDSA</tt> signature algorithm defined in <xref target="FIPS186-5" format="default" sectionFormat="of" derivedContent="FIPS186-5"/> using curve P-256 with the signer's private signing key and
the signature base (<xref target="create-sig-input" format="default" sectionFormat="of" derivedContent="Section 2.5"/>).
The hash SHA-256 <xref target="RFC6234" format="default" sectionFormat="of" derivedContent="RFC6234"/> is applied to the signature base to create
the digest content to which the digital signature is applied (<tt>M</tt>).
The signature algorithm returns two integer values: <tt>r</tt> and <tt>s</tt>. These are both encoded as big-endian unsigned integers, zero-padded to 32 octets each. These encoded values are concatenated into a single 64-octet array consisting of the encoded value of <tt>r</tt> followed by the encoded value of <tt>s</tt>. The resulting concatenation of <tt>(r, s)</tt> is a byte array of the HTTP message signature output used in <xref target="sign" format="default" sectionFormat="of" derivedContent="Section 3.1"/>.</t>
          <t indent="0" pn="section-3.3.4-2">To verify using this algorithm, the verifier applies the <tt>ECDSA</tt> signature algorithm defined in <xref target="FIPS186-5" format="default" sectionFormat="of" derivedContent="FIPS186-5"/>  using the public key portion of the verification key material and the signature base recreated as described in <xref target="verify" format="default" sectionFormat="of" derivedContent="Section 3.2"/>.
The hash function SHA-256 <xref target="RFC6234" format="default" sectionFormat="of" derivedContent="RFC6234"/> is applied to the signature base to create the digest content to which the signature verification function is applied (<tt>M</tt>).
The verifier extracts the HTTP message signature to be verified (<tt>S</tt>) as described in <xref target="verify" format="default" sectionFormat="of" derivedContent="Section 3.2"/>. This value is a 64-octet array consisting of the encoded values of <tt>r</tt> and <tt>s</tt> concatenated in order. These are both encoded as big-endian unsigned integers, zero-padded to 32 octets each. The resulting signature value <tt>(r, s)</tt> is used as input to the signature verification function.
The results of the verification function indicate whether the signature presented is valid.</t>
          <t indent="0" pn="section-3.3.4-3">Note that the output of ECDSA signature algorithms is non-deterministic; therefore, it is not correct to recalculate a new signature on the signature base and compare the results to an existing signature. Instead, the verification algorithm defined here needs to be used. See <xref target="security-nondeterministic" format="default" sectionFormat="of" derivedContent="Section 7.3.5"/>.</t>
          <t indent="0" pn="section-3.3.4-4">The use of this algorithm can be indicated at runtime using the <tt>ecdsa-p256-sha256</tt> value for the <tt>alg</tt> signature parameter.</t>
        </section>
        <section anchor="method-ecdsa-p384-sha384" numbered="true" removeInRFC="false" toc="include" pn="section-3.3.5">
          <name slugifiedName="name-ecdsa-using-curve-p-384-dss">ECDSA Using Curve P-384 DSS and SHA-384</name>
          <t indent="0" pn="section-3.3.5-1">To sign using this algorithm, the signer applies the <tt>ECDSA</tt> signature algorithm defined in <xref target="FIPS186-5" format="default" sectionFormat="of" derivedContent="FIPS186-5"/> using curve P-384 with the signer's private signing key and the
signature base (<xref target="create-sig-input" format="default" sectionFormat="of" derivedContent="Section 2.5"/>).
The hash SHA-384 <xref target="RFC6234" format="default" sectionFormat="of" derivedContent="RFC6234"/> is applied to the signature base to create
the digest content to which the digital signature is applied (<tt>M</tt>).
The signature algorithm returns two integer values: <tt>r</tt> and <tt>s</tt>. These are both encoded as big-endian unsigned integers, zero-padded to 48 octets each. These encoded values are concatenated into a single 96-octet array consisting of the encoded value of <tt>r</tt> followed by the encoded value of <tt>s</tt>. The resulting concatenation of <tt>(r, s)</tt> is a byte array of the HTTP message signature output used in <xref target="sign" format="default" sectionFormat="of" derivedContent="Section 3.1"/>.</t>
          <t indent="0" pn="section-3.3.5-2">To verify using this algorithm, the verifier applies the <tt>ECDSA</tt> signature algorithm defined in <xref target="FIPS186-5" format="default" sectionFormat="of" derivedContent="FIPS186-5"/>  using the public key portion of the verification key material and the signature base recreated as described in <xref target="verify" format="default" sectionFormat="of" derivedContent="Section 3.2"/>.
The hash function SHA-384 <xref target="RFC6234" format="default" sectionFormat="of" derivedContent="RFC6234"/> is applied to the signature base to create the digest content to which the signature verification function is applied (<tt>M</tt>).
The verifier extracts the HTTP message signature to be verified (<tt>S</tt>) as described in <xref target="verify" format="default" sectionFormat="of" derivedContent="Section 3.2"/>. This value is a 96-octet array consisting of the encoded values of <tt>r</tt> and <tt>s</tt> concatenated in order. These are both encoded as big-endian unsigned integers, zero-padded to 48 octets each. The resulting signature value <tt>(r, s)</tt> is used as input to the signature verification function.
The results of the verification function indicate whether the signature presented is valid.</t>
          <t indent="0" pn="section-3.3.5-3">Note that the output of ECDSA signature algorithms is non-deterministic; therefore, it is not correct to recalculate a new signature on the signature base and compare the results to an existing signature. Instead, the verification algorithm defined here needs to be used. See <xref target="security-nondeterministic" format="default" sectionFormat="of" derivedContent="Section 7.3.5"/>.</t>
          <t indent="0" pn="section-3.3.5-4">The use of this algorithm can be indicated at runtime using the <tt>ecdsa-p384-sha384</tt> value for the <tt>alg</tt> signature parameter.</t>
        </section>
        <section anchor="method-ed25519" numbered="true" removeInRFC="false" toc="include" pn="section-3.3.6">
          <name slugifiedName="name-eddsa-using-curve-edwards25">EdDSA Using Curve edwards25519</name>
          <t indent="0" pn="section-3.3.6-1">To sign using this algorithm, the signer applies the <tt>Ed25519</tt> algorithm defined in <xref section="5.1.6" sectionFormat="of" target="RFC8032" format="default" derivedLink="https://rfc-editor.org/rfc/rfc8032#section-5.1.6" derivedContent="RFC8032"/> with the signer's private signing key and
the signature base (<xref target="create-sig-input" format="default" sectionFormat="of" derivedContent="Section 2.5"/>).
The signature base is taken as the input message (<tt>M</tt>) with no prehash function.
The signature is a 64-octet concatenation of <tt>R</tt> and <tt>S</tt> as specified in <xref section="5.1.6" sectionFormat="of" target="RFC8032" format="default" derivedLink="https://rfc-editor.org/rfc/rfc8032#section-5.1.6" derivedContent="RFC8032"/>, and this is taken as a byte array for the HTTP message signature output used in <xref target="sign" format="default" sectionFormat="of" derivedContent="Section 3.1"/>.</t>
          <t indent="0" pn="section-3.3.6-2">To verify using this algorithm, the signer applies the <tt>Ed25519</tt> algorithm defined in <xref section="5.1.7" sectionFormat="of" target="RFC8032" format="default" derivedLink="https://rfc-editor.org/rfc/rfc8032#section-5.1.7" derivedContent="RFC8032"/> using the public key portion of the verification key material (<tt>A</tt>) and the signature base recreated as described in <xref target="verify" format="default" sectionFormat="of" derivedContent="Section 3.2"/>.
The signature base is taken as the input message (<tt>M</tt>) with no prehash function.
The signature to be verified is processed as the 64-octet concatenation of <tt>R</tt> and <tt>S</tt> as specified in <xref section="5.1.7" sectionFormat="of" target="RFC8032" format="default" derivedLink="https://rfc-editor.org/rfc/rfc8032#section-5.1.7" derivedContent="RFC8032"/>.
The results of the verification function indicate whether the signature presented is valid.</t>
          <t indent="0" pn="section-3.3.6-3">The use of this algorithm can be indicated at runtime using the <tt>ed25519</tt> value for the <tt>alg</tt> signature parameter.</t>
        </section>
        <section anchor="method-jose" numbered="true" removeInRFC="false" toc="include" pn="section-3.3.7">
          <name slugifiedName="name-json-web-signature-jws-algo">JSON Web Signature (JWS) Algorithms</name>
          <t indent="0" pn="section-3.3.7-1">If the signing algorithm is a JSON Object Signing and Encryption (JOSE) signing algorithm from the "JSON Web Signature and Encryption Algorithms" registry established by <xref target="RFC7518" format="default" sectionFormat="of" derivedContent="RFC7518"/>, the
JWS algorithm definition determines the signature and hashing algorithms to apply for both signing and verification.</t>
          <t indent="0" pn="section-3.3.7-2">For both signing and verification, the HTTP message's signature base (<xref target="create-sig-input" format="default" sectionFormat="of" derivedContent="Section 2.5"/>) is used as the entire "JWS Signing Input".
The JOSE Header <xref target="RFC7515" format="default" sectionFormat="of" derivedContent="JWS"/> <xref target="RFC7517" format="default" sectionFormat="of" derivedContent="RFC7517"/> is not used, and the signature base is not first encoded in Base64 before applying the algorithm.
The output of the JWS Signature is taken as a byte array prior to the Base64url encoding used in JOSE.</t>
          <t indent="0" pn="section-3.3.7-3">The JWS algorithm <bcp14>MUST NOT</bcp14> be "<tt>none</tt>" and <bcp14>MUST NOT</bcp14> be any algorithm with a JOSE Implementation Requirement of "<tt>Prohibited</tt>".</t>
          <t indent="0" pn="section-3.3.7-4">JSON Web Algorithm (JWA) values from the "JSON Web Signature and Encryption Algorithms" registry are not included as signature parameters. Typically, the JWS algorithm can be signaled using JSON Web Keys (JWKs) or other mechanisms common to JOSE implementations. In fact, JWA values are not registered in the <xref target="hsa-registry" format="default" sectionFormat="of" derivedContent="Section 6.2">"HTTP Signature Algorithms" registry</xref>, and so the explicit <tt>alg</tt> signature parameter is not used at all when using JOSE signing algorithms.</t>
        </section>
      </section>
    </section>
    <section anchor="attach-signature" numbered="true" removeInRFC="false" toc="include" pn="section-4">
      <name slugifiedName="name-including-a-message-signatu">Including a Message Signature in a Message</name>
      <t indent="0" pn="section-4-1">HTTP message signatures can be included within an HTTP message via the Signature-Input and Signature fields, both defined within this specification.</t>
      <t indent="0" pn="section-4-2">The Signature-Input field identifies the covered components and parameters that describe how the signature was generated, while the Signature field contains the signature value. Each field <bcp14>MAY</bcp14> contain multiple labeled values.</t>
      <t indent="0" pn="section-4-3">An HTTP message signature is identified by a label within an HTTP message. This label <bcp14>MUST</bcp14> be unique within a given HTTP message and <bcp14>MUST</bcp14> be used in both the Signature-Input field and the Signature field. The label is chosen by the signer, except where a specific label is dictated by protocol negotiations such as those described in <xref target="request-signature" format="default" sectionFormat="of" derivedContent="Section 5"/>.</t>
      <t indent="0" pn="section-4-4">An HTTP message signature <bcp14>MUST</bcp14> use both the Signature-Input field and the Signature field, and each field <bcp14>MUST</bcp14> contain the same labels. The presence of a label in one field but not the other is an error.</t>
      <section anchor="signature-input-header" numbered="true" removeInRFC="false" toc="include" pn="section-4.1">
        <name slugifiedName="name-the-signature-input-http-fi">The Signature-Input HTTP Field</name>
        <t indent="0" pn="section-4.1-1">The Signature-Input field is a Dictionary Structured Field (defined in <xref section="3.2" sectionFormat="of" target="RFC8941" format="default" derivedLink="https://rfc-editor.org/rfc/rfc8941#section-3.2" derivedContent="STRUCTURED-FIELDS"/>) containing the metadata for one or more message signatures generated from components within the HTTP message. Each member describes a single message signature. The member's key is the label that uniquely identifies the message signature within the HTTP message. The member's value is the covered components ordered set serialized as an Inner List, including all signature metadata parameters identified by the label:</t>
        <sourcecode type="http-message" markers="false" pn="section-4.1-2">
NOTE: '\' line wrapping per RFC 8792

Signature-Input: sig1=("@method" "@target-uri" "@authority" \
  "content-digest" "cache-control");\
  created=1618884475;keyid="test-key-rsa-pss"
</sourcecode>
        <t indent="0" pn="section-4.1-3">To facilitate signature validation, the Signature-Input field value <bcp14>MUST</bcp14> contain the same serialized value used
in generating the signature base's <tt>@signature-params</tt> value defined in <xref target="signature-params" format="default" sectionFormat="of" derivedContent="Section 2.3"/>. Note that in a Structured Field value, list order and parameter order have to be preserved.</t>
        <t indent="0" pn="section-4.1-4">The signer <bcp14>MAY</bcp14> include the Signature-Input field as a trailer to facilitate signing a message after its content has been processed by the signer. However, since intermediaries are allowed to drop trailers as per <xref target="RFC9110" format="default" sectionFormat="of" derivedContent="HTTP"/>, it is <bcp14>RECOMMENDED</bcp14> that the Signature-Input field be included only as a header field to avoid signatures being inadvertently stripped from a message.</t>
        <t indent="0" pn="section-4.1-5">Multiple Signature-Input fields <bcp14>MAY</bcp14> be included in a single HTTP message. The signature labels <bcp14>MUST</bcp14> be unique across all field values.</t>
      </section>
      <section anchor="signature-header" numbered="true" removeInRFC="false" toc="include" pn="section-4.2">
        <name slugifiedName="name-the-signature-http-field">The Signature HTTP Field</name>
        <t indent="0" pn="section-4.2-1">The Signature field is a Dictionary Structured Field (defined in <xref section="3.2" sectionFormat="of" target="RFC8941" format="default" derivedLink="https://rfc-editor.org/rfc/rfc8941#section-3.2" derivedContent="STRUCTURED-FIELDS"/>) containing one or more message signatures generated from the signature context of the target message. The member's key is the label that uniquely identifies the message signature within the HTTP message. The member's value is a Byte Sequence containing the signature value for the message signature identified by the label:</t>
        <sourcecode type="http-message" markers="false" pn="section-4.2-2">
NOTE: '\' line wrapping per RFC 8792

Signature: sig1=:P0wLUszWQjoi54udOtydf9IWTfNhy+r53jGFj9XZuP4uKwxyJo\
  1RSHi+oEF1FuX6O29d+lbxwwBao1BAgadijW+7O/PyezlTnqAOVPWx9GlyntiCiHz\
  C87qmSQjvu1CFyFuWSjdGa3qLYYlNm7pVaJFalQiKWnUaqfT4LyttaXyoyZW84jS8\
  gyarxAiWI97mPXU+OVM64+HVBHmnEsS+lTeIsEQo36T3NFf2CujWARPQg53r58Rmp\
  Z+J9eKR2CD6IJQvacn5A4Ix5BUAVGqlyp8JYm+S/CWJi31PNUjRRCusCVRj05NrxA\
  BNFv3r5S9IXf2fYJK+eyW4AiGVMvMcOg==:
</sourcecode>
        <t indent="0" pn="section-4.2-3">The signer <bcp14>MAY</bcp14> include the Signature field as a trailer to facilitate signing a message after its content has been processed by the signer. However, since intermediaries are allowed to drop trailers as per <xref target="RFC9110" format="default" sectionFormat="of" derivedContent="HTTP"/>, it is <bcp14>RECOMMENDED</bcp14> that the Signature field be included only as a header field to avoid signatures being inadvertently stripped from a message.</t>
        <t indent="0" pn="section-4.2-4">Multiple Signature fields <bcp14>MAY</bcp14> be included in a single HTTP message. The signature labels <bcp14>MUST</bcp14> be unique across all field values.</t>
      </section>
      <section anchor="signature-multiple" numbered="true" removeInRFC="false" toc="include" pn="section-4.3">
        <name slugifiedName="name-multiple-signatures">Multiple Signatures</name>
        <t indent="0" pn="section-4.3-1">Multiple distinct signatures <bcp14>MAY</bcp14> be included in a single message. Each distinct signature <bcp14>MUST</bcp14> have a unique label. These multiple signatures could all be added by the same signer, or they could come from several different signers. For example, a signer may include multiple signatures signing the same message components with different keys or algorithms to support verifiers with different capabilities, or a reverse proxy may include information about the client in fields when forwarding the request to a service host, including a signature over the client's original signature values.</t>
        <t indent="0" pn="section-4.3-2">The following non-normative example starts with a signed request from the client. A reverse proxy takes this request and validates the client's signature:</t>
        <sourcecode type="http-message" markers="false" pn="section-4.3-3">
NOTE: '\' line wrapping per RFC 8792

POST /foo?param=Value&amp;Pet=dog HTTP/1.1
Host: example.com
Date: Tue, 20 Apr 2021 02:07:55 GMT
Content-Type: application/json
Content-Length: 18
Content-Digest: sha-512=:WZDPaVn/7XgHaAy8pmojAkGWoRx2UFChF41A2svX+T\
  aPm+AbwAgBWnrIiYllu7BNNyealdVLvRwEmTHWXvJwew==:
Signature-Input: sig1=("@method" "@authority" "@path" \
  "content-digest" "content-type" "content-length")\
  ;created=1618884475;keyid="test-key-ecc-p256"
Signature: sig1=:X5spyd6CFnAG5QnDyHfqoSNICd+BUP4LYMz2Q0JXlb//4Ijpzp\
  +kve2w4NIyqeAuM7jTDX+sNalzA8ESSaHD3A==:

{"hello": "world"}
</sourcecode>
        <t indent="0" pn="section-4.3-4">The proxy then alters the message before forwarding it on to the origin server, changing the target host and adding the Forwarded header field defined in <xref target="RFC7239" format="default" sectionFormat="of" derivedContent="RFC7239"/>:</t>
        <sourcecode type="http-message" markers="false" pn="section-4.3-5">
NOTE: '\' line wrapping per RFC 8792

POST /foo?param=Value&amp;Pet=dog HTTP/1.1
Host: origin.host.internal.example
Date: Tue, 20 Apr 2021 02:07:56 GMT
Content-Type: application/json
Content-Length: 18
Forwarded: for=192.0.2.123;host=example.com;proto=https
Content-Digest: sha-512=:WZDPaVn/7XgHaAy8pmojAkGWoRx2UFChF41A2svX+T\
  aPm+AbwAgBWnrIiYllu7BNNyealdVLvRwEmTHWXvJwew==:
Signature-Input: sig1=("@method" "@authority" "@path" \
  "content-digest" "content-type" "content-length")\
  ;created=1618884475;keyid="test-key-ecc-p256"
Signature: sig1=:X5spyd6CFnAG5QnDyHfqoSNICd+BUP4LYMz2Q0JXlb//4Ijpzp\
  +kve2w4NIyqeAuM7jTDX+sNalzA8ESSaHD3A==:

{"hello": "world"}
</sourcecode>
        <t indent="0" pn="section-4.3-6">The proxy is in a position to validate the incoming client's signature and make its own statement to the origin server about the nature of the request that it is forwarding by adding its own signature over the new message before passing it along to the origin server.
The proxy also includes all the elements from the original message that are relevant to the origin server's processing. In many cases, the proxy will want to cover all the same components that were covered by the client's signature, which is the case in the following example. Note that in this example, the proxy is signing over the new authority value, which it has changed. The proxy also adds the Forwarded header field to its own signature value.
The proxy identifies its own key and algorithm and, in this example, includes an expiration for the signature to indicate to downstream systems that the proxy will not vouch for this signed message past this short time window. This results in a signature base of:</t>
        <artwork align="left" pn="section-4.3-7">
NOTE: '\' line wrapping per RFC 8792

"@method": POST
"@authority": origin.host.internal.example
"@path": /foo
"content-digest": sha-512=:WZDPaVn/7XgHaAy8pmojAkGWoRx2UFChF41A2svX\
  +TaPm+AbwAgBWnrIiYllu7BNNyealdVLvRwEmTHWXvJwew==:
"content-type": application/json
"content-length": 18
"forwarded": for=192.0.2.123;host=example.com;proto=https
"@signature-params": ("@method" "@authority" "@path" \
  "content-digest" "content-type" "content-length" "forwarded")\
  ;created=1618884480;keyid="test-key-rsa";alg="rsa-v1_5-sha256"\
  ;expires=1618884540
</artwork>
        <t indent="0" pn="section-4.3-8">and a signature output value of:</t>
        <artwork align="left" pn="section-4.3-9">
NOTE: '\' line wrapping per RFC 8792

S6ZzPXSdAMOPjN/6KXfXWNO/f7V6cHm7BXYUh3YD/fRad4BCaRZxP+JH+8XY1I6+8Cy\
+CM5g92iHgxtRPz+MjniOaYmdkDcnL9cCpXJleXsOckpURl49GwiyUpZ10KHgOEe11s\
x3G2gxI8S0jnxQB+Pu68U9vVcasqOWAEObtNKKZd8tSFu7LB5YAv0RAGhB8tmpv7sFn\
Im9y+7X5kXQfi8NMaZaA8i2ZHwpBdg7a6CMfwnnrtflzvZdXAsD3LH2TwevU+/PBPv0\
B6NMNk93wUs/vfJvye+YuI87HU38lZHowtznbLVdp770I6VHR6WfgS9ddzirrswsE1w\
5o0LV/g==
</artwork>
        <t indent="0" pn="section-4.3-10">These values are added to the HTTP request message by the proxy. The original signature is included under the label <tt>sig1</tt>, and the reverse proxy's signature is included under the label <tt>proxy_sig</tt>. The proxy uses the key <tt>test-key-rsa</tt> to create its signature using the <tt>rsa-v1_5-sha256</tt> signature algorithm, while the client's original signature was made using the key <tt>test-key-rsa-pss</tt> and an RSA-PSS signature algorithm:</t>
        <sourcecode type="http-message" markers="false" pn="section-4.3-11">
NOTE: '\' line wrapping per RFC 8792

POST /foo?param=Value&amp;Pet=dog HTTP/1.1
Host: origin.host.internal.example
Date: Tue, 20 Apr 2021 02:07:56 GMT
Content-Type: application/json
Content-Length: 18
Forwarded: for=192.0.2.123;host=example.com;proto=https
Content-Digest: sha-512=:WZDPaVn/7XgHaAy8pmojAkGWoRx2UFChF41A2svX+T\
  aPm+AbwAgBWnrIiYllu7BNNyealdVLvRwEmTHWXvJwew==:
Signature-Input: sig1=("@method" "@authority" "@path" \
    "content-digest" "content-type" "content-length")\
    ;created=1618884475;keyid="test-key-ecc-p256", \
  proxy_sig=("@method" "@authority" "@path" "content-digest" \
    "content-type" "content-length" "forwarded")\
    ;created=1618884480;keyid="test-key-rsa";alg="rsa-v1_5-sha256"\
    ;expires=1618884540
Signature: sig1=:X5spyd6CFnAG5QnDyHfqoSNICd+BUP4LYMz2Q0JXlb//4Ijpzp\
    +kve2w4NIyqeAuM7jTDX+sNalzA8ESSaHD3A==:, \
  proxy_sig=:S6ZzPXSdAMOPjN/6KXfXWNO/f7V6cHm7BXYUh3YD/fRad4BCaRZxP+\
    JH+8XY1I6+8Cy+CM5g92iHgxtRPz+MjniOaYmdkDcnL9cCpXJleXsOckpURl49G\
    wiyUpZ10KHgOEe11sx3G2gxI8S0jnxQB+Pu68U9vVcasqOWAEObtNKKZd8tSFu7\
    LB5YAv0RAGhB8tmpv7sFnIm9y+7X5kXQfi8NMaZaA8i2ZHwpBdg7a6CMfwnnrtf\
    lzvZdXAsD3LH2TwevU+/PBPv0B6NMNk93wUs/vfJvye+YuI87HU38lZHowtznbL\
    Vdp770I6VHR6WfgS9ddzirrswsE1w5o0LV/g==:

{"hello": "world"}
</sourcecode>
        <t indent="0" pn="section-4.3-12">While the proxy could additionally include the client's Signature field value and Signature-Input fields from the original message in the new signature's covered components, this practice is <bcp14>NOT RECOMMENDED</bcp14> due to known weaknesses in signing signature values as discussed in <xref target="security-sign-signature" format="default" sectionFormat="of" derivedContent="Section 7.3.7"/>. The proxy is in a position to validate the client's signature; the changes the proxy makes to the message will invalidate the existing signature when the message is seen by the origin server. In this example, it is possible for the origin server to have additional information in its signature context to account for the change in authority, though this practice requires additional configuration and extra care as discussed in <xref target="security-context-multiple-signatures" format="default" sectionFormat="of" derivedContent="Section 7.4.4"/>. In other applications, the origin server will not be able to verify the original signature itself but will still want to verify that the proxy has done the appropriate validation of the client's signature. An application that needs to signal successful processing or receipt of a signature would need to carefully specify alternative mechanisms for sending such a signal securely.</t>
      </section>
    </section>
    <section anchor="request-signature" numbered="true" removeInRFC="false" toc="include" pn="section-5">
      <name slugifiedName="name-requesting-signatures">Requesting Signatures</name>
      <t indent="0" pn="section-5-1">While a signer is free to attach a signature to a request or response without prompting, it is often desirable for a potential verifier to signal that it expects a signature from a potential signer using the Accept-Signature field.</t>
      <t indent="0" pn="section-5-2">When the Accept-Signature field is sent in an HTTP request message, the field indicates that the client desires the server to sign the response using the identified parameters, and the target message is the response to this request. All responses from resources that support such signature negotiation <bcp14>SHOULD</bcp14> either be uncacheable or contain a Vary header field that lists Accept-Signature, in order to prevent a cache from returning a response with a signature intended for a different request.</t>
      <t indent="0" pn="section-5-3">When the Accept-Signature field is used in an HTTP response message, the field indicates that the server desires the client to sign its next request to the server with the identified parameters, and the target message is the client's next request. The client can choose to also continue signing future requests to the same server in the same way.</t>
      <t indent="0" pn="section-5-4">The target message of an Accept-Signature field <bcp14>MUST</bcp14> include all labeled signatures indicated in the Accept-Signature field, each covering the same identified components of the Accept-Signature field.</t>
      <t indent="0" pn="section-5-5">The sender of an Accept-Signature field <bcp14>MUST</bcp14> include only identifiers that are appropriate for the type of the target message. For example, if the target message is a request, the covered components cannot include the <tt>@status</tt> component identifier.</t>
      <section anchor="accept-signature-header" numbered="true" removeInRFC="false" toc="include" pn="section-5.1">
        <name slugifiedName="name-the-accept-signature-field">The Accept-Signature Field</name>
        <t indent="0" pn="section-5.1-1">The Accept-Signature field is a Dictionary Structured Field (defined in <xref section="3.2" sectionFormat="of" target="RFC8941" format="default" derivedLink="https://rfc-editor.org/rfc/rfc8941#section-3.2" derivedContent="STRUCTURED-FIELDS"/>) containing the metadata for one or more requested message signatures to be generated from message components of the target HTTP message. Each member describes a single message signature. The member's key is the label that uniquely identifies the requested message signature within the context of the target HTTP message.</t>
        <t indent="0" pn="section-5.1-2">The member's value is the serialization of the desired covered components of the target message, including any allowed component metadata parameters, using the serialization process defined in <xref target="signature-params" format="default" sectionFormat="of" derivedContent="Section 2.3"/>:</t>
        <sourcecode type="http-message" markers="false" pn="section-5.1-3">
NOTE: '\' line wrapping per RFC 8792

Accept-Signature: sig1=("@method" "@target-uri" "@authority" \
  "content-digest" "cache-control");\
  keyid="test-key-rsa-pss";created;tag="app-123"
</sourcecode>
        <t indent="0" pn="section-5.1-4">The list of component identifiers indicates the exact set of component identifiers to be included in the requested signature, including all applicable component parameters.</t>
        <t indent="0" pn="section-5.1-5">The signature request <bcp14>MAY</bcp14> include signature metadata parameters that indicate desired behavior for the signer. The following behavior is defined by this specification:</t>
        <dl spacing="normal" indent="3" newline="false" pn="section-5.1-6">
          <dt pn="section-5.1-6.1">
            <tt>created</tt>:</dt>
          <dd pn="section-5.1-6.2">The signer is requested to generate and include a creation time. This parameter has no associated value when sent as a signature request.</dd>
          <dt pn="section-5.1-6.3">
            <tt>expires</tt>:</dt>
          <dd pn="section-5.1-6.4">The signer is requested to generate and include an expiration time. This parameter has no associated value when sent as a signature request.</dd>
          <dt pn="section-5.1-6.5">
            <tt>nonce</tt>:</dt>
          <dd pn="section-5.1-6.6">The signer is requested to include the value of this parameter as the signature <tt>nonce</tt> in the target signature.</dd>
          <dt pn="section-5.1-6.7">
            <tt>alg</tt>:</dt>
          <dd pn="section-5.1-6.8">The signer is requested to use the indicated signature algorithm from the "HTTP Signature Algorithms" registry to create the target signature.</dd>
          <dt pn="section-5.1-6.9">
            <tt>keyid</tt>:</dt>
          <dd pn="section-5.1-6.10">The signer is requested to use the indicated key material to create the target signature.</dd>
          <dt pn="section-5.1-6.11">
            <tt>tag</tt>:</dt>
          <dd pn="section-5.1-6.12">The signer is requested to include the value of this parameter as the signature <tt>tag</tt> in the target signature.</dd>
        </dl>
      </section>
      <section anchor="processing-an-accept-signature" numbered="true" removeInRFC="false" toc="include" pn="section-5.2">
        <name slugifiedName="name-processing-an-accept-signat">Processing an Accept-Signature</name>
        <t indent="0" pn="section-5.2-1">The receiver of an Accept-Signature field fulfills that header as follows:</t>
        <ol spacing="normal" type="1" indent="adaptive" start="1" pn="section-5.2-2"><li pn="section-5.2-2.1" derivedCounter="1.">Parse the field value as a Dictionary.</li>
          <li pn="section-5.2-2.2" derivedCounter="2.">
            <t indent="0" pn="section-5.2-2.2.1">For each member of the Dictionary:
            </t>
            <ol spacing="normal" type="%p%d." indent="adaptive" start="1" pn="section-5.2-2.2.2"><li pn="section-5.2-2.2.2.1" derivedCounter="2.1.">The key is taken as the label of the output signature as specified in <xref target="signature-input-header" format="default" sectionFormat="of" derivedContent="Section 4.1"/>.</li>
              <li pn="section-5.2-2.2.2.2" derivedCounter="2.2.">Parse the value of the member to obtain the set of covered component identifiers.</li>
              <li pn="section-5.2-2.2.2.3" derivedCounter="2.3.">Determine that the covered components are applicable to the target message. If not, the process fails and returns an error.</li>
              <li pn="section-5.2-2.2.2.4" derivedCounter="2.4.">Process the requested parameters, such as the signing algorithm and key material. If any requested parameters cannot be fulfilled or if the requested parameters conflict with those deemed appropriate to the target message, the process fails and returns an error.</li>
              <li pn="section-5.2-2.2.2.5" derivedCounter="2.5.">Select and generate any additional parameters necessary for completing the signature.</li>
              <li pn="section-5.2-2.2.2.6" derivedCounter="2.6.">Create the HTTP message signature over the target message.</li>
              <li pn="section-5.2-2.2.2.7" derivedCounter="2.7.">Create the Signature-Input and Signature field values, and associate them with the label.</li>
            </ol>
          </li>
          <li pn="section-5.2-2.3" derivedCounter="3.">Optionally create any additional Signature-Input and Signature field values, with unique labels not found in the Accept-Signature field.</li>
          <li pn="section-5.2-2.4" derivedCounter="4.">Combine all labeled Signature-Input and Signature field values, and attach both fields to the target message.</li>
        </ol>
        <t indent="0" pn="section-5.2-3">By this process, a signature applied to a target message <bcp14>MUST</bcp14> have the same label, <bcp14>MUST</bcp14> include the same set of covered components, <bcp14>MUST</bcp14> process all requested parameters, and <bcp14>MAY</bcp14> have additional parameters.</t>
        <t indent="0" pn="section-5.2-4">The receiver of an Accept-Signature field <bcp14>MAY</bcp14> ignore any signature request that does not fit application parameters.</t>
        <t indent="0" pn="section-5.2-5">The target message <bcp14>MAY</bcp14> include additional signatures not specified by the Accept-Signature field. For example, to cover additional message components, the signer can create a second signature that includes the additional components as well as the signature output of the requested signature.</t>
      </section>
    </section>
    <section anchor="iana" numbered="true" removeInRFC="false" toc="include" pn="section-6">
      <name slugifiedName="name-iana-considerations">IANA Considerations</name>
      <t indent="0" pn="section-6-1">IANA has updated one registry and created four new registries, according to the following sections.</t>
      <section anchor="http-field-name-registration" numbered="true" removeInRFC="false" toc="include" pn="section-6.1">
        <name slugifiedName="name-http-field-name-registratio">HTTP Field Name Registration</name>
        <t indent="0" pn="section-6.1-1">IANA has updated the entries in the 
"Hypertext Transfer Protocol (HTTP) Field Name Registry" as follows:
</t>
        <table align="center" pn="table-1">
          <name slugifiedName="name-updates-to-the-hypertext-tr">Updates to the Hypertext Transfer Protocol (HTTP) Field Name Registry</name>
          <thead>
            <tr>
              <th align="left" colspan="1" rowspan="1">Field Name</th>
              <th align="left" colspan="1" rowspan="1">Status</th>
              <th align="left" colspan="1" rowspan="1">Reference</th>
            </tr>
          </thead>
          <tbody>
            <tr>
              <td align="left" colspan="1" rowspan="1">Signature-Input</td>
              <td align="left" colspan="1" rowspan="1">permanent</td>
              <td align="left" colspan="1" rowspan="1">
                <xref target="signature-input-header" format="default" sectionFormat="of" derivedContent="Section 4.1"/> of RFC 9421</td>
            </tr>
            <tr>
              <td align="left" colspan="1" rowspan="1">Signature</td>
              <td align="left" colspan="1" rowspan="1">permanent</td>
              <td align="left" colspan="1" rowspan="1">
                <xref target="signature-header" format="default" sectionFormat="of" derivedContent="Section 4.2"/> of RFC 9421</td>
            </tr>
            <tr>
              <td align="left" colspan="1" rowspan="1">Accept-Signature</td>
              <td align="left" colspan="1" rowspan="1">permanent</td>
              <td align="left" colspan="1" rowspan="1">
                <xref target="accept-signature-header" format="default" sectionFormat="of" derivedContent="Section 5.1"/> of RFC 9421</td>
            </tr>
          </tbody>
        </table>
      </section>
      <section anchor="hsa-registry" numbered="true" removeInRFC="false" toc="include" pn="section-6.2">
        <name slugifiedName="name-http-signature-algorithms-r">HTTP Signature Algorithms Registry</name>
        <t indent="0" pn="section-6.2-1">This document defines HTTP signature algorithms, for which IANA has created and now maintains a new registry titled "HTTP Signature Algorithms". Initial values for this registry are given in <xref target="iana-hsa-contents" format="default" sectionFormat="of" derivedContent="Section 6.2.2"/>. Future assignments and modifications to existing assignments are to be made through the Specification Required registration policy <xref target="RFC8126" format="default" sectionFormat="of" derivedContent="RFC8126"/>.</t>
        <t indent="0" pn="section-6.2-2">The algorithms listed in this registry identify some possible cryptographic algorithms for applications to use with this specification, but the entries neither represent an exhaustive list of possible algorithms nor indicate fitness for purpose with any particular application of this specification. An application is free to implement any algorithm that suits its needs, provided the signer and verifier can agree to the parameters of that algorithm in a secure and deterministic fashion. When an application needs to signal the use of a particular algorithm at runtime using the <tt>alg</tt> signature parameter, this registry provides a mapping between the value of that parameter and a particular algorithm. However, the use of the <tt>alg</tt> parameter needs to be treated with caution to avoid various forms of algorithm confusion and substitution attacks, as discussed in <xref target="security" format="default" sectionFormat="of" derivedContent="Section 7"/>.</t>
        <t indent="0" pn="section-6.2-3">The Status value should reflect standardization status and the broad opinion of relevant interest groups such as the IETF or security-related Standards Development Organizations (SDOs). When an algorithm is first registered, the designated expert (DE) should set the Status field to "Active" if there is consensus for the algorithm to be generally recommended as secure or "Provisional" if the algorithm has not reached that consensus, e.g., for an experimental algorithm. A status of "Provisional" does not mean that the algorithm is known to be insecure but instead indicates that the algorithm has not reached consensus regarding its properties. If at a future time the algorithm as registered is found to have flaws, the registry entry can be updated and the algorithm can be marked as "Deprecated" to indicate that the algorithm has been found to have problems. This status does not preclude an application from using a particular algorithm; rather, it serves to provide a warning regarding possible known issues with an algorithm that need to be considered by the application. The DE can further ensure that the registration includes an explanation and reference for the Status value; this is particularly important for deprecated algorithms.</t>
        <t indent="0" pn="section-6.2-4">The DE is expected to do the following:</t>
        <ul bare="false" empty="false" indent="3" spacing="normal" pn="section-6.2-5">
          <li pn="section-6.2-5.1">Ensure that the algorithms referenced by a registered algorithm identifier are fully defined with all parameters (e.g., salt, hash, required key length) fixed by the defining text.</li>
          <li pn="section-6.2-5.2">Ensure that the algorithm definition fully specifies the <tt>HTTP_SIGN</tt> and <tt>HTTP_VERIFY</tt> primitive functions, including how all defined inputs and outputs map to the underlying cryptographic algorithm.</li>
          <li pn="section-6.2-5.3">Reject any registrations that are aliases of existing registrations.</li>
          <li pn="section-6.2-5.4">Ensure that all registrations follow the template presented in <xref target="iana-hsa-template" format="default" sectionFormat="of" derivedContent="Section 6.2.1"/>; this includes ensuring that the length of the name is not excessive while still being unique and recognizable.</li>
        </ul>
        <t indent="0" pn="section-6.2-6">This specification creates algorithm identifiers by including major parameters in the identifier String in order to make the algorithm name unique and recognizable by developers. However, algorithm identifiers in this registry are to be interpreted as whole String values and not as a combination of parts. That is to say, it is expected that implementors understand <tt>rsa-pss-sha512</tt> as referring to one specific algorithm with its hash, mask, and salt values set as defined in the defining text that establishes the identifier in question. Implementors do not parse out the <tt>rsa</tt>, <tt>pss</tt>, and <tt>sha512</tt> portions of the identifier to determine parameters of the signing algorithm from the String, and the registration of one combination of parameters does not imply the registration of other combinations.</t>
        <section anchor="iana-hsa-template" numbered="true" removeInRFC="false" toc="include" pn="section-6.2.1">
          <name slugifiedName="name-registration-template">Registration Template</name>
          <dl newline="true" indent="3" spacing="normal" pn="section-6.2.1-1">
            <dt pn="section-6.2.1-1.1">Algorithm Name:</dt>
            <dd pn="section-6.2.1-1.2">
              <t indent="0" pn="section-6.2.1-1.2.1">An identifier for the HTTP signature algorithm. The name <bcp14>MUST</bcp14> be an ASCII string that conforms to the <tt>sf-string</tt> ABNF rule in <xref section="3.3.3" sectionFormat="of" target="RFC8941" format="default" derivedLink="https://rfc-editor.org/rfc/rfc8941#section-3.3.3" derivedContent="STRUCTURED-FIELDS"/> and <bcp14>SHOULD NOT</bcp14> exceed 20 characters in length. The identifier <bcp14>MUST</bcp14> be unique within the context of the registry.</t>
            </dd>
            <dt pn="section-6.2.1-1.3">Description:</dt>
            <dd pn="section-6.2.1-1.4">
              <t indent="0" pn="section-6.2.1-1.4.1">A brief description of the algorithm used to sign the signature base.</t>
            </dd>
            <dt pn="section-6.2.1-1.5">Status:</dt>
            <dd pn="section-6.2.1-1.6">
              <t indent="0" pn="section-6.2.1-1.6.1">The status of the algorithm. <bcp14>MUST</bcp14> start with one of the following values and <bcp14>MAY</bcp14> contain additional explanatory text. The options are:</t>
              <dl newline="false" spacing="normal" indent="3" pn="section-6.2.1-1.6.2">
                <dt pn="section-6.2.1-1.6.2.1">"Active":</dt>
                <dd pn="section-6.2.1-1.6.2.2">For algorithms without known problems. The signature algorithm is fully specified, and its security properties are understood.</dd>
                <dt pn="section-6.2.1-1.6.2.3">"Provisional":</dt>
                <dd pn="section-6.2.1-1.6.2.4">For unproven algorithms. The signature algorithm is fully specified, but its security properties are not known or proven.</dd>
                <dt pn="section-6.2.1-1.6.2.5">"Deprecated":</dt>
                <dd pn="section-6.2.1-1.6.2.6">For algorithms with known security issues. The signature algorithm is no longer recommended for general use and might be insecure or unsafe in some known circumstances.</dd>
              </dl>
            </dd>
            <dt pn="section-6.2.1-1.7">Reference:</dt>
            <dd pn="section-6.2.1-1.8">
              <t indent="0" pn="section-6.2.1-1.8.1">Reference to the document or documents that specify the
  algorithm, preferably including a URI that can be used
  to retrieve a copy of the document(s). An indication of the
  relevant sections may also be included but is not required.</t>
            </dd>
          </dl>
        </section>
        <section anchor="iana-hsa-contents" numbered="true" removeInRFC="false" toc="include" pn="section-6.2.2">
          <name slugifiedName="name-initial-contents">Initial Contents</name>
          <t indent="0" pn="section-6.2.2-1">The table below contains the initial contents of the "HTTP Signature Algorithms" registry.</t>
          <table align="center" pn="table-2">
            <name slugifiedName="name-initial-contents-of-the-htt">Initial Contents of the HTTP Signature Algorithms Registry</name>
            <thead>
              <tr>
                <th align="left" colspan="1" rowspan="1">Algorithm Name</th>
                <th align="left" colspan="1" rowspan="1">Description</th>
                <th align="left" colspan="1" rowspan="1">Status</th>
                <th align="left" colspan="1" rowspan="1">Reference</th>
              </tr>
            </thead>
            <tbody>
              <tr>
                <td align="left" colspan="1" rowspan="1">
                  <tt>rsa-pss-sha512</tt></td>
                <td align="left" colspan="1" rowspan="1">RSASSA-PSS using SHA-512</td>
                <td align="left" colspan="1" rowspan="1">Active</td>
                <td align="left" colspan="1" rowspan="1">
                  <xref target="method-rsa-pss-sha512" format="default" sectionFormat="of" derivedContent="Section 3.3.1"/> of RFC 9421</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">
                  <tt>rsa-v1_5-sha256</tt></td>
                <td align="left" colspan="1" rowspan="1">RSASSA-PKCS1-v1_5 using SHA-256</td>
                <td align="left" colspan="1" rowspan="1">Active</td>
                <td align="left" colspan="1" rowspan="1">
                  <xref target="method-rsa-v1_5-sha256" format="default" sectionFormat="of" derivedContent="Section 3.3.2"/> of RFC 9421</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">
                  <tt>hmac-sha256</tt></td>
                <td align="left" colspan="1" rowspan="1">HMAC using SHA-256</td>
                <td align="left" colspan="1" rowspan="1">Active</td>
                <td align="left" colspan="1" rowspan="1">
                  <xref target="method-hmac-sha256" format="default" sectionFormat="of" derivedContent="Section 3.3.3"/> of RFC 9421</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">
                  <tt>ecdsa-p256-sha256</tt></td>
                <td align="left" colspan="1" rowspan="1">ECDSA using curve P-256 DSS and SHA-256</td>
                <td align="left" colspan="1" rowspan="1">Active</td>
                <td align="left" colspan="1" rowspan="1">
                  <xref target="method-ecdsa-p256-sha256" format="default" sectionFormat="of" derivedContent="Section 3.3.4"/> of RFC 9421</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">
                  <tt>ecdsa-p384-sha384</tt></td>
                <td align="left" colspan="1" rowspan="1">ECDSA using curve P-384 DSS and SHA-384</td>
                <td align="left" colspan="1" rowspan="1">Active</td>
                <td align="left" colspan="1" rowspan="1">
                  <xref target="method-ecdsa-p384-sha384" format="default" sectionFormat="of" derivedContent="Section 3.3.5"/> of RFC 9421</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">
                  <tt>ed25519</tt></td>
                <td align="left" colspan="1" rowspan="1">EdDSA using curve edwards25519</td>
                <td align="left" colspan="1" rowspan="1">Active</td>
                <td align="left" colspan="1" rowspan="1">
                  <xref target="method-ed25519" format="default" sectionFormat="of" derivedContent="Section 3.3.6"/> of RFC 9421</td>
              </tr>
            </tbody>
          </table>
        </section>
      </section>
      <section anchor="param-registry" numbered="true" removeInRFC="false" toc="include" pn="section-6.3">
        <name slugifiedName="name-http-signature-metadata-par">HTTP Signature Metadata Parameters Registry</name>
        <t indent="0" pn="section-6.3-1">This document defines the signature parameters structure (<xref target="signature-params" format="default" sectionFormat="of" derivedContent="Section 2.3"/>), which may have parameters containing metadata about a message signature. IANA has created and now maintains a new registry titled "HTTP Signature Metadata Parameters" to record and maintain the set of parameters defined for use with member values in the signature parameters structure. Initial values for this registry are given in <xref target="iana-param-contents" format="default" sectionFormat="of" derivedContent="Section 6.3.2"/>. Future assignments and modifications to existing assignments are to be made through the Expert Review registration policy <xref target="RFC8126" format="default" sectionFormat="of" derivedContent="RFC8126"/>.</t>
        <t indent="0" pn="section-6.3-2">The DE is expected to do the following:</t>
        <ul bare="false" empty="false" indent="3" spacing="normal" pn="section-6.3-3">
          <li pn="section-6.3-3.1">Ensure that the name follows the template presented in <xref target="iana-param-template" format="default" sectionFormat="of" derivedContent="Section 6.3.1"/>; this includes ensuring that the length of the name is not excessive while still being unique and recognizable for its defined function.</li>
          <li pn="section-6.3-3.2">Ensure that the defined functionality is clear and does not conflict with other registered parameters.</li>
          <li pn="section-6.3-3.3">Ensure that the definition of the metadata parameter includes its behavior when used as part of the normal signature process as well as when used in an Accept-Signature field.</li>
        </ul>
        <section anchor="iana-param-template" numbered="true" removeInRFC="false" toc="include" pn="section-6.3.1">
          <name slugifiedName="name-registration-template-2">Registration Template</name>
          <dl newline="true" indent="3" spacing="normal" pn="section-6.3.1-1">
            <dt pn="section-6.3.1-1.1">Name:</dt>
            <dd pn="section-6.3.1-1.2">
              <t indent="0" pn="section-6.3.1-1.2.1">An identifier for the HTTP signature metadata parameter. The name <bcp14>MUST</bcp14> be an ASCII string that conforms to the <tt>key</tt> ABNF rule defined in <xref section="3.1.2" sectionFormat="of" target="RFC8941" format="default" derivedLink="https://rfc-editor.org/rfc/rfc8941#section-3.1.2" derivedContent="STRUCTURED-FIELDS"/> and <bcp14>SHOULD NOT</bcp14> exceed 20 characters in length. The identifier <bcp14>MUST</bcp14> be unique within the context of the registry.</t>
            </dd>
            <dt pn="section-6.3.1-1.3">Description:</dt>
            <dd pn="section-6.3.1-1.4">
              <t indent="0" pn="section-6.3.1-1.4.1">A brief description of the metadata parameter and what it represents.</t>
            </dd>
            <dt pn="section-6.3.1-1.5">Reference:</dt>
            <dd pn="section-6.3.1-1.6">
              <t indent="0" pn="section-6.3.1-1.6.1">Reference to the document or documents that specify the
  parameter, preferably including a URI that can be used
  to retrieve a copy of the document(s). An indication of the
  relevant sections may also be included but is not required.</t>
            </dd>
          </dl>
        </section>
        <section anchor="iana-param-contents" numbered="true" removeInRFC="false" toc="include" pn="section-6.3.2">
          <name slugifiedName="name-initial-contents-2">Initial Contents</name>
          <t indent="0" pn="section-6.3.2-1">The table below contains the initial contents of the "HTTP Signature Metadata Parameters" registry. Each row in the table represents a distinct entry in the registry.</t>
          <table align="center" pn="table-3">
            <name slugifiedName="name-initial-contents-of-the-http">Initial Contents of the HTTP Signature Metadata Parameters Registry</name>
            <thead>
              <tr>
                <th align="left" colspan="1" rowspan="1">Name</th>
                <th align="left" colspan="1" rowspan="1">Description</th>
                <th align="left" colspan="1" rowspan="1">Reference</th>
              </tr>
            </thead>
            <tbody>
              <tr>
                <td align="left" colspan="1" rowspan="1">
                  <tt>alg</tt></td>
                <td align="left" colspan="1" rowspan="1">Explicitly declared signature algorithm</td>
                <td align="left" colspan="1" rowspan="1">
                  <xref target="signature-params" format="default" sectionFormat="of" derivedContent="Section 2.3"/> of RFC 9421</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">
                  <tt>created</tt></td>
                <td align="left" colspan="1" rowspan="1">Timestamp of signature creation</td>
                <td align="left" colspan="1" rowspan="1">
                  <xref target="signature-params" format="default" sectionFormat="of" derivedContent="Section 2.3"/> of RFC 9421</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">
                  <tt>expires</tt></td>
                <td align="left" colspan="1" rowspan="1">Timestamp of proposed signature expiration</td>
                <td align="left" colspan="1" rowspan="1">
                  <xref target="signature-params" format="default" sectionFormat="of" derivedContent="Section 2.3"/> of RFC 9421</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">
                  <tt>keyid</tt></td>
                <td align="left" colspan="1" rowspan="1">Key identifier for the signing and verification keys used to create this signature</td>
                <td align="left" colspan="1" rowspan="1">
                  <xref target="signature-params" format="default" sectionFormat="of" derivedContent="Section 2.3"/> of RFC 9421</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">
                  <tt>nonce</tt></td>
                <td align="left" colspan="1" rowspan="1">A single-use nonce value</td>
                <td align="left" colspan="1" rowspan="1">
                  <xref target="signature-params" format="default" sectionFormat="of" derivedContent="Section 2.3"/> of RFC 9421</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">
                  <tt>tag</tt></td>
                <td align="left" colspan="1" rowspan="1">An application-specific tag for a signature</td>
                <td align="left" colspan="1" rowspan="1">
                  <xref target="signature-params" format="default" sectionFormat="of" derivedContent="Section 2.3"/> of RFC 9421</td>
              </tr>
            </tbody>
          </table>
        </section>
      </section>
      <section anchor="content-registry" numbered="true" removeInRFC="false" toc="include" pn="section-6.4">
        <name slugifiedName="name-http-signature-derived-comp">HTTP Signature Derived Component Names Registry</name>
        <t indent="0" pn="section-6.4-1">This document defines a method for canonicalizing HTTP message components, including components that can be derived from the context of the target message outside of the HTTP fields. These derived components are identified by a unique String, known as the component name. Component names for derived components always start with the "at" (@) symbol to distinguish them from HTTP field names. IANA has created and now maintains a new registry titled "HTTP Signature Derived Component Names" to record and maintain the set of non-field component names and the methods used to produce their associated component values. Initial values for this registry are given in <xref target="iana-content-contents" format="default" sectionFormat="of" derivedContent="Section 6.4.2"/>. Future assignments and modifications to existing assignments are to be made through the Expert Review registration policy <xref target="RFC8126" format="default" sectionFormat="of" derivedContent="RFC8126"/>.</t>
        <t indent="0" pn="section-6.4-2">The DE is expected to do the following:</t>
        <ul bare="false" empty="false" indent="3" spacing="normal" pn="section-6.4-3">
          <li pn="section-6.4-3.1">Ensure that the name follows the template presented in <xref target="iana-content-template" format="default" sectionFormat="of" derivedContent="Section 6.4.1"/>; this includes ensuring that the length of the name is not excessive while still being unique and recognizable for its defined function.</li>
          <li pn="section-6.4-3.2">Ensure that the component value represented by the registration request can be deterministically derived from the target HTTP message.</li>
          <li pn="section-6.4-3.3">Ensure that any parameters defined for the registration request are clearly documented, along with their effects on the component value.</li>
        </ul>
        <t indent="0" pn="section-6.4-4">The DE should ensure that a registration is sufficiently distinct from existing derived component definitions to warrant its registration.</t>
        <t indent="0" pn="section-6.4-5">When setting a registered item's status to "Deprecated", the DE should ensure that a reason for the deprecation is documented, along with instructions for moving away from the deprecated functionality.</t>
        <section anchor="iana-content-template" numbered="true" removeInRFC="false" toc="include" pn="section-6.4.1">
          <name slugifiedName="name-registration-template-3">Registration Template</name>
          <dl newline="true" indent="3" spacing="normal" pn="section-6.4.1-1">
            <dt pn="section-6.4.1-1.1">Name:</dt>
            <dd pn="section-6.4.1-1.2">
              <t indent="0" pn="section-6.4.1-1.2.1">A name for the HTTP derived component. The name <bcp14>MUST</bcp14> begin with the "at" (<tt>@</tt>) character followed by an ASCII string consisting only of lowercase characters (<tt>"a"</tt>-<tt>"z"</tt>), digits (<tt>"0"</tt>-<tt>"9"</tt>), and hyphens (<tt>"-"</tt>), and <bcp14>SHOULD NOT</bcp14> exceed 20 characters in length. The name <bcp14>MUST</bcp14> be unique within the context of the registry.</t>
            </dd>
            <dt pn="section-6.4.1-1.3">Description:</dt>
            <dd pn="section-6.4.1-1.4">
              <t indent="0" pn="section-6.4.1-1.4.1">A description of the derived component.</t>
            </dd>
            <dt pn="section-6.4.1-1.5">Status:</dt>
            <dd pn="section-6.4.1-1.6">
              <t indent="0" pn="section-6.4.1-1.6.1">A brief text description of the status of the algorithm. The description <bcp14>MUST</bcp14> begin with one of "Active" or "Deprecated" and <bcp14>MAY</bcp14> provide further context or explanation as to the reason for the status. A value of "Deprecated" indicates that the derived component name is no longer recommended for use.</t>
            </dd>
            <dt pn="section-6.4.1-1.7">Target:</dt>
            <dd pn="section-6.4.1-1.8">
              <t indent="0" pn="section-6.4.1-1.8.1">The valid message targets for the derived parameter. <bcp14>MUST</bcp14> be one of the values "Request", "Response", or "Request, Response". The semantics of these entries are defined in <xref target="derived-components" format="default" sectionFormat="of" derivedContent="Section 2.2"/>.</t>
            </dd>
            <dt pn="section-6.4.1-1.9">Reference:</dt>
            <dd pn="section-6.4.1-1.10">
              <t indent="0" pn="section-6.4.1-1.10.1">Reference to the document or documents that specify the
  derived component, preferably including a URI that can be used
  to retrieve a copy of the document(s). An indication of the
  relevant sections may also be included but is not required.</t>
            </dd>
          </dl>
        </section>
        <section anchor="iana-content-contents" numbered="true" removeInRFC="false" toc="include" pn="section-6.4.2">
          <name slugifiedName="name-initial-contents-3">Initial Contents</name>
          <t indent="0" pn="section-6.4.2-1">The table below contains the initial contents of the "HTTP Signature Derived Component Names" registry.</t>
          <table align="center" pn="table-4">
            <name slugifiedName="name-initial-contents-of-the-http-">Initial Contents of the HTTP Signature Derived Component Names Registry</name>
            <thead>
              <tr>
                <th align="left" colspan="1" rowspan="1">Name</th>
                <th align="left" colspan="1" rowspan="1">Description</th>
                <th align="left" colspan="1" rowspan="1">Status</th>
                <th align="left" colspan="1" rowspan="1">Target</th>
                <th align="left" colspan="1" rowspan="1">Reference</th>
              </tr>
            </thead>
            <tbody>
              <tr>
                <td align="left" colspan="1" rowspan="1">
                  <tt>@signature-params</tt></td>
                <td align="left" colspan="1" rowspan="1">Reserved for signature parameters line in signature base</td>
                <td align="left" colspan="1" rowspan="1">Active</td>
                <td align="left" colspan="1" rowspan="1">Request, Response</td>
                <td align="left" colspan="1" rowspan="1">
                  <xref target="signature-params" format="default" sectionFormat="of" derivedContent="Section 2.3"/> of RFC 9421</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">
                  <tt>@method</tt></td>
                <td align="left" colspan="1" rowspan="1">The HTTP request method</td>
                <td align="left" colspan="1" rowspan="1">Active</td>
                <td align="left" colspan="1" rowspan="1">Request</td>
                <td align="left" colspan="1" rowspan="1">
                  <xref target="content-request-method" format="default" sectionFormat="of" derivedContent="Section 2.2.1"/> of RFC 9421</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">
                  <tt>@authority</tt></td>
                <td align="left" colspan="1" rowspan="1">The HTTP authority, or target host</td>
                <td align="left" colspan="1" rowspan="1">Active</td>
                <td align="left" colspan="1" rowspan="1">Request</td>
                <td align="left" colspan="1" rowspan="1">
                  <xref target="content-request-authority" format="default" sectionFormat="of" derivedContent="Section 2.2.3"/> of RFC 9421</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">
                  <tt>@scheme</tt></td>
                <td align="left" colspan="1" rowspan="1">The URI scheme of the request URI</td>
                <td align="left" colspan="1" rowspan="1">Active</td>
                <td align="left" colspan="1" rowspan="1">Request</td>
                <td align="left" colspan="1" rowspan="1">
                  <xref target="content-request-scheme" format="default" sectionFormat="of" derivedContent="Section 2.2.4"/> of RFC 9421</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">
                  <tt>@target-uri</tt></td>
                <td align="left" colspan="1" rowspan="1">The full target URI of the request</td>
                <td align="left" colspan="1" rowspan="1">Active</td>
                <td align="left" colspan="1" rowspan="1">Request</td>
                <td align="left" colspan="1" rowspan="1">
                  <xref target="content-target-uri" format="default" sectionFormat="of" derivedContent="Section 2.2.2"/> of RFC 9421</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">
                  <tt>@request-target</tt></td>
                <td align="left" colspan="1" rowspan="1">The request target of the request</td>
                <td align="left" colspan="1" rowspan="1">Active</td>
                <td align="left" colspan="1" rowspan="1">Request</td>
                <td align="left" colspan="1" rowspan="1">
                  <xref target="content-request-target" format="default" sectionFormat="of" derivedContent="Section 2.2.5"/> of RFC 9421</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">
                  <tt>@path</tt></td>
                <td align="left" colspan="1" rowspan="1">The full path of the request URI</td>
                <td align="left" colspan="1" rowspan="1">Active</td>
                <td align="left" colspan="1" rowspan="1">Request</td>
                <td align="left" colspan="1" rowspan="1">
                  <xref target="content-request-path" format="default" sectionFormat="of" derivedContent="Section 2.2.6"/> of RFC 9421</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">
                  <tt>@query</tt></td>
                <td align="left" colspan="1" rowspan="1">The full query of the request URI</td>
                <td align="left" colspan="1" rowspan="1">Active</td>
                <td align="left" colspan="1" rowspan="1">Request</td>
                <td align="left" colspan="1" rowspan="1">
                  <xref target="content-request-query" format="default" sectionFormat="of" derivedContent="Section 2.2.7"/> of RFC 9421</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">
                  <tt>@query-param</tt></td>
                <td align="left" colspan="1" rowspan="1">A single named query parameter</td>
                <td align="left" colspan="1" rowspan="1">Active</td>
                <td align="left" colspan="1" rowspan="1">Request</td>
                <td align="left" colspan="1" rowspan="1">
                  <xref target="content-request-query-param" format="default" sectionFormat="of" derivedContent="Section 2.2.8"/> of RFC 9421</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">
                  <tt>@status</tt></td>
                <td align="left" colspan="1" rowspan="1">The status code of the response</td>
                <td align="left" colspan="1" rowspan="1">Active</td>
                <td align="left" colspan="1" rowspan="1">Response</td>
                <td align="left" colspan="1" rowspan="1">
                  <xref target="content-status-code" format="default" sectionFormat="of" derivedContent="Section 2.2.9"/> of RFC 9421</td>
              </tr>
            </tbody>
          </table>
        </section>
      </section>
      <section anchor="component-param-registry" numbered="true" removeInRFC="false" toc="include" pn="section-6.5">
        <name slugifiedName="name-http-signature-component-pa">HTTP Signature Component Parameters Registry</name>
        <t indent="0" pn="section-6.5-1">This document defines several kinds of component identifiers, some of which can be parameterized in specific circumstances to provide unique modified behavior. IANA has created and now maintains a new registry titled "HTTP Signature Component Parameters" to record and maintain the set of parameter names, the component identifiers they are associated with, and the modifications these parameters make to the component value. Definitions of parameters <bcp14>MUST</bcp14> define the targets to which they apply (such as specific field types, derived components, or contexts). Initial values for this registry are given in <xref target="iana-component-param-contents" format="default" sectionFormat="of" derivedContent="Section 6.5.2"/>. Future assignments and modifications to existing assignments are to be made through the Expert Review registration policy <xref target="RFC8126" format="default" sectionFormat="of" derivedContent="RFC8126"/>.</t>
        <t indent="0" pn="section-6.5-2">The DE is expected to do the following:</t>
        <ul bare="false" empty="false" indent="3" spacing="normal" pn="section-6.5-3">
          <li pn="section-6.5-3.1">Ensure that the name follows the template presented in <xref target="iana-component-param-template" format="default" sectionFormat="of" derivedContent="Section 6.5.1"/>; this includes ensuring that the length of the name is not excessive while still being unique and recognizable for its defined function.</li>
          <li pn="section-6.5-3.2">Ensure that the definition of the field sufficiently defines any interactions or incompatibilities with other existing parameters known at the time of the registration request.</li>
          <li pn="section-6.5-3.3">Ensure that the component value defined by the component identifier with the parameter applied can be deterministically derived from the target HTTP message in cases where the parameter changes the component value.</li>
        </ul>
        <section anchor="iana-component-param-template" numbered="true" removeInRFC="false" toc="include" pn="section-6.5.1">
          <name slugifiedName="name-registration-template-4">Registration Template</name>
          <dl newline="true" indent="3" spacing="normal" pn="section-6.5.1-1">
            <dt pn="section-6.5.1-1.1">Name:</dt>
            <dd pn="section-6.5.1-1.2">
              <t indent="0" pn="section-6.5.1-1.2.1">A name for the parameter. The name <bcp14>MUST</bcp14> be an ASCII string that conforms to the <tt>key</tt> ABNF rule defined in <xref section="3.1.2" sectionFormat="of" target="RFC8941" format="default" derivedLink="https://rfc-editor.org/rfc/rfc8941#section-3.1.2" derivedContent="STRUCTURED-FIELDS"/> and <bcp14>SHOULD NOT</bcp14> exceed 20 characters in length. The name <bcp14>MUST</bcp14> be unique within the context of the registry.</t>
            </dd>
            <dt pn="section-6.5.1-1.3">Description:</dt>
            <dd pn="section-6.5.1-1.4">
              <t indent="0" pn="section-6.5.1-1.4.1">A description of the parameter's function.</t>
            </dd>
            <dt pn="section-6.5.1-1.5">Reference:</dt>
            <dd pn="section-6.5.1-1.6">
              <t indent="0" pn="section-6.5.1-1.6.1">Reference to the document or documents that specify the
  derived component, preferably including a URI that can be used
  to retrieve a copy of the document(s). An indication of the
  relevant sections may also be included but is not required.</t>
            </dd>
          </dl>
        </section>
        <section anchor="iana-component-param-contents" numbered="true" removeInRFC="false" toc="include" pn="section-6.5.2">
          <name slugifiedName="name-initial-contents-4">Initial Contents</name>
          <t indent="0" pn="section-6.5.2-1">The table below contains the initial contents of the "HTTP Signature Component Parameters" registry.</t>
          <table align="center" pn="table-5">
            <name slugifiedName="name-initial-contents-of-the-http-s">Initial Contents of the HTTP Signature Component Parameters Registry</name>
            <thead>
              <tr>
                <th align="left" colspan="1" rowspan="1">Name</th>
                <th align="left" colspan="1" rowspan="1">Description</th>
                <th align="left" colspan="1" rowspan="1">Reference</th>
              </tr>
            </thead>
            <tbody>
              <tr>
                <td align="left" colspan="1" rowspan="1">
                  <tt>sf</tt></td>
                <td align="left" colspan="1" rowspan="1">Strict Structured Field serialization</td>
                <td align="left" colspan="1" rowspan="1">
                  <xref target="http-field-structured" format="default" sectionFormat="of" derivedContent="Section 2.1.1"/> of RFC 9421</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">
                  <tt>key</tt></td>
                <td align="left" colspan="1" rowspan="1">Single key value of Dictionary Structured Fields</td>
                <td align="left" colspan="1" rowspan="1">
                  <xref target="http-field-dictionary" format="default" sectionFormat="of" derivedContent="Section 2.1.2"/> of RFC 9421</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">
                  <tt>bs</tt></td>
                <td align="left" colspan="1" rowspan="1">Byte Sequence wrapping indicator</td>
                <td align="left" colspan="1" rowspan="1">
                  <xref target="http-field-byte-sequence" format="default" sectionFormat="of" derivedContent="Section 2.1.3"/> of RFC 9421</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">
                  <tt>tr</tt></td>
                <td align="left" colspan="1" rowspan="1">Trailer</td>
                <td align="left" colspan="1" rowspan="1">
                  <xref target="http-trailer" format="default" sectionFormat="of" derivedContent="Section 2.1.4"/> of RFC 9421</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">
                  <tt>req</tt></td>
                <td align="left" colspan="1" rowspan="1">Related request indicator</td>
                <td align="left" colspan="1" rowspan="1">
                  <xref target="content-request-response" format="default" sectionFormat="of" derivedContent="Section 2.4"/> of RFC 9421</td>
              </tr>
              <tr>
                <td align="left" colspan="1" rowspan="1">
                  <tt>name</tt></td>
                <td align="left" colspan="1" rowspan="1">Single named query parameter</td>
                <td align="left" colspan="1" rowspan="1">
                  <xref target="content-request-query-param" format="default" sectionFormat="of" derivedContent="Section 2.2.8"/> of RFC 9421</td>
              </tr>
            </tbody>
          </table>
        </section>
      </section>
    </section>
    <section anchor="security" numbered="true" removeInRFC="false" toc="include" pn="section-7">
      <name slugifiedName="name-security-considerations">Security Considerations</name>
      <t indent="0" pn="section-7-1">In order for an HTTP message to be considered <em>covered</em> by a signature, all of the following conditions have to be true:</t>
      <ul spacing="normal" bare="false" empty="false" indent="3" pn="section-7-2">
        <li pn="section-7-2.1">A signature is expected or allowed on the message by the verifier.</li>
        <li pn="section-7-2.2">The signature exists on the message.</li>
        <li pn="section-7-2.3">The signature is verified against the identified key material and algorithm.</li>
        <li pn="section-7-2.4">The key material and algorithm are appropriate for the context of the message.</li>
        <li pn="section-7-2.5">The signature is within expected time boundaries.</li>
        <li pn="section-7-2.6">The signature covers the expected content, including any critical components.</li>
        <li pn="section-7-2.7">The list of covered components is applicable to the context of the message.</li>
      </ul>
      <t indent="0" pn="section-7-3">In addition to the application requirement definitions listed in <xref target="application" format="default" sectionFormat="of" derivedContent="Section 1.4"/>, the following security considerations provide discussion and context regarding the requirements of creating and verifying signatures on HTTP messages.</t>
      <section anchor="general-considerations" numbered="true" removeInRFC="false" toc="include" pn="section-7.1">
        <name slugifiedName="name-general-considerations">General Considerations</name>
        <section anchor="security-ignore" numbered="true" removeInRFC="false" toc="include" pn="section-7.1.1">
          <name slugifiedName="name-skipping-signature-verifica">Skipping Signature Verification</name>
          <t indent="0" pn="section-7.1.1-1">HTTP message signatures only provide security if the signature is verified by the verifier. Since the message to which the signature is attached remains a valid HTTP message without the Signature or Signature-Input fields, it is possible for a verifier to ignore the output of the verification function and still process the message. Common reasons for this could be relaxed requirements in a development environment or a temporary suspension of enforcing verification while debugging an overall system. Such temporary suspensions are difficult to detect under positive-example testing, since a good signature will always trigger a valid response whether or not it has been checked.</t>
          <t indent="0" pn="section-7.1.1-2">To detect this, verifiers should be tested using both valid and invalid signatures, ensuring that an invalid signature fails as expected.</t>
        </section>
        <section anchor="security-tls" numbered="true" removeInRFC="false" toc="include" pn="section-7.1.2">
          <name slugifiedName="name-use-of-tls">Use of TLS</name>
          <t indent="0" pn="section-7.1.2-1">The use of HTTP message signatures does not negate the need for TLS or its equivalent to protect information in transit. Message signatures provide message integrity over the covered message components but do not provide any confidentiality for communication between parties.</t>
          <t indent="0" pn="section-7.1.2-2">TLS provides such confidentiality between the TLS endpoints. As part of this, TLS also protects the signature data itself from being captured by an attacker.  This is an important step in preventing <xref target="security-replay" format="default" sectionFormat="of" derivedContent="Section 7.2.2">signature replay</xref>.</t>
          <t indent="0" pn="section-7.1.2-3">When TLS is used, it needs to be deployed according to the recommendations provided in <xref target="BCP195" format="default" sectionFormat="of" derivedContent="BCP195"/>.</t>
        </section>
      </section>
      <section anchor="message-processing-and-selection" numbered="true" removeInRFC="false" toc="include" pn="section-7.2">
        <name slugifiedName="name-message-processing-and-sele">Message Processing and Selection</name>
        <section anchor="security-coverage" numbered="true" removeInRFC="false" toc="include" pn="section-7.2.1">
          <name slugifiedName="name-insufficient-coverage">Insufficient Coverage</name>
          <t indent="0" pn="section-7.2.1-1">Any portions of the message not covered by the signature are susceptible to modification by an attacker without affecting the signature. An attacker can take advantage of this by introducing or modifying a header field or other message component that will change the processing of the message but will not be covered by the signature. Such an altered message would still pass signature verification, but when the verifier processes the message as a whole, the unsigned content injected by the attacker would subvert the trust conveyed by the valid signature and change the outcome of processing the message.</t>
          <t indent="0" pn="section-7.2.1-2">To combat this, an application of this specification should require as much of the message as possible to be signed, within the limits of the application and deployment. The verifier should only trust message components that have been signed. Verifiers could also strip out any sensitive unsigned portions of the message before processing of the message continues.</t>
        </section>
        <section anchor="security-replay" numbered="true" removeInRFC="false" toc="include" pn="section-7.2.2">
          <name slugifiedName="name-signature-replay">Signature Replay</name>
          <t indent="0" pn="section-7.2.2-1">Since HTTP message signatures allow sub-portions of the HTTP message to be signed, it is possible for two different HTTP messages to validate against the same signature. The most extreme form of this would be a signature over no message components. If such a signature were intercepted, it could be replayed at will by an attacker, attached to any HTTP message. Even with sufficient component coverage, a given signature could be applied to two similar HTTP messages, allowing a message to be replayed by an attacker with the signature intact.</t>
          <t indent="0" pn="section-7.2.2-2">To counteract these kinds of attacks, it's first important for the signer to cover sufficient portions of the message to differentiate it from other messages. In addition, the signature can use the <tt>nonce</tt> signature parameter to provide a per-message unique value to allow the verifier to detect replay of the signature itself if a nonce value is repeated. Furthermore, the signer can provide a timestamp for when the signature was created and a time at which the signer considers the signature to be expired, limiting the utility of a captured signature value.</t>
          <t indent="0" pn="section-7.2.2-3">If a verifier wants to trigger a new signature from a signer, it can send the Accept-Signature header field with a new <tt>nonce</tt> parameter. An attacker that is simply replaying a signature would not be able to generate a new signature with the chosen nonce value.</t>
        </section>
        <section anchor="security-components" numbered="true" removeInRFC="false" toc="include" pn="section-7.2.3">
          <name slugifiedName="name-choosing-message-components">Choosing Message Components</name>
          <t indent="0" pn="section-7.2.3-1">Applications of HTTP message signatures need to decide which message components will be covered by the signature. Depending on the application, some components could be expected to be changed by intermediaries prior to the signature's verification. If these components are covered, such changes would, by design, break the signature.</t>
          <t indent="0" pn="section-7.2.3-2">However, this document allows for flexibility in determining which components are signed precisely so that a given application can choose the appropriate portions of the message that need to be signed, avoiding problematic components. For example, a web application framework that relies on rewriting query parameters might avoid using the <tt>@query</tt> derived component in favor of sub-indexing the query value using <tt>@query-param</tt> derived components instead.</t>
          <t indent="0" pn="section-7.2.3-3">Some components are expected to be changed by intermediaries and ought not to be signed under most circumstances. The Via and Forwarded header fields, for example, are expected to be manipulated by proxies and other middleboxes, including replacing or entirely dropping existing values. These fields should not be covered by the signature, except in very limited and tightly coupled scenarios.</t>
          <t indent="0" pn="section-7.2.3-4">Additional considerations for choosing signature aspects are discussed in <xref target="application" format="default" sectionFormat="of" derivedContent="Section 1.4"/>.</t>
        </section>
        <section anchor="security-not-fields" numbered="true" removeInRFC="false" toc="include" pn="section-7.2.4">
          <name slugifiedName="name-choosing-signature-paramete">Choosing Signature Parameters and Derived Components over HTTP Fields</name>
          <t indent="0" pn="section-7.2.4-1">Some HTTP fields have values and interpretations that are similar to HTTP signature parameters or derived components. In most cases, it is more desirable to sign the non-field alternative. In particular, the following fields should usually not be included in the signature unless the application specifically requires it:</t>
          <dl indent="3" newline="false" spacing="normal" pn="section-7.2.4-2">
            <dt pn="section-7.2.4-2.1">"date"</dt>
            <dd pn="section-7.2.4-2.2">
              <t indent="0" pn="section-7.2.4-2.2.1">The Date header field value represents the timestamp of the HTTP message. However, the creation time of the signature itself is encoded in the <tt>created</tt> signature parameter. These two values can be different, depending on how the signature and the HTTP message are created and serialized. Applications processing signatures for valid time windows should use the <tt>created</tt> signature parameter for such calculations. An application could also put limits on how much skew there is between the Date field and the <tt>created</tt> signature parameter, in order to limit the application of a generated signature to different HTTP messages. See also Sections <xref target="security-replay" format="counter" sectionFormat="of" derivedContent="7.2.2"/> and <xref target="security-coverage" format="counter" sectionFormat="of" derivedContent="7.2.1"/>.</t>
            </dd>
            <dt pn="section-7.2.4-2.3">"host"</dt>
            <dd pn="section-7.2.4-2.4">
              <t indent="0" pn="section-7.2.4-2.4.1">The Host header field is specific to HTTP/1.1, and its functionality is subsumed by the <tt>@authority</tt> derived component, defined in <xref target="content-request-authority" format="default" sectionFormat="of" derivedContent="Section 2.2.3"/>. In order to preserve the value across different HTTP versions, applications should always use the <tt>@authority</tt> derived component. See also <xref target="security-versions" format="default" sectionFormat="of" derivedContent="Section 7.5.4"/>.</t>
            </dd>
          </dl>
        </section>
        <section anchor="security-labels" numbered="true" removeInRFC="false" toc="include" pn="section-7.2.5">
          <name slugifiedName="name-signature-labels">Signature Labels</name>
          <t indent="0" pn="section-7.2.5-1">HTTP message signature values are identified in the Signature and Signature-Input field values by unique labels. These labels are chosen only when attaching the signature values to the message and are not accounted for during the signing process. An intermediary is allowed to relabel an existing signature when processing the message.</t>
          <t indent="0" pn="section-7.2.5-2">Therefore, applications should not rely on specific labels being present, and applications should not put semantic meaning on the labels themselves. Instead, additional signature parameters can be used to convey whatever additional meaning is required to be attached to, and covered by, the signature. In particular, the <tt>tag</tt> parameter can be used to define an application-specific value as described in <xref target="security-signature-tag" format="default" sectionFormat="of" derivedContent="Section 7.2.7"/>.</t>
        </section>
        <section anchor="security-multiple" numbered="true" removeInRFC="false" toc="include" pn="section-7.2.6">
          <name slugifiedName="name-multiple-signature-confusio">Multiple Signature Confusion</name>
          <t indent="0" pn="section-7.2.6-1">Since <xref target="signature-multiple" format="default" sectionFormat="of" derivedContent="Section 4.3">multiple signatures can be applied to one message</xref>, it is possible for an attacker to attach their own signature to a captured message without modifying existing signatures. This new signature could be completely valid based on the attacker's key, or it could be an invalid signature for any number of reasons. Each of these situations needs to be accounted for.</t>
          <t indent="0" pn="section-7.2.6-2">A verifier processing a set of valid signatures needs to account for all of the signers, identified by the signing keys. Only signatures from expected signers should be accepted, regardless of the cryptographic validity of the signature itself.</t>
          <t indent="0" pn="section-7.2.6-3">A verifier processing a set of signatures on a message also needs to determine what to do when one or more of the signatures are not valid. If a message is accepted when at least one signature is valid, then a verifier could drop all invalid signatures from the request before processing the message further. Alternatively, if the verifier rejects a message for a single invalid signature, an attacker could use this to deny service to otherwise valid messages by injecting invalid signatures alongside the valid signatures.</t>
        </section>
        <section anchor="security-signature-tag" numbered="true" removeInRFC="false" toc="include" pn="section-7.2.7">
          <name slugifiedName="name-collision-of-application-sp">Collision of Application-Specific Signature Tag</name>
          <t indent="0" pn="section-7.2.7-1">Multiple applications and protocols could apply HTTP signatures on the same message simultaneously. In fact, this is a desired feature in many circumstances; see <xref target="signature-multiple" format="default" sectionFormat="of" derivedContent="Section 4.3"/>. A naive verifier could become confused while processing multiple signatures, either accepting or rejecting a message based on an unrelated or irrelevant signature. In order to help an application select which signatures apply to its own processing, the application can declare a specific value for the <tt>tag</tt> signature parameter as defined in <xref target="signature-params" format="default" sectionFormat="of" derivedContent="Section 2.3"/>. For example, a signature targeting an application gateway could require <tt>tag="app-gateway"</tt> as part of the signature parameters for that application.</t>
          <t indent="0" pn="section-7.2.7-2">The use of the <tt>tag</tt> parameter does not prevent an attacker from also using the same value as a target application, since the parameter's value is public and otherwise unrestricted. As a consequence, a verifier should only use a value of the <tt>tag</tt> parameter to limit which signatures to check. Each signature still needs to be examined by the verifier to ensure that sufficient coverage is provided, as discussed in <xref target="security-coverage" format="default" sectionFormat="of" derivedContent="Section 7.2.1"/>.</t>
        </section>
        <section anchor="security-message-content" numbered="true" removeInRFC="false" toc="include" pn="section-7.2.8">
          <name slugifiedName="name-message-content">Message Content</name>
          <t indent="0" pn="section-7.2.8-1">On its own, this specification does not provide coverage for the content of an HTTP message under the signature, in either a request or a response. However, <xref target="RFC9530" format="default" sectionFormat="of" derivedContent="DIGEST"/> defines a set of fields that allow a cryptographic digest of the content to be represented in a field. Once this field is created, it can be included just like any other field as defined in <xref target="http-fields" format="default" sectionFormat="of" derivedContent="Section 2.1"/>.</t>
          <t indent="0" pn="section-7.2.8-2">For example, in the following response message:</t>
          <sourcecode type="http-message" markers="false" pn="section-7.2.8-3">
HTTP/1.1 200 OK
Content-Type: application/json

{"hello": "world"}
</sourcecode>
          <t indent="0" pn="section-7.2.8-4">The digest of the content can be added to the Content-Digest field as follows:</t>
          <sourcecode type="http-message" markers="false" pn="section-7.2.8-5">
NOTE: '\' line wrapping per RFC 8792

HTTP/1.1 200 OK
Content-Type: application/json
Content-Digest: \
  sha-256=:X48E9qOokqqrvdts8nOJRJN3OWDUoyWxBf7kbu9DBPE=:

{"hello": "world"}
</sourcecode>
          <t indent="0" pn="section-7.2.8-6">This field can be included in a signature base just like any other field along with the basic signature parameters:</t>
          <artwork align="left" pn="section-7.2.8-7">
"@status": 200
"content-digest": \
  sha-256=:X48E9qOokqqrvdts8nOJRJN3OWDUoyWxBf7kbu9DBPE=:
"@signature-input": ("@status" "content-digest")
</artwork>
          <t indent="0" pn="section-7.2.8-8">From here, the signing process proceeds as usual.</t>
          <t indent="0" pn="section-7.2.8-9">Upon verification, it is important that the verifier validate not only the signature but also the value of the Content-Digest field itself against the actual received content. Unless the verifier performs this step, it would be possible for an attacker to substitute the message content but leave the Content-Digest field value untouched to pass the signature. Since only the field value is covered by the signature directly, checking only the signature is not sufficient protection against such a substitution attack.</t>
          <t indent="0" pn="section-7.2.8-10">As discussed in <xref target="RFC9530" format="default" sectionFormat="of" derivedContent="DIGEST"/>, the value of the Content-Digest field is dependent on the content encoding of the message. If an intermediary changes the content encoding, the resulting Content-Digest value would change. This would in turn invalidate the signature. Any intermediary performing such an action would need to apply a new signature with the updated Content-Digest field value, similar to the reverse proxy use case discussed in <xref target="signature-multiple" format="default" sectionFormat="of" derivedContent="Section 4.3"/>.</t>
          <t indent="0" pn="section-7.2.8-11">Applications that make use of the <xref target="content-request-response" format="default" sectionFormat="of" derivedContent="Section 2.4"><tt>req</tt> parameter</xref> also need to be aware of the limitations of this functionality. Specifically, if a client does not include something like a Content-Digest header field in the request, the server is unable to include a signature that covers the request's content.</t>
        </section>
      </section>
      <section anchor="cryptographic-considerations" numbered="true" removeInRFC="false" toc="include" pn="section-7.3">
        <name slugifiedName="name-cryptographic-consideration">Cryptographic Considerations</name>
        <section anchor="security-collision" numbered="true" removeInRFC="false" toc="include" pn="section-7.3.1">
          <name slugifiedName="name-cryptography-and-signature-">Cryptography and Signature Collision</name>
          <t indent="0" pn="section-7.3.1-1">This document does not define any of its own cryptographic primitives and instead relies on other specifications to define such elements. If the signature algorithm or key used to process the signature base is vulnerable to any attacks, the resulting signature will also be susceptible to these same attacks.</t>
          <t indent="0" pn="section-7.3.1-2">A common attack against signature systems is to force a signature collision, where the same signature value successfully verifies against multiple different inputs. Since this specification relies on reconstruction of the signature base from an HTTP message and the list of components signed is fixed in the signature, it is difficult but not impossible for an attacker to effect such a collision. An attacker would need to manipulate the HTTP message and its covered message components in order to make the collision effective.</t>
          <t indent="0" pn="section-7.3.1-3">To counter this, only vetted keys and signature algorithms should be used to sign HTTP messages. The "HTTP Signature Algorithms" registry is one source of trusted signature algorithms for applications to apply to their messages.</t>
          <t indent="0" pn="section-7.3.1-4">While it is possible for an attacker to substitute the signature parameters value or the signature value separately, the <xref target="create-sig-input" format="default" sectionFormat="of" derivedContent="Section 2.5">signature base generation algorithm</xref> always covers the signature parameters as the final value in the signature base using a deterministic serialization method. This step strongly binds the signature base with the signature value in a way that makes it much more difficult for an attacker to perform a partial substitution on the signature base.</t>
        </section>
        <section anchor="security-keys" numbered="true" removeInRFC="false" toc="include" pn="section-7.3.2">
          <name slugifiedName="name-key-theft">Key Theft</name>
          <t indent="0" pn="section-7.3.2-1">A foundational assumption of signature-based cryptographic systems is that the signing key is not compromised by an attacker. If the keys used to sign the message are exfiltrated or stolen, the attacker will be able to generate their own signatures using those keys. As a consequence, signers have to protect any signing key material from exfiltration, capture, and use by an attacker.</t>
          <t indent="0" pn="section-7.3.2-2">To combat this, signers can rotate keys over time to limit the amount of time that stolen keys are useful. Signers can also use key escrow and storage systems to limit the attack surface against keys. Furthermore, the use of asymmetric signing algorithms exposes key material less than the use of <xref target="security-symmetric" format="default" sectionFormat="of" derivedContent="Section 7.3.3">symmetric signing algorithms</xref>.</t>
        </section>
        <section anchor="security-symmetric" numbered="true" removeInRFC="false" toc="include" pn="section-7.3.3">
          <name slugifiedName="name-symmetric-cryptography">Symmetric Cryptography</name>
          <t indent="0" pn="section-7.3.3-1">This document allows both asymmetric and symmetric cryptography to be applied to HTTP messages. By their nature, symmetric cryptographic methods require the same key material to be known by both the signer and verifier. This effectively means that a verifier is capable of generating a valid signature, since they have access to the same key material. An attacker that is able to compromise a verifier would be able to then impersonate a signer.</t>
          <t indent="0" pn="section-7.3.3-2">Where possible, asymmetric methods or secure key agreement mechanisms should be used in order to avoid this type of attack. When symmetric methods are used, distribution of the key material needs to be protected by the overall system. One technique for this is the use of separate cryptographic modules that separate the verification process (and therefore the key material) from other code, minimizing the vulnerable attack surface. Another technique is the use of key derivation functions that allow the signer and verifier to agree on unique keys for each message without having to share the key values directly.</t>
          <t indent="0" pn="section-7.3.3-3">Additionally, if symmetric algorithms are allowed within a system, special care must be taken to avoid <xref target="security-keydowngrade" format="default" sectionFormat="of" derivedContent="Section 7.3.6">key downgrade attacks</xref>.</t>
        </section>
        <section anchor="security-keymixup" numbered="true" removeInRFC="false" toc="include" pn="section-7.3.4">
          <name slugifiedName="name-key-specification-mixup">Key Specification Mixup</name>
          <t indent="0" pn="section-7.3.4-1">The existence of a valid signature on an HTTP message is not sufficient to prove that the message has been signed by the appropriate party. It is up to the verifier to ensure that a given key and algorithm are appropriate for the message in question. If the verifier does not perform such a step, an attacker could substitute their own signature using their own key on a message and force a verifier to accept and process it. To combat this, the verifier needs to ensure not only that the signature can be validated for a message but that the key and algorithm used are appropriate.</t>
        </section>
        <section anchor="security-nondeterministic" numbered="true" removeInRFC="false" toc="include" pn="section-7.3.5">
          <name slugifiedName="name-non-deterministic-signature">Non-deterministic Signature Primitives</name>
          <t indent="0" pn="section-7.3.5-1">Some cryptographic primitives, such as RSA-PSS and ECDSA, have non-deterministic outputs, which include some amount of entropy within the algorithm. For such algorithms, multiple signatures generated in succession will not match. A lazy implementation of a verifier could ignore this distinction and simply check for the same value being created by re-signing the signature base. Such an implementation would work for deterministic algorithms such as HMAC and EdDSA but fail to verify valid signatures made using non-deterministic algorithms. It is therefore important that a verifier always use the correctly defined verification function for the algorithm in question and not do a simple comparison.</t>
        </section>
        <section anchor="security-keydowngrade" numbered="true" removeInRFC="false" toc="include" pn="section-7.3.6">
          <name slugifiedName="name-key-and-algorithm-specifica">Key and Algorithm Specification Downgrades</name>
          <t indent="0" pn="section-7.3.6-1">Applications of this specification need to protect against key specification downgrade attacks. For example, the same RSA key can be used for both RSA-PSS and RSA v1.5 signatures. If an application expects a key to only be used with RSA-PSS, it needs to reject signatures for any key that uses the weaker RSA 1.5 specification.</t>
          <t indent="0" pn="section-7.3.6-2">Another example of a downgrade attack would be when an asymmetric algorithm is expected, such as RSA-PSS, but an attacker substitutes a signature using a symmetric algorithm, such as HMAC. A naive verifier implementation could use the value of the public RSA key as the input to the HMAC verification function. Since the public key is known to the attacker, this would allow the attacker to create a valid HMAC signature against this known key. To prevent this, the verifier needs to ensure that both the key material and the algorithm are appropriate for the usage in question. Additionally, while this specification does allow runtime specification of the algorithm using the <tt>alg</tt> signature parameter, applications are encouraged to use other mechanisms such as static configuration or a higher-protocol-level algorithm specification instead, preventing an attacker from substituting the algorithm specified.</t>
        </section>
        <section anchor="security-sign-signature" numbered="true" removeInRFC="false" toc="include" pn="section-7.3.7">
          <name slugifiedName="name-signing-signature-values">Signing Signature Values</name>
          <t indent="0" pn="section-7.3.7-1">When applying the <xref target="content-request-response" format="default" sectionFormat="of" derivedContent="Section 2.4"><tt>req</tt>
parameter</xref> or <xref target="signature-multiple" format="default" sectionFormat="of" derivedContent="Section 4.3">multiple signatures</xref> to a message, it is possible to sign the value of an existing Signature field, thereby covering the bytes of the existing signature output in the new signature's value. While it would seem that this practice would transitively cover the components under the original signature in a verifiable fashion, the attacks described in <xref target="JACKSON2019" format="default" sectionFormat="of" derivedContent="JACKSON2019"/> can be used to impersonate a signature output value on an unrelated message.</t>
          <t indent="0" pn="section-7.3.7-2">In this example, Alice intends to send a signed request to Bob, and Bob wants to provide a signed response to Alice that includes a cryptographic proof that Bob is responding to Alice's incoming message. Mallory wants to intercept this traffic and replace Alice's message with her own, without Alice being aware that the interception has taken place.</t>
          <ol spacing="normal" type="1" indent="adaptive" start="1" pn="section-7.3.7-3"><li pn="section-7.3.7-3.1" derivedCounter="1.">Alice creates a message <tt>Req_A</tt> and applies a signature <tt>Sig_A</tt> using her private key <tt>Key_A_Sign</tt>.</li>
            <li pn="section-7.3.7-3.2" derivedCounter="2.">Alice believes she is sending <tt>Req_A</tt> to Bob.</li>
            <li pn="section-7.3.7-3.3" derivedCounter="3.">Mallory intercepts <tt>Req_A</tt> and reads the value <tt>Sig_A</tt> from this message.</li>
            <li pn="section-7.3.7-3.4" derivedCounter="4.">Mallory generates a different message <tt>Req_M</tt> to send to Bob instead.</li>
            <li pn="section-7.3.7-3.5" derivedCounter="5.">Mallory crafts a signing key <tt>Key_M_Sign</tt> such that she can create a valid signature <tt>Sig_M</tt> over her request <tt>Req_M</tt> using this key, but the byte value of <tt>Sig_M</tt> exactly equals that of <tt>Sig_A</tt>.</li>
            <li pn="section-7.3.7-3.6" derivedCounter="6.">Mallory sends <tt>Req_M</tt> with <tt>Sig_M</tt> to Bob.</li>
            <li pn="section-7.3.7-3.7" derivedCounter="7.">Bob validates <tt>Sig_M</tt> against Mallory's verification key <tt>Key_M_Verify</tt>. At no time does Bob think that he's responding to Alice.</li>
            <li pn="section-7.3.7-3.8" derivedCounter="8.">Bob responds with response message <tt>Res_B</tt> to <tt>Req_M</tt> and creates signature <tt>Sig_B</tt> over this message using his key <tt>Key_B_Sign</tt>. Bob includes the value of <tt>Sig_M</tt> under <tt>Sig_B</tt>'s covered components but does not include anything else from the request message.</li>
            <li pn="section-7.3.7-3.9" derivedCounter="9.">Mallory receives the response <tt>Res_B</tt> from Bob, including the signature <tt>Sig_B</tt> value. Mallory replays this response to Alice.</li>
            <li pn="section-7.3.7-3.10" derivedCounter="10.">Alice reads <tt>Res_B</tt> from Mallory and verifies <tt>Sig_B</tt> using Bob's verification key <tt>Key_B_Verify</tt>. Alice includes the bytes of her original signature <tt>Sig_A</tt> in the signature base, and the signature verifies.</li>
            <li pn="section-7.3.7-3.11" derivedCounter="11.">Alice is led to believe that Bob has responded to her message and believes she has cryptographic proof of this happening, but in fact Bob responded to Mallory's malicious request and Alice is none the wiser.</li>
          </ol>
          <t indent="0" pn="section-7.3.7-4">To mitigate this, Bob can sign more portions of the request message than just the Signature field, in order to more fully differentiate Alice's message from Mallory's. Applications using this feature, particularly for non-repudiation purposes, can stipulate that any components required in the original signature also be covered separately in the second signature. For signed messages, requiring coverage of the corresponding Signature-Input field of the first signature ensures that unique items such as nonces and timestamps are also covered sufficiently by the second signature.</t>
        </section>
      </section>
      <section anchor="matching-covered-components-to-message" numbered="true" removeInRFC="false" toc="include" pn="section-7.4">
        <name slugifiedName="name-matching-signature-paramete">Matching Signature Parameters to the Target Message</name>
        <section anchor="security-modify" numbered="true" removeInRFC="false" toc="include" pn="section-7.4.1">
          <name slugifiedName="name-modification-of-required-me">Modification of Required Message Parameters</name>
          <t indent="0" pn="section-7.4.1-1">An attacker could effectively deny a service by modifying an otherwise benign signature parameter or signed message component. While rejecting a modified message is the desired behavior, consistently failing signatures could lead to (1) the verifier turning off signature checking in order to make systems work again (see <xref target="security-ignore" format="default" sectionFormat="of" derivedContent="Section 7.1.1"/>) or (2) the application minimizing the requirements related to the signed component.</t>
          <t indent="0" pn="section-7.4.1-2">If such failures are common within an application, the signer and verifier should compare their generated signature bases with each other to determine which part of the message is being modified. If an expected modification is found, the signer and verifier can agree on an alternative set of requirements that will pass. However, the signer and verifier should not remove the requirement to sign the modified component when it is suspected that an attacker is modifying the component.</t>
        </section>
        <section anchor="security-mismatch" numbered="true" removeInRFC="false" toc="include" pn="section-7.4.2">
          <name slugifiedName="name-matching-values-of-covered-">Matching Values of Covered Components to Values in the Target Message</name>
          <t indent="0" pn="section-7.4.2-1">The verifier needs to make sure that the signed message components match those in the message itself. For example, the <tt>@method</tt> derived component requires that the value within the signature base be the same as the HTTP method used when presenting this message. This specification encourages this by requiring the verifier to derive the signature base from the message, but lazy caching or conveyance of a raw signature base to a processing subsystem could lead to downstream verifiers accepting a message that does not match the presented signature.</t>
          <t indent="0" pn="section-7.4.2-2">To counter this, the component that generates the signature base needs to be trusted by both the signer and verifier within a system.</t>
        </section>
        <section anchor="security-message-component-context" numbered="true" removeInRFC="false" toc="include" pn="section-7.4.3">
          <name slugifiedName="name-message-component-source-an">Message Component Source and Context</name>
          <t indent="0" pn="section-7.4.3-1">The signature context for deriving message component values includes the target HTTP message itself, any associated messages (such as the request that triggered a response), and additional information that the signer or verifier has access to. Both signers and verifiers need to carefully consider the source of all information when creating component values for the signature base and take care not to take information from untrusted sources. Otherwise, an attacker could leverage such a loosely defined message context to inject their own values into the signature base string, overriding or corrupting the intended values.</t>
          <t indent="0" pn="section-7.4.3-2">For example, in most situations, the target URI of the message is as defined in <xref section="7.1" sectionFormat="comma" target="RFC9110" format="default" derivedLink="https://rfc-editor.org/rfc/rfc9110#section-7.1" derivedContent="HTTP"/>. However, let's say that there is an application that requires signing of the <tt>@authority</tt> of the incoming request, but the application doing the processing is behind a reverse proxy. Such an application would expect a change in the <tt>@authority</tt> value, and it could be configured to know the external target URI as seen by the client on the other side of the proxy. This application would use this configured value as its target URI for the purposes of deriving message component values such as <tt>@authority</tt> instead of using the target URI of the incoming message.</t>
          <t indent="0" pn="section-7.4.3-3">This approach is not without problems, as a misconfigured system could accept signed requests intended for different components in the system. For this scenario, an intermediary could instead add its own signature to be verified by the application directly, as demonstrated in <xref target="signature-multiple" format="default" sectionFormat="of" derivedContent="Section 4.3"/>. This alternative approach requires a more active intermediary but relies less on the target application knowing external configuration values.</t>
          <t indent="0" pn="section-7.4.3-4">As another example, <xref target="content-request-response" format="default" sectionFormat="of" derivedContent="Section 2.4"/> defines a method for signing response messages and also including portions of the request message that triggered the response. In this case, the context for component value calculation is the combination of the response and request messages, not just the single message to which the signature is applied. For this feature, the <tt>req</tt> flag allows both signers to explicitly signal which part of the context is being sourced for a component identifier's value. Implementations need to ensure that only the intended message is being referred to for each component; otherwise, an attacker could attempt to subvert a signature by manipulating one side or the other.</t>
        </section>
        <section anchor="security-context-multiple-signatures" numbered="true" removeInRFC="false" toc="include" pn="section-7.4.4">
          <name slugifiedName="name-multiple-message-component-">Multiple Message Component Contexts</name>
          <t indent="0" pn="section-7.4.4-1">It is possible that the context for deriving message component values could be distinct for each signature present within a single message. This is particularly the case when proxies mutate messages and include signatures over the mutated values, in addition to any existing signatures. For example, a reverse proxy can replace a public hostname in a request to a service with the hostname for the individual service host to which it is forwarding the request. If both the client and the reverse proxy add signatures covering <tt>@authority</tt>, the service host will see two signatures on the request, each signing different values for the <tt>@authority</tt> message component, reflecting the change to that component as the message made its way from the client to the service host.</t>
          <t indent="0" pn="section-7.4.4-2">In such a case, it's common for the internal service to verify only one of the signatures or to use externally configured information, as discussed in <xref target="security-message-component-context" format="default" sectionFormat="of" derivedContent="Section 7.4.3"/>. However, a verifier processing both signatures has to use a different message component context for each signature, since the component value for the <tt>@authority</tt> component will be different for each signature. Verifiers like this need to be aware of both the reverse proxy's context for incoming messages and the target service's context for the message coming from the reverse proxy. The verifier needs to take particular care to apply the correct context to the correct signature; otherwise, an attacker could use knowledge of this complex setup to confuse the inputs to the verifier.</t>
          <t indent="0" pn="section-7.4.4-3">Such verifiers also need to ensure that any differences in message component contexts between signatures are expected and permitted. For example, in the above scenario, the reverse proxy could include the original hostname in a Forwarded header field and could sign <tt>@authority</tt>, forwarded, and the client's entry in the Signature field. The verifier can use the hostname from the Forwarded header field to confirm that the hostname was transformed as expected.</t>
        </section>
      </section>
      <section anchor="http-processing" numbered="true" removeInRFC="false" toc="include" pn="section-7.5">
        <name slugifiedName="name-http-processing">HTTP Processing</name>
        <section anchor="security-lazy-header-parser" numbered="true" removeInRFC="false" toc="include" pn="section-7.5.1">
          <name slugifiedName="name-processing-invalid-http-fie">Processing Invalid HTTP Field Names as Derived Component Names</name>
          <t indent="0" pn="section-7.5.1-1">The definition of HTTP field names does not allow for the use of the 
<tt>@</tt> character anywhere in the name. As such, since all derived component names start with the <tt>@</tt> character, these namespaces should be completely separate. However, some HTTP implementations are not sufficiently strict about the characters accepted in HTTP field names. In such implementations, a sender (or attacker) could inject a header field starting with an <tt>@</tt> character and have it passed through to the application code. These invalid header fields could be used to override a portion of the derived message content and substitute an arbitrary value, providing a potential place for an attacker to mount a <xref target="security-collision" format="default" sectionFormat="of" derivedContent="Section 7.3.1">signature collision</xref> attack or other functional substitution attack (such as using the signature from a GET request on a crafted POST request).</t>
          <t indent="0" pn="section-7.5.1-2">To combat this, when selecting values for a message component, if the component name starts with the <tt>@</tt> character, it needs to be processed as a derived component and never processed as an HTTP field. Only if the component name does not start with the <tt>@</tt> character can it be taken from the fields of the message. The algorithm discussed in <xref target="create-sig-input" format="default" sectionFormat="of" derivedContent="Section 2.5"/> provides a safe order of operations.</t>
        </section>
        <section anchor="security-field-values" numbered="true" removeInRFC="false" toc="include" pn="section-7.5.2">
          <name slugifiedName="name-semantically-equivalent-fie">Semantically Equivalent Field Values</name>
          <t indent="0" pn="section-7.5.2-1">The <xref target="create-sig-input" format="default" sectionFormat="of" derivedContent="Section 2.5">signature base generation algorithm</xref> uses the value of an HTTP field as its component value. In the common case, this amounts to taking the actual bytes of the field value as the component value for both the signer and verifier. However, some field values allow for transformation of the values in semantically equivalent ways that alter the bytes used in the value itself. For example, a field definition can declare some or all of its values to be case insensitive or to have special handling of internal whitespace characters. Other fields have expected transformations from intermediaries, such as the removal of comments in the Via header field. In such cases, a verifier could be tripped up by using the equivalent transformed field value, which would differ from the byte value used by the signer. The verifier would have a difficult time finding this class of errors, since the value of the field is still acceptable for the application but the actual bytes required by the signature base would not match.</t>
          <t indent="0" pn="section-7.5.2-2">When processing such fields, the signer and verifier have to agree on how to handle such transformations, if at all. One option is to not sign problematic fields, but care must be taken to ensure that there is still <xref target="security-coverage" format="default" sectionFormat="of" derivedContent="Section 7.2.1">sufficient signature coverage</xref> for the application. Another option is to define an application-specific canonicalization value for the field before it is added to the HTTP message, such as to always remove internal comments before signing or to always transform values to lowercase. Since these transformations are applied prior to the field being used as input to the signature base generation algorithm, the signature base will still simply contain the byte value of the field as it appears within the message. If the transformations were to be applied after the value is extracted from the message but before it is added to the signature base, different attack surfaces such as value substitution attacks could be launched against the application. All application-specific additional rules are outside the scope of this specification, and by their very nature these transformations would harm interoperability of the implementation outside of this specific application. It is recommended that applications avoid the use of such additional rules wherever possible.</t>
        </section>
        <section anchor="security-structured" numbered="true" removeInRFC="false" toc="include" pn="section-7.5.3">
          <name slugifiedName="name-parsing-structured-field-va">Parsing Structured Field Values</name>
          <t indent="0" pn="section-7.5.3-1">Several parts of this specification rely on the parsing of Structured Field values <xref target="RFC8941" format="default" sectionFormat="of" derivedContent="STRUCTURED-FIELDS"/> -- in particular, <xref target="http-field-structured" format="default" sectionFormat="of" derivedContent="Section 2.1.1">strict serialization of HTTP Structured Field values</xref>, <xref target="http-field-dictionary" format="default" sectionFormat="of" derivedContent="Section 2.1.2">referencing members of a Dictionary Structured Field</xref>, and processing the <tt>@signature-input</tt> value when <xref target="verify" format="default" sectionFormat="of" derivedContent="Section 3.2">verifying a signature</xref>. While Structured Field values are designed to be relatively simple to parse, a naive or broken implementation of such a parser could lead to subtle attack surfaces being exposed in the implementation.</t>
          <t indent="0" pn="section-7.5.3-2">For example, if a buggy parser of the <tt>@signature-input</tt> value does not enforce proper closing of quotes around string values within the list of component identifiers, an attacker could take advantage of this and inject additional content into the signature base through manipulating the Signature-Input field value on a message.</t>
          <t indent="0" pn="section-7.5.3-3">To counteract this, implementations should use fully compliant and trusted parsers for all Structured Field processing, on both the signer side and the verifier side.</t>
        </section>
        <section anchor="security-versions" numbered="true" removeInRFC="false" toc="include" pn="section-7.5.4">
          <name slugifiedName="name-http-versions-and-component">HTTP Versions and Component Ambiguity</name>
          <t indent="0" pn="section-7.5.4-1">Some message components are expressed in different ways across HTTP versions. For example, the authority of the request target is sent using the Host header field in HTTP/1.1 but with the <tt>:authority</tt> pseudo-header in HTTP/2. If a signer sends an HTTP/1.1 message and signs the Host header field but the message is translated to HTTP/2 before it reaches the verifier, the signature will not validate, as the Host header field could be dropped.</t>
          <t indent="0" pn="section-7.5.4-2">It is for this reason that HTTP message signatures define a set of derived components that define a single way to get the value in question, such as the <tt>@authority</tt> derived component (<xref target="content-request-authority" format="default" sectionFormat="of" derivedContent="Section 2.2.3"/>) in lieu of the Host header field. Applications should therefore prefer derived components for such options where possible.</t>
        </section>
        <section anchor="security-canonicalization" numbered="true" removeInRFC="false" toc="include" pn="section-7.5.5">
          <name slugifiedName="name-canonicalization-attacks">Canonicalization Attacks</name>
          <t indent="0" pn="section-7.5.5-1">Any ambiguity in the generation of the signature base could provide an attacker with leverage to substitute or break a signature on a message. Some message component values, particularly HTTP field values, are potentially susceptible to broken implementations that could lead to unexpected and insecure behavior. Naive implementations of this specification might implement HTTP field processing by taking the single value of a field and using it as the direct component value without processing it appropriately.</t>
          <t indent="0" pn="section-7.5.5-2">For example, if the handling of <tt>obs-fold</tt> field values does not remove the internal line folding and whitespace, additional newlines could be introduced into the signature base by the signer, providing a potential place for an attacker to mount a <xref target="security-collision" format="default" sectionFormat="of" derivedContent="Section 7.3.1">signature collision</xref> attack. Alternatively, if header fields that appear multiple times are not joined into a single string value, as required by this specification, similar attacks can be mounted, as a signed component value would show up in the signature base more than once and could be substituted or otherwise attacked in this way.</t>
          <t indent="0" pn="section-7.5.5-3">To counter this, the entire field value processing algorithm needs to be implemented by all implementations of signers and verifiers.</t>
        </section>
        <section anchor="security-non-list" numbered="true" removeInRFC="false" toc="include" pn="section-7.5.6">
          <name slugifiedName="name-non-list-field-values">Non-List Field Values</name>
          <t indent="0" pn="section-7.5.6-1">When an HTTP field occurs multiple times in a single message, these values need to be combined into a single one-line string value to be included in the HTTP signature base, as described in <xref target="create-sig-input" format="default" sectionFormat="of" derivedContent="Section 2.5"/>. Not all HTTP fields can be combined into a single value in this way and still be a valid value for the field. For the purposes of generating the signature base, the message component value is never meant to be read back out of the signature base string or used in the application. Therefore, it is considered best practice to treat the signature base generation algorithm separately from processing the field values by the application, particularly for fields that are known to have this property. If the field values that are being signed do not validate, the signed message should also be rejected.</t>
          <t indent="0" pn="section-7.5.6-2">If an HTTP field allows for unquoted commas within its values, combining multiple field values can lead to a situation where two semantically different messages produce the same line in a signature base. For example, take the following hypothetical header field with an internal comma in its syntax, here used to define two separate lists of values:</t>
          <sourcecode type="http-message" markers="false" pn="section-7.5.6-3">
Example-Header: value, with, lots
Example-Header: of, commas
</sourcecode>
          <t indent="0" pn="section-7.5.6-4">For this header field, sending all of these values as a single field value results in a single list of values:</t>
          <sourcecode type="http-message" markers="false" pn="section-7.5.6-5">
Example-Header: value, with, lots, of, commas
</sourcecode>
          <t indent="0" pn="section-7.5.6-6">Both of these messages would create the following line in the signature base:</t>
          <artwork align="left" pn="section-7.5.6-7">
"example-header": value, with, lots, of, commas
</artwork>
          <t indent="0" pn="section-7.5.6-8">Since two semantically distinct inputs can create the same output in the signature base, special care has to be taken when handling such values.</t>
          <t indent="0" pn="section-7.5.6-9">Specifically, the Set-Cookie field <xref target="RFC6265" format="default" sectionFormat="of" derivedContent="COOKIE"/> defines an internal syntax that does not conform to the List syntax provided in <xref target="RFC8941" format="default" sectionFormat="of" derivedContent="STRUCTURED-FIELDS"/>. In particular, some portions allow unquoted commas, and the field is typically sent as multiple separate field lines with distinct values when sending multiple cookies. When multiple Set-Cookie fields are sent in the same message, it is not generally possible to combine these into a single line and be able to parse and use the results, as discussed in <xref section="5.3" sectionFormat="comma" target="RFC9110" format="default" derivedLink="https://rfc-editor.org/rfc/rfc9110#section-5.3" derivedContent="HTTP"/>. Therefore, all the cookies need to be processed from their separate field values, without being combined, while the signature base needs to be processed from the special combined value generated solely for this purpose. If the cookie value is invalid, the signed message ought to be rejected, as this is a possible padding attack as described in <xref target="security-multiple-fields" format="default" sectionFormat="of" derivedContent="Section 7.5.7"/>.</t>
          <t indent="0" pn="section-7.5.6-10">To deal with this, an application can choose to limit signing of problematic fields like Set-Cookie, such as including the field in a signature only when a single field value is present and the results would be unambiguous. Similar caution needs to be taken with all fields that could have non-deterministic mappings into the signature base. Signers can also make use of the <tt>bs</tt> parameter to armor such fields, as described in <xref target="http-field-byte-sequence" format="default" sectionFormat="of" derivedContent="Section 2.1.3"/>.</t>
        </section>
        <section anchor="security-multiple-fields" numbered="true" removeInRFC="false" toc="include" pn="section-7.5.7">
          <name slugifiedName="name-padding-attacks-with-multip">Padding Attacks with Multiple Field Values</name>
          <t indent="0" pn="section-7.5.7-1">Since HTTP field values need to be combined into a single string value to be included in the HTTP signature base (see <xref target="create-sig-input" format="default" sectionFormat="of" derivedContent="Section 2.5"/>), it is possible for an attacker to inject an additional value for a given field and add this to the signature base of the verifier.</t>
          <t indent="0" pn="section-7.5.7-2">In most circumstances, this causes the signature validation to fail as expected, since the new signature base value will not match the one used by the signer to create the signature. However, it is theoretically possible for the attacker to inject both a garbage value into a field and a desired value into another field in order to force a particular input. This is a variation of the collision attack described in <xref target="security-collision" format="default" sectionFormat="of" derivedContent="Section 7.3.1"/>, where the attacker accomplishes their change in the message by adding to existing field values.</t>
          <t indent="0" pn="section-7.5.7-3">To counter this, an application needs to validate the content of the fields covered in the signature in addition to ensuring that the signature itself validates. With such protections, the attacker's padding attack would be rejected by the field value processor, even in the case where the attacker could force a signature collision.</t>
        </section>
        <section anchor="security-query-elements" numbered="true" removeInRFC="false" toc="include" pn="section-7.5.8">
          <name slugifiedName="name-ambiguous-handling-of-query">Ambiguous Handling of Query Elements</name>
          <t indent="0" pn="section-7.5.8-1">The HTML form parameters format defined in Section <xref target="HTMLURL" section="5" relative="https://url.spec.whatwg.org/#application/x-www-form-urlencoded" sectionFormat="bare" format="default" derivedLink="https://url.spec.whatwg.org/#application/x-www-form-urlencoded" derivedContent="HTMLURL">"application/x-www-form-urlencoded"</xref> of
<xref target="HTMLURL" format="default" sectionFormat="of" derivedContent="HTMLURL"/> is widely deployed and supported by many application frameworks. For convenience, some of these frameworks in particular combine query parameters that are found in the HTTP query and those found in the message content, particularly for POST messages with a Content-Type value of "application/x-www-form-urlencoded". The <tt>@query-param</tt> derived component identifier defined in <xref target="content-request-query-param" format="default" sectionFormat="of" derivedContent="Section 2.2.8"/> draws its values only from the query section of the target URI of the request. As such, it would be possible for an attacker to shadow or replace query parameters in a request by overriding a signed query parameter with an unsigned form parameter, or vice versa.</t>
          <t indent="0" pn="section-7.5.8-2">To counter this, an application needs to make sure that values used for the signature base and the application are drawn from a consistent context, in this case the query component of the target URI. Additionally, when the HTTP request has content, an application should sign the message content as well, as discussed in <xref target="security-message-content" format="default" sectionFormat="of" derivedContent="Section 7.2.8"/>.</t>
        </section>
      </section>
    </section>
    <section anchor="privacy" numbered="true" removeInRFC="false" toc="include" pn="section-8">
      <name slugifiedName="name-privacy-considerations">Privacy Considerations</name>
      <section anchor="privacy-identify-keys" numbered="true" removeInRFC="false" toc="include" pn="section-8.1">
        <name slugifiedName="name-identification-through-keys">Identification through Keys</name>
        <t indent="0" pn="section-8.1-1">If a signer uses the same key with multiple verifiers or uses the same key over time with a single verifier, the ongoing use of that key can be used to track the signer throughout the set of verifiers that messages are sent to. Since cryptographic keys are meant to be functionally unique, the use of the same key over time is a strong indicator that it is the same party signing multiple messages.</t>
        <t indent="0" pn="section-8.1-2">In many applications, this is a desirable trait, and it allows HTTP message signatures to be used as part of authenticating the signer to the verifier. However, it could also result in unintentional tracking that a signer might not be aware of. To counter this kind of tracking, a signer can use a different key for each verifier that it is in communication with. Sometimes, a signer could also rotate their key when sending messages to a given verifier. These approaches do not negate the need for other anti-tracking techniques to be applied as necessary.</t>
      </section>
      <section anchor="privacy-confidentiality" numbered="true" removeInRFC="false" toc="include" pn="section-8.2">
        <name slugifiedName="name-signatures-do-not-provide-c">Signatures do not provide confidentiality</name>
        <t indent="0" pn="section-8.2-1">HTTP message signatures do not provide confidentiality for any of the information protected by the signature. The content of the HTTP message, including the value of all fields and the value of the signature itself, is presented in plaintext to any party with access to the message.</t>
        <t indent="0" pn="section-8.2-2">To provide confidentiality at the transport level, TLS or its equivalent can be used, as discussed in <xref target="security-tls" format="default" sectionFormat="of" derivedContent="Section 7.1.2"/>.</t>
      </section>
      <section anchor="privacy-oracle" numbered="true" removeInRFC="false" toc="include" pn="section-8.3">
        <name slugifiedName="name-oracles">Oracles</name>
        <t indent="0" pn="section-8.3-1">It is important to balance the need for providing useful feedback to developers regarding error conditions without providing additional information to an attacker. For example, a naive but helpful server implementation might try to indicate the required key identifier needed for requesting a resource. If someone knows who controls that key, a correlation can be made between the resource's existence and the party identified by the key. Access to such information could be used by an attacker as a means to target the legitimate owner of the resource for further attacks.</t>
      </section>
      <section anchor="privacy-required" numbered="true" removeInRFC="false" toc="include" pn="section-8.4">
        <name slugifiedName="name-required-content">Required Content</name>
        <t indent="0" pn="section-8.4-1">A core design tenet of this specification is that all message components covered by the signature need to be available to the verifier in order to recreate the signature base and verify the signature. As a consequence, if an application of this specification requires that a particular field be signed, the verifier will need access to the value of that field.</t>
        <t indent="0" pn="section-8.4-2">For example, in some complex systems with intermediary processors, this could cause surprising behavior where, for fear of breaking the signature, an intermediary cannot remove privacy-sensitive information from a message before forwarding it on for processing. One way to mitigate this specific situation would be for the intermediary to verify the signature itself and then modify the message to remove the privacy-sensitive information. The intermediary can add its own signature at this point to signal to the next destination that the incoming signature was validated, as shown in the example in <xref target="signature-multiple" format="default" sectionFormat="of" derivedContent="Section 4.3"/>.</t>
      </section>
    </section>
  </middle>
  <back>
    <displayreference target="POSIX" to="POSIX.1"/>
    <displayreference target="RFC0020" to="ASCII"/>
    <displayreference target="RFC8941" to="STRUCTURED-FIELDS"/>
    <displayreference target="RFC9110" to="HTTP"/>
    <displayreference target="RFC9112" to="HTTP/1.1"/>
    <displayreference target="RFC3986" to="URI"/>
    <displayreference target="RFC5234" to="ABNF"/>
    <displayreference target="RFC7515" to="JWS"/>
    <displayreference target="RFC9440" to="CLIENT-CERT"/>
    <displayreference target="RFC6265" to="COOKIE"/>
    <displayreference target="RFC8446" to="TLS"/>
    <displayreference target="RFC9530" to="DIGEST"/>
    <displayreference target="I-D.cavage-http-signatures" to="SIGNING-HTTP-MESSAGES"/>
    <references pn="section-9">
      <name slugifiedName="name-references">References</name>
      <references pn="section-9.1">
        <name slugifiedName="name-normative-references">Normative References</name>
        <reference anchor="RFC5234" target="https://www.rfc-editor.org/info/rfc5234" quoteTitle="true" derivedAnchor="ABNF">
          <front>
            <title>Augmented BNF for Syntax Specifications: ABNF</title>
            <author fullname="D. Crocker" initials="D." role="editor" surname="Crocker"/>
            <author fullname="P. Overell" initials="P." surname="Overell"/>
            <date month="January" year="2008"/>
            <abstract>
              <t indent="0">Internet technical specifications often need to define a formal syntax. Over the years, a modified version of Backus-Naur Form (BNF), called Augmented BNF (ABNF), has been popular among many Internet specifications. The current specification documents ABNF. It balances compactness and simplicity with reasonable representational power. The differences between standard BNF and ABNF involve naming rules, repetition, alternatives, order-independence, and value ranges. This specification also supplies additional rule definitions and encoding for a core lexical analyzer of the type common to several Internet specifications. [STANDARDS-TRACK]</t>
            </abstract>
          </front>
          <seriesInfo name="STD" value="68"/>
          <seriesInfo name="RFC" value="5234"/>
          <seriesInfo name="DOI" value="10.17487/RFC5234"/>
        </reference>
        <reference anchor="RFC0020" target="https://www.rfc-editor.org/info/rfc20" quoteTitle="true" derivedAnchor="ASCII">
          <front>
            <title>ASCII format for network interchange</title>
            <author fullname="V.G. Cerf" initials="V.G." surname="Cerf"/>
            <date month="October" year="1969"/>
          </front>
          <seriesInfo name="STD" value="80"/>
          <seriesInfo name="RFC" value="20"/>
          <seriesInfo name="DOI" value="10.17487/RFC0020"/>
        </reference>
        <reference anchor="FIPS186-5" target="https://doi.org/10.6028/NIST.FIPS.186-5" quoteTitle="true" derivedAnchor="FIPS186-5">
          <front>
            <title>Digital Signature Standard (DSS)</title>
            <author>
              <organization showOnFrontPage="true">NIST</organization>
            </author>
            <date month="February" year="2023"/>
          </front>
          <seriesInfo name="DOI" value="10.6028/NIST.FIPS.186-5"/>
        </reference>
        <reference anchor="HTMLURL" target="https://url.spec.whatwg.org/" quoteTitle="true" derivedAnchor="HTMLURL">
          <front>
            <title>URL (Living Standard)</title>
            <author>
              <organization showOnFrontPage="true">WHATWG</organization>
            </author>
            <date month="January" year="2024"/>
          </front>
        </reference>
        <reference anchor="RFC9110" target="https://www.rfc-editor.org/info/rfc9110" quoteTitle="true" derivedAnchor="HTTP">
          <front>
            <title>HTTP Semantics</title>
            <author fullname="R. Fielding" initials="R." role="editor" surname="Fielding"/>
            <author fullname="M. Nottingham" initials="M." role="editor" surname="Nottingham"/>
            <author fullname="J. Reschke" initials="J." role="editor" surname="Reschke"/>
            <date month="June" year="2022"/>
            <abstract>
              <t indent="0">The Hypertext Transfer Protocol (HTTP) is a stateless application-level protocol for distributed, collaborative, hypertext information systems. This document describes the overall architecture of HTTP, establishes common terminology, and defines aspects of the protocol that are shared by all versions. In this definition are core protocol elements, extensibility mechanisms, and the "http" and "https" Uniform Resource Identifier (URI) schemes.</t>
              <t indent="0">This document updates RFC 3864 and obsoletes RFCs 2818, 7231, 7232, 7233, 7235, 7538, 7615, 7694, and portions of 7230.</t>
            </abstract>
          </front>
          <seriesInfo name="STD" value="97"/>
          <seriesInfo name="RFC" value="9110"/>
          <seriesInfo name="DOI" value="10.17487/RFC9110"/>
        </reference>
        <reference anchor="RFC9112" target="https://www.rfc-editor.org/info/rfc9112" quoteTitle="true" derivedAnchor="HTTP/1.1">
          <front>
            <title>HTTP/1.1</title>
            <author fullname="R. Fielding" initials="R." role="editor" surname="Fielding"/>
            <author fullname="M. Nottingham" initials="M." role="editor" surname="Nottingham"/>
            <author fullname="J. Reschke" initials="J." role="editor" surname="Reschke"/>
            <date month="June" year="2022"/>
            <abstract>
              <t indent="0">The Hypertext Transfer Protocol (HTTP) is a stateless application-level protocol for distributed, collaborative, hypertext information systems. This document specifies the HTTP/1.1 message syntax, message parsing, connection management, and related security concerns.</t>
              <t indent="0">This document obsoletes portions of RFC 7230.</t>
            </abstract>
          </front>
          <seriesInfo name="STD" value="99"/>
          <seriesInfo name="RFC" value="9112"/>
          <seriesInfo name="DOI" value="10.17487/RFC9112"/>
        </reference>
        <reference anchor="POSIX" target="https://pubs.opengroup.org/onlinepubs/9699919799/" quoteTitle="true" derivedAnchor="POSIX.1">
          <front>
            <title>The Open Group Base Specifications Issue 7, 2018 edition</title>
            <author>
              <organization showOnFrontPage="true">IEEE</organization>
            </author>
            <date year="2018"/>
          </front>
        </reference>
        <reference anchor="RFC2104" target="https://www.rfc-editor.org/info/rfc2104" quoteTitle="true" derivedAnchor="RFC2104">
          <front>
            <title>HMAC: Keyed-Hashing for Message Authentication</title>
            <author fullname="H. Krawczyk" initials="H." surname="Krawczyk"/>
            <author fullname="M. Bellare" initials="M." surname="Bellare"/>
            <author fullname="R. Canetti" initials="R." surname="Canetti"/>
            <date month="February" year="1997"/>
            <abstract>
              <t indent="0">This document describes HMAC, a mechanism for message authentication using cryptographic hash functions. HMAC can be used with any iterative cryptographic hash function, e.g., MD5, SHA-1, in combination with a secret shared key. The cryptographic strength of HMAC depends on the properties of the underlying hash function. This memo provides information for the Internet community. This memo does not specify an Internet standard of any kind</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="2104"/>
          <seriesInfo name="DOI" value="10.17487/RFC2104"/>
        </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 fullname="S. Bradner" initials="S." surname="Bradner"/>
            <date month="March" year="1997"/>
            <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="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 fullname="D. Eastlake 3rd" initials="D." surname="Eastlake 3rd"/>
            <author fullname="T. Hansen" initials="T." surname="Hansen"/>
            <date month="May" year="2011"/>
            <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="RFC7517" target="https://www.rfc-editor.org/info/rfc7517" quoteTitle="true" derivedAnchor="RFC7517">
          <front>
            <title>JSON Web Key (JWK)</title>
            <author fullname="M. Jones" initials="M." surname="Jones"/>
            <date month="May" year="2015"/>
            <abstract>
              <t indent="0">A JSON Web Key (JWK) is a JavaScript Object Notation (JSON) data structure that represents a cryptographic key. This specification also defines a JWK Set JSON data structure that represents a set of JWKs. Cryptographic algorithms and identifiers for use with this specification are described in the separate JSON Web Algorithms (JWA) specification and IANA registries established by that specification.</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="7517"/>
          <seriesInfo name="DOI" value="10.17487/RFC7517"/>
        </reference>
        <reference anchor="RFC7518" target="https://www.rfc-editor.org/info/rfc7518" quoteTitle="true" derivedAnchor="RFC7518">
          <front>
            <title>JSON Web Algorithms (JWA)</title>
            <author fullname="M. Jones" initials="M." surname="Jones"/>
            <date month="May" year="2015"/>
            <abstract>
              <t indent="0">This specification registers cryptographic algorithms and identifiers to be used with the JSON Web Signature (JWS), JSON Web Encryption (JWE), and JSON Web Key (JWK) specifications. It defines several IANA registries for these identifiers.</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="7518"/>
          <seriesInfo name="DOI" value="10.17487/RFC7518"/>
        </reference>
        <reference anchor="RFC8017" target="https://www.rfc-editor.org/info/rfc8017" quoteTitle="true" derivedAnchor="RFC8017">
          <front>
            <title>PKCS #1: RSA Cryptography Specifications Version 2.2</title>
            <author fullname="K. Moriarty" initials="K." role="editor" surname="Moriarty"/>
            <author fullname="B. Kaliski" initials="B." surname="Kaliski"/>
            <author fullname="J. Jonsson" initials="J." surname="Jonsson"/>
            <author fullname="A. Rusch" initials="A." surname="Rusch"/>
            <date month="November" year="2016"/>
            <abstract>
              <t indent="0">This document provides recommendations for the implementation of public-key cryptography based on the RSA algorithm, covering cryptographic primitives, encryption schemes, signature schemes with appendix, and ASN.1 syntax for representing keys and for identifying the schemes.</t>
              <t indent="0">This document represents a republication of PKCS #1 v2.2 from RSA Laboratories' Public-Key Cryptography Standards (PKCS) series. By publishing this RFC, change control is transferred to the IETF.</t>
              <t indent="0">This document also obsoletes RFC 3447.</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="8017"/>
          <seriesInfo name="DOI" value="10.17487/RFC8017"/>
        </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 fullname="S. Josefsson" initials="S." surname="Josefsson"/>
            <author fullname="I. Liusvaara" initials="I." surname="Liusvaara"/>
            <date month="January" year="2017"/>
            <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 fullname="B. Leiba" initials="B." surname="Leiba"/>
            <date month="May" year="2017"/>
            <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="RFC8941" target="https://www.rfc-editor.org/info/rfc8941" quoteTitle="true" derivedAnchor="STRUCTURED-FIELDS">
          <front>
            <title>Structured Field Values for HTTP</title>
            <author fullname="M. Nottingham" initials="M." surname="Nottingham"/>
            <author fullname="P-H. Kamp" surname="P-H. Kamp"/>
            <date month="February" year="2021"/>
            <abstract>
              <t indent="0">This document describes a set of data types and associated algorithms that are intended to make it easier and safer to define and handle HTTP header and trailer fields, known as "Structured Fields", "Structured Headers", or "Structured Trailers". It is intended for use by specifications of new HTTP fields that wish to use a common syntax that is more restrictive than traditional HTTP field values.</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="8941"/>
          <seriesInfo name="DOI" value="10.17487/RFC8941"/>
        </reference>
        <reference anchor="RFC3986" target="https://www.rfc-editor.org/info/rfc3986" quoteTitle="true" derivedAnchor="URI">
          <front>
            <title>Uniform Resource Identifier (URI): Generic Syntax</title>
            <author fullname="T. Berners-Lee" initials="T." surname="Berners-Lee"/>
            <author fullname="R. Fielding" initials="R." surname="Fielding"/>
            <author fullname="L. Masinter" initials="L." surname="Masinter"/>
            <date month="January" year="2005"/>
            <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>
      </references>
      <references pn="section-9.2">
        <name slugifiedName="name-informative-references">Informative References</name>
        <reference anchor="AWS-SIGv4" target="https://docs.aws.amazon.com/AmazonS3/latest/API/sig-v4-authenticating-requests.html" quoteTitle="true" derivedAnchor="AWS-SIGv4">
          <front>
            <title>Authenticating Requests (AWS Signature Version 4)</title>
            <author>
              <organization showOnFrontPage="true">Amazon Simple Storage Service</organization>
            </author>
            <date month="March" year="2006"/>
          </front>
        </reference>
        <referencegroup anchor="BCP195" target="https://www.rfc-editor.org/info/bcp195" derivedAnchor="BCP195">
          <reference anchor="RFC8996" target="https://www.rfc-editor.org/info/rfc8996" quoteTitle="true">
            <front>
              <title>Deprecating TLS 1.0 and TLS 1.1</title>
              <author fullname="K. Moriarty" initials="K." surname="Moriarty"/>
              <author fullname="S. Farrell" initials="S." surname="Farrell"/>
              <date month="March" year="2021"/>
              <abstract>
                <t indent="0">This document formally deprecates Transport Layer Security (TLS) versions 1.0 (RFC 2246) and 1.1 (RFC 4346). Accordingly, those documents have been moved to Historic status. These versions lack support for current and recommended cryptographic algorithms and mechanisms, and various government and industry profiles of applications using TLS now mandate avoiding these old TLS versions. TLS version 1.2 became the recommended version for IETF protocols in 2008 (subsequently being obsoleted by TLS version 1.3 in 2018), providing sufficient time to transition away from older versions. Removing support for older versions from implementations reduces the attack surface, reduces opportunity for misconfiguration, and streamlines library and product maintenance.</t>
                <t indent="0">This document also deprecates Datagram TLS (DTLS) version 1.0 (RFC 4347) but not DTLS version 1.2, and there is no DTLS version 1.1.</t>
                <t indent="0">This document updates many RFCs that normatively refer to TLS version 1.0 or TLS version 1.1, as described herein. This document also updates the best practices for TLS usage in RFC 7525; hence, it is part of BCP 195.</t>
              </abstract>
            </front>
            <seriesInfo name="BCP" value="195"/>
            <seriesInfo name="RFC" value="8996"/>
            <seriesInfo name="DOI" value="10.17487/RFC8996"/>
          </reference>
          <reference anchor="RFC9325" target="https://www.rfc-editor.org/info/rfc9325" quoteTitle="true">
            <front>
              <title>Recommendations for Secure Use of Transport Layer Security (TLS) and Datagram Transport Layer Security (DTLS)</title>
              <author fullname="Y. Sheffer" initials="Y." surname="Sheffer"/>
              <author fullname="P. Saint-Andre" initials="P." surname="Saint-Andre"/>
              <author fullname="T. Fossati" initials="T." surname="Fossati"/>
              <date month="November" year="2022"/>
              <abstract>
                <t indent="0">Transport Layer Security (TLS) and Datagram Transport Layer Security (DTLS) are used to protect data exchanged over a wide range of application protocols and can also form the basis for secure transport protocols. Over the years, the industry has witnessed several serious attacks on TLS and DTLS, including attacks on the most commonly used cipher suites and their modes of operation. This document provides the latest recommendations for ensuring the security of deployed services that use TLS and DTLS. These recommendations are applicable to the majority of use cases.</t>
                <t indent="0">RFC 7525, an earlier version of the TLS recommendations, was published when the industry was transitioning to TLS 1.2. Years later, this transition is largely complete, and TLS 1.3 is widely available. This document updates the guidance given the new environment and obsoletes RFC 7525. In addition, this document updates RFCs 5288 and 6066 in view of recent attacks.</t>
              </abstract>
            </front>
            <seriesInfo name="BCP" value="195"/>
            <seriesInfo name="RFC" value="9325"/>
            <seriesInfo name="DOI" value="10.17487/RFC9325"/>
          </reference>
        </referencegroup>
        <reference anchor="RFC9440" target="https://www.rfc-editor.org/info/rfc9440" quoteTitle="true" derivedAnchor="CLIENT-CERT">
          <front>
            <title>Client-Cert HTTP Header Field</title>
            <author fullname="B. Campbell" initials="B." surname="Campbell"/>
            <author fullname="M. Bishop" initials="M." surname="Bishop"/>
            <date month="July" year="2023"/>
            <abstract>
              <t indent="0">This document describes HTTP extension header fields that allow a TLS terminating reverse proxy (TTRP) to convey the client certificate information of a mutually authenticated TLS connection to the origin server in a common and predictable manner.</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="9440"/>
          <seriesInfo name="DOI" value="10.17487/RFC9440"/>
        </reference>
        <reference anchor="RFC6265" target="https://www.rfc-editor.org/info/rfc6265" quoteTitle="true" derivedAnchor="COOKIE">
          <front>
            <title>HTTP State Management Mechanism</title>
            <author fullname="A. Barth" initials="A." surname="Barth"/>
            <date month="April" year="2011"/>
            <abstract>
              <t indent="0">This document defines the HTTP Cookie and Set-Cookie header fields. These header fields can be used by HTTP servers to store state (called cookies) at HTTP user agents, letting the servers maintain a stateful session over the mostly stateless HTTP protocol. Although cookies have many historical infelicities that degrade their security and privacy, the Cookie and Set-Cookie header fields are widely used on the Internet. This document obsoletes RFC 2965. [STANDARDS-TRACK]</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="6265"/>
          <seriesInfo name="DOI" value="10.17487/RFC6265"/>
        </reference>
        <reference anchor="RFC9530" target="https://www.rfc-editor.org/info/rfc9530" quoteTitle="true" derivedAnchor="DIGEST">
          <front>
            <title>Digest Fields</title>
            <author initials="R." surname="Polli" fullname="Roberto Polli">
              <organization showOnFrontPage="true">Team Digitale, Italian Government</organization>
            </author>
            <author initials="L." surname="Pardue" fullname="Lucas Pardue">
              <organization showOnFrontPage="true">Cloudflare</organization>
            </author>
            <date month="February" year="2024"/>
          </front>
          <seriesInfo name="RFC" value="9530"/>
          <seriesInfo name="DOI" value="10.17487/RFC9530"/>
        </reference>
        <reference anchor="JACKSON2019" target="https://dl.acm.org/doi/10.1145/3319535.3339813" quoteTitle="true" derivedAnchor="JACKSON2019">
          <front>
            <title>Seems Legit: Automated Analysis of Subtle Attacks on Protocols that Use Signatures</title>
            <author initials="D." surname="Jackson" fullname="Dennis Jackson">
              <organization showOnFrontPage="true">University of Oxford</organization>
            </author>
            <author initials="C." surname="Cremers" fullname="Cas Cremers">
              <organization showOnFrontPage="true">CISPA Helmholtz Center for Information Security</organization>
            </author>
            <author initials="K." surname="Cohn-Gordon" fullname="Katriel Cohn-Gordon">
              <organization showOnFrontPage="true">Independent Scholar</organization>
            </author>
            <author initials="R." surname="Sasse" fullname="Ralf Sasse">
              <organization showOnFrontPage="true">Department of Computer Science, ETH Zurich</organization>
            </author>
            <date year="2019" month="November"/>
          </front>
          <seriesInfo name="DOI" value="10.1145/3319535.3339813"/>
          <refcontent>CCS '19: Proceedings of the 2019 ACM SIGSAC Conference on Computer and Communications Security, pp. 2165-2180</refcontent>
        </reference>
        <reference anchor="RFC7515" target="https://www.rfc-editor.org/info/rfc7515" quoteTitle="true" derivedAnchor="JWS">
          <front>
            <title>JSON Web Signature (JWS)</title>
            <author fullname="M. Jones" initials="M." surname="Jones"/>
            <author fullname="J. Bradley" initials="J." surname="Bradley"/>
            <author fullname="N. Sakimura" initials="N." surname="Sakimura"/>
            <date month="May" year="2015"/>
            <abstract>
              <t indent="0">JSON Web Signature (JWS) represents content secured with digital signatures or Message Authentication Codes (MACs) using JSON-based data structures. Cryptographic algorithms and identifiers for use with this specification are described in the separate JSON Web Algorithms (JWA) specification and an IANA registry defined by that specification. Related encryption capabilities are described in the separate JSON Web Encryption (JWE) specification.</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="7515"/>
          <seriesInfo name="DOI" value="10.17487/RFC7515"/>
        </reference>
        <reference anchor="RFC7239" target="https://www.rfc-editor.org/info/rfc7239" quoteTitle="true" derivedAnchor="RFC7239">
          <front>
            <title>Forwarded HTTP Extension</title>
            <author fullname="A. Petersson" initials="A." surname="Petersson"/>
            <author fullname="M. Nilsson" initials="M." surname="Nilsson"/>
            <date month="June" year="2014"/>
            <abstract>
              <t indent="0">This document defines an HTTP extension header field that allows proxy components to disclose information lost in the proxying process, for example, the originating IP address of a request or IP address of the proxy on the user-agent-facing interface. In a path of proxying components, this makes it possible to arrange it so that each subsequent component will have access to, for example, all IP addresses used in the chain of proxied HTTP requests.</t>
              <t indent="0">This document also specifies guidelines for a proxy administrator to anonymize the origin of a request.</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="7239"/>
          <seriesInfo name="DOI" value="10.17487/RFC7239"/>
        </reference>
        <reference anchor="RFC7468" target="https://www.rfc-editor.org/info/rfc7468" quoteTitle="true" derivedAnchor="RFC7468">
          <front>
            <title>Textual Encodings of PKIX, PKCS, and CMS Structures</title>
            <author fullname="S. Josefsson" initials="S." surname="Josefsson"/>
            <author fullname="S. Leonard" initials="S." surname="Leonard"/>
            <date month="April" year="2015"/>
            <abstract>
              <t indent="0">This document describes and discusses the textual encodings of the Public-Key Infrastructure X.509 (PKIX), Public-Key Cryptography Standards (PKCS), and Cryptographic Message Syntax (CMS). The textual encodings are well-known, are implemented by several applications and libraries, and are widely deployed. This document articulates the de facto rules by which existing implementations operate and defines them so that future implementations can interoperate.</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="7468"/>
          <seriesInfo name="DOI" value="10.17487/RFC7468"/>
        </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 fullname="M. Nottingham" initials="M." surname="Nottingham"/>
            <author fullname="E. Wilde" initials="E." surname="Wilde"/>
            <date month="March" year="2016"/>
            <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="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 fullname="M. Cotton" initials="M." surname="Cotton"/>
            <author fullname="B. Leiba" initials="B." surname="Leiba"/>
            <author fullname="T. Narten" initials="T." surname="Narten"/>
            <date month="June" year="2017"/>
            <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="RFC8792" target="https://www.rfc-editor.org/info/rfc8792" quoteTitle="true" derivedAnchor="RFC8792">
          <front>
            <title>Handling Long Lines in Content of Internet-Drafts and RFCs</title>
            <author fullname="K. Watsen" initials="K." surname="Watsen"/>
            <author fullname="E. Auerswald" initials="E." surname="Auerswald"/>
            <author fullname="A. Farrel" initials="A." surname="Farrel"/>
            <author fullname="Q. Wu" initials="Q." surname="Wu"/>
            <date month="June" year="2020"/>
            <abstract>
              <t indent="0">This document defines two strategies for handling long lines in width-bounded text content. One strategy, called the "single backslash" strategy, is based on the historical use of a single backslash ('\') character to indicate where line-folding has occurred, with the continuation occurring with the first character that is not a space character (' ') on the next line. The second strategy, called the "double backslash" strategy, extends the first strategy by adding a second backslash character to identify where the continuation begins and is thereby able to handle cases not supported by the first strategy. Both strategies use a self-describing header enabling automated reconstitution of the original content.</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="8792"/>
          <seriesInfo name="DOI" value="10.17487/RFC8792"/>
        </reference>
        <reference anchor="RFC9457" target="https://www.rfc-editor.org/info/rfc9457" quoteTitle="true" derivedAnchor="RFC9457">
          <front>
            <title>Problem Details for HTTP APIs</title>
            <author fullname="M. Nottingham" initials="M." surname="Nottingham"/>
            <author fullname="E. Wilde" initials="E." surname="Wilde"/>
            <author fullname="S. Dalal" initials="S." surname="Dalal"/>
            <date month="July" year="2023"/>
            <abstract>
              <t indent="0">This document defines a "problem detail" to carry machine-readable details of errors in HTTP response content to avoid the need to define new error response formats for HTTP APIs.</t>
              <t indent="0">This document obsoletes RFC 7807.</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="9457"/>
          <seriesInfo name="DOI" value="10.17487/RFC9457"/>
        </reference>
        <reference anchor="I-D.cavage-http-signatures" target="https://datatracker.ietf.org/doc/html/draft-cavage-http-signatures-12" quoteTitle="true" derivedAnchor="SIGNING-HTTP-MESSAGES">
          <front>
            <title>Signing HTTP Messages</title>
            <author initials="M." surname="Cavage" fullname="Mark Cavage">
              <organization showOnFrontPage="true">Oracle</organization>
            </author>
            <author initials="M." surname="Sporny" fullname="Manu Sporny">
              <organization showOnFrontPage="true">Digital Bazaar</organization>
            </author>
            <date month="October" day="21" year="2019"/>
            <abstract>
              <t indent="0">   When communicating over the Internet using the HTTP protocol, it can
   be desirable for a server or client to authenticate the sender of a
   particular message.  It can also be desirable to ensure that the
   message was not tampered with during transit.  This document
   describes a way for servers and clients to simultaneously add
   authentication and message integrity to HTTP messages by using a
   digital signature.

              </t>
            </abstract>
          </front>
          <seriesInfo name="Internet-Draft" value="draft-cavage-http-signatures-12"/>
          <refcontent>Work in Progress</refcontent>
        </reference>
        <reference anchor="SIGNING-HTTP-REQS-OAUTH" quoteTitle="true" target="https://datatracker.ietf.org/doc/html/draft-ietf-oauth-signed-http-request-03" derivedAnchor="SIGNING-HTTP-REQS-OAUTH">
          <front>
            <title>A Method for Signing HTTP Requests for OAuth</title>
            <author initials="J." surname="Richer" fullname="Justin Richer" role="editor">
         </author>
            <author initials="J." surname="Bradley" fullname="John Bradley">
              <organization showOnFrontPage="true">Ping Identity</organization>
            </author>
            <author initials="H." surname="Tschofenig" fullname="Hannes Tschofenig">
              <organization showOnFrontPage="true">ARM Limited</organization>
            </author>
            <date month="August" day="8" year="2016"/>
          </front>
          <seriesInfo name="Internet-Draft" value="draft-ietf-oauth-signed-http-request-03"/>
          <refcontent>Work in Progress</refcontent>
        </reference>
        <reference anchor="RFC8446" target="https://www.rfc-editor.org/info/rfc8446" quoteTitle="true" derivedAnchor="TLS">
          <front>
            <title>The Transport Layer Security (TLS) Protocol Version 1.3</title>
            <author fullname="E. Rescorla" initials="E." surname="Rescorla"/>
            <date month="August" year="2018"/>
            <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>
      </references>
    </references>
    <section anchor="detection" numbered="true" removeInRFC="false" toc="include" pn="section-appendix.a">
      <name slugifiedName="name-detecting-http-message-sign">Detecting HTTP Message Signatures</name>
      <t indent="0" pn="section-appendix.a-1">There have been many attempts to create signed HTTP messages in the past, including other non-standardized definitions of the Signature field that is used within this specification. It is recommended that developers wishing to support this specification, other published documents, or other historical drafts do so carefully and deliberately, as incompatibilities between this specification and other documents or various versions of other drafts could lead to unexpected problems.</t>
      <t indent="0" pn="section-appendix.a-2">It is recommended that implementors first detect and validate the Signature-Input field defined in this specification to detect that the mechanism described in this document is in use and not an alternative. If the Signature-Input field is present, all Signature fields can be parsed and interpreted in the context of this specification.</t>
    </section>
    <section anchor="examples" numbered="true" removeInRFC="false" toc="include" pn="section-appendix.b">
      <name slugifiedName="name-examples">Examples</name>
      <t indent="0" pn="section-appendix.b-1">The following non-normative examples are provided as a means of testing implementations of HTTP message signatures. The signed messages given can be used to create the signature base with the stated parameters, creating signatures using the stated algorithms and keys.</t>
      <t indent="0" pn="section-appendix.b-2">The private keys given can be used to generate signatures, though since several of the demonstrated algorithms are non-deterministic, the results of a signature are expected to be different from the exact bytes of the examples. The public keys given can be used to validate all signed examples.</t>
      <section anchor="example-keys" numbered="true" removeInRFC="false" toc="include" pn="section-appendix.b.1">
        <name slugifiedName="name-example-keys">Example Keys</name>
        <t indent="0" pn="section-appendix.b.1-1">This section provides cryptographic keys that are referenced in example signatures throughout this document. These keys <bcp14>MUST NOT</bcp14> be used for any purpose other than testing.</t>
        <t indent="0" pn="section-appendix.b.1-2">The key identifiers for each key are used throughout the examples in this specification. It is assumed for these examples that the signer and verifier can unambiguously dereference all key identifiers used here and that the keys and algorithms used are appropriate for the context in which the signature is presented.</t>
        <t indent="0" pn="section-appendix.b.1-3">The components for each private key, in PEM format <xref target="RFC7468" format="default" sectionFormat="of" derivedContent="RFC7468"/>, can be displayed by executing the following OpenSSL command:</t>
        <artwork align="left" pn="section-appendix.b.1-4">
openssl pkey -text
</artwork>
        <t indent="0" pn="section-appendix.b.1-5">This command was tested with all the example keys on OpenSSL version 1.1.1m. Note that some systems cannot produce or use all of these keys directly and may require additional processing. All keys are also made available in JWK format.</t>
        <section anchor="example-key-rsa-test" numbered="true" removeInRFC="false" toc="include" pn="section-appendix.b.1.1">
          <name slugifiedName="name-example-rsa-key">Example RSA Key</name>
          <t indent="0" pn="section-appendix.b.1.1-1">The following key is a 2048-bit RSA public and private key pair, referred to in this document
as <tt>test-key-rsa</tt>. This key is encoded in PEM format, with no encryption.</t>
          <artwork align="left" pn="section-appendix.b.1.1-2">
-----BEGIN RSA PUBLIC KEY-----
MIIBCgKCAQEAhAKYdtoeoy8zcAcR874L8cnZxKzAGwd7v36APp7Pv6Q2jdsPBRrw
WEBnez6d0UDKDwGbc6nxfEXAy5mbhgajzrw3MOEt8uA5txSKobBpKDeBLOsdJKFq
MGmXCQvEG7YemcxDTRPxAleIAgYYRjTSd/QBwVW9OwNFhekro3RtlinV0a75jfZg
kne/YiktSvLG34lw2zqXBDTC5NHROUqGTlML4PlNZS5Ri2U4aCNx2rUPRcKIlE0P
uKxI4T+HIaFpv8+rdV6eUgOrB2xeI1dSFFn/nnv5OoZJEIB+VmuKn3DCUcCZSFlQ
PSXSfBDiUGhwOw76WuSSsf1D4b/vLoJ10wIDAQAB
-----END RSA PUBLIC KEY-----

-----BEGIN RSA PRIVATE KEY-----
MIIEqAIBAAKCAQEAhAKYdtoeoy8zcAcR874L8cnZxKzAGwd7v36APp7Pv6Q2jdsP
BRrwWEBnez6d0UDKDwGbc6nxfEXAy5mbhgajzrw3MOEt8uA5txSKobBpKDeBLOsd
JKFqMGmXCQvEG7YemcxDTRPxAleIAgYYRjTSd/QBwVW9OwNFhekro3RtlinV0a75
jfZgkne/YiktSvLG34lw2zqXBDTC5NHROUqGTlML4PlNZS5Ri2U4aCNx2rUPRcKI
lE0PuKxI4T+HIaFpv8+rdV6eUgOrB2xeI1dSFFn/nnv5OoZJEIB+VmuKn3DCUcCZ
SFlQPSXSfBDiUGhwOw76WuSSsf1D4b/vLoJ10wIDAQABAoIBAG/JZuSWdoVHbi56
vjgCgkjg3lkO1KrO3nrdm6nrgA9P9qaPjxuKoWaKO1cBQlE1pSWp/cKncYgD5WxE
CpAnRUXG2pG4zdkzCYzAh1i+c34L6oZoHsirK6oNcEnHveydfzJL5934egm6p8DW
+m1RQ70yUt4uRc0YSor+q1LGJvGQHReF0WmJBZHrhz5e63Pq7lE0gIwuBqL8SMaA
yRXtK+JGxZpImTq+NHvEWWCu09SCq0r838ceQI55SvzmTkwqtC+8AT2zFviMZkKR
Qo6SPsrqItxZWRty2izawTF0Bf5S2VAx7O+6t3wBsQ1sLptoSgX3QblELY5asI0J
YFz7LJECgYkAsqeUJmqXE3LP8tYoIjMIAKiTm9o6psPlc8CrLI9CH0UbuaA2JCOM
cCNq8SyYbTqgnWlB9ZfcAm/cFpA8tYci9m5vYK8HNxQr+8FS3Qo8N9RJ8d0U5Csw
DzMYfRghAfUGwmlWj5hp1pQzAuhwbOXFtxKHVsMPhz1IBtF9Y8jvgqgYHLbmyiu1
mwJ5AL0pYF0G7x81prlARURwHo0Yf52kEw1dxpx+JXER7hQRWQki5/NsUEtv+8RT
qn2m6qte5DXLyn83b1qRscSdnCCwKtKWUug5q2ZbwVOCJCtmRwmnP131lWRYfj67
B/xJ1ZA6X3GEf4sNReNAtaucPEelgR2nsN0gKQKBiGoqHWbK1qYvBxX2X3kbPDkv
9C+celgZd2PW7aGYLCHq7nPbmfDV0yHcWjOhXZ8jRMjmANVR/eLQ2EfsRLdW69bn
f3ZD7JS1fwGnO3exGmHO3HZG+6AvberKYVYNHahNFEw5TsAcQWDLRpkGybBcxqZo
81YCqlqidwfeO5YtlO7etx1xLyqa2NsCeG9A86UjG+aeNnXEIDk1PDK+EuiThIUa
/2IxKzJKWl1BKr2d4xAfR0ZnEYuRrbeDQYgTImOlfW6/GuYIxKYgEKCFHFqJATAG
IxHrq1PDOiSwXd2GmVVYyEmhZnbcp8CxaEMQoevxAta0ssMK3w6UsDtvUvYvF22m
qQKBiD5GwESzsFPy3Ga0MvZpn3D6EJQLgsnrtUPZx+z2Ep2x0xc5orneB5fGyF1P
WtP+fG5Q6Dpdz3LRfm+KwBCWFKQjg7uTxcjerhBWEYPmEMKYwTJF5PBG9/ddvHLQ
EQeNC8fHGg4UXU8mhHnSBt3EA10qQJfRDs15M38eG2cYwB1PZpDHScDnDA0=
-----END RSA PRIVATE KEY-----
</artwork>
          <t indent="0" pn="section-appendix.b.1.1-3">The same public and private key pair in JWK format:</t>
          <sourcecode type="json" markers="false" pn="section-appendix.b.1.1-4">
NOTE: '\' line wrapping per RFC 8792

{
  "kty": "RSA",
  "kid": "test-key-rsa",
  "p": "sqeUJmqXE3LP8tYoIjMIAKiTm9o6psPlc8CrLI9CH0UbuaA2JCOMcCNq8Sy\
  YbTqgnWlB9ZfcAm_cFpA8tYci9m5vYK8HNxQr-8FS3Qo8N9RJ8d0U5CswDzMYfRgh\
  AfUGwmlWj5hp1pQzAuhwbOXFtxKHVsMPhz1IBtF9Y8jvgqgYHLbmyiu1mw",
  "q": "vSlgXQbvHzWmuUBFRHAejRh_naQTDV3GnH4lcRHuFBFZCSLn82xQS2_7xFO\
  qfabqq17kNcvKfzdvWpGxxJ2cILAq0pZS6DmrZlvBU4IkK2ZHCac_XfWVZFh-PrsH\
  _EnVkDpfcYR_iw1F40C1q5w8R6WBHaew3SAp",
  "d": "b8lm5JZ2hUduLnq-OAKCSODeWQ7Uqs7eet2bqeuAD0_2po-PG4qhZoo7VwF\
  CUTWlJan9wqdxiAPlbEQKkCdFRcbakbjN2TMJjMCHWL5zfgvqhmgeyKsrqg1wSce9\
  7J1_Mkvn3fh6CbqnwNb6bVFDvTJS3i5FzRhKiv6rUsYm8ZAdF4XRaYkFkeuHPl7rc\
  -ruUTSAjC4GovxIxoDJFe0r4kbFmkiZOr40e8RZYK7T1IKrSvzfxx5AjnlK_OZOTC\
  q0L7wBPbMW-IxmQpFCjpI-yuoi3FlZG3LaLNrBMXQF_lLZUDHs77q3fAGxDWwum2h\
  KBfdBuUQtjlqwjQlgXPsskQ",
  "e": "AQAB",
  "qi": "PkbARLOwU_LcZrQy9mmfcPoQlAuCyeu1Q9nH7PYSnbHTFzmiud4Hl8bIXU\
  9a0_58blDoOl3PctF-b4rAEJYUpCODu5PFyN6uEFYRg-YQwpjBMkXk8Eb39128ctA\
  RB40Lx8caDhRdTyaEedIG3cQDXSpAl9EOzXkzfx4bZxjAHU9mkMdJwOcMDQ",
  "dp": "aiodZsrWpi8HFfZfeRs8OS_0L5x6WBl3Y9btoZgsIeruc9uZ8NXTIdxaM6\
  FdnyNEyOYA1VH94tDYR-xEt1br1ud_dkPslLV_Aac7d7EaYc7cdkb7oC9t6sphVg0\
  dqE0UTDlOwBxBYMtGmQbJsFzGpmjzVgKqWqJ3B947li2U7t63HXEvKprY2w",
  "dq": "b0DzpSMb5p42dcQgOTU8Mr4S6JOEhRr_YjErMkpaXUEqvZ3jEB9HRmcRi5\
  Gtt4NBiBMiY6V9br8a5gjEpiAQoIUcWokBMAYjEeurU8M6JLBd3YaZVVjISaFmdty\
  nwLFoQxCh6_EC1rSywwrfDpSwO29S9i8Xbaap",
  "n": "hAKYdtoeoy8zcAcR874L8cnZxKzAGwd7v36APp7Pv6Q2jdsPBRrwWEBnez6\
  d0UDKDwGbc6nxfEXAy5mbhgajzrw3MOEt8uA5txSKobBpKDeBLOsdJKFqMGmXCQvE\
  G7YemcxDTRPxAleIAgYYRjTSd_QBwVW9OwNFhekro3RtlinV0a75jfZgkne_YiktS\
  vLG34lw2zqXBDTC5NHROUqGTlML4PlNZS5Ri2U4aCNx2rUPRcKIlE0PuKxI4T-HIa\
  Fpv8-rdV6eUgOrB2xeI1dSFFn_nnv5OoZJEIB-VmuKn3DCUcCZSFlQPSXSfBDiUGh\
  wOw76WuSSsf1D4b_vLoJ10w"
}
</sourcecode>
        </section>
        <section anchor="example-key-rsa-pss-test" numbered="true" removeInRFC="false" toc="include" pn="section-appendix.b.1.2">
          <name slugifiedName="name-example-rsa-pss-key">Example RSA-PSS Key</name>
          <t indent="0" pn="section-appendix.b.1.2-1">The following key is a 2048-bit RSA public and private key pair, referred to in this document
as <tt>test-key-rsa-pss</tt>. This key is PKCS #8 encoded in PEM format, with no encryption.</t>
          <artwork align="left" pn="section-appendix.b.1.2-2">
-----BEGIN PUBLIC KEY-----
MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAr4tmm3r20Wd/PbqvP1s2
+QEtvpuRaV8Yq40gjUR8y2Rjxa6dpG2GXHbPfvMs8ct+Lh1GH45x28Rw3Ry53mm+
oAXjyQ86OnDkZ5N8lYbggD4O3w6M6pAvLkhk95AndTrifbIFPNU8PPMO7OyrFAHq
gDsznjPFmTOtCEcN2Z1FpWgchwuYLPL+Wokqltd11nqqzi+bJ9cvSKADYdUAAN5W
Utzdpiy6LbTgSxP7ociU4Tn0g5I6aDZJ7A8Lzo0KSyZYoA485mqcO0GVAdVw9lq4
aOT9v6d+nb4bnNkQVklLQ3fVAvJm+xdDOp9LCNCN48V2pnDOkFV6+U9nV5oyc6XI
2wIDAQAB
-----END PUBLIC KEY-----

-----BEGIN PRIVATE KEY-----
MIIEvgIBADALBgkqhkiG9w0BAQoEggSqMIIEpgIBAAKCAQEAr4tmm3r20Wd/Pbqv
P1s2+QEtvpuRaV8Yq40gjUR8y2Rjxa6dpG2GXHbPfvMs8ct+Lh1GH45x28Rw3Ry5
3mm+oAXjyQ86OnDkZ5N8lYbggD4O3w6M6pAvLkhk95AndTrifbIFPNU8PPMO7Oyr
FAHqgDsznjPFmTOtCEcN2Z1FpWgchwuYLPL+Wokqltd11nqqzi+bJ9cvSKADYdUA
AN5WUtzdpiy6LbTgSxP7ociU4Tn0g5I6aDZJ7A8Lzo0KSyZYoA485mqcO0GVAdVw
9lq4aOT9v6d+nb4bnNkQVklLQ3fVAvJm+xdDOp9LCNCN48V2pnDOkFV6+U9nV5oy
c6XI2wIDAQABAoIBAQCUB8ip+kJiiZVKF8AqfB/aUP0jTAqOQewK1kKJ/iQCXBCq
pbo360gvdt05H5VZ/RDVkEgO2k73VSsbulqezKs8RFs2tEmU+JgTI9MeQJPWcP6X
aKy6LIYs0E2cWgp8GADgoBs8llBq0UhX0KffglIeek3n7Z6Gt4YFge2TAcW2WbN4
XfK7lupFyo6HHyWRiYHMMARQXLJeOSdTn5aMBP0PO4bQyk5ORxTUSeOciPJUFktQ
HkvGbym7KryEfwH8Tks0L7WhzyP60PL3xS9FNOJi9m+zztwYIXGDQuKM2GDsITeD
2mI2oHoPMyAD0wdI7BwSVW18p1h+jgfc4dlexKYRAoGBAOVfuiEiOchGghV5vn5N
RDNscAFnpHj1QgMr6/UG05RTgmcLfVsI1I4bSkbrIuVKviGGf7atlkROALOG/xRx
DLadgBEeNyHL5lz6ihQaFJLVQ0u3U4SB67J0YtVO3R6lXcIjBDHuY8SjYJ7Ci6Z6
vuDcoaEujnlrtUhaMxvSfcUJAoGBAMPsCHXte1uWNAqYad2WdLjPDlKtQJK1diCm
rqmB2g8QE99hDOHItjDBEdpyFBKOIP+NpVtM2KLhRajjcL9Ph8jrID6XUqikQuVi
4J9FV2m42jXMuioTT13idAILanYg8D3idvy/3isDVkON0X3UAVKrgMEne0hJpkPL
FYqgetvDAoGBAKLQ6JZMbSe0pPIJkSamQhsehgL5Rs51iX4m1z7+sYFAJfhvN3Q/
OGIHDRp6HjMUcxHpHw7U+S1TETxePwKLnLKj6hw8jnX2/nZRgWHzgVcY+sPsReRx
NJVf+Cfh6yOtznfX00p+JWOXdSY8glSSHJwRAMog+hFGW1AYdt7w80XBAoGBAImR
NUugqapgaEA8TrFxkJmngXYaAqpA0iYRA7kv3S4QavPBUGtFJHBNULzitydkNtVZ
3w6hgce0h9YThTo/nKc+OZDZbgfN9s7cQ75x0PQCAO4fx2P91Q+mDzDUVTeG30mE
t2m3S0dGe47JiJxifV9P3wNBNrZGSIF3mrORBVNDAoGBAI0QKn2Iv7Sgo4T/XjND
dl2kZTXqGAk8dOhpUiw/HdM3OGWbhHj2NdCzBliOmPyQtAr770GITWvbAI+IRYyF
S7Fnk6ZVVVHsxjtaHy1uJGFlaZzKR4AGNaUTOJMs6NadzCmGPAxNQQOCqoUjn4XR
rOjr9w349JooGXhOxbu8nOxX
-----END PRIVATE KEY-----
</artwork>
          <t indent="0" pn="section-appendix.b.1.2-3">The same public and private key pair in JWK format:</t>
          <sourcecode type="json" markers="false" pn="section-appendix.b.1.2-4">
NOTE: '\' line wrapping per RFC 8792

{
  "kty": "RSA",
  "kid": "test-key-rsa-pss",
  "p": "5V-6ISI5yEaCFXm-fk1EM2xwAWekePVCAyvr9QbTlFOCZwt9WwjUjhtKRus\
  i5Uq-IYZ_tq2WRE4As4b_FHEMtp2AER43IcvmXPqKFBoUktVDS7dThIHrsnRi1U7d\
  HqVdwiMEMe5jxKNgnsKLpnq-4NyhoS6OeWu1SFozG9J9xQk",
  "q": "w-wIde17W5Y0Cphp3ZZ0uM8OUq1AkrV2IKauqYHaDxAT32EM4ci2MMER2nI\
  UEo4g_42lW0zYouFFqONwv0-HyOsgPpdSqKRC5WLgn0VXabjaNcy6KhNPXeJ0Agtq\
  diDwPeJ2_L_eKwNWQ43RfdQBUquAwSd7SEmmQ8sViqB628M",
  "d": "lAfIqfpCYomVShfAKnwf2lD9I0wKjkHsCtZCif4kAlwQqqW6N-tIL3bdOR-\
  VWf0Q1ZBIDtpO91UrG7pansyrPERbNrRJlPiYEyPTHkCT1nD-l2isuiyGLNBNnFoK\
  fBgA4KAbPJZQatFIV9Cn34JSHnpN5-2ehreGBYHtkwHFtlmzeF3yu5bqRcqOhx8lk\
  YmBzDAEUFyyXjknU5-WjAT9DzuG0MpOTkcU1EnjnIjyVBZLUB5Lxm8puyq8hH8B_E\
  5LNC-1oc8j-tDy98UvRTTiYvZvs87cGCFxg0LijNhg7CE3g9piNqB6DzMgA9MHSOw\
  cElVtfKdYfo4H3OHZXsSmEQ",
  "e": "AQAB",
  "qi": "jRAqfYi_tKCjhP9eM0N2XaRlNeoYCTx06GlSLD8d0zc4ZZuEePY10LMGWI\
  6Y_JC0CvvvQYhNa9sAj4hFjIVLsWeTplVVUezGO1ofLW4kYWVpnMpHgAY1pRM4kyz\
  o1p3MKYY8DE1BA4KqhSOfhdGs6Ov3Dfj0migZeE7Fu7yc7Fc",
  "dp": "otDolkxtJ7Sk8gmRJqZCGx6GAvlGznWJfibXPv6xgUAl-G83dD84YgcNGn\
  oeMxRzEekfDtT5LVMRPF4_AoucsqPqHDyOdfb-dlGBYfOBVxj6w-xF5HE0lV_4J-H\
  rI63Od9fTSn4lY5d1JjyCVJIcnBEAyiD6EUZbUBh23vDzRcE",
  "dq": "iZE1S6CpqmBoQDxOsXGQmaeBdhoCqkDSJhEDuS_dLhBq88FQa0UkcE1QvO\
  K3J2Q21VnfDqGBx7SH1hOFOj-cpz45kNluB832ztxDvnHQ9AIA7h_HY_3VD6YPMNR\
  VN4bfSYS3abdLR0Z7jsmInGJ9X0_fA0E2tkZIgXeas5EFU0M",
  "n": "r4tmm3r20Wd_PbqvP1s2-QEtvpuRaV8Yq40gjUR8y2Rjxa6dpG2GXHbPfvM\
  s8ct-Lh1GH45x28Rw3Ry53mm-oAXjyQ86OnDkZ5N8lYbggD4O3w6M6pAvLkhk95An\
  dTrifbIFPNU8PPMO7OyrFAHqgDsznjPFmTOtCEcN2Z1FpWgchwuYLPL-Wokqltd11\
  nqqzi-bJ9cvSKADYdUAAN5WUtzdpiy6LbTgSxP7ociU4Tn0g5I6aDZJ7A8Lzo0KSy\
  ZYoA485mqcO0GVAdVw9lq4aOT9v6d-nb4bnNkQVklLQ3fVAvJm-xdDOp9LCNCN48V\
  2pnDOkFV6-U9nV5oyc6XI2w"
}
</sourcecode>
        </section>
        <section anchor="example-key-ecc-p256" numbered="true" removeInRFC="false" toc="include" pn="section-appendix.b.1.3">
          <name slugifiedName="name-example-ecc-p-256-test-key">Example ECC P-256 Test Key</name>
          <t indent="0" pn="section-appendix.b.1.3-1">The following key is a public and private elliptical curve key pair over the curve P-256, referred
to in this document as <tt>test-key-ecc-p256</tt>. This key is encoded in PEM format, with no encryption.</t>
          <artwork align="left" pn="section-appendix.b.1.3-2">
-----BEGIN PUBLIC KEY-----
MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEqIVYZVLCrPZHGHjP17CTW0/+D9Lf
w0EkjqF7xB4FivAxzic30tMM4GF+hR6Dxh71Z50VGGdldkkDXZCnTNnoXQ==
-----END PUBLIC KEY-----

-----BEGIN EC PRIVATE KEY-----
MHcCAQEEIFKbhfNZfpDsW43+0+JjUr9K+bTeuxopu653+hBaXGA7oAoGCCqGSM49
AwEHoUQDQgAEqIVYZVLCrPZHGHjP17CTW0/+D9Lfw0EkjqF7xB4FivAxzic30tMM
4GF+hR6Dxh71Z50VGGdldkkDXZCnTNnoXQ==
-----END EC PRIVATE KEY-----
</artwork>
          <t indent="0" pn="section-appendix.b.1.3-3">The same public and private key pair in JWK format:</t>
          <sourcecode type="json" markers="false" pn="section-appendix.b.1.3-4">
{
  "kty": "EC",
  "crv": "P-256",
  "kid": "test-key-ecc-p256",
  "d": "UpuF81l-kOxbjf7T4mNSv0r5tN67Gim7rnf6EFpcYDs",
  "x": "qIVYZVLCrPZHGHjP17CTW0_-D9Lfw0EkjqF7xB4FivA",
  "y": "Mc4nN9LTDOBhfoUeg8Ye9WedFRhnZXZJA12Qp0zZ6F0"
}
</sourcecode>
        </section>
        <section anchor="example-key-ed25519" numbered="true" removeInRFC="false" toc="include" pn="section-appendix.b.1.4">
          <name slugifiedName="name-example-ed25519-test-key">Example Ed25519 Test Key</name>
          <t indent="0" pn="section-appendix.b.1.4-1">The following key is an elliptical curve key over the Edwards curve ed25519, referred to in this document as <tt>test-key-ed25519</tt>. This key is PKCS #8 encoded in PEM format, with no encryption.</t>
          <artwork align="left" pn="section-appendix.b.1.4-2">
-----BEGIN PUBLIC KEY-----
MCowBQYDK2VwAyEAJrQLj5P/89iXES9+vFgrIy29clF9CC/oPPsw3c5D0bs=
-----END PUBLIC KEY-----

-----BEGIN PRIVATE KEY-----
MC4CAQAwBQYDK2VwBCIEIJ+DYvh6SEqVTm50DFtMDoQikTmiCqirVv9mWG9qfSnF
-----END PRIVATE KEY-----
</artwork>
          <t indent="0" pn="section-appendix.b.1.4-3">The same public and private key pair in JWK format:</t>
          <sourcecode type="json" markers="false" pn="section-appendix.b.1.4-4">
{
  "kty": "OKP",
  "crv": "Ed25519",
  "kid": "test-key-ed25519",
  "d": "n4Ni-HpISpVObnQMW0wOhCKROaIKqKtW_2ZYb2p9KcU",
  "x": "JrQLj5P_89iXES9-vFgrIy29clF9CC_oPPsw3c5D0bs"
}
</sourcecode>
        </section>
        <section anchor="example-shared-secret" numbered="true" removeInRFC="false" toc="include" pn="section-appendix.b.1.5">
          <name slugifiedName="name-example-shared-secret">Example Shared Secret</name>
          <t indent="0" pn="section-appendix.b.1.5-1">The following shared secret is 64 randomly generated bytes encoded in Base64,
referred to in this document as <tt>test-shared-secret</tt>:</t>
          <artwork align="left" pn="section-appendix.b.1.5-2">
NOTE: '\' line wrapping per RFC 8792

uzvJfB4u3N0Jy4T7NZ75MDVcr8zSTInedJtkgcu46YW4XByzNJjxBdtjUkdJPBt\
  bmHhIDi6pcl8jsasjlTMtDQ==
</artwork>
        </section>
      </section>
      <section anchor="test-cases" numbered="true" removeInRFC="false" toc="include" pn="section-appendix.b.2">
        <name slugifiedName="name-test-cases">Test Cases</name>
        <t indent="0" pn="section-appendix.b.2-1">This section provides non-normative examples that may be used as test cases to validate implementation correctness. These examples are based on the following HTTP messages:</t>
        <t indent="0" pn="section-appendix.b.2-2">For requests, this <tt>test-request</tt> message is used:</t>
        <sourcecode type="http-message" markers="false" pn="section-appendix.b.2-3">
NOTE: '\' line wrapping per RFC 8792

POST /foo?param=Value&amp;Pet=dog HTTP/1.1
Host: example.com
Date: Tue, 20 Apr 2021 02:07:55 GMT
Content-Type: application/json
Content-Digest: sha-512=:WZDPaVn/7XgHaAy8pmojAkGWoRx2UFChF41A2svX+T\
  aPm+AbwAgBWnrIiYllu7BNNyealdVLvRwEmTHWXvJwew==:
Content-Length: 18

{"hello": "world"}
</sourcecode>
        <t indent="0" pn="section-appendix.b.2-4">For responses, this <tt>test-response</tt> message is used:</t>
        <sourcecode type="http-message" markers="false" pn="section-appendix.b.2-5">
NOTE: '\' line wrapping per RFC 8792

HTTP/1.1 200 OK
Date: Tue, 20 Apr 2021 02:07:56 GMT
Content-Type: application/json
Content-Digest: sha-512=:mEWXIS7MaLRuGgxOBdODa3xqM1XdEvxoYhvlCFJ41Q\
  JgJc4GTsPp29l5oGX69wWdXymyU0rjJuahq4l5aGgfLQ==:
Content-Length: 23

{"message": "good dog"}
</sourcecode>
        <section anchor="minimal-signature-using-rsa-pss-sha512" numbered="true" removeInRFC="false" toc="include" pn="section-appendix.b.2.1">
          <name slugifiedName="name-minimal-signature-using-rsa">Minimal Signature Using rsa-pss-sha512</name>
          <t indent="0" pn="section-appendix.b.2.1-1">This example presents a minimal signature using the <tt>rsa-pss-sha512</tt> algorithm over <tt>test-request</tt>, covering none
of the components of the HTTP message but providing a timestamped signature proof of possession of the key with a signer-provided nonce.</t>
          <t indent="0" pn="section-appendix.b.2.1-2">The corresponding signature base is:</t>
          <artwork align="left" pn="section-appendix.b.2.1-3">
NOTE: '\' line wrapping per RFC 8792

"@signature-params": ();created=1618884473;keyid="test-key-rsa-pss"\
  ;nonce="b3k2pp5k7z-50gnwp.yemd"
</artwork>
          <t indent="0" pn="section-appendix.b.2.1-4">This results in the following Signature-Input and Signature header fields being added to the message under the signature label <tt>sig-b21</tt>:</t>
          <sourcecode type="http-message" markers="false" pn="section-appendix.b.2.1-5">
NOTE: '\' line wrapping per RFC 8792

Signature-Input: sig-b21=();created=1618884473\
  ;keyid="test-key-rsa-pss";nonce="b3k2pp5k7z-50gnwp.yemd"
Signature: sig-b21=:d2pmTvmbncD3xQm8E9ZV2828BjQWGgiwAaw5bAkgibUopem\
  LJcWDy/lkbbHAve4cRAtx31Iq786U7it++wgGxbtRxf8Udx7zFZsckzXaJMkA7ChG\
  52eSkFxykJeNqsrWH5S+oxNFlD4dzVuwe8DhTSja8xxbR/Z2cOGdCbzR72rgFWhzx\
  2VjBqJzsPLMIQKhO4DGezXehhWwE56YCE+O6c0mKZsfxVrogUvA4HELjVKWmAvtl6\
  UnCh8jYzuVG5WSb/QEVPnP5TmcAnLH1g+s++v6d4s8m0gCw1fV5/SITLq9mhho8K3\
  +7EPYTU8IU1bLhdxO5Nyt8C8ssinQ98Xw9Q==:
</sourcecode>
          <t indent="0" pn="section-appendix.b.2.1-6">Note that since the covered components list is empty, this signature could be applied by an attacker to an unrelated HTTP message. In this example, the <tt>nonce</tt> parameter is included to prevent the same signature from being replayed more than once, but if an attacker intercepts the signature and prevents its delivery to the verifier, the attacker could apply this signature to another message. Therefore, the use of an empty covered components set is discouraged. See <xref target="security-coverage" format="default" sectionFormat="of" derivedContent="Section 7.2.1"/> for more discussion.</t>
          <t indent="0" pn="section-appendix.b.2.1-7">Note that the RSA-PSS algorithm in use here is non-deterministic, meaning that a different signature value will be created every time the algorithm is run. The signature value provided here can be validated against the given keys, but newly generated signature values are not expected to match the example. See <xref target="security-nondeterministic" format="default" sectionFormat="of" derivedContent="Section 7.3.5"/>.</t>
        </section>
        <section anchor="selective-covered-components-using-rsa-pss-sha512" numbered="true" removeInRFC="false" toc="include" pn="section-appendix.b.2.2">
          <name slugifiedName="name-selective-covered-component">Selective Covered Components Using rsa-pss-sha512</name>
          <t indent="0" pn="section-appendix.b.2.2-1">This example covers additional components (the authority, the Content-Digest header field, and a single named query parameter) in <tt>test-request</tt> using the <tt>rsa-pss-sha512</tt> algorithm. This example also adds a <tt>tag</tt> parameter with the application-specific value of <tt>header-example</tt>.</t>
          <t indent="0" pn="section-appendix.b.2.2-2">The corresponding signature base is:</t>
          <artwork align="left" pn="section-appendix.b.2.2-3">
NOTE: '\' line wrapping per RFC 8792

"@authority": example.com
"content-digest": sha-512=:WZDPaVn/7XgHaAy8pmojAkGWoRx2UFChF41A2svX\
  +TaPm+AbwAgBWnrIiYllu7BNNyealdVLvRwEmTHWXvJwew==:
"@query-param";name="Pet": dog
"@signature-params": ("@authority" "content-digest" \
  "@query-param";name="Pet")\
  ;created=1618884473;keyid="test-key-rsa-pss"\
  ;tag="header-example"
</artwork>
          <t indent="0" pn="section-appendix.b.2.2-4">This results in the following Signature-Input and Signature header fields being added to the message under the label <tt>sig-b22</tt>:</t>
          <sourcecode type="http-message" markers="false" pn="section-appendix.b.2.2-5">
NOTE: '\' line wrapping per RFC 8792

Signature-Input: sig-b22=("@authority" "content-digest" \
  "@query-param";name="Pet");created=1618884473\
  ;keyid="test-key-rsa-pss";tag="header-example"
Signature: sig-b22=:LjbtqUbfmvjj5C5kr1Ugj4PmLYvx9wVjZvD9GsTT4F7GrcQ\
  EdJzgI9qHxICagShLRiLMlAJjtq6N4CDfKtjvuJyE5qH7KT8UCMkSowOB4+ECxCmT\
  8rtAmj/0PIXxi0A0nxKyB09RNrCQibbUjsLS/2YyFYXEu4TRJQzRw1rLEuEfY17SA\
  RYhpTlaqwZVtR8NV7+4UKkjqpcAoFqWFQh62s7Cl+H2fjBSpqfZUJcsIk4N6wiKYd\
  4je2U/lankenQ99PZfB4jY3I5rSV2DSBVkSFsURIjYErOs0tFTQosMTAoxk//0RoK\
  UqiYY8Bh0aaUEb0rQl3/XaVe4bXTugEjHSw==:
</sourcecode>
          <t indent="0" pn="section-appendix.b.2.2-6">Note that the RSA-PSS algorithm in use here is non-deterministic, meaning that a different signature value will be created every time the algorithm is run. The signature value provided here can be validated against the given keys, but newly generated signature values are not expected to match the example. See <xref target="security-nondeterministic" format="default" sectionFormat="of" derivedContent="Section 7.3.5"/>.</t>
        </section>
        <section anchor="full-coverage-using-rsa-pss-sha512" numbered="true" removeInRFC="false" toc="include" pn="section-appendix.b.2.3">
          <name slugifiedName="name-full-coverage-using-rsa-pss">Full Coverage Using rsa-pss-sha512</name>
          <t indent="0" pn="section-appendix.b.2.3-1">This example covers all applicable message components in <tt>test-request</tt> (including the content type and length) plus many derived components, again using the <tt>rsa-pss-sha512</tt> algorithm. Note that the Host header field is not covered because the <tt>@authority</tt> derived component is included instead.</t>
          <t indent="0" pn="section-appendix.b.2.3-2">The corresponding signature base is:</t>
          <artwork align="left" pn="section-appendix.b.2.3-3">
NOTE: '\' line wrapping per RFC 8792

"date": Tue, 20 Apr 2021 02:07:55 GMT
"@method": POST
"@path": /foo
"@query": ?param=Value&amp;Pet=dog
"@authority": example.com
"content-type": application/json
"content-digest": sha-512=:WZDPaVn/7XgHaAy8pmojAkGWoRx2UFChF41A2svX\
  +TaPm+AbwAgBWnrIiYllu7BNNyealdVLvRwEmTHWXvJwew==:
"content-length": 18
"@signature-params": ("date" "@method" "@path" "@query" \
  "@authority" "content-type" "content-digest" "content-length")\
  ;created=1618884473;keyid="test-key-rsa-pss"
</artwork>
          <t indent="0" pn="section-appendix.b.2.3-4">This results in the following Signature-Input and Signature header fields being added to the message under the label <tt>sig-b23</tt>:</t>
          <sourcecode type="http-message" markers="false" pn="section-appendix.b.2.3-5">
NOTE: '\' line wrapping per RFC 8792

Signature-Input: sig-b23=("date" "@method" "@path" "@query" \
  "@authority" "content-type" "content-digest" "content-length")\
  ;created=1618884473;keyid="test-key-rsa-pss"
Signature: sig-b23=:bbN8oArOxYoyylQQUU6QYwrTuaxLwjAC9fbY2F6SVWvh0yB\
  iMIRGOnMYwZ/5MR6fb0Kh1rIRASVxFkeGt683+qRpRRU5p2voTp768ZrCUb38K0fU\
  xN0O0iC59DzYx8DFll5GmydPxSmme9v6ULbMFkl+V5B1TP/yPViV7KsLNmvKiLJH1\
  pFkh/aYA2HXXZzNBXmIkoQoLd7YfW91kE9o/CCoC1xMy7JA1ipwvKvfrs65ldmlu9\
  bpG6A9BmzhuzF8Eim5f8ui9eH8LZH896+QIF61ka39VBrohr9iyMUJpvRX2Zbhl5Z\
  JzSRxpJyoEZAFL2FUo5fTIztsDZKEgM4cUA==:
</sourcecode>
          <t indent="0" pn="section-appendix.b.2.3-6">Note in this example that the value of the Date header field and the value of the <tt>created</tt> signature parameter need not be the same. This is due to the fact that the Date header field is added when creating the HTTP message and the <tt>created</tt> parameter is populated when creating the signature over that message, and these two times could vary. If the Date header field is covered by the signature, it is up to the verifier to determine whether its value has to match that of the <tt>created</tt> parameter or not. See <xref target="security-not-fields" format="default" sectionFormat="of" derivedContent="Section 7.2.4"/> for more discussion.</t>
          <t indent="0" pn="section-appendix.b.2.3-7">Note that the RSA-PSS algorithm in use here is non-deterministic, meaning that a different signature value will be created every time the algorithm is run. The signature value provided here can be validated against the given keys, but newly generated signature values are not expected to match the example. See <xref target="security-nondeterministic" format="default" sectionFormat="of" derivedContent="Section 7.3.5"/>.</t>
        </section>
        <section anchor="signing-a-response-using-ecdsa-p256-sha256" numbered="true" removeInRFC="false" toc="include" pn="section-appendix.b.2.4">
          <name slugifiedName="name-signing-a-response-using-ec">Signing a Response Using ecdsa-p256-sha256</name>
          <t indent="0" pn="section-appendix.b.2.4-1">This example covers portions of the <tt>test-response</tt> message using the <tt>ecdsa-p256-sha256</tt> algorithm
and the key <tt>test-key-ecc-p256</tt>.</t>
          <t indent="0" pn="section-appendix.b.2.4-2">The corresponding signature base is:</t>
          <artwork align="left" pn="section-appendix.b.2.4-3">
NOTE: '\' line wrapping per RFC 8792

"@status": 200
"content-type": application/json
"content-digest": sha-512=:mEWXIS7MaLRuGgxOBdODa3xqM1XdEvxoYhvlCFJ4\
  1QJgJc4GTsPp29l5oGX69wWdXymyU0rjJuahq4l5aGgfLQ==:
"content-length": 23
"@signature-params": ("@status" "content-type" "content-digest" \
  "content-length");created=1618884473;keyid="test-key-ecc-p256"
</artwork>
          <t indent="0" pn="section-appendix.b.2.4-4">This results in the following Signature-Input and Signature header fields being added to the message under the label <tt>sig-b24</tt>:</t>
          <sourcecode type="http-message" markers="false" pn="section-appendix.b.2.4-5">
NOTE: '\' line wrapping per RFC 8792

Signature-Input: sig-b24=("@status" "content-type" \
  "content-digest" "content-length");created=1618884473\
  ;keyid="test-key-ecc-p256"
Signature: sig-b24=:wNmSUAhwb5LxtOtOpNa6W5xj067m5hFrj0XQ4fvpaCLx0NK\
  ocgPquLgyahnzDnDAUy5eCdlYUEkLIj+32oiasw==:
</sourcecode>
          <t indent="0" pn="section-appendix.b.2.4-6">Note that the ECDSA signature algorithm in use here is non-deterministic, meaning that a different signature value will be created every time the algorithm is run. The signature value provided here can be validated against the given keys, but newly generated signature values are not expected to match the example. See <xref target="security-nondeterministic" format="default" sectionFormat="of" derivedContent="Section 7.3.5"/>.</t>
        </section>
        <section anchor="signing-a-request-using-hmac-sha256" numbered="true" removeInRFC="false" toc="include" pn="section-appendix.b.2.5">
          <name slugifiedName="name-signing-a-request-using-hma">Signing a Request Using hmac-sha256</name>
          <t indent="0" pn="section-appendix.b.2.5-1">This example covers portions of the <tt>test-request</tt> message using the <tt>hmac-sha256</tt> algorithm and the
secret <tt>test-shared-secret</tt>.</t>
          <t indent="0" pn="section-appendix.b.2.5-2">The corresponding signature base is:</t>
          <artwork align="left" pn="section-appendix.b.2.5-3">
NOTE: '\' line wrapping per RFC 8792

"date": Tue, 20 Apr 2021 02:07:55 GMT
"@authority": example.com
"content-type": application/json
"@signature-params": ("date" "@authority" "content-type")\
  ;created=1618884473;keyid="test-shared-secret"
</artwork>
          <t indent="0" pn="section-appendix.b.2.5-4">This results in the following Signature-Input and Signature header fields being added to the message under the label <tt>sig-b25</tt>:</t>
          <sourcecode type="http-message" markers="false" pn="section-appendix.b.2.5-5">
NOTE: '\' line wrapping per RFC 8792

Signature-Input: sig-b25=("date" "@authority" "content-type")\
  ;created=1618884473;keyid="test-shared-secret"
Signature: sig-b25=:pxcQw6G3AjtMBQjwo8XzkZf/bws5LelbaMk5rGIGtE8=:
</sourcecode>
          <t indent="0" pn="section-appendix.b.2.5-6">Before using symmetric signatures in practice, see the discussion regarding security trade-offs in <xref target="security-symmetric" format="default" sectionFormat="of" derivedContent="Section 7.3.3"/>.</t>
        </section>
        <section anchor="signing-a-request-using-ed25519" numbered="true" removeInRFC="false" toc="include" pn="section-appendix.b.2.6">
          <name slugifiedName="name-signing-a-request-using-ed2">Signing a Request Using ed25519</name>
          <t indent="0" pn="section-appendix.b.2.6-1">This example covers portions of the <tt>test-request</tt> message using the <tt>Ed25519</tt> algorithm
and the key <tt>test-key-ed25519</tt>.</t>
          <t indent="0" pn="section-appendix.b.2.6-2">The corresponding signature base is:</t>
          <artwork align="left" pn="section-appendix.b.2.6-3">
NOTE: '\' line wrapping per RFC 8792

"date": Tue, 20 Apr 2021 02:07:55 GMT
"@method": POST
"@path": /foo
"@authority": example.com
"content-type": application/json
"content-length": 18
"@signature-params": ("date" "@method" "@path" "@authority" \
  "content-type" "content-length");created=1618884473\
  ;keyid="test-key-ed25519"
</artwork>
          <t indent="0" pn="section-appendix.b.2.6-4">This results in the following Signature-Input and Signature header fields being added to the message under the label <tt>sig-b26</tt>:</t>
          <sourcecode type="http-message" markers="false" pn="section-appendix.b.2.6-5">
NOTE: '\' line wrapping per RFC 8792

Signature-Input: sig-b26=("date" "@method" "@path" "@authority" \
  "content-type" "content-length");created=1618884473\
  ;keyid="test-key-ed25519"
Signature: sig-b26=:wqcAqbmYJ2ji2glfAMaRy4gruYYnx2nEFN2HN6jrnDnQCK1\
  u02Gb04v9EDgwUPiu4A0w6vuQv5lIp5WPpBKRCw==:
</sourcecode>
        </section>
      </section>
      <section anchor="tls-terminating-proxies" numbered="true" removeInRFC="false" toc="include" pn="section-appendix.b.3">
        <name slugifiedName="name-tls-terminating-proxies">TLS-Terminating Proxies</name>
        <t indent="0" pn="section-appendix.b.3-1">In this example, there is a TLS-terminating reverse proxy sitting in front of the resource. The client does not sign the request but instead uses mutual TLS to make its call. The terminating proxy validates the TLS stream and injects a Client-Cert header field according to <xref target="RFC9440" format="default" sectionFormat="of" derivedContent="CLIENT-CERT"/>, and then applies a signature to this field. By signing this header field, a reverse proxy not only can attest to its own validation of the initial request's TLS parameters but can also authenticate itself to the backend system independently of the client's actions.</t>
        <t indent="0" pn="section-appendix.b.3-2">The client makes the following request to the TLS-terminating proxy using mutual TLS:</t>
        <sourcecode type="http-message" markers="false" pn="section-appendix.b.3-3">
POST /foo?param=Value&amp;Pet=dog HTTP/1.1
Host: example.com
Date: Tue, 20 Apr 2021 02:07:55 GMT
Content-Type: application/json
Content-Length: 18

{"hello": "world"}
</sourcecode>
        <t indent="0" pn="section-appendix.b.3-4">The proxy processes the TLS connection and extracts the client's TLS certificate to a Client-Cert header field and passes it along to the internal service hosted at <tt>service.internal.example</tt>. This results in the following unsigned request:</t>
        <sourcecode type="http-message" markers="false" pn="section-appendix.b.3-5">
NOTE: '\' line wrapping per RFC 8792

POST /foo?param=Value&amp;Pet=dog HTTP/1.1
Host: service.internal.example
Date: Tue, 20 Apr 2021 02:07:55 GMT
Content-Type: application/json
Content-Length: 18
Client-Cert: :MIIBqDCCAU6gAwIBAgIBBzAKBggqhkjOPQQDAjA6MRswGQYDVQQKD\
  BJMZXQncyBBdXRoZW50aWNhdGUxGzAZBgNVBAMMEkxBIEludGVybWVkaWF0ZSBDQT\
  AeFw0yMDAxMTQyMjU1MzNaFw0yMTAxMjMyMjU1MzNaMA0xCzAJBgNVBAMMAkJDMFk\
  wEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAE8YnXXfaUgmnMtOXU/IncWalRhebrXmck\
  C8vdgJ1p5Be5F/3YC8OthxM4+k1M6aEAEFcGzkJiNy6J84y7uzo9M6NyMHAwCQYDV\
  R0TBAIwADAfBgNVHSMEGDAWgBRm3WjLa38lbEYCuiCPct0ZaSED2DAOBgNVHQ8BAf\
  8EBAMCBsAwEwYDVR0lBAwwCgYIKwYBBQUHAwIwHQYDVR0RAQH/BBMwEYEPYmRjQGV\
  4YW1wbGUuY29tMAoGCCqGSM49BAMCA0gAMEUCIBHda/r1vaL6G3VliL4/Di6YK0Q6\
  bMjeSkC3dFCOOB8TAiEAx/kHSB4urmiZ0NX5r5XarmPk0wmuydBVoU4hBVZ1yhk=:

{"hello": "world"}
</sourcecode>
        <t indent="0" pn="section-appendix.b.3-6">Without a signature, the internal service would need to trust that the incoming connection has the right information. By signing the Client-Cert header field and other portions of the internal request, the internal service can be assured that the correct party, the trusted proxy, has processed the request and presented it to the correct service. The proxy's signature base consists of the following:</t>
        <artwork align="left" pn="section-appendix.b.3-7">
NOTE: '\' line wrapping per RFC 8792

"@path": /foo
"@query": ?param=Value&amp;Pet=dog
"@method": POST
"@authority": service.internal.example
"client-cert": :MIIBqDCCAU6gAwIBAgIBBzAKBggqhkjOPQQDAjA6MRswGQYDVQQ\
  KDBJMZXQncyBBdXRoZW50aWNhdGUxGzAZBgNVBAMMEkxBIEludGVybWVkaWF0ZSBD\
  QTAeFw0yMDAxMTQyMjU1MzNaFw0yMTAxMjMyMjU1MzNaMA0xCzAJBgNVBAMMAkJDM\
  FkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAE8YnXXfaUgmnMtOXU/IncWalRhebrXm\
  ckC8vdgJ1p5Be5F/3YC8OthxM4+k1M6aEAEFcGzkJiNy6J84y7uzo9M6NyMHAwCQY\
  DVR0TBAIwADAfBgNVHSMEGDAWgBRm3WjLa38lbEYCuiCPct0ZaSED2DAOBgNVHQ8B\
  Af8EBAMCBsAwEwYDVR0lBAwwCgYIKwYBBQUHAwIwHQYDVR0RAQH/BBMwEYEPYmRjQ\
  GV4YW1wbGUuY29tMAoGCCqGSM49BAMCA0gAMEUCIBHda/r1vaL6G3VliL4/Di6YK0\
  Q6bMjeSkC3dFCOOB8TAiEAx/kHSB4urmiZ0NX5r5XarmPk0wmuydBVoU4hBVZ1yhk=:
"@signature-params": ("@path" "@query" "@method" "@authority" \
  "client-cert");created=1618884473;keyid="test-key-ecc-p256"
</artwork>
        <t indent="0" pn="section-appendix.b.3-8">This results in the following signature:</t>
        <artwork align="left" pn="section-appendix.b.3-9">
NOTE: '\' line wrapping per RFC 8792

xVMHVpawaAC/0SbHrKRs9i8I3eOs5RtTMGCWXm/9nvZzoHsIg6Mce9315T6xoklyy0y\
zhD9ah4JHRwMLOgmizw==
</artwork>
        <t indent="0" pn="section-appendix.b.3-10">which results in the following signed request sent from the proxy to the internal service with the proxy's signature under the label <tt>ttrp</tt>:</t>
        <artwork align="left" pn="section-appendix.b.3-11">
NOTE: '\' line wrapping per RFC 8792

POST /foo?param=Value&amp;Pet=dog HTTP/1.1
Host: service.internal.example
Date: Tue, 20 Apr 2021 02:07:55 GMT
Content-Type: application/json
Content-Length: 18
Client-Cert: :MIIBqDCCAU6gAwIBAgIBBzAKBggqhkjOPQQDAjA6MRswGQYDVQQKD\
  BJMZXQncyBBdXRoZW50aWNhdGUxGzAZBgNVBAMMEkxBIEludGVybWVkaWF0ZSBDQT\
  AeFw0yMDAxMTQyMjU1MzNaFw0yMTAxMjMyMjU1MzNaMA0xCzAJBgNVBAMMAkJDMFk\
  wEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAE8YnXXfaUgmnMtOXU/IncWalRhebrXmck\
  C8vdgJ1p5Be5F/3YC8OthxM4+k1M6aEAEFcGzkJiNy6J84y7uzo9M6NyMHAwCQYDV\
  R0TBAIwADAfBgNVHSMEGDAWgBRm3WjLa38lbEYCuiCPct0ZaSED2DAOBgNVHQ8BAf\
  8EBAMCBsAwEwYDVR0lBAwwCgYIKwYBBQUHAwIwHQYDVR0RAQH/BBMwEYEPYmRjQGV\
  4YW1wbGUuY29tMAoGCCqGSM49BAMCA0gAMEUCIBHda/r1vaL6G3VliL4/Di6YK0Q6\
  bMjeSkC3dFCOOB8TAiEAx/kHSB4urmiZ0NX5r5XarmPk0wmuydBVoU4hBVZ1yhk=:
Signature-Input: ttrp=("@path" "@query" "@method" "@authority" \
  "client-cert");created=1618884473;keyid="test-key-ecc-p256"
Signature: ttrp=:xVMHVpawaAC/0SbHrKRs9i8I3eOs5RtTMGCWXm/9nvZzoHsIg6\
  Mce9315T6xoklyy0yzhD9ah4JHRwMLOgmizw==:

{"hello": "world"}
</artwork>
        <t indent="0" pn="section-appendix.b.3-12">The internal service can validate the proxy's signature and therefore be able to trust that the client's certificate has been appropriately processed.</t>
      </section>
      <section anchor="example-transform" numbered="true" removeInRFC="false" toc="include" pn="section-appendix.b.4">
        <name slugifiedName="name-http-message-transformations">HTTP Message Transformations</name>
        <t indent="0" pn="section-appendix.b.4-1">HTTP allows intermediaries and applications to transform an HTTP message without affecting the semantics of the message itself. HTTP message signatures are designed to be robust against many of these transformations in different circumstances.</t>
        <t indent="0" pn="section-appendix.b.4-2">For example, the following HTTP request message has been signed using the <tt>Ed25519</tt> algorithm
and the key <tt>test-key-ed25519</tt>:</t>
        <sourcecode type="http-message" markers="false" pn="section-appendix.b.4-3">
NOTE: '\' line wrapping per RFC 8792

GET /demo?name1=Value1&amp;Name2=value2 HTTP/1.1
Host: example.org
Date: Fri, 15 Jul 2022 14:24:55 GMT
Accept: application/json
Accept: */*
Signature-Input: transform=("@method" "@path" "@authority" \
  "accept");created=1618884473;keyid="test-key-ed25519"
Signature: transform=:ZT1kooQsEHpZ0I1IjCqtQppOmIqlJPeo7DHR3SoMn0s5J\
  Z1eRGS0A+vyYP9t/LXlh5QMFFQ6cpLt2m0pmj3NDA==:
</sourcecode>
        <t indent="0" pn="section-appendix.b.4-4">The signature base string for this message is:</t>
        <artwork align="left" pn="section-appendix.b.4-5">
"@method": GET
"@path": /demo
"@authority": example.org
"accept": application/json, */*
"@signature-params": ("@method" "@path" "@authority" "accept")\
  ;created=1618884473;keyid="test-key-ed25519"
</artwork>
        <t indent="0" pn="section-appendix.b.4-6">The following message has been altered by adding the Accept-Language header field as well as adding a query parameter. However, since neither the Accept-Language header field nor the query is covered by the signature, the same signature is still valid:</t>
        <sourcecode type="http-message" markers="false" pn="section-appendix.b.4-7">
NOTE: '\' line wrapping per RFC 8792

GET /demo?name1=Value1&amp;Name2=value2&amp;param=added HTTP/1.1
Host: example.org
Date: Fri, 15 Jul 2022 14:24:55 GMT
Accept: application/json
Accept: */*
Accept-Language: en-US,en;q=0.5
Signature-Input: transform=("@method" "@path" "@authority" \
  "accept");created=1618884473;keyid="test-key-ed25519"
Signature: transform=:ZT1kooQsEHpZ0I1IjCqtQppOmIqlJPeo7DHR3SoMn0s5J\
  Z1eRGS0A+vyYP9t/LXlh5QMFFQ6cpLt2m0pmj3NDA==:
</sourcecode>
        <t indent="0" pn="section-appendix.b.4-8">The following message has been altered by removing the Date header field, adding a Referer header field, and collapsing the Accept header field into a single line. The Date and Referer header fields are not covered by the signature, and the collapsing of the Accept header field is an allowed transformation that is already accounted for by the canonicalization algorithm for HTTP field values. The same signature is still valid:</t>
        <sourcecode type="http-message" markers="false" pn="section-appendix.b.4-9">
NOTE: '\' line wrapping per RFC 8792

GET /demo?name1=Value1&amp;Name2=value2 HTTP/1.1
Host: example.org
Referer: https://developer.example.org/demo
Accept: application/json, */*
Signature-Input: transform=("@method" "@path" "@authority" \
  "accept");created=1618884473;keyid="test-key-ed25519"
Signature: transform=:ZT1kooQsEHpZ0I1IjCqtQppOmIqlJPeo7DHR3SoMn0s5J\
  Z1eRGS0A+vyYP9t/LXlh5QMFFQ6cpLt2m0pmj3NDA==:
</sourcecode>
        <t indent="0" pn="section-appendix.b.4-10">The following message has been altered by reordering the field values of the original message but not reordering the individual Accept header fields. The same signature is still valid:</t>
        <sourcecode type="http-message" markers="false" pn="section-appendix.b.4-11">
NOTE: '\' line wrapping per RFC 8792

GET /demo?name1=Value1&amp;Name2=value2 HTTP/1.1
Accept: application/json
Accept: */*
Date: Fri, 15 Jul 2022 14:24:55 GMT
Host: example.org
Signature-Input: transform=("@method" "@path" "@authority" \
  "accept");created=1618884473;keyid="test-key-ed25519"
Signature: transform=:ZT1kooQsEHpZ0I1IjCqtQppOmIqlJPeo7DHR3SoMn0s5J\
  Z1eRGS0A+vyYP9t/LXlh5QMFFQ6cpLt2m0pmj3NDA==:
</sourcecode>
        <t indent="0" pn="section-appendix.b.4-12">The following message has been altered by changing the method to POST and the authority to "example.com" (inside the Host header field). Since both the method and authority are covered by the signature, the same signature is NOT still valid:</t>
        <sourcecode type="http-message" markers="false" pn="section-appendix.b.4-13">
NOTE: '\' line wrapping per RFC 8792

POST /demo?name1=Value1&amp;Name2=value2 HTTP/1.1
Host: example.com
Date: Fri, 15 Jul 2022 14:24:55 GMT
Accept: application/json
Accept: */*
Signature-Input: transform=("@method" "@path" "@authority" \
  "accept");created=1618884473;keyid="test-key-ed25519"
Signature: transform=:ZT1kooQsEHpZ0I1IjCqtQppOmIqlJPeo7DHR3SoMn0s5J\
  Z1eRGS0A+vyYP9t/LXlh5QMFFQ6cpLt2m0pmj3NDA==:
</sourcecode>
        <t indent="0" pn="section-appendix.b.4-14">The following message has been altered by changing the order of the two instances of the Accept header field. Since the order of fields with the same name is semantically significant in HTTP, this changes the value used in the signature base, and the same signature is NOT still valid:</t>
        <sourcecode type="http-message" markers="false" pn="section-appendix.b.4-15">
NOTE: '\' line wrapping per RFC 8792

GET /demo?name1=Value1&amp;Name2=value2 HTTP/1.1
Host: example.org
Date: Fri, 15 Jul 2022 14:24:55 GMT
Accept: */*
Accept: application/json
Signature-Input: transform=("@method" "@path" "@authority" \
  "accept");created=1618884473;keyid="test-key-ed25519"
Signature: transform=:ZT1kooQsEHpZ0I1IjCqtQppOmIqlJPeo7DHR3SoMn0s5J\
  Z1eRGS0A+vyYP9t/LXlh5QMFFQ6cpLt2m0pmj3NDA==:
</sourcecode>
      </section>
    </section>
    <section numbered="false" anchor="acknowledgements" removeInRFC="false" toc="include" pn="section-appendix.c">
      <name slugifiedName="name-acknowledgements">Acknowledgements</name>
      <t indent="0" pn="section-appendix.c-1">This specification was initially based on <xref target="I-D.cavage-http-signatures" format="default" sectionFormat="of" derivedContent="SIGNING-HTTP-MESSAGES"/>. The editors would like to thank the authors of <xref target="I-D.cavage-http-signatures" format="default" sectionFormat="of" derivedContent="SIGNING-HTTP-MESSAGES"/> -- <contact fullname="Mark Cavage"/> and <contact fullname="Manu Sporny"/> -- for their work on that Internet-Draft and their continuing contributions. This specification also includes contributions from <xref target="SIGNING-HTTP-REQS-OAUTH" format="default" sectionFormat="of" derivedContent="SIGNING-HTTP-REQS-OAUTH"/> and other similar efforts.</t>
      <t indent="0" pn="section-appendix.c-2">The editors would also like to thank the following individuals (listed in alphabetical order) for feedback, insight, and implementation of this document and its predecessors:
<contact fullname="Mark Adamcin"/>,
<contact fullname="Mark Allen"/>,
<contact fullname="Paul Annesley"/>,
<contact fullname="Karl Böhlmark"/>,
<contact fullname="Stéphane Bortzmeyer"/>,
<contact fullname="Sarven Capadisli"/>,
<contact fullname="Liam Dennehy"/>,
<contact fullname="Stephen Farrell"/>,
<contact fullname="Phillip Hallam-Baker"/>,
<contact fullname="Tyler Ham"/>,
<contact fullname="Eric Holmes"/>,
<contact fullname="Andrey Kislyuk"/>,
<contact fullname="Adam Knight"/>,
<contact fullname="Dave Lehn"/>,
<contact fullname="Ilari Liusvaara"/>,
<contact fullname="Dave Longley"/>,
<contact fullname="James H. Manger"/>,
<contact fullname="Kathleen Moriarty"/>,
<contact fullname="Yoav Nir"/>,
<contact fullname="Mark Nottingham"/>,
<contact fullname="Adrian Palmer"/>,
<contact fullname="Lucas Pardue"/>,
<contact fullname="Roberto Polli"/>,
<contact fullname="Julian Reschke"/>,
<contact fullname="Michael Richardson"/>,
<contact fullname="Wojciech Rygielski"/>,
<contact fullname="Rich Salz"/>,
<contact fullname="Adam Scarr"/>,
<contact fullname="Cory J. Slep"/>,
<contact fullname="Dirk Stein"/>,
<contact fullname="Henry Story"/>,
<contact fullname="Lukasz Szewc"/>,
<contact fullname="Chris Webber"/>, and
<contact fullname="Jeffrey Yasskin"/>.</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="A." surname="Backman" fullname="Annabelle Backman" role="editor">
        <organization showOnFrontPage="true">Amazon</organization>
        <address>
          <postal>
            <street>P.O. Box 81226</street>
            <city>Seattle</city>
            <region>WA</region>
            <code>98108-1226</code>
            <country>United States of America</country>
          </postal>
          <email>richanna@amazon.com</email>
          <uri>https://www.amazon.com/</uri>
        </address>
      </author>
      <author initials="J." surname="Richer" fullname="Justin Richer" role="editor">
        <organization showOnFrontPage="true">Bespoke Engineering</organization>
        <address>
          <email>ietf@justin.richer.org</email>
          <uri>https://bspk.io/</uri>
        </address>
      </author>
      <author initials="M." surname="Sporny" fullname="Manu Sporny">
        <organization showOnFrontPage="true">Digital Bazaar</organization>
        <address>
          <postal>
            <street>203 Roanoke Street W.</street>
            <city>Blacksburg</city>
            <region>VA</region>
            <code>24060</code>
            <country>United States of America</country>
          </postal>
          <email>msporny@digitalbazaar.com</email>
        </address>
      </author>
    </section>
  </back>
</rfc>
