<?xml version='1.0' encoding='utf-8'?>
<!DOCTYPE rfc [
  <!ENTITY nbsp    "&#160;">
  <!ENTITY zwsp   "&#8203;">
  <!ENTITY nbhy   "&#8209;">
  <!ENTITY wj     "&#8288;">
]>
<?xml-stylesheet type="text/xsl" href="rfc2629.xslt" ?>
<!-- generated by https://github.com/cabo/kramdown-rfc version 1.7.8 (Ruby 3.2.2) -->
<rfc xmlns:xi="http://www.w3.org/2001/XInclude" ipr="trust200902" docName="draft-ietf-privacypass-auth-scheme-extensions-00" category="std" consensus="true" submissionType="IETF" tocInclude="true" sortRefs="true" symRefs="true" version="3">
  <!-- xml2rfc v2v3 conversion 3.20.1 -->
  <front>
    <title abbrev="PrivateToken Authentication Extensions">The PrivateToken HTTP Authentication Scheme Extensions Parameter</title>
    <seriesInfo name="Internet-Draft" value="draft-ietf-privacypass-auth-scheme-extensions-00"/>
    <author fullname="Scott Hendrickson">
      <organization>Google</organization>
      <address>
        <email>scott@shendrickson.com</email>
      </address>
    </author>
    <author fullname="Christopher A. Wood">
      <organization>Cloudflare, Inc.</organization>
      <address>
        <email>caw@heapingbits.net</email>
      </address>
    </author>
    <date year="2024" month="March" day="31"/>
    <area>Security</area>
    <workgroup>Privacy Pass</workgroup>
    <keyword>token</keyword>
    <abstract>
      <?line 38?>

<t>This document specifies a new parameter for the "PrivateToken" HTTP authentication
scheme. This purpose of this parameter is to carry extensions for Privacy Pass
protocols that support public metadata.</t>
    </abstract>
    <note removeInRFC="true">
      <name>About This Document</name>
      <t>
        The latest revision of this draft can be found at <eref target="https://ietf-wg-privacypass.github.io/draft-ietf-privacypass-extensible-token/draft-ietf-privacypass-extensible-token.html"/>.
        Status information for this document may be found at <eref target="https://datatracker.ietf.org/doc/draft-ietf-privacypass-auth-scheme-extensions/"/>.
      </t>
      <t>
        Discussion of this document takes place on the
        Privacy Pass Working Group mailing list (<eref target="mailto:privacy-pass@ietf.org"/>),
        which is archived at <eref target="https://mailarchive.ietf.org/arch/browse/privacy-pass/"/>.
        Subscribe at <eref target="https://www.ietf.org/mailman/listinfo/privacy-pass/"/>.
      </t>
      <t>Source for this draft and an issue tracker can be found at
        <eref target="https://github.com/ietf-wg-privacypass/draft-ietf-privacypass-extensible-token"/>.</t>
    </note>
  </front>
  <middle>
    <?line 44?>

<section anchor="introduction">
      <name>Introduction</name>
      <t>The primary Token structure in the "PrivateToken" HTTP authentication scheme
<xref target="AUTHSCHEME"/> is composed as follows:</t>
      <artwork><![CDATA[
struct {
    uint16_t token_type;
    uint8_t nonce[32];
    uint8_t challenge_digest[32];
    uint8_t token_key_id[Nid];
    uint8_t authenticator[Nk];
} Token;
]]></artwork>
      <t>Functionally, this structure conveys a single bit of information from the
issuance protocol: whether or not the token is valid (as indicated by a valid
authenticator value). This structure does not admit any additional information
to flow from the issuance protocol, including, for example, public metadata
that is incorporated into the issuance protocol.</t>
      <t>This document specifies a new parameter for the "PrivateToken" HTTP authentication
scheme for carrying extensions. This extensions parameter, otherwise referred to as
public metadata, is cryptographically bound to the Token structure via the Privacy
Pass issuance protocol.</t>
    </section>
    <section anchor="conventions-and-definitions">
      <name>Conventions and Definitions</name>
      <t>The key words "<bcp14>MUST</bcp14>", "<bcp14>MUST NOT</bcp14>", "<bcp14>REQUIRED</bcp14>", "<bcp14>SHALL</bcp14>", "<bcp14>SHALL
