<?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  (Ruby 3.1.2) -->
<rfc xmlns:xi="http://www.w3.org/2001/XInclude" ipr="trust200902" docName="draft-amsuess-core-edhoc-grease-01" category="info" version="3">
  <!-- xml2rfc v2v3 conversion 3.17.0 -->
  <front>
    <title>Applying Generate Random Extensions And Sustain Extensibility (GREASE) to EDHOC Extensibility</title>
    <seriesInfo name="Internet-Draft" value="draft-amsuess-core-edhoc-grease-01"/>
    <author initials="C." surname="Amsüss" fullname="Christian Amsüss">
      <organization/>
      <address>
        <postal>
          <country>Austria</country>
        </postal>
        <email>christian@amsuess.com</email>
      </address>
    </author>
    <date year="2023" month="October" day="22"/>
    <workgroup>CoRE</workgroup>
    <abstract>
      <t>This document applies the extensibility mechanism GREASE (Generate Random Extensions And Sustain Extensibility),
which was pioneered for TLS,
to the EDHOC ecosystem.
It reserves a set of non-critical EAD labels and unusable cipher suites
that may be included in messages
to ensure peers correctly handle unknown values.</t>
    </abstract>
    <note removeInRFC="true">
      <name>Discussion Venues</name>
      <t>Discussion of this document takes place on the
    Constrained RESTful Environments Working Group mailing list (core@ietf.org),
    which is archived at <eref target="https://mailarchive.ietf.org/arch/browse/core/"/>.</t>
      <t>Source for this draft and an issue tracker can be found at
    <eref target="https://gitlab.com/chrysn/core-edhoc-grease"/>.</t>
    </note>
  </front>
  <middle>
    <section anchor="introduction">
      <name>Introduction</name>
      <t>[ See abstract ]</t>
      <t>The introduction of <xref target="RFC8701"/> provides comprehensive motivation for adding such extensions.</t>
      <t>The extension points of the EDHOC protocol (<xref target="I-D.ietf-lake-edhoc"/>) are
cipher suites,
methods,
EADs (External Authorization Data items)
and COSE headers.
Of these,
EADs and cipher suites
can be used in such a way that even in the presence of an unknown value,
a connection can still be established.</t>
      <t>Unlike in TLS GREASE,
EDHOC is operating on tight bandwidth and message size budget,
with some messages just barely fitting within relevant networks' fragmentation limits.
Thus,
more than with TLS GREASE,
it is up to implementations to decide
whether in their particular use case
they can afford to send addtional data.</t>
    </section>
    <section anchor="the-grease-ead-labels">
      <name>The GREASE EAD labels</name>
      <t>This document registers the following EAD labels as GREASE EADs:</t>
      <t>160, 41120, 43690, 44975</t>
      <t>These EADs are available in all EDHOC messages.
The EADs are only used in their positive (non-critical) form.</t>
      <section anchor="use-of-grease-eads-by-message-senders">
        <name>Use of GREASE EADs by message senders</name>
        <t>A sender of an EDHOC message MAY send a GREASE EAD using the non-critical (positive) form at any time,
with any or no EAD value (that is, with or without a byte string of any usable length),
in any message.</t>
        <t>Senders SHOULD consider the properties of the network their messages are sent over,
and refrain from adding GREASE when its use would be detrimental to the network
(for example, when the added size causes fragmentation of the message).</t>
        <t>On networks where the data added by the grease EADs does not significantly impact the network,
senders SHOULD irregularly send arbitrary (possibly random) GREASE EADs with their messages
to ensure that errors resulting from the use of GREASE are detected.</t>
        <t>The GREASE EADs MAY be used as an alternative form of padding.</t>
        <section anchor="suggested-pattern">
          <name>Pattern for limited fingerprinting</name>
          <t>A method of deciding how to apply GREASE is suggested as follows:</t>
          <ul spacing="normal">
            <li>For every message, use GREASE with a random probability of 1 in 64.</li>
            <li>Pick a random GREASE label out of the uniform distribution of available options.</li>
            <li>Pick a random length from the uniformly distributed interval 9 to 40 (inclusive).</li>
            <li>Add the selected GREASE label with a value of the selected length,
