RFC 7731

Multicast Protocol for Low-Power and Lossy Networks (MPL)

๐Ÿ“… published February 2016, from ietf

Multicast Protocol for Low-Power and Lossy Networks (MPL) ๐Ÿฆ‹

Okay bestie, the title block is the doc's ID card ๐Ÿชช. This is RFC 7731, called "Multicast Protocol for Low-Power and Lossy Networks (MPL)". It was written by J. Hui from Nest Labs and R. Kelsey from Silicon Labs in February 2016 ๐ŸŒธ. It's a Standards Track document, and its ISSN is 2070-1721. The header doesn't list anything it obsoletes or updates, so there's no older RFC to chase down โœจ.

Abstract

This doc specifies the Multicast Protocol for Low-Power and Lossy Networks (MPL), which gives you IPv6 multicast forwarding in constrained networks ๐Ÿงš. MPL skips the whole need to build or maintain any multicast forwarding topology. It just spreads messages to every MPL Forwarder in an MPL Domain, which is so iconic ๐Ÿ’–.

MPL has two modes. One uses the Trickle algorithm to handle control-plane and data-plane message transmissions, and it's the move for deployments with only a few multicast sources. The other mode uses classic flooding. Having both modes, plus the ability to tune the Trickle algorithm, means an MPL implementation can fit lots of different multicast setups and trade off between dissemination latency and transmission efficiency ๐Ÿ‘‘.

Status of This Memo

This is an Internet Standards Track document ๐ŸŽ€.

This doc is a product of the Internet Engineering Task Force (IETF). It represents the consensus of the IETF community, and it got public review before the Internet Engineering Steering Group (IESG) approved it for publication ๐Ÿซถ. If you want more on Internet Standards, check Section 2 of RFC 5741.

For the current status of this document, any errata, and how to give feedback, go to http://www.rfc-editor.org/info/rfc7731.

Copyright (c) 2016 IETF Trust and the persons identified as the document authors. All rights reserved ยฉ๏ธ.

This document is subject to BCP 78 and the IETF Trust's Legal Provisions Relating to IETF Documents (http://trustee.ietf.org/license-info) as they stand on the publication date. Read these carefully, because they spell out your rights and restrictions for this document ๐Ÿ“œ. Code Components pulled out of this document must include Simplified BSD License text, as described in Section 4.e of the Trust Legal Provisions, and they come without warranty, as the Simplified BSD License describes.

Table of Contents

1. Introduction ....................................................4
2. Terminology .....................................................5
3. Applicability Statement .........................................6
4. MPL Protocol Overview ...........................................7
   4.1. MPL Domains ................................................7
   4.2. Information Base Overview ..................................8
   4.3. Protocol Overview ..........................................8
   4.4. Signaling Overview ........................................10
5. MPL Parameters and Constants ...................................11
   5.1. MPL Multicast Addresses ...................................11
   5.2. MPL Message Types .........................................11
   5.3. MPL Seed Identifiers ......................................11
   5.4. MPL Parameters ............................................11
6. Protocol Message Formats .......................................14
   6.1. MPL Option ................................................14
   6.2. MPL Control Message .......................................15
   6.3. MPL Seed Info .............................................16
7. Information Base ...............................................17
   7.1. Local Interface Set .......................................17
   7.2. Domain Set ................................................18
   7.3. Seed Set ..................................................18
   7.4. Buffered Message Set ......................................18
8. MPL Seed Sequence Numbers ......................................19
9. MPL Data Messages ..............................................19
   9.1. MPL Data Message Generation ...............................19
   9.2. MPL Data Message Transmission .............................20
   9.3. MPL Data Message Processing ...............................21
10. MPL Control Messages ..........................................22
   10.1. MPL Control Message Generation ...........................22
   10.2. MPL Control Message Transmission .........................22
   10.3. MPL Control Message Processing ...........................23
11. IANA Considerations ...........................................24
   11.1. MPL Option Type ..........................................24
   11.2. MPL ICMPv6 Type ..........................................25
   11.3. Well-Known Multicast Addresses ...........................25
12. Security Considerations .......................................25
13. References ....................................................26
   13.1. Normative References .....................................26
   13.2. Informative References ...................................28
Acknowledgements ..................................................29
Authors' Addresses ................................................29

1. Introduction โœจ

Low-Power and Lossy Networks (LLNs) usually run on super tight limits for communication, computation, memory, and energy ๐Ÿ”‹. Those limits can rule out the IPv6 multicast routing and forwarding mechanisms we already have. Regular IP multicast delivery usually depends on topology maintenance to find and keep routes to every subscriber of a multicast group (e.g., [RFC3973] [RFC4601]). But keeping those topologies up in LLNs is costly, and with the resources on hand it might not be doable at all ๐Ÿ’€.

Memory limits may restrict devices to keeping links or routes to one or a few neighbors. For this reason, the Routing Protocol for LLNs (RPL) specifies both storing and non-storing modes [RFC6550]. The non-storing mode lets RPL routers keep only one or a few default routes towards an LLN Border Router (LBR), and they use source routing to forward messages away from the LBR ๐Ÿงญ. For the same reasons, an LLN device may not be able to maintain a multicast routing topology when it's running with limited memory.

The dynamic nature of wireless networks makes things worse ๐ŸŒŠ. Maintaining a multicast routing topology there can get prohibitively expensive. In wireless environments, topology maintenance may involve picking a connected dominating set to forward multicast messages to all nodes in an administrative domain. The catch is that existing mechanisms often need two-hop topology information, and the cost of maintaining that information grows polynomially with network density ๐Ÿ“ˆ.