NOT</bcp14>", "<bcp14>SHOULD</bcp14>", "<bcp14>SHOULD NOT</bcp14>", "<bcp14>RECOMMENDED</bcp14>", "<bcp14>NOT RECOMMENDED</bcp14>",
"<bcp14>MAY</bcp14>", and "<bcp14>OPTIONAL</bcp14>" in this document are to be interpreted as
described in BCP 14 <xref target="RFC2119"/> <xref target="RFC8174"/> when, and only when, they
appear in all capitals, as shown here.</t>
      <?line -18?>

</section>
    <section anchor="privatetoken-extensions-parameter">
      <name>PrivateToken Extensions Parameter</name>
      <t>As defined in <xref section="2.2" sectionFormat="of" target="AUTHSCHEME"/>, the "PrivateToken" authentication
scheme defines one parameter, "token", which contains the base64url-encoded
Token struct. This document defines a new parameter, "extensions," which contains
the base64url-encoded representation of the following Extensions structure.
This document follows the default padding behavior described in
<xref section="3.2" sectionFormat="of" target="RFC4648"/>, so the base64url value <bcp14>MUST</bcp14> include padding.</t>
      <artwork><![CDATA[
struct {
    ExtensionType extension_type;
    opaque extension_data<0..2^16-1>;
} Extension;

enum {
    reserved(0),
    (65535)
} ExtensionType;

struct {
    Extension extensions<0..2^16-1>;
} Extensions;
]]></artwork>
      <t>The contents of Extensions are a list of Extension values, each of which is a type-length-value
structure whose semantics are determined by the type. The type and length of each
extension are 2-octet integers, in network byte order. The length of the extensions
list is also a 2-octet integer, in network byte order.</t>
      <t>Clients, Issuers, and Origins all agree on the content and encoding of this Extensions
structure, i.e., they agree on the same type-length-value list. The list <bcp14>MUST</bcp14> be ordered
by ExtensionType value, from 0 to 65535. Extension types <bcp14>MAY</bcp14> be repeated. The value of the
Extensions structure is used as-is when verifying the value of the corresponding "token" parameter
in the "PrivateToken" authentication header. As an example, Clients presenting this extension
parameter to origins would use an Authorization header field like the following:</t>
      <artwork><![CDATA[
Authorization: PrivateToken token="abc...", extensions="def..."
]]></artwork>
      <t>Future documents may specify extensions to be included in this structure.
Registration details for these extensions are in <xref target="iana"/>.</t>
      <t>Each Privacy Pass issuance protocol, identified by a token type, specifies the structure
of the PrivateToken value to be used. Extensions are bound to the resulting tokens via the
issuance protocol. In particular, the value of an Extensions structure is provided as
metadata for the issuance protocol. Candidate issuance protocols are specified in
<xref target="PUBLIC-ISSUANCE"/>.</t>
    </section>
    <section anchor="negotiation">
      <name>Extensions Negotiation</name>
      <t>The mechanism Clients and Origins use to determine which set of extensions to provide
for redemption is out of scope for this document.</t>
      <t>In some Privacy Pass deployments, the set
of extensions may be well known to Clients and Origins and thus do not require negotiation.
In other settings, negotiation may be required. However, negotiation can raise privacy
risks, especially if negotiation can be abused by Origins for partitioning Clients and
risking Origin-Client unlinkability. Some of these risks may be mitigated if all Clients
in a given redemption context respond to negotiation in the same manner. However, if
Clients have different observable behavior, e.g., if certain extension use is determined
by user choice, Origins can observe this differential behavior and therefore partition
Clients in a redemption context.</t>
    </section>
    <section anchor="security-considerations">
      <name>Security Considerations</name>
      <t>Privacy considerations for tokens that include additional information are discussed
in <xref section="6.1" sectionFormat="of" target="ARCHITECTURE"/>. Additional
considerations for use of extensions, including those that arise when deciding which
extensions to use, are described in <xref target="negotiation"/>.</t>
    </section>
    <section anchor="iana">
      <name>IANA Considerations</name>
      <t>IANA is requested to create a new "Privacy Pass PrivateToken Extensions" registry
