<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE rfc [
<!ENTITY RFC2119 SYSTEM "http://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.2119.xml">
<!ENTITY RFC4443 SYSTEM "http://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.4443.xml">
<!ENTITY RFC8174 SYSTEM "http://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.8174.xml">
<!ENTITY RFC8200 SYSTEM "http://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.8200.xml">
<!ENTITY RFC8883 SYSTEM "http://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.8883.xml">
]>
<?xml-stylesheet type='text/xsl' href='rfc2629.xslt' ?>
<?rfc strict="yes" ?>
<?rfc toc="yes"?>
<?rfc tocdepth="2"?>
<?rfc symrefs="yes"?>
<?rfc sortrefs="yes" ?>
<?rfc compact="yes" ?>
<?rfc subcompact="no" ?>
<rfc category="std" docName="draft-iurman-6man-eh-occurrences-01"
     ipr="trust200902" submissionType="IETF" consensus="true">
  <front>
    <title abbrev="IPv6 EH Enforcement for Destinations">Enforcement of IPv6
    Extension Headers Ordering and Occurrence at Destination Nodes</title>

    <author fullname="Justin Iurman" initials="J." surname="Iurman">
      <organization abbrev="">University of Liege</organization>
      <address>
        <postal>
          <street>10, Allee de la decouverte (B28)</street>
          <code>4000</code>
          <city>Sart-Tilman</city>
          <country>Belgium</country>
        </postal>
        <email>justin.iurman@uliege.be</email>
      </address>
    </author>

    <author fullname="Tom Herbert" initials="T." surname="Herbert">
      <organization abbrev="">XDPnet</organization>
      <address>
        <postal>
          <city>Los Gatos, CA,</city>
          <country>United States of America</country>
        </postal>
        <email>tom@herbertland.com</email>
      </address>
    </author>

    <date day="16" month="March" year="2026"/>

    <abstract>
      <t>Operational experience has demonstrated that permitting multiple
      occurrences of the same IPv6 Extension Header can create parsing
      ambiguity, complicate packet processing, and increase potential security
      risks. Although RFC 8200 recommends that senders follow a specific order
      of appearance and limit the occurrences of Extension Headers, receivers
      cannot assume that these recommendations have been followed. This document
      specifies behavior that allows an IPv6 destination node, namely a host
      (i.e., the final destination of an IPv6 packet) or an intermediate
      destination node addressed by an entry in a Routing header list other than
      the final one, to enforce strict ordering and limits on the occurrence of
      Extension Headers.</t>
    </abstract>
  </front>

  <middle>
    <section title="Introduction" toc="default">
      <t>Operational experience has demonstrated that permitting multiple
      occurrences of the same IPv6 Extension Header can create parsing
      ambiguity, complicate packet processing, and increase potential security
      risks. This is particularly true for the Hop-by-Hop Options header and the
      Destination Options header, which may each carry multiple options.</t>

      <t>Although RFC 8200 recommends that senders follow a specific order of
      appearance and limit the occurrences of Extension Headers, receivers
      cannot assume that these recommendations have been followed. As a result,
      they may be exposed to denial-of-service attacks, where Extension Headers
      are used as the attack vector.</t>

      <t>This document specifies behavior that allows an IPv6 destination node,
      namely a host (i.e., the final destination of an IPv6 packet) or an
      intermediate destination node addressed by an entry in a Routing header
      list other than the final one, to enforce strict ordering and limits on
      the occurrence of Extension Headers. The specification applies only to
      IPv6 destination nodes and does not impose requirements on routers
      forwarding IPv6 packets not explicitly addressed to themselves.</t>
    </section>

    <section title="Conventions">
      <t>The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
      "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and
      "OPTIONAL" 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>
    </section>

    <section title="Enforcement of IPv6 Extension Headers Ordering and Occurrence">
      <t>An IPv6 destination, i.e., a host or an intermediate destination node,
      MAY enforce the recommended ordering and limits on the occurrence of
      Extension Headers described in Section 4.1 of <xref target="RFC8200"/>.
      Per the ordering recommendations, each Extension Header can occur at most
      once in a packet, with the exception of the Destination Options header
      which can occur twice. The recommended Extension Headers ordering per
      <xref target="RFC8200"/> is:
        <list style="numbers">
          <t>IPv6 header</t>
          <t>Hop-by-Hop Options header</t>
          <t>Destination Options header</t>
          <t>Routing header</t>
          <t>Fragment header</t>
          <t>Authentication header</t>
          <t>Encapsulating Security Payload header</t>
          <t>Destination Options header</t>
          <t>Upper-Layer header</t>
        </list>
      </t>

      <t>If a host or an intermediate destination node enforces the recommended
      ordering and a packet is received with out-of-order Extension Headers, or
      the occurrence of an Extension Header is greater than one (or two for the
      Destination Options header), then the receiving node MUST discard the
      packet. In the case of a host, it MAY send an ICMP Parameter Problem
      message with code 1 (Unrecognized Next Header type encountered)
      <xref target="RFC4443"/> to the packet's source address. In the case of an
      intermediate destination node, it MAY send an ICMP Parameter Problem
      message with code 5 (Unrecognized Next Header type encountered by
      intermediate node) <xref target="RFC8883"/> to the packet's source
      address.</t>
    </section>

    <section title="Operational Considerations">
      <t>Enforcing strict ordering and occurrence limits may cause packets whose
      Extension Headers do not follow the recommended order or appear more than
      suggested to be discarded. While such packets are not formally
      non-compliant with RFC 8200, they are unexpected and may lead to parsing
      ambiguities or interoperability issues. Operators should consider the
      potential impact on traffic when enabling enforcement at destination
      nodes, particularly at intermediate destination nodes.</t>
    </section>

    <section title="Security Considerations">
      <t>This document mitigates a potential denial-of-service attack based on
      abusive use of Extension Headers in IPv6 packets. Hosts and intermediate
      destination nodes are now allowed to enforce strict ordering and limits on
      the occurrence of Extension Headers to reduce the attack vector.</t>

      <t>This document does not introduce any new security concerns.</t>
    </section>

    <section title="IANA Considerations">
      <t>This document does not require any action from IANA.</t>
    </section>

    <section title="Acknowledgements">
      <t>TBD</t>
    </section>
  </middle>

  <back>
    <references title="Normative References">
      &RFC2119;
      &RFC4443;
      &RFC8174;
      &RFC8200;
      &RFC8883;
    </references>
  </back>
</rfc>