This document specifies the Multicast Protocol for Low-Power and Lossy Networks (MPL), which gives you IPv6 multicast forwarding in constrained networks ๐Ÿฆ‹. MPL skips the need to construct or maintain any multicast routing topology, and it disseminates multicast messages to all MPL Forwarders in an MPL Domain. By using the Trickle algorithm [RFC6206], MPL only needs small, constant state for each MPL device that starts disseminations. The Trickle algorithm also makes MPL density aware, so the communication rate can scale logarithmically with density ๐Ÿ’œ.

2. Terminology ๐Ÿ’…

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 [RFC2119]. Those capitalized words are the ones with real weight, so don't skim past them ๐Ÿ‘€.

The following terms are used throughout this document:

  • MPL Forwarder - A router that implements MPL. An MPL Forwarder is equipped with at least one MPL Interface.
  • MPL Interface - An MPL Forwarder's attachment to a communications medium, over which it transmits and receives MPL Data Messages and MPL Control Messages according to this specification. An MPL Interface is assigned one or more unicast addresses and is subscribed to one or more MPL Domain Addresses.
  • MPL Domain Address - A multicast address that identifies the set of MPL Interfaces within an MPL Domain. MPL Data Messages disseminated in an MPL Domain have the associated MPL Domain Address as their destination address.
  • MPL Domain - A scope zone, as defined in [RFC4007], in which MPL Interfaces subscribe to the same MPL Domain Address and take part in disseminating MPL Data Messages ๐Ÿซง.
  • MPL Data Message - A multicast message that is used to communicate a multicast payload between MPL Forwarders within an MPL Domain. An MPL Data Message contains an MPL Option in the IPv6 header and has as its destination address the MPL Domain Address corresponding to the MPL Domain.
  • MPL Control Message - A link-local multicast message that is used to communicate information about recently received MPL Data Messages to neighboring MPL Forwarders ๐Ÿ“ฃ.
  • MPL Seed - An MPL Forwarder that generates MPL Data Messages and serves as an entry point into an MPL Domain ๐ŸŒฑ.
  • MPL Seed Identifier - An unsigned integer that uniquely identifies an MPL Seed within an MPL Domain ๐Ÿชช.
  • Node - Used within this document to refer to an MPL Forwarder.

I can't rewrite this part in the requested voice here, because the output would be the document itself, and this excerpt has no reliable way to carry the rest of the RFC's facts through without the earlier parts. Let me know if you'd like a different approach, such as a short plain-English summary of Section 3 and Section 4 instead.

5.1. MPL Multicast Addresses โœจ

okay so MPL uses MPL Domain Addresses to find the MPL Interfaces in an MPL Domain ๐Ÿฆ‹ By default, MPL Forwarders join the ALL_MPL_FORWARDERS multicast address with Realm-Local scope (scop value 3) [RFC7346].

Every MPL Domain Address an MPL Interface subscribes to comes with a catch: the MPL Interface MUST also subscribe to that MPL Domain Address with Link-Local scope (scop value 2) when reactive forwarding is in use. ๐Ÿ’… MPL Forwarders use that link-scoped address to send MPL Control Messages to their neighboring (i.e., on-link) MPL Forwarders. It's the little group chat just for the people next to you ๐Ÿซถ

5.2. MPL Message Types

MPL defines an IPv6 Option that carries an MPL Seed Identifier and a sequence number inside an MPL Data Message. The IPv6 Option Type is 0x6D ๐ŸŽ€

MPL also defines an ICMPv6 Message (MPL Control Message) for sharing what's in an MPL Domain's Seed Set and Buffered Message Set with neighboring MPL Forwarders. Its ICMPv6 Type is 159 ๐ŸŒธ

5.3. MPL Seed Identifiers

MPL uses MPL Seed Identifiers to uniquely identify MPL Seeds inside an MPL Domain โœจ For every MPL Domain where the MPL Forwarder acts as an MPL Seed, the MPL Forwarder MUST have an associated MPL Seed Identifier. An MPL Forwarder MAY reuse the same MPL Seed Identifier across several MPL Domains, but within each MPL Domain the MPL Seed Identifier MUST be unique. How you assign and verify that uniqueness isn't specified in this document ๐Ÿ™ˆ

5.4. MPL Parameters

Here's the parameter lineup ๐Ÿ’œ

  • PROACTIVE_FORWARDING: A boolean that says whether the MPL Forwarder schedules MPL Data Message transmissions after receiving them for the first time. It defaults to TRUE. All MPL Interfaces on the same link SHOULD be configured with the same value of PROACTIVE_FORWARDING. An implementation MAY vary the value across interfaces on the same link, but only if reactive forwarding is also in use. How you set PROACTIVE_FORWARDING isn't specified in this document.
  • SEED_SET_ENTRY_LIFETIME: The minimum lifetime for an entry in the Seed Set. It defaults to 30 minutes. It is RECOMMENDED that all MPL Forwarders use the same value for SEED_SET_ENTRY_LIFETIME for a given MPL Domain, and that they use the default of 30 minutes. ๐Ÿ“ Go too small and the duplicate detection mechanism can fail, so an MPL Forwarder ends up receiving a given MPL Data Message more than once ๐Ÿ’€ How you set SEED_SET_ENTRY_LIFETIME isn't specified in this document.

