<?xml version="1.0" encoding="utf-8"?>
<rfc xmlns:xi="http://www.w3.org/2001/XInclude"
     ipr="trust200902"
     submissionType="IETF"
     category="std"
     consensus="true"
     docName="draft-yang-ipsecme-esp-entropy-header-00"
     xml:lang="en"
     tocInclude="true"
     sortRefs="true"
     symRefs="true"
     version="3">

  <front>
    <title abbrev="ESP Entropy Header">An Entropy Header for
    Load Balancing of IPsec ESP Traffic</title>
    <seriesInfo name="Internet-Draft"
                value="draft-yang-ipsecme-esp-entropy-header-00" />

    <author fullname="Jin Yang" initials="J." surname="Yang">
      <organization>China Mobile</organization>
      <address>
        <postal>
          <street/>
          <city>Beijing</city>
          <code>100053</code>
          <country>China</country>
        </postal>
        <email>yangjinwl@chinamobile.com</email>
      </address>
    </author>

    <author fullname="Yuchi Tian" initials="Y." surname="Tian">
      <organization>China Mobile</organization>
      <address>
        <postal>
          <city>Beijing</city>
          <code>100053</code>
          <country>China</country>
        </postal>
        <email>tianyuchi@chinamobile.com</email>
      </address>
    </author>

    <author fullname="Weiqiang Cheng" initials="W." surname="Cheng">
      <organization>China Mobile</organization>
      <address>
        <postal>
          <street/>
          <city>Beijing</city>
          <code>100053</code>
          <country>China</country>
        </postal>
        <email>chengweiqiang@chinamobile.com</email>
      </address>
    </author>
    <author fullname="Junjie Wang" initials="J." surname="Wang">
      <organization>Centec</organization>
      <address>
        <postal>
          <city>Suzhou</city>
          <code>215000</code>
          <country>China</country>
        </postal>
        <email>wangjj@centec.com</email>
      </address>
    </author>
    <author fullname="Guoying Zhang" initials="G." surname="Zhang">
      <organization>Centec</organization>
      <address>
        <postal>
          <city>Suzhou</city>
          <code>215000</code>
          <country>China</country>
        </postal>
        <email>zhanggy@centec.com</email>
      </address>
    </author>

    <date year="2026" month="June" day="22" />
    <area>SEC</area>
    <workgroup>IPSECME</workgroup>

    <keyword>IPsec</keyword>
    <keyword>ESP</keyword>
    <keyword>ECMP</keyword>
    <keyword>LAG</keyword>
    <keyword>entropy</keyword>
    <keyword>load balancing</keyword>

    <abstract>
      <t>
        When IPsec Encapsulating Security Payload (ESP) is used in
        tunnel mode, an intermediate node cannot inspect the
        encrypted inner headers to derive entropy for Equal-Cost
        Multipath (ECMP) or Link Aggregation Group (LAG) path
        selection. Path selection is then driven by outer header
        fields that are identical for every packet of a given
        tunnel, so all packets of the tunnel are placed on a single
        path regardless of the number of inner flows.
      </t>
      <t>
        This document defines the ESP Entropy Header, an IP
        protocol header that is placed immediately ahead of ESP and
        carries an entropy value in a fixed position that transit
        nodes can use for path selection. It also defines an
        Internet Key Exchange Protocol Version 2 (IKEv2) extension
        with which peers negotiate the use of the header on a
        per-Child-SA basis. The mechanism applies to both IPv4 and
        IPv6.
      </t>
    </abstract>
  </front>

  <middle>

    <section anchor="intro" numbered="true" toc="include">
      <name>Introduction</name>

      <section anchor="problem" numbered="true" toc="include">
        <name>Problem Statement</name>
        <t>
          IPsec <xref target="RFC4301"/> provides security
          services for IP traffic at the network layer. ESP
          <xref target="RFC4303"/> is the most widely deployed
          IPsec protocol and provides confidentiality, integrity,
          and anti-replay protection. In tunnel mode the original
          packet is encrypted and encapsulated in a new outer IP
          header.
        </t>
        <t>
          Intermediate nodes along the tunnel path perform ECMP and
          LAG path selection by computing a hash over selected
          packet header fields. For an ESP tunnel-mode packet, only
          the outer IP header is available to such a node. When a
          single tunnel carries multiple inner flows, the outer
          source and destination addresses are the same for every
          packet, so the hash yields the same result at each hop
          and all packets of the tunnel are assigned to the same
          path. The available paths are therefore not used evenly.
          This behavior is a recognized operational limitation of
          IPsec deployments.
        </t>
        <t>
          Comparable problems have been addressed in other
          encapsulations. MPLS uses entropy labels
          <xref target="RFC6790"/>. IPv6 tunnels can use the flow
          label for the same purpose <xref target="RFC6438"/>. For
          IPsec there is at present no header within the IP protocol
          stack, common to IPv4 and IPv6, that carries entropy in a
          fixed location for a transit node to use.
        </t>
      </section>

      <section anchor="overview" numbered="true" toc="include">
        <name>Overview</name>
        <t>
          This document defines an IP protocol header, the ESP
          Entropy Header, that immediately precedes the ESP header.
          The header carries a 16-bit Entropy field that is set by
          the IPsec sender and is available for inspection by
          transit nodes. A transit node that recognizes the
          assigned protocol number <bcp14>MAY</bcp14> include the
          Entropy field in its ECMP and LAG path-selection input.
        </t>
        <t>
          Use of the ESP Entropy Header is negotiated between IPsec
          peers using an IKEv2 <xref target="RFC7296"/> Notify
          exchange, so that a peer includes the header only when its
          peer is prepared to process packets that carry it.
        </t>
        <t>
          Improving the entropy available for path selection, as
          this document does, is complementary to making the
          path-selection decision itself load-aware. The latter
          approach is described in
          <xref target="I-D.yang-rtgwg-ecmp-adaptive-load-balance"/>;
          the two mechanisms operate at different points and may be
          combined. The relationship is discussed in
          <xref target="design"/>.
        </t>
      </section>

      <section anchor="design" numbered="true" toc="include">
        <name>Design Considerations</name>
        <t>
          Entropy for encrypted tunnel traffic can be provided in
          more than one way. This section records the trade-offs
          that apply to the alternatives, so that the choice made in
          this document is documented rather than assumed.
        </t>
        <t>
          UDP encapsulation:
          <xref target="I-D.xu-ipsecme-esp-in-udp-lb"/> and
          <xref target="I-D.acharya-ipsecme-esp-ecmp"/> encapsulate
          ESP in UDP and use the UDP source port to carry entropy.
          This suits environments in which transit nodes already
          hash on the UDP five-tuple. It adds an 8-octet UDP header,
          requires a UDP checksum in IPv6 <xref target="RFC8200"/>,
          and shares the UDP port space with NAT traversal
          <xref target="RFC3948"/>, which can interact with the use
          of the source port for entropy.
        </t>
        <t>
          IPv6 flow label: <xref target="RFC6438"/> uses the IPv6
          flow label for ECMP and LAG in tunnels. It is native to
          IPv6 and adds no header, but is not available in IPv4 and
          provides a 20-bit field whose use for load balancing
          depends on transit support.
        </t>
        <t>
          Multiple Security Associations: distinct SPI values across
          several SAs can provide differentiation at the ESP layer.
          This increases IKE signaling and keying state and requires
          a transit node to inspect fields beyond the IP header.
        </t>
        <t>
          The ESP Entropy Header is defined as an IP protocol type
          and so applies to both IPv4 and IPv6. The Entropy field is
          at a fixed octet offset from the start of the header,
          which allows a transit node to locate it without parsing
          variable-length structures. This approach follows the
          precedent of Wrapped ESP <xref target="RFC5840"/>, which
          defined an IP-protocol-numbered header that wraps ESP for
          a different purpose (traffic visibility); that precedent
          shows that an IP-protocol-numbered header adjacent to ESP
          is an established mechanism in the IPsec architecture.
        </t>
      </section>

      <section anchor="reqlang" numbered="true" toc="include">
        <name>Requirements Language</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>
      </section>

      <section anchor="terminology" numbered="true" toc="include">
        <name>Terminology</name>
        <t>
          This document uses the following terms.
        </t>
        <dl>
          <dt>IPsec Sender:</dt>
          <dd>
            The IPsec peer that performs outbound ESP processing. In
            tunnel mode this is the tunnel ingress.
          </dd>
          <dt>IPsec Receiver:</dt>
          <dd>
            The IPsec peer that performs inbound ESP processing. In
            tunnel mode this is the tunnel egress.
          </dd>
          <dt>Transit Node:</dt>
          <dd>
            Any router or Layer 3 switch on the path between the
            IPsec sender and receiver that makes ECMP or LAG path
            selection decisions.
          </dd>
          <dt>Entropy:</dt>
          <dd>
            A value that, when included in the path-selection hash,
            differentiates packets that would otherwise hash to the
            same result, consistent with the use of the term in
            <xref target="RFC6790"/>.
          </dd>
        </dl>
      </section>
    </section>

    <section anchor="format" numbered="true" toc="include">
      <name>ESP Entropy Header Format</name>

      <t>
        The ESP Entropy Header is 8 octets in length. It is
        identified by its own IP protocol number (see
        <xref target="iana"/>). In the IP header that precedes it,
        the Protocol field (IPv4) or the Next Header field (IPv6)
        carries this protocol number.
      </t>

      <figure anchor="fig-header-format">
        <name>ESP Entropy Header</name>
        <artwork type="ascii-art"><![CDATA[
 0                   1                   2                   3
 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|  Next Header  |    Hdr Len    |            Entropy            |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|                        Reserved (MBZ)                         |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
]]></artwork>
      </figure>

      <dl>
        <dt>Next Header (8 bits):</dt>
        <dd>
          Identifies the header that immediately follows the ESP
          Entropy Header, using a value from the IANA "Assigned
          Internet Protocol Numbers" registry. For the typical use
          with ESP this field is 50.
        </dd>

        <dt>Hdr Len (8 bits):</dt>
        <dd>
          Length of the ESP Entropy Header in 4-octet units, not
          including the first 4 octets. For the header defined in
          this document the value is 1, indicating a total length of
          8 octets. This field allows a future extension to increase
          the header length without a new protocol number. A
          receiver that encounters a Hdr Len value it does not
          support <bcp14>MUST</bcp14> skip the indicated number of
          octets and continue processing at the Next Header.
        </dd>

        <dt>Entropy (16 bits):</dt>
        <dd>
          <t>
            A 16-bit value. A transit node <bcp14>MAY</bcp14> use
            this field as input to ECMP and LAG path selection.
          </t>
          <t>
            The value is set by the IPsec sender. The means by which
            the sender selects the value is a local matter and is
            outside the scope of this document. To be useful for
            load distribution, the Entropy field has the following
            properties:
          </t>
          <ul>
            <li>
              All packets of the same inner flow
              <bcp14>MUST</bcp14> carry the same Entropy value, so
              that per-flow packet ordering is preserved across ECMP
              and LAG paths.
            </li>
            <li>
              The Entropy values used across the active flows of a
              tunnel <bcp14>SHOULD</bcp14> be approximately
              uniformly distributed.
            </li>
          </ul>
        </dd>

        <dt>Reserved (MBZ) (32 bits):</dt>
        <dd>
          Set to zero on transmission and ignored on receipt.
          Reserved for future use.
        </dd>
      </dl>
    </section>

    <section anchor="encap" numbered="true" toc="include">
      <name>Header Placement</name>

      <t>
        The ESP Entropy Header is placed between the outer IP header
        (and any IPv6 extension headers) and the ESP header. The
        following diagrams show the resulting packet structure.
      </t>

      <figure anchor="fig-encap-ipv4">
        <name>IPv4 Tunnel Mode Packet Structure</name>
        <artwork type="ascii-art"><![CDATA[
+-------------------+
|    Outer IPv4      |  Protocol = EEH (TBD1)
|    Header          |
+-------------------+
|  ESP Entropy Hdr   |  Next Header = 50 (ESP)
|    (8 octets)      |
+-------------------+
|    ESP Header      |  SPI, Sequence Number
+-------------------+
|                    |  Original IP Packet
|  Encrypted Payload |  (encrypted by ESP)
|                    |
+-------------------+
|    ESP Trailer     |  Padding, Pad Length, NH
+-------------------+
|    ESP ICV         |
+-------------------+
]]></artwork>
      </figure>

      <figure anchor="fig-encap-ipv6">
        <name>IPv6 Tunnel Mode Packet Structure</name>
        <artwork type="ascii-art"><![CDATA[
+-------------------+
|    Outer IPv6      |  Next Header = EEH (TBD1)
|    Header          |  or extension header chain
+-------------------+
| (Extension Hdrs)   |  (if any; last NH = TBD1)
+-------------------+
|  ESP Entropy Hdr   |  Next Header = 50 (ESP)
|    (8 octets)      |
+-------------------+
|    ESP Header      |  SPI, Sequence Number
+-------------------+
|                    |  Original IP Packet
|  Encrypted Payload |  (encrypted by ESP)
|                    |
+-------------------+
|    ESP Trailer     |  Padding, Pad Length, NH
+-------------------+
|    ESP ICV         |
+-------------------+
]]></artwork>
      </figure>

      <t>
        The ESP Entropy Header is not covered by ESP encryption or
        integrity protection. It is visible in the clear to nodes on
        the path. The security consequences are discussed in
        <xref target="security"/>.
      </t>
    </section>

    <section anchor="processing" numbered="true" toc="include">
      <name>Processing Requirements</name>

      <section anchor="proc-sender" numbered="true" toc="include">
        <name>IPsec Sender</name>
        <t>
          When the ESP Entropy Header has been negotiated for a
          Child SA (see <xref target="negotiation"/>), the IPsec
          sender that chooses to include the header in an outbound
          packet on that SA does so subject to the following
          requirements.
        </t>
        <ul>
          <li>
            The outer IP Protocol (IPv4) or Next Header (IPv6) field
            <bcp14>MUST</bcp14> carry the protocol number assigned
            to the ESP Entropy Header.
          </li>
          <li>
            The Next Header field of the ESP Entropy Header
            <bcp14>MUST</bcp14> identify the following header,
            typically ESP (value 50).
          </li>
          <li>
            The Hdr Len field <bcp14>MUST</bcp14> be set to 1 for
            the header defined in this document.
          </li>
          <li>
            The Entropy field <bcp14>MUST</bcp14> carry a value that
            is the same for all packets of the same inner flow (see
            <xref target="format"/>).
          </li>
          <li>
            The Reserved field <bcp14>MUST</bcp14> be set to zero.
          </li>
          <li>
            ESP encryption and integrity protection are applied to
            the payload that follows the ESP Entropy Header, as in
            <xref target="RFC4303"/>. The ESP Entropy Header is not
            part of the ESP-protected payload.
          </li>
        </ul>
        <t>
          The IPsec sender <bcp14>MAY</bcp14> omit the ESP Entropy
          Header on some packets of an SA for which it has been
          negotiated, for example when no useful entropy can be
          derived for a packet. When the header is omitted, the
          outer IP Protocol or Next Header field
          <bcp14>MUST</bcp14> be set to the ESP value (50) and no
          ESP Entropy Header is present. A receiver
          <bcp14>MUST</bcp14> accept packets both with and without
          the header on an SA for which the header has been
          negotiated.
        </t>
      </section>

      <section anchor="proc-transit" numbered="true" toc="include">
        <name>Transit Node</name>
        <t>
          A transit node that recognizes the ESP Entropy Header
          protocol number <bcp14>MAY</bcp14> include the Entropy
          field in the fields it uses for ECMP or LAG path
          selection. The Entropy field is at octets 2 and 3 of the
          header.
        </t>
        <t>
          A transit node <bcp14>MUST NOT</bcp14> modify any field of
          the ESP Entropy Header.
        </t>
        <t>
          A transit node that does not recognize the protocol number
          forwards the packet according to its existing behavior for
          the outer IP header; an unrecognized protocol number does
          not prevent forwarding. The mechanism is therefore
          incrementally deployable: a node that recognizes the
          header obtains improved path selection, and a node that
          does not continues to forward the traffic.
        </t>
      </section>

      <section anchor="proc-receiver" numbered="true" toc="include">
        <name>IPsec Receiver</name>
        <t>
          When the IPsec receiver has negotiated the ESP Entropy
          Header for a Child SA, it <bcp14>MUST</bcp14> accept and
          process an incoming packet whose outer IP Protocol or Next
          Header value indicates the ESP Entropy Header.
        </t>
        <t>
          Because the SPI that identifies the Child SA is carried
          in the ESP header, which follows the ESP Entropy Header, a
          receiver cannot determine the SA before it has parsed the
          ESP Entropy Header. A receiver that implements this
          specification therefore <bcp14>MUST</bcp14> process the ESP
          Entropy Header whenever the outer IP Protocol or Next
          Header value indicates it, and then continue to inbound
          ESP processing where the SA is resolved. Per-Child-SA
          negotiation (<xref target="negotiation"/>) governs whether
          a sender is permitted to emit the header; it does not gate
          the receiver's ability to parse it. A node that does not
          implement this specification does not recognize the
          protocol number and handles the packet according to its
          existing behavior for an unknown IP protocol number, as
          described for transit nodes in
          <xref target="proc-transit"/>.
        </t>
        <ul>
          <li>
            The receiver reads the Next Header field of the ESP
            Entropy Header to determine the following protocol. If
            the value is not recognized, the receiver
            <bcp14>MUST</bcp14> discard the packet and
            <bcp14>MAY</bcp14> log the event.
          </li>
          <li>
            The receiver uses the Hdr Len field to determine the
            length of the ESP Entropy Header and to locate the next
            header.
          </li>
          <li>
            The receiver does not examine the Entropy or Reserved
            fields; they are meaningful only to transit nodes.
          </li>
          <li>
            The receiver then processes the following header,
            typically ESP, according to normal inbound IPsec
            processing <xref target="RFC4303"/>.
          </li>
        </ul>
      </section>
    </section>

    <section anchor="negotiation" numbered="true" toc="include">
      <name>IKEv2 Negotiation</name>

      <t>
        Use of the ESP Entropy Header <bcp14>MUST</bcp14> be
        negotiated between peers before the header is sent. This
        document defines an IKEv2 <xref target="RFC7296"/> Notify
        Message of type Status, ESP_ENTROPY_HEADER_SUPPORTED, for
        this purpose.
      </t>

      <section anchor="nego-procedure" numbered="true"
               toc="include">
        <name>Negotiation Procedure</name>
        <t>
          The initiator includes the ESP_ENTROPY_HEADER_SUPPORTED
          notification in the IKE_AUTH or CREATE_CHILD_SA exchange
          that establishes or rekeys the Child SA.
        </t>
        <t>
          If the responder is willing to receive packets that carry
          the ESP Entropy Header on the Child SA, it includes the
          same notification in its response.
        </t>
        <t>
          The ESP Entropy Header is negotiated successfully when
          both the request and the response carry the
          ESP_ENTROPY_HEADER_SUPPORTED notification. If the response
          does not carry it, the initiator <bcp14>MUST NOT</bcp14>
          send packets that carry the ESP Entropy Header on the
          Child SA.
        </t>
        <t>
          Successful negotiation means that each peer is prepared to
          receive the header. Each peer decides independently
          whether to include the header in its own outbound packets;
          the notification does not require a peer to include the
          header in every packet.
        </t>
      </section>

      <section anchor="nego-format" numbered="true" toc="include">
        <name>Notify Payload Format</name>

        <figure anchor="fig-notify">
          <name>ESP_ENTROPY_HEADER_SUPPORTED Notify Payload</name>
          <artwork type="ascii-art"><![CDATA[
                     1                   2                   3
 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Next Payload  |C|  RESERVED   |         Payload Length        |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|  Protocol ID  |   SPI Size    |      Notify Message Type      |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
]]></artwork>
        </figure>

        <dl>
          <dt>Protocol ID:</dt>
          <dd>0 when the notification is sent in the IKE_AUTH
              exchange, or 3 (ESP) when it is sent in a
              CREATE_CHILD_SA exchange.</dd>
          <dt>SPI Size:</dt>
          <dd>0.</dd>
          <dt>Notify Message Type:</dt>
          <dd>ESP_ENTROPY_HEADER_SUPPORTED (value TBD2, see
              <xref target="iana-notify"/>).</dd>
        </dl>
        <t>
          This notification carries no data.
        </t>
      </section>
    </section>

    <section anchor="mtu" numbered="true" toc="include">
      <name>Path MTU Considerations</name>

      <t>
        The ESP Entropy Header adds 8 octets to each packet that
        carries it. An implementation that uses the header
        <bcp14>MUST</bcp14> account for the additional 8 octets when
        it performs Path MTU Discovery
        <xref target="RFC1191"/> <xref target="RFC8201"/> or when it
        determines the effective MTU for inner packets.
      </t>

      <t>
        The effective inner MTU when the header is in use is reduced
        by 8 octets. An implementation <bcp14>SHOULD</bcp14> use
        PMTUD and adjust the tunnel MTU accordingly. When PMTUD is
        not available, the implementation <bcp14>MUST</bcp14> use a
        conservative MTU estimate that accounts for the 8-octet
        header.
      </t>
    </section>

    <section anchor="security" numbered="true" toc="include">
      <name>Security Considerations</name>

      <section anchor="sec-visibility" numbered="true"
               toc="include">
        <name>Information Exposure</name>
        <t>
          The ESP Entropy Header is outside the ESP encryption and
          integrity boundaries, so the Entropy field is visible to
          observers on the path.
        </t>
        <t>
          The Entropy field does not directly carry inner packet
          content. Because its value is typically associated with an
          inner flow, an observer can infer that packets with the
          same Entropy value belong to the same flow, and over time
          the number of distinct Entropy values in a tunnel gives an
          estimate of the number of concurrent flows. This is a form
          of traffic analysis.
        </t>
        <t>
          An operator whose threat model includes flow-level traffic
          analysis by an on-path observer <bcp14>SHOULD</bcp14>
          weigh the benefit of improved load distribution against
          this exposure. Periodically changing the Entropy value of
          a long-lived flow reduces the duration over which packets
          can be correlated, at the cost of moving the flow between
          paths when the value changes.
        </t>
      </section>

      <section anchor="sec-integrity" numbered="true"
               toc="include">
        <name>Header Integrity</name>
        <t>
          The ESP Entropy Header is not integrity-protected by ESP.
          An on-path attacker that can modify packets could alter
          the Entropy field and influence transit path selection,
          for example to concentrate traffic on a subset of paths or
          to direct traffic onto a path the attacker observes.
        </t>
        <t>
          These risks are the same in kind as those from
          modification of other unprotected outer header fields such
          as the DSCP or the IPv6 flow label. An operator that
          requires integrity protection of the outer header chain
          <bcp14>MAY</bcp14> apply AH <xref target="RFC4302"/>
          around the ESP Entropy Header.
        </t>
      </section>

      <section anchor="sec-collision" numbered="true"
               toc="include">
        <name>Entropy Collisions</name>
        <t>
          The 16-bit Entropy field provides 65,536 values. When a
          tunnel carries many concurrent flows, two or more flows
          may share an Entropy value. A collision does not affect
          correctness; it reduces the granularity of load
          distribution for the affected flows.
        </t>
      </section>
    </section>

    <section anchor="ops" numbered="true" toc="include">
      <name>Operational Considerations</name>

      <section anchor="ops-incremental" numbered="true"
               toc="include">
        <name>Incremental Deployment</name>
        <t>
          A transit node that does not recognize the assigned
          protocol number forwards packets using its existing
          outer-header path selection, so the presence of the header
          on a path with non-supporting nodes does not cause packet
          loss. A benefit is obtained at each transit node that
          recognizes the header, independently of the other nodes on
          the path.
        </t>
      </section>

      <section anchor="ops-coexist" numbered="true" toc="include">
        <name>Coexistence with UDP Encapsulation</name>
        <t>
          When IPsec traffic is already encapsulated in UDP, for
          example for NAT traversal <xref target="RFC3948"/>, the
          UDP source port can serve as entropy if the implementation
          varies it per flow. In that case the ESP Entropy Header
          adds no benefit and <bcp14>SHOULD NOT</bcp14> be
          negotiated.
        </t>
      </section>

      <section anchor="ops-loadaware" numbered="true"
               toc="include">
        <name>Relationship to Load-Aware Path Selection</name>
        <t>
          The ESP Entropy Header improves the entropy that a transit
          node can use as input to a static path-selection hash. It
          does not change how a node reacts to load after a flow has
          been placed on a path. Load-aware path selection, such as
          the procedures of
          <xref target="I-D.yang-rtgwg-ecmp-adaptive-load-balance"/>,
          adjusts placement in response to measured load and is
          complementary: better entropy improves the initial
          distribution, and load-aware selection corrects skew that
          develops afterward. The two mechanisms do not conflict.
        </t>
      </section>
    </section>

    <section anchor="iana" numbered="true" toc="include">
      <name>IANA Considerations</name>

      <section anchor="iana-proto" numbered="true" toc="include">
        <name>IP Protocol Number</name>
        <t>
          IANA is requested to assign a value from the "Assigned
          Internet Protocol Numbers" registry. Allocation of an IP
          protocol number requires IESG approval per
          <xref target="RFC5237"/>.
        </t>
        <table anchor="tab-proto">
          <name>Protocol Number Allocation</name>
          <thead>
            <tr>
              <th>Decimal</th>
              <th>Keyword</th>
              <th>Protocol</th>
              <th>Reference</th>
            </tr>
          </thead>
          <tbody>
            <tr>
              <td>TBD1</td>
              <td>EEH</td>
              <td>ESP Entropy Header</td>
              <td>[This document]</td>
            </tr>
          </tbody>
        </table>
      </section>

      <section anchor="iana-notify" numbered="true" toc="include">
        <name>IKEv2 Notify Message Type</name>
        <t>
          IANA is requested to assign a value from the "IKEv2 Notify
          Message Types - Status Types" registry.
        </t>
        <table anchor="tab-notify">
          <name>IKEv2 Notify Message Type Allocation</name>
          <thead>
            <tr>
              <th>Value</th>
              <th>Notify Message Type</th>
              <th>Reference</th>
            </tr>
          </thead>
          <tbody>
            <tr>
              <td>TBD2</td>
              <td>ESP_ENTROPY_HEADER_SUPPORTED</td>
              <td>[This document]</td>
            </tr>
          </tbody>
        </table>
      </section>
    </section>

  </middle>

  <back>

    <references>
      <name>References</name>

      <references>
        <name>Normative References</name>

        <reference anchor="RFC2119"
                   target="https://www.rfc-editor.org/info/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"/>
          </front>
          <seriesInfo name="BCP" value="14"/>
          <seriesInfo name="RFC" value="2119"/>
          <seriesInfo name="DOI" value="10.17487/RFC2119"/>
        </reference>

        <reference anchor="RFC8174"
                   target="https://www.rfc-editor.org/info/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"/>
          </front>
          <seriesInfo name="BCP" value="14"/>
          <seriesInfo name="RFC" value="8174"/>
          <seriesInfo name="DOI" value="10.17487/RFC8174"/>
        </reference>

        <reference anchor="RFC4301"
                   target="https://www.rfc-editor.org/info/rfc4301">
          <front>
            <title>Security Architecture for the Internet
            Protocol</title>
            <author fullname="S. Kent" initials="S."
                    surname="Kent"/>
            <author fullname="K. Seo" initials="K."
                    surname="Seo"/>
            <date month="December" year="2005"/>
          </front>
          <seriesInfo name="RFC" value="4301"/>
          <seriesInfo name="DOI" value="10.17487/RFC4301"/>
        </reference>

        <reference anchor="RFC4303"
                   target="https://www.rfc-editor.org/info/rfc4303">
          <front>
            <title>IP Encapsulating Security Payload (ESP)</title>
            <author fullname="S. Kent" initials="S."
                    surname="Kent"/>
            <date month="December" year="2005"/>
          </front>
          <seriesInfo name="RFC" value="4303"/>
          <seriesInfo name="DOI" value="10.17487/RFC4303"/>
        </reference>

        <reference anchor="RFC7296"
                   target="https://www.rfc-editor.org/info/rfc7296">
          <front>
            <title>Internet Key Exchange Protocol Version 2
            (IKEv2)</title>
            <author fullname="C. Kaufman" initials="C."
                    surname="Kaufman"/>
            <author fullname="P. Hoffman" initials="P."
                    surname="Hoffman"/>
            <author fullname="Y. Nir" initials="Y."
                    surname="Nir"/>
            <author fullname="P. Eronen" initials="P."
                    surname="Eronen"/>
            <author fullname="T. Kivinen" initials="T."
                    surname="Kivinen"/>
            <date month="October" year="2014"/>
          </front>
          <seriesInfo name="STD" value="79"/>
          <seriesInfo name="RFC" value="7296"/>
          <seriesInfo name="DOI" value="10.17487/RFC7296"/>
        </reference>

        <reference anchor="RFC5237"
                   target="https://www.rfc-editor.org/info/rfc5237">
          <front>
            <title>IANA Allocation Guidelines for the Protocol
            Field</title>
            <author fullname="J. Arkko" initials="J."
                    surname="Arkko"/>
            <author fullname="S. Bradner" initials="S."
                    surname="Bradner"/>
            <date month="February" year="2008"/>
          </front>
          <seriesInfo name="BCP" value="37"/>
          <seriesInfo name="RFC" value="5237"/>
          <seriesInfo name="DOI" value="10.17487/RFC5237"/>
        </reference>

        <reference anchor="RFC1191"
                   target="https://www.rfc-editor.org/info/rfc1191">
          <front>
            <title>Path MTU Discovery</title>
            <author fullname="J. Mogul" initials="J."
                    surname="Mogul"/>
            <author fullname="S. Deering" initials="S."
                    surname="Deering"/>
            <date month="November" year="1990"/>
          </front>
          <seriesInfo name="RFC" value="1191"/>
          <seriesInfo name="DOI" value="10.17487/RFC1191"/>
        </reference>

        <reference anchor="RFC8200"
                   target="https://www.rfc-editor.org/info/rfc8200">
          <front>
            <title>Internet Protocol, Version 6 (IPv6)
            Specification</title>
            <author fullname="S. Deering" initials="S."
                    surname="Deering"/>
            <author fullname="R. Hinden" initials="R."
                    surname="Hinden"/>
            <date month="July" year="2017"/>
          </front>
          <seriesInfo name="STD" value="86"/>
          <seriesInfo name="RFC" value="8200"/>
          <seriesInfo name="DOI" value="10.17487/RFC8200"/>
        </reference>

        <reference anchor="RFC8201"
                   target="https://www.rfc-editor.org/info/rfc8201">
          <front>
            <title>Path MTU Discovery for IP version 6</title>
            <author fullname="J. McCann" initials="J."
                    surname="McCann"/>
            <author fullname="S. Deering" initials="S."
                    surname="Deering"/>
            <author fullname="J. Mogul" initials="J."
                    surname="Mogul"/>
            <author fullname="R. Hinden" initials="R."
                    surname="Hinden" role="editor"/>
            <date month="July" year="2017"/>
          </front>
          <seriesInfo name="STD" value="87"/>
          <seriesInfo name="RFC" value="8201"/>
          <seriesInfo name="DOI" value="10.17487/RFC8201"/>
        </reference>

      </references>

      <references>
        <name>Informative References</name>

        <reference anchor="RFC3948"
                   target="https://www.rfc-editor.org/info/rfc3948">
          <front>
            <title>UDP Encapsulation of IPsec ESP Packets</title>
            <author fullname="A. Huttunen" initials="A."
                    surname="Huttunen"/>
            <author fullname="B. Swander" initials="B."
                    surname="Swander"/>
            <author fullname="V. Volpe" initials="V."
                    surname="Volpe"/>
            <author fullname="L. DiBurro" initials="L."
                    surname="DiBurro"/>
            <author fullname="M. Stenberg" initials="M."
                    surname="Stenberg"/>
            <date month="January" year="2005"/>
          </front>
          <seriesInfo name="RFC" value="3948"/>
          <seriesInfo name="DOI" value="10.17487/RFC3948"/>
        </reference>

        <reference anchor="RFC4302"
                   target="https://www.rfc-editor.org/info/rfc4302">
          <front>
            <title>IP Authentication Header</title>
            <author fullname="S. Kent" initials="S."
                    surname="Kent"/>
            <date month="December" year="2005"/>
          </front>
          <seriesInfo name="RFC" value="4302"/>
          <seriesInfo name="DOI" value="10.17487/RFC4302"/>
        </reference>

        <reference anchor="RFC5840"
                   target="https://www.rfc-editor.org/info/rfc5840">
          <front>
            <title>Wrapped Encapsulating Security Payload (ESP) for
            Traffic Visibility</title>
            <author fullname="K. Grewal" initials="K."
                    surname="Grewal"/>
            <author fullname="G. Montenegro" initials="G."
                    surname="Montenegro"/>
            <author fullname="M. Bhatia" initials="M."
                    surname="Bhatia"/>
            <date month="April" year="2010"/>
          </front>
          <seriesInfo name="RFC" value="5840"/>
          <seriesInfo name="DOI" value="10.17487/RFC5840"/>
        </reference>

        <reference anchor="RFC6438"
                   target="https://www.rfc-editor.org/info/rfc6438">
          <front>
            <title>Using the IPv6 Flow Label for Equal Cost
            Multipath Routing and Link Aggregation in
            Tunnels</title>
            <author fullname="B. Carpenter" initials="B."
                    surname="Carpenter"/>
            <author fullname="S. Amante" initials="S."
                    surname="Amante"/>
            <date month="November" year="2011"/>
          </front>
          <seriesInfo name="RFC" value="6438"/>
          <seriesInfo name="DOI" value="10.17487/RFC6438"/>
        </reference>

        <reference anchor="RFC6790"
                   target="https://www.rfc-editor.org/info/rfc6790">
          <front>
            <title>The Use of Entropy Labels in MPLS
            Forwarding</title>
            <author fullname="K. Kompella" initials="K."
                    surname="Kompella"/>
            <author fullname="J. Drake" initials="J."
                    surname="Drake"/>
            <author fullname="S. Amante" initials="S."
                    surname="Amante"/>
            <author fullname="W. Henderickx" initials="W."
                    surname="Henderickx"/>
            <author fullname="L. Yong" initials="L."
                    surname="Yong"/>
            <date month="November" year="2012"/>
          </front>
          <seriesInfo name="RFC" value="6790"/>
          <seriesInfo name="DOI" value="10.17487/RFC6790"/>
        </reference>

        <reference anchor="I-D.xu-ipsecme-esp-in-udp-lb">
          <front>
            <title>Encapsulating IPsec ESP in UDP for
            Load-balancing</title>
            <author fullname="X. Xu" initials="X."
                    surname="Xu"/>
            <author fullname="S. Hegde" initials="S."
                    surname="Hegde"/>
            <author fullname="B. Pismenny" initials="B."
                    surname="Pismenny"/>
            <author fullname="D. Zhang" initials="D."
                    surname="Zhang"/>
            <author fullname="L. Xia" initials="L."
                    surname="Xia"/>
            <date month="March" year="2024"/>
          </front>
          <seriesInfo name="Internet-Draft"
                      value="draft-xu-ipsecme-esp-in-udp-lb-15"/>
        </reference>

        <reference anchor="I-D.acharya-ipsecme-esp-ecmp">
          <front>
            <title>UDP encapsulated ESP for ECMP</title>
            <author fullname="A. Acharya" initials="A."
                    surname="Acharya"/>
            <date year="2023"/>
          </front>
          <seriesInfo name="Internet-Draft"
                      value="draft-acharya-ipsecme-esp-ecmp-00"/>
        </reference>

        <reference
            anchor="I-D.yang-rtgwg-ecmp-adaptive-load-balance">
          <front>
            <title>Adaptive Load Balancing for Equal-Cost Multipath
            (ECMP)</title>
            <author fullname="J. Yang" initials="J."
                    surname="Yang"/>
            <author fullname="W. Cheng" initials="W."
                    surname="Cheng"/>
            <author fullname="J. Wang" initials="J."
                    surname="Wang"/>
            <author fullname="G. Zhang" initials="G."
                    surname="Zhang"/>
            <date year="2026"/>
          </front>
          <seriesInfo name="Internet-Draft"
              value="draft-yang-rtgwg-ecmp-adaptive-load-balance-00"/>
        </reference>

      </references>
    </references>

    <section anchor="ack" numbered="false">
      <name>Acknowledgements</name>
      <t>
        The use of an entropy value to distribute load for
        encapsulated traffic is established in the MPLS architecture
        through entropy labels <xref target="RFC6790"/> and in IPv6
        through the flow label <xref target="RFC6438"/>. This
        document applies the same idea within the IPsec protocol
        stack.
      </t>
    </section>

  </back>
</rfc>