in the "Privacy Pass Parameters" page to list possible extension values and their meaning.
Each extension has a two-byte type, so the maximum possible value is 0xFFFF = 65535.</t>
      <t>Template:</t>
      <ul spacing="normal">
        <li>
          <t>Type: The two-byte extension type</t>
        </li>
        <li>
          <t>Name: Name of the extension</t>
        </li>
        <li>
          <t>Value: Syntax and semantics of the extension</t>
        </li>
        <li>
          <t>Reference: Where this extension and its value are defined</t>
        </li>
        <li>
          <t>Notes: Any notes associated with the entry</t>
        </li>
      </ul>
      <t>New entries in this registry are subject to the Specification Required
registration policy (<xref section="4.6" sectionFormat="comma" target="RFC8126"/>). Designated experts need to
ensure that the extension is sufficiently clearly defined and, importantly,
has a clear description of the privacy implications of using the extension,
framed in the context of partitioning the client anonymity set as described
in <xref section="6.1" sectionFormat="of" target="ARCHITECTURE"/>.</t>
    </section>
  </middle>
  <back>
    <references>
      <name>References</name>
      <references anchor="sec-normative-references">
        <name>Normative References</name>
        <reference anchor="AUTHSCHEME">
          <front>
            <title>The Privacy Pass HTTP Authentication Scheme</title>
            <author fullname="Tommy Pauly" initials="T." surname="Pauly">
              <organization>Apple Inc.</organization>
            </author>
            <author fullname="Steven Valdez" initials="S." surname="Valdez">
              <organization>Google LLC</organization>
            </author>
            <author fullname="Christopher A. Wood" initials="C. A." surname="Wood">
              <organization>Cloudflare</organization>
            </author>
            <date day="23" month="October" year="2023"/>
            <abstract>
              <t>   This document defines an HTTP authentication scheme for Privacy Pass,
   a privacy-preserving authentication mechanism used for authorization.
   The authentication scheme in this document can be used by clients to
   redeem Privacy Pass tokens with an origin.  It can also be used by
   origins to challenge clients to present Privacy Pass tokens.

              </t>
            </abstract>
          </front>
          <seriesInfo name="Internet-Draft" value="draft-ietf-privacypass-auth-scheme-15"/>
        </reference>
        <reference anchor="RFC2119">
          <front>
            <title>Key words for use in RFCs to Indicate Requirement Levels</title>
            <author fullname="S. Bradner" initials="S." surname="Bradner"/>
            <date month="March" year="1997"/>
            <abstract>
              <t>In many standards track documents several words are used to signify the requirements in the specification. These words are often capitalized. This document defines these words as they should be interpreted in IETF documents. This document specifies an Internet Best Current Practices for the Internet Community, and requests discussion and suggestions for improvements.</t>
            </abstract>
          </front>
          <seriesInfo name="BCP" value="14"/>
          <seriesInfo name="RFC" value="2119"/>
          <seriesInfo name="DOI" value="10.17487/RFC2119"/>
        </reference>
        <reference anchor="RFC8174">
          <front>
            <title>Ambiguity of Uppercase vs Lowercase in RFC 2119 Key Words</title>
            <author fullname="B. Leiba" initials="B." surname="Leiba"/>
            <date month="May" year="2017"/>
            <abstract>
              <t>RFC 2119 specifies common key words that may be used in protocol specifications. This document aims to reduce the ambiguity by clarifying that only UPPERCASE usage of the key words have the defined special meanings.</t>
            </abstract>
          </front>
          <seriesInfo name="BCP" value="14"/>
          <seriesInfo name="RFC" value="8174"/>
          <seriesInfo name="DOI" value="10.17487/RFC8174"/>
        </reference>
        <reference anchor="RFC4648">
          <front>
            <title>The Base16, Base32, and Base64 Data Encodings</title>
            <author fullname="S. Josefsson" initials="S." surname="Josefsson"/>
            <date month="October" year="2006"/>
            <abstract>
              <t>This document describes the commonly used base 64, base 32, and base 16 encoding schemes. It also discusses the use of line-feeds in encoded data, use of padding in encoded data, use of non-alphabet characters in encoded data, use of different encoding alphabets, and canonical encodings. [STANDARDS-TRACK]</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="4648"/>
          <seriesInfo name="DOI" value="10.17487/RFC4648"/>
        </reference>
        <reference anchor="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>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>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>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>
      </references>
      <references anchor="sec-informative-references">
        <name>Informative References</name>
        <reference anchor="PUBLIC-ISSUANCE">
          <front>
            <title>Public Metadata Issuance</title>
            <author fullname="Scott Hendrickson" initials="S." surname="Hendrickson">
              <organization>Google</organization>
            </author>
            <author fullname="Christopher A. Wood" initials="C. A." surname="Wood">
              <organization>Cloudflare, Inc.</organization>
            </author>
            <date day="25" month="November" year="2023"/>
            <abstract>
              <t>   This document specifies Privacy Pass issuance protocols that encode
   public information visible to the Client, Attester, Issuer, and
   Origin into each token.

              </t>
            </abstract>
          </front>
          <seriesInfo name="Internet-Draft" value="draft-hendrickson-privacypass-public-metadata-03"/>
        </reference>
        <reference anchor="ARCHITECTURE">
          <front>
            <title>The Privacy Pass Architecture</title>
            <author fullname="Alex Davidson" initials="A." surname="Davidson">
              <organization>LIP</organization>
            </author>
            <author fullname="Jana Iyengar" initials="J." surname="Iyengar">
              <organization>Fastly</organization>
            </author>
            <author fullname="Christopher A. Wood" initials="C. A." surname="Wood">
              <organization>Cloudflare</organization>
            </author>
            <date day="25" month="September" year="2023"/>
            <abstract>
              <t>   This document specifies the Privacy Pass architecture and
   requirements for its constituent protocols used for authorization
   based on privacy-preserving authentication mechanisms.  It describes
   the conceptual model of Privacy Pass and its protocols, its security
   and privacy goals, practical deployment models, and recommendations
   for each deployment model that helps ensure the desired security and
   privacy goals are fulfilled.

              </t>
            </abstract>
          </front>
          <seriesInfo name="Internet-Draft" value="draft-ietf-privacypass-architecture-16"/>
        </reference>
      </references>
    </references>
    <?line 187?>



  </back>
  <!-- ##markdown-source:
H4sIAAAAAAAAA7VZUXPbNhJ+x6/AKS/JjcTGjuvLqU1T1XFqzyROzpav08n0
MhAJSagpggVAyzqP+1vut9wvu28XpEjKyl1fLg+JCAK7i293v91lRqORCCbk
eiwH06WWH525VUFP7Y0u5Nl0+lFOqrDURTCpCsYW8ipd6pWWp3dBFx4LXn5U
Tq100G4g1Gzm9C1E9cTsSGiPDgSW9MK6zVj6kAmR2bSArLHMnJqHkdFhPipJ
VLoplfcjBUkjzxaM9FbM6Plz4avZynh6DJsSAs5Pp29FUa1m2o1FBi1jkWIr
TlR+LIOrtICdL4RyWsHeK51WzoTNQKytu1k4W5XNLdINbuhh643e4GU2FnIk
A11M3OqigmAp9x+QMtoy+AkyTbGQP9I2Wl8pk2O9vtqI7vY9XTaxbkHvFyYs
qxl2MALrRReEr76ATY3HLNcjto7k5Li4D5CzDKH046++2iMvicoSY/+o5D+6
L1mGVT4QgrxmHeEGk6ScV3kevXyV2hDkmS4yZ9Ibbwt+DwxUYf7JwTKWP1q7
yDW/0DVsno5975ftuSS1q8Fj+SdLZ3yw5VI7OUnkT9ZmezSc5LbK5jkiYSjP
izTp6krV+vulViW8NzPBJ4UOQhTWrXD2Fq4Xpph3nsRoNJJq5oNTKTZOl8ZL
xHS1QvhLX+rUzI32UslCr2XZ5I2ECIkU6afNIKaf6iWPiMGfSBZdVq60Xks7
x3F63krEQ7Cw3rmNbBOFFXVjVJTOBpvaHNuXCiZWZWld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