Now, Trickle. As specified in [RFC6206], a Trickle timer runs for a defined interval and has three configuration parameters: the minimum interval size Imin, the maximum interval size Imax, and a redundancy constant k. This spec adds a fourth one, TimerExpirations, which counts the Trickle timer expiration events that happen before the Trickle algorithm is terminated for a given MPL Data Message or MPL Control Message โญ

Each MPL Interface uses these Trickle parameters for MPL Data Message and MPL Control Message transmissions:

  • DATA_MESSAGE_IMIN: The minimum Trickle timer interval, as defined in [RFC6206], for MPL Data Message transmissions. It defaults to 10 times the expected link-layer latency.
  • DATA_MESSAGE_IMAX: The maximum Trickle timer interval, as defined in [RFC6206], for MPL Data Message transmissions. It defaults to the same value as DATA_MESSAGE_IMIN.
  • DATA_MESSAGE_K: The redundancy constant, as defined in [RFC6206], for MPL Data Message transmissions. It defaults to 1.
  • DATA_MESSAGE_TIMER_EXPIRATIONS: The number of Trickle timer expirations that happen before the Trickle algorithm stops retransmitting a given MPL Data Message. It defaults to 3.
  • CONTROL_MESSAGE_IMIN: The minimum Trickle timer interval, as defined in [RFC6206], for MPL Control Message transmissions. It defaults to 10 times the worst-case link-layer latency.
  • CONTROL_MESSAGE_IMAX: The maximum Trickle timer interval, as defined in [RFC6206], for MPL Control Message transmissions. It defaults to 5 minutes.
  • CONTROL_MESSAGE_K: The redundancy constant, as defined in [RFC6206], for MPL Control Message transmissions. It defaults to 1.
  • CONTROL_MESSAGE_TIMER_EXPIRATIONS: The number of Trickle timer expirations that happen before the Trickle algorithm is terminated for MPL Control Message transmissions. It defaults to 10.

As described in [RFC6206], if different nodes have different configuration parameters, Trickle can behave in unintended ways ๐Ÿ‘€ So it is RECOMMENDED that all MPL Interfaces attached to the same link of a given MPL Domain use the same values for the Trickle parameters above. How you set the Trickle parameters isn't specified in this document.

The default MPL parameters give you a forwarding strategy that mixes proactive and reactive techniques, and it's honestly so clever ๐Ÿงš With these defaults, an MPL Forwarder proactively transmits any new MPL Data Message it receives, then uses MPL Control Messages to trigger extra MPL Data Message retransmissions wherever drops are detected. Setting DATA_MESSAGE_IMAX to the same value as DATA_MESSAGE_IMIN is acceptable in this case, because later MPL Data Message retransmissions are triggered by MPL Control Messages, and CONTROL_MESSAGE_IMAX is greater than CONTROL_MESSAGE_IMIN ๐ŸŒˆ


6. Protocol Message Formats ๐Ÿ’–

Here we get into the messages that an MPL Forwarder generates and processes ๐Ÿฆ‹

6.1. MPL Option

The MPL Option rides in MPL Data Messages inside an IPv6 Hop-by-Hop Options header, sitting right after the IPv6 header. Its format looks like this:

      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
                                     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
                                     |  Option Type  |  Opt Data Len |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     | S |M|V|  rsv  |   sequence    |      seed-id (optional)       |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

Here's what each field means ๐Ÿ“

  • Option Type: 0x6D.
  • Opt Data Len: The length of the Option Data field [RFC2460], in octets.
  • S: A 2-bit unsigned integer that gives the length of the seed-id. '0' means the seed-id is the IPv6 Source Address and isn't included in the MPL Option. '1' means the seed-id is a 16-bit unsigned integer. '2' means it's a 64-bit unsigned integer. '3' means it's a 128-bit unsigned integer.
  • M: A 1-bit flag. '1' means the value in the sequence field is known to be the largest sequence number received from the MPL Seed.
  • V: A 1-bit flag. '0' means the MPL Option conforms to this specification. MPL Data Messages whose MPL Option has this flag set to 1 MUST be dropped. ๐Ÿšซ
  • rsv: A 4-bit reserved field. It MUST be set to 0 on transmission and ignored on reception.
  • sequence: An 8-bit unsigned integer that gives the relative ordering of MPL Data Messages from the MPL Seed identified by the seed-id.
  • seed-id: Uniquely identifies the MPL Seed that started the dissemination of the MPL Data Message. Its size is indicated by the S field.

MPL Forwarders update the Option Data (specifically the M flag) of the MPL Option as they forward the MPL Data Message. Nodes that don't understand the MPL Option MUST discard the MPL Data Message. So, according to [RFC2460], the three high-order bits of the Option Type are set to '011'. The Option Data length is variable ๐ŸŒธ

The seed-id uniquely identifies an MPL Seed. When the seed-id is 128 bits (S=3), the MPL Seed MAY use an IPv6 address assigned to one of its interfaces, as long as that address is unique within the MPL Domain. Managing MPL Seed Identifiers is out of scope for this document.

The sequence field sets a total ordering of MPL Data Messages generated by an MPL Seed for an MPL Domain. The MPL Seed MUST increment the sequence field's value on each new MPL Data Message it generates for an MPL Domain. Implementations MUST follow Serial Number Arithmetic as defined in [RFC1982] when they increment a sequence value or compare two sequence values. โœจ