filled with random bytes.</li>
          </ul>
        </section>
      </section>
      <section anchor="use-of-grease-eads-by-message-recipients">
        <name>Use of GREASE EADs by message recipients</name>
        <t>A party receiving a GREASE EAD MUST NOT alter its behavior
in any way that would allow random GREASE EADs
to alter the security context that gets established.</t>
        <t>It MAY alter its behavior in other ways;
in particular, it SHOULD randomly insert GREASE EADs
in later messages of an exchange in which any were received.</t>
        <t>If it does not alter its behavior,
it is RECOMMENDED that implementations make no attempt to recognize GREASE EADs,
and apply the default processing --
that is, to ignoring any unknown non-critical EADs.</t>
      </section>
    </section>
    <section anchor="grease-cipher-suites">
      <name>GREASE cipher suites</name>
      <t>This document registers the following cipher suites:</t>
      <t>160, 41120, -41121, 43690</t>
      <t>An initiator may insert a GREASE cipher suite
at any position in its sequence of preferred cipher suites.</t>
      <t>A responder MUST NOT support any of these cipher suites,
and MUST treat them like any other cipher suite it does not support.</t>
      <t>Thus, these cipher suites never occur as the selected cipher suite.
An initiator whose choice of a GREASE cipher suite is accepted
needs to discontinue the protocol.</t>
    </section>
    <section anchor="privacy-considerations">
      <name>Privacy considerations</name>
      <t>The way in which GREASE is applied
can contribute to identifying which implementation of EDHOC
is being used.
Implementers of EDHOC are encouraged to use the algorithm described in <xref target="suggested-pattern"/>,
both to reduce the likelihood of their implementation to be identified through the use of GREASE
and to increase the anonymity set of other users of the same algorithm.</t>
    </section>
    <section anchor="security-considerations">
      <name>Security Considerations</name>
      <t>The use of the GREASE option has no impact on security
in a correct EDHOC implementation.</t>
    </section>
    <section anchor="iana-considerations">
      <name>IANA considerations</name>
      <section anchor="edhoc-eads">
        <name>EDHOC EADs</name>
        <t>IANA is requested to register
four new entries into the EDHOC External Authorization Data Registry
established in <xref target="I-D.ietf-lake-edhoc"/>:</t>
        <t>160, 41120, 43690, 44975</t>
        <t>All share the name "GREASE",
the description "Arbitrary data to ensure extensibility",
and this document as a reference.</t>
      </section>
      <section anchor="edhoc-cipher-suites">
        <name>EDHOC cipher suites</name>
        <t>IANA is requested to register
four new values into the EDHOC Cipher Suites Registry
established in <xref target="I-D.ietf-lake-edhoc"/>:</t>
        <t>160, 41120, -41121, 43690</t>
        <t>All share the name "GREASE",
the array N/A,
the description "Unimplementable cipher suite to ensure extensibility",
and this document as a reference.</t>
      </section>
    </section>
  </middle>
  <back>
    <references>
      <name>References</name>
      <references>
        <name>Normative References</name>
        <reference anchor="I-D.ietf-lake-edhoc">
          <front>
            <title>Ephemeral Diffie-Hellman Over COSE (EDHOC)</title>
            <author fullname="Göran Selander" initials="G." surname="Selander">
              <organization>Ericsson AB</organization>
            </author>
            <author fullname="John Preuß Mattsson" initials="J. P." surname="Mattsson">
              <organization>Ericsson AB</organization>
            </author>
            <author fullname="Francesca Palombini" initials="F." surname="Palombini">
              <organization>Ericsson AB</organization>
            </author>
            <date day="25" month="August" year="2023"/>
            <abstract>
              <t>   This document specifies Ephemeral Diffie-Hellman Over COSE (EDHOC), a
   very compact and lightweight authenticated Diffie-Hellman key
   exchange with ephemeral keys.  EDHOC provides mutual authentication,
   forward secrecy, and identity protection.  EDHOC is intended for
   usage in constrained scenarios and a main use case is to establish an
   OSCORE security context.  By reusing COSE for cryptography, CBOR for
   encoding, and CoAP for transport, the additional code size can be
   kept very low.

              </t>
            </abstract>
          </front>
          <seriesInfo name="Internet-Draft" value="draft-ietf-lake-edhoc-22"/>
        </reference>
      </references>
      <references>
        <name>Informative References</name>
        <reference anchor="RFC8701">
          <front>
            <title>Applying Generate Random Extensions And Sustain Extensibility (GREASE) to TLS Extensibility</title>
            <author fullname="D. Benjamin" initials="D." surname="Benjamin"/>
            <date month="January" year="2020"/>
            <abstract>
              <t>This document describes GREASE (Generate Random Extensions And Sustain Extensibility), a mechanism to prevent extensibility failures in the TLS ecosystem. It reserves a set of TLS protocol values that may be advertised to ensure peers correctly handle unknown values.</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="8701"/>
          <seriesInfo name="DOI" value="10.17487/RFC8701"/>
        </reference>
      </references>
    </references>
    <section anchor="open-questions">
      <name>Open questions</name>
      <t>Do the GREASE EADs add any value that padding does not already add?</t>
      <t>Probably yes, because padding is "special enough" that it could be handled in a hard-coded fashion.
