<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE rfc [
  <!ENTITY RFC2119 SYSTEM "https://bib.ietf.org/public/rfc/bibxml/reference.RFC.2119.xml">
  <!ENTITY RFC6550 SYSTEM "https://bib.ietf.org/public/rfc/bibxml/reference.RFC.6550.xml">
  <!ENTITY RFC6554 SYSTEM "https://bib.ietf.org/public/rfc/bibxml/reference.RFC.6554.xml">
  <!ENTITY RFC8174 SYSTEM "https://bib.ietf.org/public/rfc/bibxml/reference.RFC.8174.xml">
  <!ENTITY RFC7942 SYSTEM "https://bib.ietf.org/public/rfc/bibxml/reference.RFC.7942.xml">
]>
<?rfc toc="yes"?>
<?rfc symrefs="yes"?>
<?rfc sortrefs="yes"?>
<?rfc compact="yes"?>
<?rfc subcompact="no"?>
<rfc xmlns:xi="http://www.w3.org/2001/XInclude"
     category="exp"
     docName="draft-silva-hymrpl-01"
     ipr="trust200902"
     submissionType="independent">

  <front>
    <title abbrev="HyMRPL">
      HyMRPL: Per-Node Hybrid Mode of Operation and Inter-DODAG
      Bridge Mechanism for RPL
    </title>

    <author fullname="Cassius Clay Batista da Silva Filho"
            initials="C. C. B."
            surname="Silva Filho">
      <organization>Instituto Metropole Digital (IMD) - UFRN</organization>
      <address>
        <postal>
          <city>Natal</city>
          <region>RN</region>
          <country>Brazil</country>
        </postal>
        <email>cassius.filho.700@ufrn.edu.br</email>
      </address>
    </author>

    <author fullname="Ramon dos Reis Fontes"
            initials="R. R."
            surname="Fontes">
      <organization>Instituto Metropole Digital (IMD) - UFRN</organization>
      <address>
        <postal>
          <city>Natal</city>
          <region>RN</region>
          <country>Brazil</country>
        </postal>
        <email>ramonfontes@imd.ufrn.br</email>
      </address>
    </author>


    <date year="2026" month="July" day="21"/>

    <area>Routing</area>
    <workgroup>Internet Engineering Task Force</workgroup>

    <keyword>RPL</keyword>
    <keyword>MOP</keyword>
    <keyword>MOPex</keyword>
    <keyword>hybrid</keyword>
    <keyword>6LoWPAN</keyword>
    <keyword>IoT</keyword>
    <keyword>LLN</keyword>

    <abstract>
      <t>
        The Routing Protocol for Low-Power and Lossy Networks (RPL),
        defined in RFC 6550, enforces a single Mode of Operation (MOP)
        across all nodes within a DODAG. This rigidity prevents
        heterogeneous devices from independently selecting their
        forwarding behavior and creates permanent isolation between
        DODAGs operating with different MOPs.
      </t>
      <t>
        This document defines HyMRPL, a Hybrid Mode of Operation
        (MOP=6) that enables per-node functional profiles within a
        single DODAG. Nodes independently adopt Class-S
        (storing-like) or Class-N (non-storing-like) behavior without
        modifying RPL control message formats. Additionally, this
        document specifies an Inter-DODAG Bridge mechanism that uses
        MOP Extension (MOPex) signaling to interconnect DODAGs with
        different MOPs through cross-DODAG route injection.
      </t>
      <t>
        The mechanisms introduce zero additional control messages,
        maintain full backward compatibility via the J-flag in
        extended options, and have been validated with a functional
        implementation demonstrating 100% packet delivery ratio
        across MOP boundaries.
      </t>
    </abstract>
  </front>

  <middle>

    <!-- ===== SECTION 1: Introduction ===== -->
    <section anchor="introduction" numbered="true" toc="default">
      <name>Introduction</name>

      <t>
        The Routing Protocol for Low-Power and Lossy Networks (RPL)
        <xref target="RFC6550"/> organizes communication through
        Destination-Oriented Directed Acyclic Graphs (DODAGs) and
        defines four Modes of Operation (MOP) that determine how
        downward routes are established and maintained. The MOP is a
        3-bit field in DIO messages set globally by the DODAG root
        and enforced uniformly across all participating nodes.
      </t>

      <t>
        This architectural constraint creates two problems in
        heterogeneous IoT deployments:
      </t>

      <ol>
        <li>
          <strong>Intra-DODAG rigidity:</strong> All nodes must
          implement the same MOP regardless of individual
          capabilities. Memory-constrained devices cannot operate as
          Non-Storing within a Storing DODAG, and capable devices
          cannot maintain local routing tables within a Non-Storing
          DODAG.
        </li>
        <li>
          <strong>Inter-DODAG isolation:</strong> DODAGs with
          different MOPs are completely incompatible. No mechanism
          exists for routing information exchange or data forwarding
          across MOP boundaries, creating permanently fragmented
          network islands.
        </li>
      </ol>

      <t>
        This document addresses both problems by defining:
      </t>

      <ol>
        <li>
          A Hybrid Mode of Operation (MOP=6) that enables per-node
          functional profiles (Class-S and Class-N) within a single
          DODAG without modifying RPL message formats.
        </li>
        <li>
          An Inter-DODAG Bridge mechanism that leverages MOPex
          signaling <xref target="I-D.ietf-roll-mopex"/> to
          interconnect DODAGs with different MOPs through MOP
          masquerading and cross-DODAG route injection.
        </li>
      </ol>

      <section anchor="requirements-language" numbered="true" toc="default">
        <name>Requirements Language</name>
        <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 anchor="terminology" numbered="true" toc="default">
        <name>Terminology</name>
        <t>
          This document uses terminology from <xref target="RFC6550"/>
          and additionally defines:
        </t>
        <dl>
          <dt>HyMRPL:</dt>
          <dd>Hybrid Mode RPL. The mechanism defined in this document
              enabling per-node MOP behavior within a single DODAG.</dd>
          <dt>Class-S:</dt>
          <dd>Storing-like profile. A node that maintains downward
              routing tables and performs target aggregation in DAO
              messages.</dd>
          <dt>Class-N:</dt>
          <dd>Non-storing-like profile. A node that maintains no
              downward state and delegates routing to the root's
              Source Routing Header (SRH) mechanism.</dd>
          <dt>MOPex Bridge:</dt>
          <dd>A node that participates in multiple DODAGs with
              different MOPs simultaneously, performing route
              translation and cross-DODAG injection.</dd>
          <dt>Foreign DODAG:</dt>
          <dd>A DODAG with a MOP different from the bridge's native
              mode, which the bridge has joined for translation
              purposes.</dd>
          <dt>MOP Masquerading:</dt>
          <dd>The technique of advertising MOP=7 (Extended) in DIO
              headers while carrying the real MOP value in a MOPex
              option, enabling backward-compatible inter-DODAG
              signaling.</dd>
        </dl>
      </section>
    </section>

    <!-- ===== SECTION 2: Problem Statement ===== -->
    <section anchor="problem" numbered="true" toc="default">
      <name>Problem Statement</name>

      <t>
        RFC 6550 Section 6.3.1 specifies that the MOP field in DIO
        messages determines how downward routes are established for
        the entire DODAG. A node that does not support the
        advertised MOP MUST either join as a leaf (if it supports
        the MOP for upward routes only) or not join at all. This
        creates several operational challenges:
      </t>

      <section anchor="problem-intra" numbered="true" toc="default">
        <name>Intra-DODAG Heterogeneity</name>
        <t>
          In a network where some nodes have sufficient memory for
          routing tables (suitable for Storing mode) while others are
          severely constrained (suitable for Non-Storing mode), the
          administrator must choose a single MOP. Choosing Storing
          (MOP=2) wastes the memory-constrained nodes' resources on
          routing tables they cannot adequately maintain. Choosing
          Non-Storing (MOP=1) wastes the capable nodes' resources by
          not utilizing their local forwarding ability, increasing
          latency for paths that could be resolved locally.
        </t>
        <t>
          No mechanism exists in RFC 6550 for individual nodes to
          independently select their forwarding behavior based on
          their own resource constraints within a single DODAG.
        </t>
      </section>

      <section anchor="problem-inter" numbered="true" toc="default">
        <name>Inter-DODAG Isolation</name>
        <t>
          When a network contains multiple DODAGs with different MOPs
          (e.g., a Storing DODAG for sensor nodes and a Non-Storing
          DODAG for actuators), no mechanism exists for:
        </t>
        <ul>
          <li>Advertising routes from one DODAG into another</li>
          <li>Translating DAO messages between different MOP formats</li>
          <li>Forwarding data packets across MOP boundaries</li>
        </ul>
        <t>
          This creates permanent isolation between MOP domains with
          no recovery mechanism defined in the protocol.
        </t>
      </section>
    </section>

    <!-- ===== SECTION 3: HyMRPL - Hybrid MOP ===== -->
    <section anchor="hymrpl" numbered="true" toc="default">
      <name>HyMRPL: Hybrid Mode of Operation (MOP=6)</name>

      <section anchor="hymrpl-overview" numbered="true" toc="default">
        <name>Overview</name>
        <t>
          HyMRPL defines MOP=6 as a Hybrid Mode of Operation. When
          the DODAG root advertises MOP=6 in DIO messages, each node
          in the DODAG independently selects one of two functional
          profiles based on its own capabilities:
        </t>
        <ul>
          <li>
            <strong>Class-S (Storing-like):</strong> The node
            maintains downward routing tables, installs routes via the
            operating system's routing subsystem, and aggregates child
            targets in DAO messages sent toward the root.
          </li>
          <li>
            <strong>Class-N (Non-storing-like):</strong> The node
            maintains no downward routing state. It forwards DAO
            messages without modification toward the root, which
            maintains full topology visibility and installs Source
            Routing Header (SRH) routes for paths traversing Class-N
            nodes.
          </li>
        </ul>
        <t>
          No modification is introduced to DIO, DAO, or DIS message
          formats. The hybrid logic operates entirely at the
          behavioral level within the RPL implementation.
        </t>
      </section>

      <section anchor="hymrpl-class-selection" numbered="true" toc="default">
        <name>Class Selection</name>
        <t>
          A node operating under MOP=6 MUST select either Class-S or
          Class-N upon joining the DODAG. The selection mechanism is
          implementation-specific but SHOULD consider:
        </t>
        <ul>
          <li>Available memory for routing table entries</li>
          <li>Energy budget and expected lifetime</li>
          <li>Link stability to parent node</li>
          <li>Administrative policy (static configuration)</li>
        </ul>
        <t>
          This document defines an adaptive selection model in
          <xref target="adaptive-model"/> that computes a composite
          score from multiple metrics.
        </t>
        <t>
          A node MAY change its class at runtime without requiring
          DODAG reconstruction. The class change takes effect at the
          next DAO transmission cycle. No DIO is emitted upon class
          change, and no global signaling is required.
        </t>
      </section>

      <section anchor="hymrpl-dao" numbered="true" toc="default">
        <name>DAO Processing Under MOP=6</name>
        <t>
          Under MOP=6, DAO processing is class-dependent:
        </t>

        <section anchor="hymrpl-dao-root" numbered="true" toc="default">
          <name>Root Behavior</name>
          <t>
            The DODAG root under MOP=6 MUST:
          </t>
          <ol>
            <li>
              Accept DAO messages from all nodes regardless of their
              class.
            </li>
            <li>
              Maintain a complete source routing tree (as in
              Non-Storing mode) enabling SRH-based forwarding for
              any path containing at least one Class-N node.
            </li>
            <li>
              Install SRH lightweight tunnel routes via the
              operating system's routing interface for paths that
              require source routing.
            </li>
          </ol>
        </section>

        <section anchor="hymrpl-dao-classS" numbered="true" toc="default">
          <name>Class-S Node Behavior</name>
          <t>
            A Class-S node receiving a DAO from a child MUST:
          </t>
          <ol>
            <li>
              Install a downward route for each target in the DAO
              via the local routing table (as in Storing mode).
            </li>
            <li>
              Aggregate the child's targets into its own DAO message
              sent toward the parent AND the root (dual-DAO).
            </li>
          </ol>
          <t>
            The dual-DAO mechanism ensures the root always maintains
            complete topology visibility (enabling SRH for any
            Class-N path) while Class-S nodes simultaneously
            maintain local hop-by-hop routes for immediate
            descendants.
          </t>
        </section>

        <section anchor="hymrpl-dao-classN" numbered="true" toc="default">
          <name>Class-N Node Behavior</name>
          <t>
            A Class-N node receiving a DAO from a child MUST:
          </t>
          <ol>
            <li>
              NOT install any downward route locally.
            </li>
            <li>
              Forward the DAO without modification toward the
              preferred parent (and/or root).
            </li>
          </ol>
          <t>
            This behavior is identical to Non-Storing mode
            processing at intermediate nodes.
          </t>
        </section>
      </section>

      <section anchor="hymrpl-forwarding" numbered="true" toc="default">
        <name>Downward Forwarding Behavior</name>
        <t>
          Three forwarding patterns emerge within a MOP=6 DODAG:
        </t>
        <ol>
          <li>
            <strong>Purely storing paths:</strong> All nodes in the
            downward path are Class-S. Forwarding is hop-by-hop via
            locally installed routes. No SRH is needed.
          </li>
          <li>
            <strong>Purely non-storing paths:</strong> At least one
            node in the path is Class-N. The root uses SRH
            (RFC 6554 <xref target="RFC6554"/>) to route packets
            through the complete path.
          </li>
          <li>
            <strong>Mixed paths:</strong> Class-S segments forward
            hop-by-hop until reaching a Class-N segment, at which
            point the root's SRH takes over for the remainder.
          </li>
        </ol>
      </section>

      <section anchor="adaptive-model" numbered="true" toc="default">
        <name>Adaptive Class Selection Model</name>
        <t>
          This document defines an OPTIONAL adaptive model for
          automatic class selection. The model computes a composite
          score S_i for node i:
        </t>
        <t>
          S_i = w_pdr * (PDR_i / 100) + w_energy * (E_i / 100)
                + w_stab * I[parent_stable]
        </t>
        <t>
          Where:
        </t>
        <ul>
          <li>w_pdr = 0.4 (weight for packet delivery ratio)</li>
          <li>w_energy = 0.3 (weight for remaining energy)</li>
          <li>w_stab = 0.3 (weight for parent stability indicator)</li>
          <li>PDR_i = sliding window DAO-ACK success ratio</li>
          <li>E_i = battery level (0-100, EMA smoothed)</li>
          <li>I[parent_stable] = 1 if parent stable, 0 otherwise</li>
        </ul>
        <t>
          If S_i >= 0.75 (threshold), the node selects Class-S.
          Otherwise, it selects Class-N. A hysteresis of 3
          consecutive evaluation cycles prevents oscillation.
        </t>
        <t>
          Implementations MAY use different scoring functions,
          weights, or thresholds appropriate to their deployment
          scenario. The specific model defined here is RECOMMENDED
          as a baseline.
        </t>
      </section>

      <section anchor="hymrpl-switching" numbered="true" toc="default">
        <name>Runtime Class Switching</name>
        <t>
          A node operating under MOP=6 MAY switch its class at
          runtime. The switch:
        </t>
        <ul>
          <li>MUST NOT trigger emission of new DIO messages</li>
          <li>MUST NOT cause DODAG reconstruction</li>
          <li>MUST take effect at the next DAO cycle</li>
          <li>MUST be reversible</li>
        </ul>
        <t>
          The switching mechanism is implementation-specific. This
          document recommends a secure command interface with
          authentication (e.g., HMAC-SHA256), replay protection
          (monotonic nonce), and rate limiting (maximum 3 switches
          per minute, minimum 10 seconds between switches) to
          prevent abuse.
        </t>
      </section>
    </section>

    <!-- ===== SECTION 4: MOPex Bridge ===== -->
    <section anchor="mopex-bridge" numbered="true" toc="default">
      <name>Inter-DODAG Bridge Mechanism</name>

      <section anchor="mopex-overview" numbered="true" toc="default">
        <name>Overview</name>
        <t>
          The Inter-DODAG Bridge mechanism enables connectivity
          between DODAGs operating with different MOPs. A bridge
          node participates in multiple DODAGs simultaneously,
          translating routing information and enabling data
          forwarding across MOP boundaries.
        </t>
        <t>
          The bridge leverages MOPex signaling
          <xref target="I-D.ietf-roll-mopex"/> to advertise its
          presence using MOP=7 (Extended) in DIO headers, with the
          real MOP carried in the extended option. This ensures
          backward compatibility: legacy nodes receiving MOP=7 DIOs
          will join as leaf per RFC 6550 Section 6.3.1 handling of
          unknown MOP values.
        </t>
      </section>

      <section anchor="mopex-wire" numbered="true" toc="default">
        <name>Wire Format</name>
        <t>
          The bridge uses MOP=7 in the DIO header's MOP field (bits
          5-3 of the mopprf byte) and appends a 4-byte Extended RPL
          Control Option per <xref target="I-D.ietf-roll-mopex"/>:
        </t>
        <figure>
          <artwork><![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
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|1|  Opt Type   | Option Length | Option Flags  |  MOPex Value  |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
]]></artwork>
        </figure>
        <t>
          Field descriptions:
        </t>
        <dl>
          <dt>X bit (MSB of Option Type):</dt>
          <dd>Set to 1, yielding Option Type = 0x80. This marks the
              option as an Extended RPL Control Option.</dd>
          <dt>Option Length:</dt>
          <dd>2 (covers Flags + MOPex Value fields).</dd>
          <dt>Option Flags:</dt>
          <dd>
            <ul>
              <li>J (bit 7): Join as leaf only. MUST be set to 1 by
                  bridge nodes to ensure legacy nodes that do not
                  understand MOPex do not become routers in the
                  bridge's DODAG.</li>
              <li>C (bit 6): Copy option in forwarded DIOs. Set to
                  0 by default.</li>
              <li>I (bit 5): Ignore entire message if option not
                  understood. Set to 0 by default.</li>
              <li>Bits 4-0: Reserved, set to 0.</li>
            </ul>
          </dd>
          <dt>MOPex Value:</dt>
          <dd>The actual Mode of Operation implemented by this node.
              For HyMRPL bridge nodes, this is 6 (Hybrid). Other
              values follow the MOPex Value Registry defined in
              <xref target="I-D.ietf-roll-mopex"/>.</dd>
        </dl>
      </section>

      <section anchor="mopex-bridge-arch" numbered="true" toc="default">
        <name>Bridge Architecture</name>
        <t>
          A MOPex Bridge node operates with five components:
        </t>

        <section anchor="mopex-masquerade" numbered="true" toc="default">
          <name>MOP Masquerading</name>
          <t>
            When building DIO messages, a bridge node MUST:
          </t>
          <ol>
            <li>
              Set the MOP field in the DIO header to 7 (Extended).
            </li>
            <li>
              Append the Extended RPL Control Option (type 0x80)
              containing the node's native MOP value and the J flag
              set to 1.
            </li>
          </ol>
          <t>
            This allows MOPex-capable receivers to determine the
            bridge's true mode while legacy receivers see MOP=7
            (unknown) and apply the behavior specified in RFC 6550
            Section 6.3.1 for unknown MOP values (join as leaf if
            possible, or do not join).
          </t>
        </section>

        <section anchor="mopex-foreign" numbered="true" toc="default">
          <name>Foreign DODAG Registration</name>
          <t>
            When a bridge node receives a DIO from a DODAG with a
            MOP different from its native mode, it MUST:
          </t>
          <ol>
            <li>
              Verify that it can support the foreign MOP
              (implementation-specific capability check).
            </li>
            <li>
              Register the foreign DODAG in a local table, recording
              the RPL Instance ID, DODAGID, original MOP, and MOPex
              value (if MOP=7).
            </li>
            <li>
              Join the foreign DODAG as a router (if capable) or
              leaf, creating a local DAG structure for participation
              in that DODAG's routing protocol.
            </li>
          </ol>
          <t>
            A bridge node SHOULD support up to 4 simultaneous
            foreign DODAGs. If the foreign DODAG table is full,
            the bridge MUST NOT join additional foreign DODAGs.
          </t>
          <t>
            The bridge MUST handle re-registration (updates to
            existing entries) when receiving subsequent DIOs from
            already-registered foreign DODAGs, and MUST remove
            entries when a foreign DODAG becomes unreachable
            (parent timeout or explicit notification).
          </t>
        </section>

        <section anchor="mopex-injection" numbered="true" toc="default">
          <name>Cross-DODAG Route Injection</name>
          <t>
            The core mechanism enabling inter-DODAG connectivity.
            When the bridge processes a DAO from DODAG X containing
            targets T_1 through T_n, it MUST:
          </t>
          <ol>
            <li>
              For each other DODAG Y (where Y != X) that the bridge
              participates in:
              <ol>
                <li>
                  Add each target T_i as a child entry in the
                  bridge's local DAG structure for DODAG Y, with
                  the bridge's own address as the next-hop.
                </li>
              </ol>
            </li>
            <li>
              Include the injected targets in the bridge's next
              periodic DAO message toward the root of DODAG Y.
            </li>
          </ol>
          <t>
            This causes the root of DODAG Y to install routes for
            T_1 through T_n via the bridge, enabling data forwarding
            from DODAG Y to nodes in DODAG X.
          </t>
          <t>
            Route injection MUST include deduplication: before adding
            a target to DODAG Y, the bridge MUST check if an
            identical prefix is already present. Duplicate entries
            MUST NOT be added.
          </t>
          <t>
            The bridge SHOULD maintain a maximum of 32 injected
            routes per foreign DODAG to prevent unbounded table
            growth.
          </t>
        </section>

        <section anchor="mopex-dao-translation" numbered="true" toc="default">
          <name>DAO Translation</name>
          <t>
            When translating DAOs between DODAGs with different MOPs,
            the bridge performs format conversion:
          </t>

          <section anchor="dao-storing-to-nonstoring" numbered="true" toc="default">
            <name>Storing to Non-Storing Translation</name>
            <t>
              A Storing-mode DAO contains RPL Target options without
              Transit Information (the DAO sender is the implicit
              next-hop). When translating to a Non-Storing DODAG,
              the bridge MUST:
            </t>
            <ol>
              <li>Copy all RPL Target options unchanged.</li>
              <li>
                Add a Transit Information option with the bridge's
                own address in the "parent" field, indicating to the
                Non-Storing root that packets for these targets
                should be routed via the bridge.
              </li>
            </ol>
          </section>

          <section anchor="dao-nonstoring-to-storing" numbered="true" toc="default">
            <name>Non-Storing to Storing Translation</name>
            <t>
              A Non-Storing DAO contains RPL Target options with
              Transit Information carrying the full source routing
              path. When translating to a Storing DODAG, the bridge
              MUST:
            </t>
            <ol>
              <li>Copy all RPL Target options unchanged.</li>
              <li>
                Strip the Transit Information option (Storing mode
                does not use it; the DAO sender is the implicit
                next-hop).
              </li>
              <li>
                The receiving root in the Storing DODAG will
                interpret the bridge as the next-hop for all
                contained targets.
              </li>
            </ol>
          </section>

          <section anchor="dao-hybrid" numbered="true" toc="default">
            <name>Hybrid (MOP=6) Translation</name>
            <t>
              MOP=6 DODAGs use a dual-DAO mechanism where DAOs are
              sent toward both the parent and the root. The bridge
              MUST handle both Storing-style DAOs (with aggregated
              targets from Class-S subtrees) and Non-Storing-style
              DAOs (with Transit Information from Class-N paths)
              using the appropriate translation rules above based on
              the target DODAG's MOP.
            </t>
          </section>
        </section>

        <section anchor="mopex-data-forwarding" numbered="true" toc="default">
          <name>Data Forwarding</name>
          <t>
            Once routes are injected and propagated via standard DAO
            mechanisms, cross-DODAG data forwarding requires no
            special handling at the bridge. The bridge acts as a
            regular intermediate hop:
          </t>
          <ul>
            <li>
              Packets from DODAG A addressed to prefixes in DODAG B
              are forwarded by root A toward the bridge (which has
              advertised those prefixes via DAO).
            </li>
            <li>
              The bridge receives the packet and forwards it into
              DODAG B using its routes in that domain (either via
              hop-by-hop routing for Storing or via SRH for
              Non-Storing).
            </li>
          </ul>
          <t>
            No encapsulation, tunneling, or special packet marking
            is required for cross-DODAG data transit.
          </t>
        </section>
      </section>

      <section anchor="mopex-dio-scanning" numbered="true" toc="default">
        <name>DIO Option Processing</name>
        <t>
          A bridge node receiving a DIO MUST scan all options in the
          DIO options area to locate the Extended RPL Control Option
          (type 0x80), regardless of option ordering. The bridge
          MUST NOT assume the destination prefix option (type 0x03)
          is always the first option after the DIO base header.
        </t>
        <t>
          If a DIO carries MOP=7 in the header:
        </t>
        <ol>
          <li>
            The bridge MUST parse the MOPex option to determine the
            real MOP value.
          </li>
          <li>
            If the MOPex option is not found, the bridge MUST treat
            the DIO as having an unknown MOP and MUST NOT join as a
            router.
          </li>
          <li>
            If an unknown extended option is encountered with the I
            flag set, the bridge MUST ignore the entire DIO message.
          </li>
        </ol>
      </section>

      <section anchor="mopex-backward" numbered="true" toc="default">
        <name>Backward Compatibility</name>
        <t>
          The J flag (Join as leaf only) in the MOPex option ensures
          incremental deployability:
        </t>
        <ul>
          <li>
            Existing RPL implementations that receive MOP=7 DIOs
            will not understand the MOP and, per RFC 6550 Section
            6.3.1, will either join as leaf nodes or not join at
            all.
          </li>
          <li>
            The J=1 flag explicitly signals that nodes not
            understanding the MOPex option SHOULD join only as leaf.
          </li>
          <li>
            Only bridge nodes require MOPex-aware firmware. All
            other nodes can run standard RPL implementations.
          </li>
        </ul>
      </section>
    </section>

    <!-- ===== SECTION 5: Security Considerations ===== -->
    <section anchor="security" numbered="true" toc="default">
      <name>Security Considerations</name>

      <section anchor="security-class-switching" numbered="true" toc="default">
        <name>Class Switching Authentication</name>
        <t>
          Runtime class switching (Section 3.6) introduces a control
          plane interface that could be exploited by an attacker to
          force nodes into suboptimal classes, degrading network
          performance. Implementations providing external class
          switching interfaces MUST implement:
        </t>
        <ul>
          <li>
            Authentication of switch commands (e.g., HMAC-SHA256
            with a pre-shared key).
          </li>
          <li>
            Replay protection using monotonically increasing nonces.
          </li>
          <li>
            Rate limiting (RECOMMENDED: maximum 3 switches per
            minute, minimum 10 seconds between consecutive
            switches).
          </li>
        </ul>
      </section>

      <section anchor="security-bridge" numbered="true" toc="default">
        <name>Bridge Route Injection Security</name>
        <t>
          The cross-DODAG route injection mechanism
          (Section 4.3.3) creates a potential attack vector: a
          malicious bridge could advertise false routes between
          DODAGs, redirecting traffic through an attacker-controlled
          node (route poisoning).
        </t>
        <t>
          Mitigations:
        </t>
        <ul>
          <li>
            Bridge nodes SHOULD be administratively authorized.
            Implementations MAY require explicit configuration
            (e.g., a "mopex_bridge=true" flag) to prevent
            arbitrary nodes from acting as bridges.
          </li>
          <li>
            Route injection SHOULD be limited to prefixes actually
            learned from the foreign DODAG's DAO messages. A bridge
            MUST NOT inject routes for prefixes it has not received
            via legitimate DAO processing.
          </li>
          <li>
            The maximum number of injected routes per foreign DODAG
            SHOULD be bounded (this document recommends 32) to
            limit the blast radius of a compromised bridge.
          </li>
          <li>
            Implementations MAY support RPL security modes (RFC 6550
            Section 10) to authenticate DAO messages between the
            bridge and DODAG roots.
          </li>
        </ul>
      </section>

      <section anchor="security-mop7" numbered="true" toc="default">
        <name>MOP=7 Spoofing</name>
        <t>
          An attacker could emit DIOs with MOP=7 and a forged MOPex
          option to attract nodes. The J flag mitigates this by
          ensuring that nodes not understanding MOPex join only as
          leaf, limiting the attacker's ability to attract routing
          traffic. However, MOPex-capable nodes could still be
          deceived.
        </t>
        <t>
          Deployments operating in adversarial environments SHOULD
          use RPL security mode (authenticated DIOs per RFC 6550
          Section 10) in addition to the mechanisms defined here.
        </t>
      </section>
    </section>

    <!-- ===== SECTION 6: IANA Considerations ===== -->
    <section anchor="iana" numbered="true" toc="default">
      <name>IANA Considerations</name>

      <section anchor="iana-mop" numbered="true" toc="default">
        <name>Mode of Operation Registry</name>
        <t>
          This document requests IANA to assign the following value
          in the "RPL Mode of Operation" registry defined by
          RFC 6550:
        </t>
        <table>
          <thead>
            <tr>
              <th>Value</th>
              <th>Description</th>
              <th>Reference</th>
            </tr>
          </thead>
          <tbody>
            <tr>
              <td>6</td>
              <td>Hybrid Mode (HyMRPL): Per-node Class-S/Class-N
                  profiles within a single DODAG</td>
              <td>[This Document]</td>
            </tr>
          </tbody>
        </table>
        <t>
          Note: MOP value 7 is defined by
          <xref target="I-D.ietf-roll-mopex"/> as "Extended MOP"
          and is not requested by this document. This document
          defines the semantics for MOPex Value = 6 in the MOPex
          Value Registry.
        </t>
      </section>

      <section anchor="iana-mopex-value" numbered="true" toc="default">
        <name>MOPex Value Registry</name>
        <t>
          This document requests IANA to assign the following value
          in the "MOPex Value" registry defined by
          <xref target="I-D.ietf-roll-mopex"/>:
        </t>
        <table>
          <thead>
            <tr>
              <th>Value</th>
              <th>Description</th>
              <th>Reference</th>
            </tr>
          </thead>
          <tbody>
            <tr>
              <td>6</td>
              <td>Hybrid Mode of Operation (HyMRPL)</td>
              <td>[This Document]</td>
            </tr>
          </tbody>
        </table>
      </section>
    </section>

    <!-- ===== SECTION 7: Implementation Status ===== -->
    <section anchor="implementation" numbered="true" toc="default">
      <name>Implementation Status</name>
      <t>
        [Note to RFC Editor: This section is to be removed before
        publication as an RFC. It is present per RFC 7942
        <xref target="RFC7942"/>.]
      </t>

      <section anchor="impl-rpld" numbered="true" toc="default">
        <name>rpld Implementation</name>
        <t>
          Organization: Instituto Metropole Digital, UFRN, Brazil
        </t>
        <t>
          Implementation Name: rpld-hymrpl
        </t>
        <t>
          Description: Extension of rpld (user-space RPL daemon for
          Linux) implementing both HyMRPL (MOP=6) and the MOPex
          bridge mechanism. The implementation adds approximately
          1000 lines of C code to rpld.
        </t>
        <t>
          Maturity Level: Experimental
        </t>
        <t>
          Coverage: This implementation covers the full specification
          defined in this document including:
        </t>
        <ul>
          <li>MOP=6 announcement in DIO messages</li>
          <li>Class-S and Class-N per-node behavior</li>
          <li>Dual-DAO processing</li>
          <li>Adaptive class selection model</li>
          <li>Secure runtime class switching via FIFO with HMAC</li>
          <li>MOPex option building and parsing (type 0x80)</li>
          <li>MOP masquerading (MOP=7 in DIO header)</li>
          <li>Foreign DODAG registration (up to 4)</li>
          <li>Cross-DODAG route injection with deduplication</li>
          <li>DAO translation between Storing and Non-Storing</li>
        </ul>
        <t>
          Licensing: Open source (available at
          https://github.com/CassiusClayB/rpld_hymrpl)
        </t>
        <t>
          Implementation Experience:
        </t>
        <ul>
          <li>
            Tested on Linux kernel 6.11.0 with
            CONFIG_IPV6_RPL_LWTUNNEL for native SRH support.
          </li>
          <li>
            Validated using Mininet-WiFi with 6LoWPAN over virtual
            IEEE 802.15.4 (mac802154_hwsim) in topologies from 5 to
            50 nodes.
          </li>
          <li>
            Over 100 independent experiment runs across 12 test
            categories demonstrate 100% PDR for intra-DODAG paths
            and 100% PDR for cross-DODAG paths through the bridge.
          </li>
          <li>
            Packet captures confirm MOP=7 visible on the wire with
            the 4-byte extended option (type 0x80, J=1, value=6).
          </li>
          <li>
            10,266 data packets captured transiting through the
            bridge between DODAGs in a single experiment run.
          </li>
          <li>
            Convergence time for HyMRPL is up to 35% faster than
            Storing mode at 20 nodes.
          </li>
          <li>
            Under intermediate node failure, the dual reconvergence
            mechanism achieves 87.2% PDR vs. 64.1% for pure
            Non-Storing (23 percentage point advantage).
          </li>
        </ul>
        <t>
          Contact: Cassius Clay B. Silva Filho
          &lt;cassius.filho.700@ufrn.edu.br&gt;
        </t>
      </section>
    </section>

    <!-- ===== SECTION 8: Operational Considerations ===== -->
    <section anchor="operational" numbered="true" toc="default">
      <name>Operational Considerations</name>

      <section anchor="op-overhead" numbered="true" toc="default">
        <name>Overhead</name>
        <t>
          The mechanisms defined in this document introduce minimal
          overhead:
        </t>
        <table>
          <thead>
            <tr>
              <th>Aspect</th>
              <th>HyMRPL (MOP=6)</th>
              <th>MOPex Bridge</th>
            </tr>
          </thead>
          <tbody>
            <tr>
              <td>DIO size increase</td>
              <td>0 bytes</td>
              <td>+4 bytes (MOPex option)</td>
            </tr>
            <tr>
              <td>Additional control messages</td>
              <td>0</td>
              <td>0</td>
            </tr>
            <tr>
              <td>Memory per node</td>
              <td>+1 byte (class field)</td>
              <td>~2 KB (bridge state)</td>
            </tr>
            <tr>
              <td>Code size</td>
              <td>~300 lines</td>
              <td>~700 lines</td>
            </tr>
          </tbody>
        </table>
      </section>

      <section anchor="op-scalability" numbered="true" toc="default">
        <name>Scalability</name>
        <t>
          The convergence advantage of MOP=6 over pure Storing mode
          grows superlinearly with network size (observed: 23% at 5
          nodes to 35% at 20 nodes). This is because MOP=6 avoids
          the distributed routing table maintenance overhead that
          limits Storing mode scalability.
        </t>
        <t>
          The bridge mechanism scales with the number of foreign
          DODAGs (bounded at 4) and the number of injected routes
          per foreign DODAG (bounded at 32). Deployments requiring
          more capacity may increase these bounds at the cost of
          additional memory on the bridge node.
        </t>
      </section>

      <section anchor="op-deployment" numbered="true" toc="default">
        <name>Deployment Guidance</name>
        <t>
          Recommended deployment patterns:
        </t>
        <ul>
          <li>
            <strong>Single DODAG with mixed capabilities:</strong>
            Use MOP=6 with Class-S for capable routers and Class-N
            for constrained sensors. This requires only the root
            and participating nodes to support MOP=6.
          </li>
          <li>
            <strong>Multiple existing DODAGs:</strong> Deploy a
            bridge node with physical connectivity to both DODAGs.
            Only the bridge requires MOPex support; all other nodes
            continue operating with their existing MOP.
          </li>
          <li>
            <strong>Gradual migration:</strong> Start with MOP=6
            for new deployments. Add bridge nodes when
            interconnection with legacy MOP=2 or MOP=1 DODAGs is
            needed. The J flag ensures no disruption to existing
            networks.
          </li>
        </ul>
      </section>
    </section>

  </middle>

  <back>
    <references>
      <name>References</name>

      <references>
        <name>Normative References</name>
        &RFC2119;
        &RFC6550;
        &RFC6554;
        &RFC8174;

        <reference anchor="I-D.ietf-roll-mopex">
          <front>
            <title>RPL Mode of Operation Extension</title>
            <author initials="R." surname="Jadhav" fullname="Rahul Jadhav"/>
            <author initials="P." surname="Thubert" fullname="Pascal Thubert"/>
            <author initials="M." surname="Richardson" fullname="Michael Richardson"/>
            <date year="2023" month="June"/>
          </front>
          <seriesInfo name="Internet-Draft" value="draft-ietf-roll-mopex-07"/>
        </reference>
      </references>

      <references>
        <name>Informative References</name>
        &RFC7942;
      </references>
    </references>

    <!-- ===== Appendix A: Example Configurations ===== -->
    <section anchor="examples" numbered="true" toc="default">
      <name>Example Configurations</name>

      <section anchor="example-root" numbered="true" toc="default">
        <name>MOP=6 Root Configuration</name>
        <figure>
          <artwork><![CDATA[
ifaces = { {
    ifname = "lowpan0",
    dodag_root = true,
    mode_of_operation = 6,
    node_class = "S",
    trickle_t = 8,
    rpls = { {
        instance = 1,
        dags = { {
            mode_of_operation = 6,
            node_class = "S",
            dest_prefix = "fd00:1::/64",
            dodagid = "fd00:1::1",
        }, }
    }, }
}, }
]]></artwork>
        </figure>
      </section>

      <section anchor="example-bridge" numbered="true" toc="default">
        <name>MOPex Bridge Configuration</name>
        <figure>
          <artwork><![CDATA[
ifaces = { {
    ifname = "lowpan0",
    dodag_root = false,
    mode_of_operation = 6,
    node_class = "S",
    trickle_t = 2,
    mopex_bridge = true,
    mopex_accept_foreign = true,
}, }
]]></artwork>
        </figure>
      </section>

      <section anchor="example-topology" numbered="true" toc="default">
        <name>Inter-DODAG Topology Example</name>
        <figure>
          <artwork><![CDATA[
        DODAG A (MOP=6, HyMRPL)       DODAG B (MOP=2, Storing)
        ========================       =========================

          +--------+                         +--------+
          | Root A |                         | Root B |
          | MOP=6  |                         | MOP=2  |
          +---+----+                         +---+----+
              |                                  |
         +----+----+                        +----+----+
         |         |                        |         |
     +---+--+  +--+---+                +---+--+  +--+---+
     |Node A1|  |Node A2|              |Node B1|  |Node B2|
     |Class-S|  |Class-N|              |Storing|  |Storing|
     +-------+  +---+---+              +-------+  +-------+
                     |
                +----+----+
                | BRIDGE  |
                | MOP=7   |  <-- advertises MOP=7 + option 0x80
                | native=6|      joins both DODAGs
                +----+----+
                     |
                (connected to Root B's domain)

  Cross-DODAG path:
    Node A1 -> Root A -> Bridge -> Root B -> Node B1
]]></artwork>
        </figure>
      </section>
    </section>

    <!-- ===== Appendix B: Test Results Summary ===== -->
    <section anchor="test-results" numbered="true" toc="default">
      <name>Experimental Results Summary</name>
      <t>
        The following results were obtained from the rpld-hymrpl
        implementation running on Mininet-WiFi with 6LoWPAN over
        mac802154_hwsim (Linux kernel 6.11.0).
      </t>

      <section anchor="results-static" numbered="true" toc="default">
        <name>Static Topology (5 nodes, 10 runs)</name>
        <table>
          <thead>
            <tr>
              <th>Metric</th>
              <th>Storing</th>
              <th>Non-Storing</th>
              <th>HyMRPL</th>
            </tr>
          </thead>
          <tbody>
            <tr>
              <td>Convergence (s)</td>
              <td>12.63</td>
              <td>9.81</td>
              <td>9.77</td>
            </tr>
            <tr>
              <td>PDR 1-3 hop</td>
              <td>100%</td>
              <td>100%</td>
              <td>100%</td>
            </tr>
            <tr>
              <td>Latency 3-hop (ms)</td>
              <td>0.21</td>
              <td>0.29</td>
              <td>0.29</td>
            </tr>
            <tr>
              <td>DIO count (15s)</td>
              <td>33</td>
              <td>45</td>
              <td>45</td>
            </tr>
          </tbody>
        </table>
      </section>

      <section anchor="results-mopex" numbered="true" toc="default">
        <name>MOPex Bridge (5 nodes, 3 runs)</name>
        <table>
          <thead>
            <tr>
              <th>Metric</th>
              <th>Value</th>
            </tr>
          </thead>
          <tbody>
            <tr>
              <td>Bridge MOPex DIOs emitted</td>
              <td>18+ per run</td>
            </tr>
            <tr>
              <td>Foreign DODAGs registered</td>
              <td>2</td>
            </tr>
            <tr>
              <td>Cross-DODAG injections</td>
              <td>18 per run</td>
            </tr>
            <tr>
              <td>Cross-DODAG PDR</td>
              <td>100%</td>
            </tr>
            <tr>
              <td>Cross-DODAG latency</td>
              <td>0.3 ms</td>
            </tr>
            <tr>
              <td>Data packets through bridge</td>
              <td>10,266</td>
            </tr>
            <tr>
              <td>Convergence time</td>
              <td>~15 s</td>
            </tr>
          </tbody>
        </table>
      </section>

      <section anchor="results-mesh" numbered="true" toc="default">
        <name>Mesh Resilience (15 nodes, node failure)</name>
        <table>
          <thead>
            <tr>
              <th>Mode</th>
              <th>PDR under failure</th>
            </tr>
          </thead>
          <tbody>
            <tr>
              <td>Storing</td>
              <td>79.5%</td>
            </tr>
            <tr>
              <td>Non-Storing</td>
              <td>64.1%</td>
            </tr>
            <tr>
              <td>HyMRPL (MOP=6)</td>
              <td>87.2%</td>
            </tr>
          </tbody>
        </table>
        <t>
          The dual reconvergence mechanism (centralized SRH + local
          hop-by-hop) provides a 23 percentage point advantage over
          Non-Storing under intermediate node failure.
        </t>
      </section>
    </section>

    <section anchor="acknowledgements" numbered="false" toc="default">
      <name>Acknowledgements</name>
      <t>
        The authors thank the developers of rpld for providing the
        base RPL daemon implementation, and the Mininet-WiFi team
        for the 6LoWPAN emulation framework used in experimental
        validation.
      </t>
    </section>
  </back>
</rfc>