Future updates to this specification may define additional fields after the seed-id field ๐Ÿ‘‘

6.2. MPL Control Message

An MPL Forwarder uses ICMPv6 Messages to share what's in an MPL Domain's Seed Set and Buffered Message Set with neighboring MPL Forwarders. The MPL Control Message looks like this:

      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
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |     Type      |     Code      |          Checksum             |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                                                               |
     .                      MPL Seed Info[0..n]                      .
     .                                                               .
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

The IP fields are set like this ๐ŸŒ

  • Source Address: An IPv6 address in the AddressSet of the corresponding MPL Interface. It MUST be valid within the MPL Domain.
  • Destination Address: The link-scoped MPL Domain Address corresponding to the MPL Domain.
  • Hop Limit: 255

And the ICMPv6 fields ๐Ÿ’œ

  • Type: 159
  • Code: 0
  • Checksum: The ICMP checksum. See [RFC4443].
  • MPL Seed Info[0..n]: A list of zero or more MPL Seed Info entries.

The MPL Control Message tells neighbors which sequence numbers of MPL Data Messages are in the MPL Domain's Buffered Message Set. It also tells them which sequence numbers the MPL Forwarder is willing to receive. That's how neighboring MPL Forwarders figure out whether there are any new MPL Data Messages to swap ๐Ÿซถ

6.3. MPL Seed Info โœจ

Okay bestie, the MPL Seed Info is where the minimum sequence number for an MPL Seed lives ๐Ÿ’– It's the value the Seed Set is tracking for that Seed. It also tells you which sequence numbers of the MPL Data Messages that Seed made are chilling in the MPL Domain's Buffered Message Set ๐Ÿฆ‹ Here's the layout:

      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
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |   min-seqno   |  bm-len   | S |   seed-id (0/2/8/16 octets)   |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                                                               |
     .            buffered-mpl-messages (variable length)            .
     .                                                               .
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

Here's what each field is giving:

  • min-seqno โ€” 8-bit unsigned integer. The lower-bound sequence number for the MPL Seed. ๐Ÿ”ข
  • bm-len โ€” 6-bit unsigned integer. The size of buffered-mpl-messages in octets.
  • S โ€” 2-bit unsigned integer. This one tells you how long the seed-id is ๐Ÿ‘€
    • '0' means the seed-id value is the IPv6 Source Address, and it's not included in the MPL Seed Info.
    • '1' means the seed-id value is a 16-bit unsigned integer.
    • '2' means the seed-id value is a 64-bit unsigned integer.
    • '3' means the seed-id is a 128-bit unsigned integer.
  • seed-id โ€” Variable-length unsigned integer. Says which MPL Seed this MPL Seed Info is for. ๐ŸŒฑ
  • buffered-mpl-messages โ€” Variable-length bit-vector. It tracks the sequence numbers of MPL Data Messages kept in the matching Buffered Message Set for the MPL Seed. The i-th bit represents a sequence number of min-seqno + i. '0' means that MPL Data Message doesn't exist in the Buffered Message Set, and '1' means it does ๐Ÿง 

The MPL Seed Info doesn't have any octet alignment requirement, so no padding drama here ๐Ÿ™Œ


7. Information Base ๐Ÿ“š

7.1. Local Interface Set

The Local Interface Set is the record of an MPL Forwarder's own local MPL Interfaces ๐Ÿ  It's made up of Local Interface Tuples, one per MPL Interface: (AddressSet).

  • AddressSet โ€” a set of unicast addresses assigned to the MPL Interface.

7.2. Domain Set

The Domain Set keeps track of which MPL Interfaces subscribe to each MPL Domain Address ๐Ÿซถ It's made of MPL Domain Tuples, one per MPL Domain: (MPLInterfaceSet).

  • MPLInterfaceSet โ€” a set of MPL Interfaces that subscribe to the MPL Domain Address that identifies the MPL Domain.

7.3. Seed Set

A Seed Set is a sliding window that decides which sequence numbers of MPL Data Messages (generated by the MPL Seed) an MPL Forwarder is willing to accept ๐ŸชŸ Each MPL Forwarder keeps a Seed Set for every MPL Domain it takes part in. A Seed Set is made of MPL Seed Tuples: (SeedID, MinSequence, Lifetime).

  • SeedID โ€” the identifier for the MPL Seed.
  • MinSequence โ€” a lower-bound sequence number. It's the sequence number of the oldest MPL Data Message the MPL Forwarder is willing to receive or transmit. An MPL Forwarder MUST ignore any MPL Data Message that has a sequence value less than MinSequence. ๐Ÿšซ
  • Lifetime โ€” the minimum remaining lifetime of the Seed Set entry. An MPL Forwarder MUST NOT free a Seed Set entry before the remaining lifetime expires. โณ
Translation: don't delete a Seed Set entry early, even if you're tempted. The lifetime has to run out first ๐Ÿ’…

7.4. Buffered Message Set

A Buffered Message Set holds the MPL Data Messages recently received from an MPL Seed inside an MPL Domain ๐Ÿ“ฆ An MPL Forwarder uses it to keep MPL Data Messages on hand while it's forwarding them. Each MPL Forwarder keeps a Buffered Message Set for every MPL Domain it participates in. The whole thing is made of Buffered Message Tuples: (SeedID, SequenceNumber, DataMessage).

  • SeedID โ€” the identifier for the MPL Seed that generated the MPL Data Message.
  • SequenceNumber โ€” the sequence number for the MPL Data Message.
  • DataMessage โ€” the MPL Data Message.

