Repository navigation
Conversation
Before this commit, the second half of ND gap 9 was open: an MLD Report waits until the link-local address is tested, so it leaves after the Neighbor Solicitation of Duplicate Address Detection, and Rfc4862GroupsBeforeDad fails. After this commit, a plan repairs it in MLDv1 and MLDv2, with the IPv6 layer and the receivers, and gives the MLD statements of the same case (RFC9777-REP-34, REP-37, REP-39) their check. Plan: plan/pending/nd-gap9-mld-unspecified-source.md Change: plan | behavior.add | - | nd-gap9-mld-unspecified-source
…ress is tested Before this commit, RFC9777-REP-37 to REP-39 had no check: the MLD checks named them work for a later level 2 pass, a node that reports before it has a link-local address. After this commit, one check covers REP-34 for a Report before the link-local address is tested, REP-37 and REP-39. A host listens from the start, while its link-local address is tentative; its Report leaves from the unspecified address, the router takes no action on it, and once the detection ends the host reports again from its link-local address. A Query Response Interval of 1 second and a Robustness Variable of 1 at the host leave the new Report of REP-39 as the only Report from the link-local address before the second startup General Query. REP-38, the listening state that the host keeps after the router discards its Report, is state inside a node and goes to that group of statements with no check. Plan: plan/pending/nd-gap9-mld-unspecified-source.md Change: doc | behavior.add | - | nd-gap9-mld-unspecified-source
… address Before this commit, fragmentPostRouting gave every local datagram from the unspecified address the preferred address of its interface, except a datagram to a solicited-node multicast address, the Neighbor Solicitation of Duplicate Address Detection. With a tentative preferred address, the datagram waited in pendingDadQueue until the detection ended. So MLD could not send a Report or a Done from the unspecified address, as RFC 3590 section 4 and RFC 9777 section 5.2.14 ask while the interface has no valid link-local address. After this commit, an MLD Report or Done (ICMPv6 types 131, 132 and 143) from the unspecified address keeps it. MLD gives the source of every Report and Done: its link-local address when that address is valid. So the IPv6 layer sees an MLD message from the unspecified address only when MLD means it. A rule by the kind of the requested source, an explicit IPv6 address :: against no address, is not used: a socket that is bound to :: requests an explicit :: too. Nothing moves at this commit: MLD holds every Report and Done until the link-local address is valid, and sends it from that address. Plan: plan/pending/nd-gap9-mld-unspecified-source.md Change: src.networklayer.ipv6 | behavior.change | - | nd-gap9-mld-unspecified-source
… unspecified address Before this commit, a multicast router looked up a route for every received multicast datagram of a scope above link-local, whatever its source. Without a route, it gave the source and the group to the multicast routing protocol, and PimDm::unroutableMulticastPacketArrived asserts that the source is specified. After this commit, a router does not forward a multicast datagram from the unspecified address, as RFC 4291 section 2.5.2 says: "An IPv6 packet with a source address of unspecified must never be forwarded by an IPv6 router." The router still delivers the datagram locally when it belongs to the group or carries the Router Alert option. Such a datagram is an MLDv1 Report to the address of its group, which a node sends before it has a valid link-local address (RFC 3590 section 4). Nothing moves at this commit: no node sends a multicast datagram of a larger scope than link-local from the unspecified address yet. Plan: plan/pending/nd-gap9-mld-unspecified-source.md Change: src.networklayer.ipv6 | behavior.change | - | nd-gap9-mld-unspecified-source
…dress Before this commit, TestMld gave an injected MLD message a destination and no source, so the message came from the unspecified address. A Report from that address is one that a router discards (RFC 9777 section 5.2.14, RFC 3590 section 4), which the next commit makes the model do; then MLDv2_interop_router loses its Reports. After this commit, every injected message comes from fe80::99, a link-local address of another node on the link, as every MLD message does (RFC 2710 section 3, RFC 9777 section 5). Nothing moves at this commit: the model does not read the source of a received MLD message yet. Plan: plan/pending/nd-gap9-mld-unspecified-source.md Change: tests.module | behavior.change.fix | - | nd-gap9-mld-unspecified-source
…ified address Before this commit, an MLDv1 or MLDv2 node acted on every Report and Done, whatever its source. A router recorded a listener, and an MLDv1 host suppressed its own Report. After this commit, a node silently discards a Report or a Done from the unspecified address, as a router (RFC 3590 section 4, RFC 9777 section 5.2.14) and as a host (RFC 3590 section 6). A node sends such a message before it has a valid link-local address, so a router cannot identify its sender. A Query from the unspecified address is not in this change. Nothing moves at this commit: no node sends an MLD message from the unspecified address yet. Plan: plan/pending/nd-gap9-mld-unspecified-source.md Change: src.networklayer.icmpv6 | behavior.change | - | nd-gap9-mld-unspecified-source
…cal address becomes valid Before this commit, MLD had no step for the moment at which a node that reported from the unspecified address gets a valid link-local address. After this commit, an MLD node remembers the interfaces that sent a Report or a Done from the unspecified address. Once the link-local address of such an interface is valid, the node sends a new Report for each group that it listens to there, as RFC 3590 section 4 and RFC 9777 section 5.2.14 say that a node SHOULD. MLDv1 sends a Report for each group; MLDv2 sends one Current-State Report, the Report of a General Query, or in MLDv1 mode an MLDv1 Report for each group. Nothing moves at this commit: MLD still holds every Report and Done until the link-local address is valid, so no interface sends from the unspecified address yet. Plan: plan/pending/nd-gap9-mld-unspecified-source.md Change: src.networklayer.icmpv6 | behavior.change | - | nd-gap9-mld-unspecified-source
…tested
Before this commit, an MLDv1 node held every Report and Done until Duplicate Address Detection had tested its link-local address (heldMessages), and then sent them from that address. So the Report for the solicited-node group of a tentative address left after the Neighbor Solicitation of the detection. RFC 4862 section 5.4.2 joins the group before the solicitation, and the Report informs MLD-snooping switches (the second half of ND gap 9).
After this commit, a Report or a Done leaves at once: from the link-local address when it is valid, else from the unspecified address (RFC 3590 section 4). Once the link-local address is valid, the node reports its groups again, and a router or a host discards a Report or a Done from the unspecified address; both steps came in earlier commits. Nothing fills the held messages any more, and a later commit removes them.
To see the defect, run Rfc4862GroupsBeforeDad of tests/protocol/nd on the parent commit: it fails at step 1, because no MLD Report of A names ff02::1:ff00:a before the solicitation for its link-local address.
Statistical results: 3 move too. The statistics commit "mld: update statistics after the MLDv1 Reports before the link-local address" holds the new values and the reason.
Baseline changes:
fingerprint runs changed in tplx,~tND,~tNl (3; examples/pim 2, examples/ipv6 1) — the examples with MLDv1 (ipv6/mld MldDemo, pim
dm_ipv6 and sm_ipv6): the nodes send their first Reports from the unspecified address at once,
the routers discard them, and the nodes report again from their link-local addresses once those
are valid, so the MLD messages and their timing change
Plan: plan/pending/nd-gap9-mld-unspecified-source.md
Change: src.networklayer.icmpv6.Mldv1 | behavior.change.fix | test whatsnew fingerprint statistical | nd-gap9-mld-unspecified-source
…ss is valid Before this commit, two MLD checks and their tests asked more than RFC 9777. "Router Alert on every message" (Rfc9777HopLimitAndSource) asked a link-local source for every MLD message, but RFC 9777 section 5 sends a Report from the unspecified address while the interface has no valid link-local address yet (RFC9777-REP-34). "Listener in MLDv1 mode" (Rfc9777ListenerV1Mode) forbade every Version 2 Report of A from the start, but RFC9777-COMPL-9 holds in the MLDv1 mode, which section 8.2.1 starts with the first MLDv1 Query that A receives. The model held such Reports until the link-local address was valid, and a change of the mode deleted the held MLDv2 Reports, so the strict checks passed. The next MLDv2 commit sends them. After this commit, the first check allows a Report from the unspecified address before the first MLD message of its sender from the link-local address, and the second check forbids a Version 2 Report of A from the first MLDv1 Query that A receives. Plan: plan/pending/nd-gap9-mld-unspecified-source.md Change: tests.protocol | behavior.change.fix | - | nd-gap9-mld-unspecified-source
Before this commit, MLDv2_router_basic and MLDv2_ssm let the receiver join at the start. Neighbor Discovery assigns the link-local address of a host after its boot-up time, up to 1 second (hostBootupTime). The model held the State-Change Reports of the join until then, and sent them from the link-local address, so the router logged the TO_EX and the ALLOW record that the tests check. With the next MLDv2 commit, they leave from the unspecified address, and the router discards them (RFC 9777 section 5.2.14). After this commit, the receiver joins at 1.5 seconds, after it has its link-local address, so the router again receives the State-Change Report of the join. Plan: plan/pending/nd-gap9-mld-unspecified-source.md Change: tests.module | behavior.change.fix | - | nd-gap9-mld-unspecified-source
…tested
Before this commit, an MLDv2 node held every Report until Duplicate Address Detection had tested its link-local address (heldMessages), and then sent it from that address. RFC 9777 section 5.2.14 sends a Report from the unspecified address while the interface has no valid link-local address, so that MLD-snooping switches learn the groups that Neighbor Discovery needs (RFC9777-REP-34).
After this commit, a Report leaves at once: from the link-local address when it is valid, else from the unspecified address. Once the link-local address is valid, the node sends one Current-State Report with all its groups (RFC9777-REP-39), and a router takes no action on a Report from the unspecified address (RFC9777-REP-37); both steps came in earlier commits. Nothing fills the held messages any more, and a later commit removes them.
The new test Rfc9777ReportBeforeLinkLocal of tests/protocol/mld checks the three statements, by the check "A start of listening before the link-local address is tested". To see the defect, run it on the parent commit: it fails at its first guard, because the first Report of A from its link-local address comes with no Report of A for G from the unspecified address before it.
Statistical results: 2 move too. The statistics commit "mld: update statistics after the MLDv2 Reports before the link-local address" holds the new values and the reason.
Baseline changes:
fingerprint runs changed in tplx,~tND,~tNl (2; examples/ipv6 1, examples/pim 1) — the examples with MLDv2 (ipv6/mld MldV2Ssm, pim
ssm_ipv6): the nodes send their first Reports from the unspecified address at once, the routers
discard them, and the nodes send a Current-State Report from their link-local addresses once
those are valid, so the MLD messages and their timing change
Plan: plan/pending/nd-gap9-mld-unspecified-source.md
Change: src.networklayer.icmpv6.Mldv2 | behavior.change.fix | test whatsnew fingerprint statistical | nd-gap9-mld-unspecified-source
…valid Before this commit, Mldv1 and Mldv2 kept the held messages (heldMessages, sendHeldMessages and deleteHeldMessages), and cancelHostTimers of Mldv2 deleted the held Reports of the old version on a change of the compatibility mode. Since the two commits before, a Report or a Done leaves from the unspecified address instead, so nothing filled them. After this commit, the held messages go, with the parameter of cancelHostTimers that only selected the held Reports. Nothing moves at this commit: it removes code that no message reaches. Plan: plan/pending/nd-gap9-mld-unspecified-source.md Change: src.networklayer.icmpv6 | behavior.change | - | nd-gap9-mld-unspecified-source
…ess are repaired Before this commit, the plan listed the steps of the repair as open. After this commit, the plan marks the twelve commits of the repair as done, lists what each moves, and records the facts found on the way: the forwarding of a datagram from the unspecified address, the source of the injected messages and the join time of two module tests, two MLD checks that asked more than RFC 9777, and the measurement of each commit. Plan: plan/pending/nd-gap9-mld-unspecified-source.md Change: plan | behavior.change | - | nd-gap9-mld-unspecified-source
…epair of gap 9 Before this commit, the ND documents named the second half of gap 9 open: Rfc4862GroupsBeforeDad failed, and RFC4862-DAD-11 and RFC4861-AR-4 had a failing core check. The MLD documents named RFC9777-REP-37 to REP-39 owed, and gap 2 said that a Report or a Done waits for the link-local address. After this commit, they follow a fresh debug run at efc9302 in the image of the CI job: ND 37 tests, 37 PASS; MLD 48 tests, 48 PASS. results.md marks the second half of ND gap 9 repaired, with the commits of MLDv1 and MLDv2, and keeps the description of the old code. In the MLD ledger, REP-37 and REP-39 are selected by the new check and Rfc9777ReportBeforeLinkLocal, REP-34 has that test too, and REP-38 is state inside a node, level 4; 55 statements stay owed. No feature verdict changes: the features of the two ND rows stay partial for their owed statements. Plan: plan/pending/nd-gap9-mld-unspecified-source.md Change: doc | behavior.change | - | nd-gap9-mld-unspecified-source
Before this commit, the plan had the documents and the gates open. After this commit, the plan marks them done, with the results of the fresh run and of the gates. The statistics commits of the repair are on a local branch of the statistics repository only, as the branch is local. Plan: plan/pending/nd-gap9-mld-unspecified-source.md Change: plan | behavior.change | - | nd-gap9-mld-unspecified-source
Before this commit, the plan of the repair was in plan/pending. After this commit, it is in plan/done, because all its steps are done. Plan: plan/done/nd-gap9-mld-unspecified-source.md Change: plan | location | - | nd-gap9-mld-unspecified-source
There was a problem hiding this comment.
🔍 Devin Review: 5 flags
Not posted on this PR by your GitHub settings — view them in Devin Review. (Configure)
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
On master,
Rfc4862GroupsBeforeDadoftests/protocol/ndfails. It is the last ND test that fails, the half of gap 9 that #1392 left open. An IPv6 interface joins the solicited-node group of each tentative address before Duplicate Address Detection (RFC 4862 section 5.4.2), and its MLD Report for the group informs MLD-snooping switches. But the model held every MLD Report and Done until the link-local address was tested, so the Report left after the Neighbor Solicitation of the detection. RFC 3590 section 4 (MLDv1) and RFC 9777 section 5.2.14 (MLDv2) send such a message from the unspecified address. They also tell a node to report its groups again once the link-local address is valid, and tell a router to discard a Report or a Done from the unspecified address.This changes only the simulations with MLD (
hasMld = true, off by default): the MLD and PIM IPv6 examples. Their nodes send their first Reports at once, from the unspecified address, and report again from the link-local address once it is valid. The applications send and receive the same packets. No parameter is new, removed or changed.The repair has three parts:
Ipv6::fragmentPostRoutingkeeps the unspecified source of a local MLD Report or Done (ICMPv6 types 131, 132 and 143), next to the exception for the solicitation of DAD. MLD sets the source of each of these messages, so the IPv6 layer sends from the unspecified address only when MLD asks for it. A rule on an explicit::source is not used, because a UDP socket bound to::also gives one. A router also does not forward a multicast datagram from the unspecified address any more (RFC 4291 section 2.5.2). Without that rule, a PIM-DM router stopped at an assertion: it tried to forward an MLDv1 Report from::, which goes to the address of its group.Mldv1andMldv2discard a Report or a Done from the unspecified address, as a router and as a host (RFC 3590 sections 4 and 6, RFC9777-REP-37).The held messages hid four wrong premises in the tests, and each has its own commit before the commit that exposes it:
TestMldinjected messages with no source;MLDv2_router_basicandMLDv2_ssmjoined before the hosts had a link-local address (hostBootupTimeis 0.4 to 1 s); and two MLD checks asked more than RFC 9777. One check asked a link-local source for every message, and the other forbade an MLDv2 Report before the first MLDv1 Query. The checks and their tests now follow the RFC text. A new check and test,Rfc9777ReportBeforeLinkLocal, covers RFC9777-REP-34, REP-37 and REP-39, which were owed.Commits, in the order to read them
The series follows PR-SPLIT-PREPARE: the
changecommits prepare the repair and move nothing, and each of the twofixcommits insrcturns on the new behavior for one MLD version, with 10 source lines. Thetestscommits change no model code. Theplananddoccommits change no behavior.f0ebcc4eeaplan: add: ND gap 9, an MLD Report before the address is tested (the plan; it moves to plan/done/ in the last commit)e0e3013087doc: add: MLD check of a start of listening before the link-local address is tested (the check of RFC9777-REP-34, REP-37 and REP-39, from the standard text alone)7ebe3f2bfbipv6: change: a local MLD Report or Done keeps the unspecified source address (moves nothing: MLD gives no message the unspecified source yet)a5ebd06427ipv6: change: a router does not forward a multicast datagram from the unspecified address (RFC 4291 section 2.5.2; moves nothing)699aae06bbtests: fix: the MLD module tests inject messages from a link-local address (prepares the receivers:TestMldsets the sourcefe80::99)0884b81727icmpv6: change: an MLD node discards a Report or Done from the unspecified address (moves nothing: no node sends one yet)0963afe263icmpv6: change: an MLD node reports its groups again when its link-local address becomes valid (moves nothing: no interface has sent from the unspecified address yet)5e36e5e1b6icmpv6: fix: an MLDv1 Report leaves before the link-local address is tested (turns the new behavior on for MLDv1;Rfc4862GroupsBeforeDadpasses, and the release note)e3a215fd40tests: fix: two MLD checks allow a Report before the link-local address is valid (prepares MLDv2: the checks and the tests of "Router Alert on every message" and "Listener in MLDv1 mode", corrected to RFC 9777)22f8efc1f6tests: fix: two MLDv2 module tests join after the link-local address (prepares MLDv2: the receivers join at 1.5 s)5ff01865c2icmpv6: fix: an MLDv2 Report leaves before the link-local address is tested (turns the new behavior on for MLDv2, withRfc9777ReportBeforeLinkLocal)9adabaf61bicmpv6: change: MLD holds no message until the link-local address is valid (the clean-up: the held messages and themldv1Modeparameter ofcancelHostTimersgo; moves nothing)efc9302250plan: change: ND gap 9 and the MLD Reports before the link-local address are repaired (the facts found on the way; the run records cite this commit)b72c90da02doc: change: ND and MLD results, coverage and conformance after the repair of gap 9 (ND 37 of 37 PASS, MLD 48 of 48 PASS, and the new counts of the RFC 9777 statements)1267f65ecfplan: change: the repair of ND gap 9 is done525f029e38plan: location: move the ND gap 9 repair plan to doneArchitectural surface:
Ipv6::fragmentPostRoutingkeeps the unspecified source of a local MLD Report or Done, andIpv6::routeMulticastPacketdrops a multicast datagram from the unspecified address.Mldv1andMldv2loseheldMessages,sendHeldMessagesanddeleteHeldMessages, and get the protected virtual functionsendReports;Mldv2getssendCurrentStateReport, and itscancelHostTimersloses the parametermldv1Mode.TestMldoftests/module/libgives its messages a link-local source;MLDv2_router_basicandMLDv2_ssmstart their receivers at 1.5 s. The MLD testsRfc9777HopLimitAndSourceandRfc9777ListenerV1Modeand their checks follow RFC 9777.AV-*orNV-*row.Baseline changes
The lists with a reason for each line are in the commits: the fingerprint list in the INET commit, the statistics list in the statistics commit that it pins (branch
topic/standards-tests-nd-gap9-fixesofinet-framework/statistics, 2 commits on76d45e4e, the statistics commit that master pins). No chart moves. Each commit has the formcommitof TR-BASELINE-ATTRIBUTION: the repair commit is the small change.3 fingerprint configurations and 3 statistical results move, the examples with MLDv1 (
ipv6/mldMldDemo,pimdm_ipv6 and sm_ipv6): the nodes send their first Reports from the unspecified address and report again from the link-local address, so the MLD frames and their timing change. The nodes send more Ethernet frames (MldDemo 38 to 45, dm_ipv6 493 to 522, sm_ipv6 464 to 491), and the applications send and receive the same packets.2 fingerprint configurations and 2 statistical results move, the examples with MLDv2 (
ipv6/mldMldV2Ssm,pimssm_ipv6): the nodes send their first Reports from the unspecified address and one Current-State Report from the link-local address. The nodes send more Ethernet frames (MldV2Ssm 48 to 52, ssm_ipv6 232 to 240), and the applications send and receive the same packets.Evidence
The runs used a copy of the CI job: the image of
ubuntu-26.04with itsclang(clang 21.1.8), OMNeT++omnetpp-6.xata2a6c68a91(6.5.0) and opp_replgithub_ci. In this image, master gives the same results as its CI. The debug runs are atefc9302250, the commit that the run records cite, and the release runs are at the tip; thesrcandteststrees of the two commits are the same.opp_run_protocol_tests -m debug -w '^tests/protocol/nd$'Rfc4862GroupsBeforeDad)opp_run_protocol_tests -m debug -w '^tests/protocol/mld$', and the same forigmpandipsecopp_run_protocol_tests -m debugopp_run_module_tests -m debugExternalProcess_1to_4,AarfRateControl*,IPv4_dont_fragment_drop_reason), the same 7 as master in the same containeropp_run_fingerprint_tests -m releaseopp_run_statistical_tests -m release, with the pinned statisticsopp_run_chart_tests -m releaseEach commit got its fingerprint values and its statistics commit in the same image, at that commit, on master
bfb149475b: the complete fingerprint test, and the 7 statistical tests of the MLD examples, against the values of the commit before. Only the twofixcommits move results. A debug run of each commit (the ND and MLD suites, and the 16 MLD and PIM module tests) showsRfc4862GroupsBeforeDadFAIL up to the MLDv1 commit and PASS from it on, and all other tests PASS at each commit.Rfc9777ReportBeforeLinkLocalfails at the parent of the MLDv2 commit, at its first guard (RFC9777-REP-34).The series was then rebased onto master
1369a093f0. The new commits of master change only comments insrc, thelan80211example with its statistics, and one 802.11 protocol test, and no baseline file is common to them and this series.baseline_pins.py rebasemade the commits again with no conflict and moved the two pins to the rebased statistics commits. The runs in the table are on this base.Not verified here:
The plan, with the decisions and the facts found on the way, is
plan/done/nd-gap9-mld-unspecified-source.md.🤖 Generated with Claude Code