<?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.43 (Ruby 4.0.7) -->
<rfc xmlns:xi="http://www.w3.org/2001/XInclude" ipr="trust200902" docName="draft-mahy-mls-new-framed-content-tbs-02" category="info" consensus="true" submissionType="IETF" tocInclude="true" sortRefs="true" symRefs="true" version="3">
  <!-- xml2rfc v2v3 conversion 3.35.0 -->
  <front>
    <title abbrev="New MLS FramedContentTBS">A more efficient FramedContentTBS structure in Messsaging Layer Security (MLS)</title>
    <seriesInfo name="Internet-Draft" value="draft-mahy-mls-new-framed-content-tbs-02"/>
    <author fullname="Rohan Mahy">
      <organization/>
      <address>
        <email>rohan.ietf@gmail.com</email>
      </address>
    </author>
    <date year="2026" month="November" day="01"/>
    <area>Security</area>
    <workgroup>Messaging Layer Security</workgroup>
    <keyword>GroupContext hash</keyword>
    <keyword>FramedContent</keyword>
    <keyword>FramedContentTBS</keyword>
    <keyword>efficient signing</keyword>
    <keyword>deterministic signing</keyword>
    <abstract>
      <?line 40?>

<t>Most MLS signatures are signed over the relatively large GroupContext structure.
This document defines a way to safely sign using a pre-hashed version of the GroupContext structure for better efficiency.</t>
    </abstract>
    <note removeInRFC="true">
      <name>About This Document</name>
      <t>
        The latest revision of this draft can be found at <eref target="https://rohanmahy.github.io/mls-new-framed-content-tbs/draft-mahy-mls-new-framed-content-tbs.html"/>.
        Status information for this document may be found at <eref target="https://datatracker.ietf.org/doc/draft-mahy-mls-new-framed-content-tbs/"/>.
      </t>
      <t>
        Discussion of this document takes place on the
        Messaging Layer Security Working Group mailing list (<eref target="mailto:mls@ietf.org"/>),
        which is archived at <eref target="https://mailarchive.ietf.org/arch/browse/mls/"/>.
        Subscribe at <eref target="https://www.ietf.org/mailman/listinfo/mls/"/>.
      </t>
      <t>Source for this draft and an issue tracker can be found at
        <eref target="https://github.com/rohanmahy/mls-new-framed-content-tbs"/>.</t>
    </note>
  </front>
  <middle>
    <?line 45?>

<section anchor="introduction">
      <name>Introduction</name>
      <t>In MLS <xref target="RFC9420"/> all in-member application, commit, and proposal messages (whether sent via a PublicMessage, PrivateMessage or SemiPrivateMessage <xref target="I-D.mahy-mls-semiprivatemessage"/>); and all external commits contain a signature of the <tt>FramedContentTBS</tt> structure.
This structure contains the full GroupContext of the group, which can store a large amount of group state.
(For example, in the MIMI protocol <xref target="I-D.ietf-mimi-protocol"/> it contains the participant list for the group, which could contain thousands of URIs.)</t>
      <t>The GroupContext only changes once per epoch, therefore it is an excellent candidate to pre-hash and cache for efficiency reasons.
Having to fetch the entire GroupContext also negatively impacts mobile clients that process new messages in the background.</t>
      <t>This document defines a replacement for the <tt>FramedContentTBS</tt> structure that uses a pre-hashed GroupContext, and an MLS extension for safely negotiating the use of the new struct.</t>
      <t>This same improvement could be incorporated into the <tt>SlimFramedContentTBS</tt> struct in Slim MLS <xref target="I-D.robert-mls-slim"/>.</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="mechanism">
      <name>Mechanism</name>
      <t>This document defines the <tt>new_framed_content_tbs</tt> extension.