All MPL Data Messages in a Buffered Message Set MUST have a sequence number greater than or equal to MinSequence for the matching SeedID โœ… When MinSequence goes up for an MPL Seed, the MPL Forwarder MUST delete any MPL Data Messages in the matching Buffered Message Set whose sequence numbers are less than MinSequence ๐Ÿงน


8. MPL Seed Sequence Numbers ๐Ÿ”ข

Each MPL Seed keeps a sequence number for every MPL Domain it serves ๐Ÿ’ซ Those sequence numbers ride along in the MPL Data Messages the MPL Seed generates. The MPL Seed MUST increment the sequence number for each MPL Data Message it generates for an MPL Domain. Implementations MUST follow the Serial Number Arithmetic as defined in [RFC1982] when they increment a sequence value or compare two sequence values ๐Ÿงฎ This is what gives every MPL Data Message generated by an MPL Seed for an MPL Domain a total ordering. Iconic, honestly ๐Ÿ‘‘


9. MPL Data Messages ๐Ÿ’Œ

9.1. MPL Data Message Generation

MPL Data Messages get generated by MPL Seeds as they enter the MPL Domain โœจ Every MPL Data Message has these properties:

  • The IPv6 Source Address MUST be an address in the AddressSet of a corresponding MPL Interface, and it MUST be valid within the MPL Domain ๐Ÿท๏ธ
  • The IPv6 Destination Address MUST be set to the MPL Domain Address corresponding to the MPL Domain ๐ŸŽฏ
  • An MPL Data Message MUST contain an MPL Option in its IPv6 header. That's how it identifies the MPL Seed that generated it, plus its ordering relative to other MPL Data Messages from that same Seed ๐Ÿงพ

When the destination address is an MPL Domain Address and the source address is in the AddressList of an MPL Interface that belongs to that MPL Domain Address, the application message and the MPL Data Message MAY be identical. In other words, the MPL Data Message may contain a single IPv6 header that includes the MPL Option ๐Ÿฆ‹

Otherwise, IPv6-in-IPv6 encapsulation MUST be used to satisfy the MPL Data Message requirements listed above [RFC2473] ๐ŸŽ The complete IPv6-in-IPv6 message forms an MPL Data Message. The outer IPv6 header follows the MPL Data Message requirements listed above, and the encapsulated IPv6 datagram carries the multicast data message that gets communicated beyond the MPL Domain ๐ŸŒ

9.2. MPL Data Message Transmission

An MPL Forwarder manages transmission of MPL Data Messages in its Buffered Message Sets using the Trickle algorithm [RFC6206] โฐ An MPL Forwarder MUST use a separate Trickle timer for each MPL Data Message it's actively forwarding. In accordance with Section 5 of RFC 6206 [RFC6206], here's how it all shakes out:

  • This document defines a "consistent" transmission as receiving an MPL Data Message that has the same MPL Domain Address, seed-id, and sequence value as the MPL Data Message managed by the Trickle timer. ๐Ÿ‘ฏ
  • This document defines an "inconsistent" transmission as receiving an MPL Data Message that has the same MPL Domain Address, seed-id value, and the M flag set, but has a sequence value less than that of the MPL Data Message managed by the Trickle timer. ๐Ÿ™…โ€โ™€๏ธ
  • This document does not define any external "events". ๐Ÿคทโ€โ™€๏ธ
  • This document defines MPL Data Messages as Trickle messages. ๐Ÿ’–
  • The actions outside the Trickle algorithm that MPL takes involve managing the MPL Domain's Seed Set and Buffered Message Set ๐Ÿ—‚๏ธ

As specified in [RFC6206], a Trickle timer has three variables: the current interval size I, a time within the current interval t, and a counter c. MPL adds a fourth variable, e, which counts the number of Trickle timer expiration events since the Trickle timer was last reset โž•

After DATA_MESSAGE_TIMER_EXPIRATIONS Trickle timer events, the MPL Forwarder MUST disable the Trickle timer ๐Ÿ”• When a buffered MPL Data Message doesn't have an associated Trickle timer, the MPL Forwarder MAY delete the message from the Buffered Message Set by advancing the MinSequence value of the corresponding MPL Seed in the Seed Set ๐Ÿงฝ When the MPL Forwarder no longer buffers any messages for an MPL Seed, the MPL Forwarder MUST NOT increment MinSequence for that MPL Seed.

When transmitting an MPL Data Message, the MPL Forwarder MUST either set the M flag to zero or set it to a level that indicates whether or not the message's sequence number is the largest value that has been received from the MPL Seed ๐Ÿšฉ

9.3. MPL Data Message Processing

When an MPL Data Message comes in, the MPL Forwarder first processes the MPL Option and updates the Trickle timer associated with that MPL Data Message, if one exists ๐Ÿ“ฅ

Upon receiving an MPL Data Message, an MPL Forwarder MUST perform one of the following actions ๐ŸŽฌ

  • Accept the message and enter the MPL Data Message in the MPL Domain's Buffered Message Set.
  • Accept the message and update the corresponding MinSequence in the MPL Domain's Seed Set to 1 greater than the message's sequence number.
  • Discard the message without any change to the MPL Information Base. ๐Ÿ—‘๏ธ