(Then again, there's nothing but the effort stopping anyone else from doing the same with the GREASE EADs, right?)</t>
      <t>Can anything be done about extra methods and COSE headers?</t>
      <t>They would not result in successful operations,
but maybe there is still some value in registering one or two --
using them would mean sacrificing the full connection,
but it may still be possible to conclude that the extension points are in order
from watching the EDHOC exchange fail in the predicted way.</t>
    </section>
    <section anchor="change-log">
      <name>Change log</name>
      <t>Since -00:</t>
      <ul spacing="normal">
        <li>Fixed a mix-up between positivity and criticality of options.</li>
        <li>Adjusted numbers accordingly to once more fit in the <tt>0xa.</tt> pattern
(actually they're using <tt>0x.a</tt>, but that doesn't work the same way with CBOR).</li>
        <li>Text improvements around recipient side processing.</li>
      </ul>
    </section>
    <section numbered="false" anchor="acknowledgements">
      <name>Acknowledgements</name>
      <t>Marco Tiloca pointed out a critical error in the numeric constructions.
Göran Selander provided input to reduce mistakable text.</t>
    </section>
  </back>
  <!-- ##markdown-source:
H4sIAAAAAAAAA6VYTXPbyBG941dMSQdLKZKRHMcbM5VyGEnrddXacknyIZVN
xUNgSEwEzCAzA1K0Sn8rp9z2j+V1zwACKNXGlT3JBuejp/v169c9nU6zoEOl
5uJg0TTVTpu1eKeMcjIocSVNYWtxcReU8doaLxamENetD1Kb7vNSVzrsxNG7
q4vF9cWxCFZcnP9weTb+/SArbG5kjYsKJ1dhKmvfKu+nuXVqqorS5tO1U9Kr
6clpphs3F8HhopcnJ29OXma40RT/kJU1in9QWS7DXGizstl2PRdn9uoik20o
rZtnU3z3+DYTi9r//B/vMyHi1Wel0z5oaQa/5LY1we3mYoHrnJb4pGqpq7nI
u9V/TsbOcltnxrpaBr1Rc6x8Pz2faRVW00repmfMM7JqsObq+7M/fHdyOs+y
bDqdCrnENTIPWXZTai/glrZWJggJ92vlRSiVUCPX1iovpdG+FtHH8PX/EaHj
SbYtdV6KrfSiwVqlnCoETBU3P15PMsSNro6xU7n1Ox9UPcveB+GUV24D26Tw
Kgi7Esaaae500LmsxMXiXFRyqSoswO2tab1cVkrkuimVE77VQfkslDKIWu7E
UiE+edUWuB1G1nCsXNMCK2Bt65RoYJpHYJxTeah2Aq8vcF5rbo3dGrGRFaIx
i+6sdYHfsuxQvEcYbdHmAW8T94d68N+HLPvpb+Jaqd774qe/UwDIlMEuvOz+
PsXr4UE0zm50oci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