When present in a <tt>LeafNode.capabilities.extensions</tt> list, it indicates that the client supports this extension.
When present in the <tt>required_capabilities.extension_types</tt> list in <tt>GroupContext.extensions</tt> it indicates that every member of the group <bcp14>MUST</bcp14> use the new <tt>FramedContentTBS</tt> structure.</t>
      <t>The <tt>FramedContentTBS</tt> structure is replaced with the new structure below. The only change is that the GroupContext is replaced with <tt>context_hash</tt>: a hash (using the current hash function from the group's MLS cipher suite) of the GroupContext.</t>
      <t>Since the <tt>context_hash</tt> can be cached for an entire epoch, this can result in a substantial efficiency improvement for additional messages sent during the same epoch.</t>
      <sourcecode type="tls"><![CDATA[
context_hash = RefHash(GroupContext);

struct {
    ProtocolVersion version = mls10;
    WireFormat wire_format;
    FramedContent content;
    select (FramedContentTBS.content.sender.sender_type) {
        case member:
        case new_member_commit:
            opaque context_hash<V>;
        case external:
        case new_member_proposal:
            struct{};
    };
} FramedContentTBS;
]]></sourcecode>
    </section>
    <section anchor="security-considerations">
      <name>Security Considerations</name>
      <t>This proposal replaces the GroupContext with the hash of the GroupContext.</t>
      <t>The primary security consequence of this change is that if a non-member is aware of the <tt>context_hash</tt>, but not the entire GroupContext, it can still validate member signatures.
This may have minor privacy implications.</t>
    </section>
    <section anchor="iana-considerations">
      <name>IANA Considerations</name>
      <t>This document requests the addition of a new MLS Extension Type value under the heading of "Messaging Layer Security".</t>
      <t>RFC EDITOR: Please replace XXXX throughout with the RFC number assigned to this document.</t>
      <t>The <tt>new_framed_content_tbs</tt> MLS Extension Type is used inside LeafNode and GroupContext objects.
In a LeafNode it indicates support the the extension.
In the <tt>required_capabilities</tt> of the GroupContext it indicates the extension is being used.</t>
      <t>Value: 0x000b (suggested)</t>
      <t>Name: new_framed_content_tbs</t>
      <t>Message(s): GC,LN: This extension may appear in GroupContext and LeafNode objects</t>
      <t>Recommended: Y</t>
      <t>Reference: RFC XXXX</t>
    </section>
  </middle>
  <back>
    <references anchor="sec-combined-references">
      <name>References</name>
      <references anchor="sec-normative-references">
        <name>Normative References</name>
        <reference anchor="RFC9420" xml:base="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.9420.xml">
          <front>
            <title>The Messaging Layer Security (MLS) Protocol</title>
            <author fullname="R. Barnes" initials="R." surname="Barnes"/>
            <author fullname="B. Beurdouche" initials="B." surname="Beurdouche"/>
            <author fullname="R. Robert" initials="R." surname="Robert"/>
            <author fullname="J. Millican" initials="J." surname="Millican"/>
            <author fullname="E. Omara" initials="E." surname="Omara"/>
            <author fullname="K. Cohn-Gordon" initials="K." surname="Cohn-Gordon"/>
            <date month="July" year="2023"/>
            <abstract>
              <t>Messaging applications are increasingly making use of end-to-end security mechanisms to ensure that messages are only accessible to the communicating endpoints, and not to any servers involved in delivering messages. Establishing keys to provide such protections is challenging for group chat settings, in which more than two clients need to agree on a key but may not be online at the same time. In this document, we specify a key establishment protocol that provides efficient asynchronous group key establishment with forward secrecy (FS) and post-compromise security (PCS) for groups in size ranging from two to thousands.</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="9420"/>
          <seriesInfo name="DOI" value="10.17487/RFC9420"/>
        </reference>
        <reference anchor="RFC2119" xml:base="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.2119.xml">
          <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" xml:base="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.8174.xml">
          <front>
            <title>Ambiguity of Uppercase vs Lowercase in RFC 2119 Key Words</title>
            <author fullname="B. Leiba" initials="B." surname="Leiba"/>
            <date month="May" year="2017"/>
            <abstract>
              <t>RFC 2119 specifies common key words that may be used in protocol specifications. This document aims to reduce the ambiguity by clarifying that only UPPERCASE usage of the key words have the defined special meanings.</t>
            </abstract>
          </front>
          <seriesInfo name="BCP" value="14"/>
          <seriesInfo name="RFC" value="8174"/>
          <seriesInfo name="DOI" value="10.17487/RFC8174"/>
        </reference>
      </references>
      <references anchor="sec-informative-references">
        <name>Informative References</name>
        <reference anchor="I-D.mahy-mls-semiprivatemessage">
          <front>
            <title>Semi-Private Messages in the Messaging Layer Security (MLS) Protocol</title>
            <author fullname="Rohan Mahy" initials="R." surname="Mahy">
              <organization>Rohan Mahy Consulting Services</organization>
            </author>
            <date day="19" month="April" year="2026"/>
            <abstract>
              <t>   This document defines a SemiPrivateMessage for the Messaging Layer
   Security (MLS) protocol.  It allows members to share otherwise
   private commits and proposals with a designated list of external
   receivers rather than send these handshakes in a PublicMessage.

              </t>
            </abstract>
          </front>
          <seriesInfo name="Internet-Draft" value="draft-mahy-mls-semiprivatemessage-07"/>
        </reference>
        <reference anchor="I-D.ietf-mimi-protocol">
          <front>
            <title>More Instant Messaging Interoperability (MIMI) using HTTPS and MLS</title>
            <author fullname="Richard Barnes" initials="R." surname="Barnes">
              <organization>Cisco</organization>
            </author>
            <author fullname="Matthew Hodgson" initials="M." surname="Hodgson">
              <organization>The Matrix.org Foundation C.I.C.</organization>
            </author>
            <author fullname="Konrad Kohbrok" initials="K." surname="Kohbrok">
              <organization>Phoenix R&amp;D</organization>
            </author>
            <author fullname="Rohan Mahy" initials="R." surname="Mahy">
              <organization>Rohan Mahy Consulting Services</organization>
            </author>
            <author fullname="Travis Ralston" initials="T." surname="Ralston">
              <organization>The Matrix.org Foundation C.I.C.</organization>
            </author>
            <author fullname="Raphael Robert" initials="R." surname="Robert">
              <organization>Phoenix R&amp;D</organization>
            </author>
            <date day="25" month="April" year="2026"/>
            <abstract>
              <t>   This document specifies the More Instant Messaging Interoperability
   (MIMI) transport protocol, which allows users of different messaging
   providers to interoperate in group chats (rooms), including to send
   and receive messages, share room policy, and add participants to and
   remove participants from rooms.  MIMI describes messages between
   providers, leaving most aspects of the provider-internal client-
   server communication up to the provider.  MIMI integrates the
   Messaging Layer Security (MLS) protocol to provide end-to-end
   security assurances, including authentication of protocol
   participants, confidentiality of messages exchanged within a room,
   and agreement on the state of the room.

              </t>
            </abstract>
          </front>
          <seriesInfo name="Internet-Draft" value="draft-ietf-mimi-protocol-06"/>
        </reference>
        <reference anchor="I-D.robert-mls-slim">
          <front>
            <title>SlimMLS</title>
            <author fullname="Raphael Robert" initials="R." surname="Robert">
              <organization>Phoenix R&amp;D</organization>
            </author>
            <author fullname="Konrad Kohbrok" initials="K." surname="Kohbrok">
              <organization>Phoenix R&amp;D</organization>
            </author>
            <date day="6" month="July" year="2026"/>
            <abstract>
              <t>   This document defines SlimMLS, an extension to the Messaging Layer
   Security (MLS) protocol for reducing wire and per-client storage
   overhead in groups that use ciphersuites with large public keys,
   ciphertexts, signatures, and credentials.  SlimMLS replaces many
   large objects that appear in MLS authenticated or transcript-hashed
   structures with typed hash references.  Clients resolve the
   referenced objects only when needed, using a per-message carrier, a
   local cache, or an application-specific retrieval channel.  The
   extension is most useful when an independent Delivery Service can
   assist with retrieval and per-recipient delivery, although local
   caching and delayed fetching also help without such assistance.
   SlimMLS defines slim variants of KeyPackage, Commit, Welcome,
   GroupInfo, and message framing.  When placing a signature outside an
   encrypted envelope would reveal the signer, SlimMLS keeps the
   signature inside the ciphertext.

              </t>
            </abstract>
          </front>
          <seriesInfo name="Internet-Draft" value="draft-robert-mls-slim-01"/>
        </reference>
      </references>
    </references>
    <?line 139?>



  </back>
  <!-- ##markdown-source:
H4sIAAAAAAAAA41Y7XLbuBX9j6dAtT9qd0zaTjPTXTmbrBPbG81Ytms7STOd
jg2SkIQuSXABUIrqcZ6lz9In67kASYmW7NY/IvISuLj33HM/kCiKmFMul0M+
OOaFNpLLyUSlSpaOnxlRyOyDLh3ebt/fcOtMnboai1TJx9JaK6aqnPJzsZSG
38i0Nsot+c74/GZ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