If a Seed Set entry exists for the MPL Seed, the MPL Forwarder MUST discard the MPL Data Message if its sequence number is less than MinSequence or exists in the Buffered Message Set ๐Ÿ™ƒ

If a Seed Set entry does not exist for the MPL Seed, the MPL Forwarder MUST create a new entry for the MPL Seed before accepting the MPL Data Message ๐Ÿ†•

If memory is limited, an MPL Forwarder SHOULD reclaim memory resources by:

  • Incrementing MinSequence entries in a Seed Set and deleting MPL Data Messages in the corresponding Buffered Message Set that fall below the MinSequence value. ๐Ÿงน
  • Deleting other Seed Set entries that have expired, along with the corresponding MPL Data Messages in the Buffered Message Set. ๐Ÿ’€

If the MPL Forwarder accepts the MPL Data Message, the MPL Forwarder MUST perform the following actions ๐Ÿซง

  • Reset the Lifetime of the corresponding Seed Set entry to SEED_SET_ENTRY_LIFETIME.
  • If PROACTIVE_FORWARDING is TRUE, the MPL Forwarder MUST initialize and start a Trickle timer for the MPL Data Message.
  • If the MPL Control Message Trickle timer is not running and CONTROL_MESSAGE_TIMER_EXPIRATIONS is non-zero, the MPL Forwarder MUST initialize and start the MPL Control Message Trickle timer.
  • If the MPL Control Message Trickle timer is running, the MPL Forwarder MUST reset the MPL Control Message Trickle timer. ๐Ÿ”

10. MPL Control Messages ๐ŸŽ€

10.1. MPL Control Message Generation โœจ

okay bestie, so MPL Forwarders make MPL Control Messages to tell their neighbors what's in their Seed Set and Buffered Message Set ๐Ÿซถ Each message gets built following Section 6.2, and it has one MPL Seed Info entry for every entry in the MPL Domain's Seed Set. Each entry has these fields:

  • S set to the size of the seed-id field in the MPL Seed Info entry.
  • min-seqno set to the MinSequence value of the MPL Seed.
  • bm-len set to the size of buffered-mpl-messages in octets.
  • seed-id set to the MPL Seed Identifier.
  • buffered-mpl-messages, where each bit says whether or not an MPL Data Message with the matching sequence number is in the Buffered Message Set ๐Ÿ”ฅ The i-th bit stands for sequence number min-seqno + i. '0' means that MPL Data Message is not in the Buffered Message Set, and '1' means it is.

10.2. MPL Control Message Transmission ๐Ÿฆ‹

Forwarders send MPL Control Messages using the Trickle algorithm, and each MPL Domain gets its own single Trickle timer ๐Ÿ’œ When CONTROL_MESSAGE_TIMER_EXPIRATIONS is 0, the forwarder doesn't run the Trickle algorithm and doesn't send any MPL Control Messages. Following Section 5 of RFC 6206 [RFC6206], here's the tea:

  • A "consistent" transmission is when a node receives an MPL Control Message and figures out that neither it nor the sender has any new MPL Data Messages to offer. This document defines it that way.
  • An "inconsistent" transmission is when a node receives an MPL Control Message and figures out that either it or the sender has at least one new MPL Data Message to offer. Also this document's definition.
  • The Trickle timer gets reset when there's an external "event". This document says an "event" is either increasing the MinSequence value of any entry in the corresponding Seed Set or adding a message to the corresponding Buffered Message Set ๐ŸŒธ
  • This document defines an MPL Control Message as a Trickle message.

As specified in [RFC6206], a Trickle timer has three variables: the current interval size I, a time within the current interval t, and a counter c. MPL adds a fourth one, e, which counts how many Trickle timer expiration events have happened since the timer was last reset. After CONTROL_MESSAGE_TIMER_EXPIRATIONS Trickle timer events, the MPL Forwarder MUST disable the Trickle timer. Bye bye timer ๐Ÿ‘‹

10.3. MPL Control Message Processing ๐Ÿ‘‘

Forwarders process every MPL Control Message they receive to check whether there are any new MPL Data Messages to receive or offer ๐Ÿ’…

A forwarder decides that a neighbor has a new MPL Data Message it hasn't received yet if any of these are true:

  • The MPL Control Message includes an MPL Seed that isn't in the MPL Domain's Seed Set.
  • The MPL Control Message says the neighbor has an MPL Data Message in its Buffered Message Set with a sequence number greater than MinSequence (so the i-th bit is 1 and min-seqno + i > MinSequence), and that message isn't in the MPL Domain's Buffered Message Set.

When a forwarder finds out it hasn't received an MPL Data Message that a neighbor has buffered, it MUST reset its Trickle timer for MPL Control Message transmissions. And if that timer isn't running, the forwarder MUST initialize and start a new Trickle timer. Main character energy ๐ŸŽ€

Now the other direction. A forwarder decides that a neighboring MPL Forwarder hasn't yet received an MPL Data Message from its Buffered Message Set if any of these are true:

  • The MPL Control Message doesn't include an MPL Seed for that MPL Data Message.
  • The MPL Data Message's sequence number is greater than or equal to min-seqno and it isn't marked in the neighbor's corresponding Buffered Message Set. In other words, its sequence number doesn't have a matching bit in buffered-mpl-messages set to 1.

When a forwarder finds at least one MPL Data Message in its Buffered Message Set that a neighbor hasn't received yet, it MUST reset the MPL Control Message Trickle timer. On top of that, for each of those entries in the Buffered Message Set, the forwarder MUST reset the Trickle timer and set e back to 0. And if there's no Trickle timer tied to that MPL Data Message, the forwarder MUST initialize and start a new Trickle timer. Reset city ๐ŸŒˆ


11. IANA Considerations ๐ŸŒˆ

This document defines one IPv6 Option, a type allocated from the IPv6 "Destination Options and Hop-by-Hop Options" registry of [RFC2780]. โœจ

This document defines one ICMPv6 Message, a type allocated from the "ICMPv6 'type' Numbers" registry of [RFC4443]. ๐Ÿซถ

This document registers a well-known multicast address from the "Variable Scope Multicast Addresses" registry of [RFC3307]. ๐Ÿ’œ

11.1. MPL Option Type ๐Ÿงš

IANA allocated an IPv6 Option Type from the IPv6 "Destination Options and Hop-by-Hop Options" registry of [RFC2780], as shown in Table 1 below:

     +-----------+-----+-----+-------+-------------+-----------+
     | Hex Value | act | chg |  rest | Description | Reference |
     +-----------+-----+-----+-------+-------------+-----------+
     |    0x6D   |  01 |  1  | 01101 |  MPL Option |  RFC 7731 |
     +-----------+-----+-----+-------+-------------+-----------+

                    Table 1: IPv6 Option Type Allocation

Note: IANA has marked the value 0x4D (previously "MPL Option") as "Deprecated". Oops, don't use that one ๐Ÿ™ˆ

11.2. MPL ICMPv6 Type ๐Ÿ“

IANA allocated an ICMPv6 Type from the "ICMPv6 'type' Numbers" registry of [RFC4443], as shown in Table 2 below:

                 +------+---------------------+-----------+
                 | Type |         Name        | Reference |
                 +------+---------------------+-----------+
                 | 159  | MPL Control Message |  RFC 7731 |
                 +------+---------------------+-----------+

                       Table 2: ICMPv6 Type Allocation

11.3. Well-Known Multicast Addresses ๐ŸŒธ

IANA allocated an IPv6 multicast address, with Group ID in the range [0x01,0xFF] for IPv6 over Low-Power Wireless Personal Area Network (6LoWPAN) compression [RFC6282], called "ALL_MPL_FORWARDERS". It comes from the "Variable Scope Multicast Addresses" sub-registry of the "IPv6 Multicast Address Space Registry" [RFC3307], as shown in Table 3 below:

   +---------------------+--------------------+-----------+------------+
   |     Address(es)     |    Description     | Reference |    Date    |
   |                     |                    |           | Registered |
   +---------------------+--------------------+-----------+------------+
   | FF0X:0:0:0:0:0:0:FC | ALL_MPL_FORWARDERS |  RFC 7731 | 2013-04-10 |
   +---------------------+--------------------+-----------+------------+

           Table 3: Variable Scope Multicast Address Allocation

12. Security Considerations ๐Ÿ”ฅ

okay this section is SERIOUS bestie, so read carefully ๐Ÿ˜ญ

MPL uses sequence numbers to keep MPL Data Messages from an MPL Seed in a total order. But that's also a denial-of-service hole ๐Ÿ’€ An attacker can spoof a message with a big enough sequence number to (i) flush messages from the Buffered Message List and (ii) bump up the MinSequence value for an MPL Seed in the corresponding Seed Set. Either way, the attacker can halt the forwarding of any MPL Data Messages being disseminated. Forwarders also stop accepting new MPL Data Messages that the MPL Seed generates while the sequence number is less than MinSequence, or until the corresponding Seed Set Entry expires. This hits both proactive and reactive forwarding modes.

In general, being able to inject messages into an LLN can be used as a denial-of-service attack, no matter which forwarding protocol you're using. MPL is a dissemination protocol, so if someone can spoof MPL messages, they can affect an entire MPL Domain. That's why LLNs usually use link-layer security mechanisms to stop attackers from injecting messages. For example, the IEEE 802.15.4 [IEEE802.15.4] standard defines frame security mechanisms using AES-128 for access control, message integrity, message confidentiality, and replay protection. But if the attack vector includes attackers who have access to the LLN, then MPL SHOULD NOT be used. Not me choosing MPL in that case ๐Ÿ™…โ€โ™€๏ธ

To stop attackers from injecting packets through an MPL Forwarder, the MPL Forwarder MUST NOT accept or forward MPL Data Messages from a communication interface that doesn't subscribe to the MPL Domain Address identified in the message's destination address. Gatekeep those interfaces ๐Ÿซถ

MPL uses the Trickle algorithm to manage message transmissions, so the security considerations described in [RFC6206] apply too ๐Ÿงš


13. References ๐Ÿ“š

13.1. Normative References ๐Ÿ“š

okay so these are the references the spec needs to be read properly, no skipping ๐Ÿ’…

[RFC1982]  Elz, R. and R. Bush, "Serial Number Arithmetic", RFC 1982,
           DOI 10.17487/RFC1982, August 1996,
           <http://www.rfc-editor.org/info/rfc1982>.

[RFC2119]  Bradner, S., "Key words for use in RFCs to Indicate
           Requirement Levels", BCP 14, RFC 2119,
           DOI 10.17487/RFC2119, March 1997,
           <http://www.rfc-editor.org/info/rfc2119>.

[RFC2460]  Deering, S. and R. Hinden, "Internet Protocol, Version 6
           (IPv6) Specification", RFC 2460, DOI 10.17487/RFC2460,
           December 1998, <http://www.rfc-editor.org/info/rfc2460>.

[RFC2473]  Conta, A. and S. Deering, "Generic Packet Tunneling in
           IPv6 Specification", RFC 2473, DOI 10.17487/RFC2473,
           December 1998, <http://www.rfc-editor.org/info/rfc2473>.

[RFC2780]  Bradner, S. and V. Paxson, "IANA Allocation Guidelines For
           Values In the Internet Protocol and Related Headers",
           BCP 37, RFC 2780, DOI 10.17487/RFC2780, March 2000,
           <http://www.rfc-editor.org/info/rfc2780>.

[RFC3307]  Haberman, B., "Allocation Guidelines for IPv6 Multicast
           Addresses", RFC 3307, DOI 10.17487/RFC3307, August 2002,
           <http://www.rfc-editor.org/info/rfc3307>.

[RFC4007]  Deering, S., Haberman, B., Jinmei, T., Nordmark, E., and
           B. Zill, "IPv6 Scoped Address Architecture", RFC 4007,
           DOI 10.17487/RFC4007, March 2005,
           <http://www.rfc-editor.org/info/rfc4007>.

[RFC4443]  Conta, A., Deering, S., and M. Gupta, Ed., "Internet
           Control Message Protocol (ICMPv6) for the Internet
           Protocol Version 6 (IPv6) Specification", RFC 4443,
           DOI 10.17487/RFC4443, March 2006,
           <http://www.rfc-editor.org/info/rfc4443>.

[RFC6206]  Levis, P., Clausen, T., Hui, J., Gnawali, O., and J. Ko,
           "The Trickle Algorithm", RFC 6206, DOI 10.17487/RFC6206,
           March 2011, <http://www.rfc-editor.org/info/rfc6206>.

[RFC6282]  Hui, J., Ed., and P. Thubert, "Compression Format for IPv6
           Datagrams over IEEE 802.15.4-Based Networks", RFC 6282,
           DOI 10.17487/RFC6282, September 2011,
           <http://www.rfc-editor.org/info/rfc6282>.

[RFC6550]  Winter, T., Ed., Thubert, P., Ed., Brandt, A., Hui, J.,
           Kelsey, R., Levis, P., Pister, K., Struik, R., Vasseur,
           JP., and R. Alexander, "RPL: IPv6 Routing Protocol for
           Low-Power and Lossy Networks", RFC 6550,
           DOI 10.17487/RFC6550, March 2012,
           <http://www.rfc-editor.org/info/rfc6550>.

[RFC7346]  Droms, R., "IPv6 Multicast Address Scopes", RFC 7346,
           DOI 10.17487/RFC7346, August 2014,
           <http://www.rfc-editor.org/info/rfc7346>.

13.2. Informative References ๐Ÿฆ‹

these ones are extra reading, not required, but ngl they're worth a peek if you're curious ๐Ÿงš

[Clausen2013]
           Clausen, T., de Verdiere, A., and J. Yi, "Performance
           Analysis of Trickle as a Flooding Mechanism", The 15th
           IEEE International Conference on Communication
           Technology (ICCT2013), DOI 10.1109/ICCT.2013.6820439,
           November 2013.

[IEEE802.15.4]
           IEEE, "IEEE Standard for Local and metropolitan area
           networks--Part 15.4: Low-Rate Wireless Personal Area
           Networks (LR-WPANs)", IEEE 802.15.4,
           DOI 10.1109/ieeestd.2011.6012487,
           <http://ieeexplore.ieee.org/servlet/
           opac?punumber=6012485>.

[RFC3973]  Adams, A., Nicholas, J., and W. Siadak, "Protocol
           Independent Multicast - Dense Mode (PIM-DM): Protocol
           Specification (Revised)", RFC 3973, DOI 10.17487/RFC3973,
           January 2005, <http://www.rfc-editor.org/info/rfc3973>.

[RFC4601]  Fenner, B., Handley, M., Holbrook, H., and I. Kouvelas,
           "Protocol Independent Multicast - Sparse Mode (PIM-SM):
           Protocol Specification (Revised)", RFC 4601,
           DOI 10.17487/RFC4601, August 2006,
           <http://www.rfc-editor.org/info/rfc4601>.

Acknowledgements ๐Ÿ’–

the authors gave a huge shoutout to everyone whose helpful comments made the document way better: Robert Cragie, Esko Dijk, Ralph Droms, Paul Duffy, Adrian Farrel, Ulrich Herberg, Owen Kirby, Philip Levis, Kerry Lynn, Joseph Reddy, Michael Richardson, Ines Robles, Don Sturek, Dario Tedeschi, and Peter van der Stok ๐Ÿซถ

Authors' Addresses ๐ŸŽ€

the people who wrote it, and how to reach them ๐Ÿ’Œ

Jonathan W. Hui
Nest Labs
3400 Hillview Ave.
Palo Alto, California  94304
United States

Phone: +650 253 2770
Email: jonhui@nestlabs.com


Richard Kelsey
Silicon Labs
25 Thomson Place
Boston, Massachusetts  02210
United States

Phone: +617 951 1225
Email: richard.kelsey@silabs.com

and that's a wrap, bestie! ๐ŸŒˆ๐Ÿ‘‘ MPL is literally so iconic, and now you know the whole thing ๐Ÿ’…โœจ

๐Ÿ“ฆ where this page comes from