CVE-2026-98026: net: bridge: mcast: properly convert mglist to rcu
In the Linux kernel, the following vulnerability has been resolved:
net: bridge: mcast: properly convert mglist to rcu
Sashiko reported a bug [1] that brmulticastdelportgroup unlists the port group not using proper rcu helper that preserves the next pointer and after that immediately frees the port group without waiting for rcu grace period. The only rcu walker of mglist is brmulticastlistadjacent() and it turns out that function has always been buggy because mglist was never properly converted to RCU. Fix it by converting it to rcu and moving its initialization after ethaddr's. Initializing p->next can use RCUINITPOINTER because we have a barrier from the hlistaddheadrcu call later, besides we're initializing an unpublished structure anyway.
[1] https://netdev-ai.bots.linux.dev/sashiko/#/patchset/20260826014200.362304-1-littleddfu%40gmail.com
Affected Software
Event History
Frequently Asked Questions
What condition creates the unsafe lifetime window?
The port group is removed from the multicast group list without the RCU helper that preserves its next pointer, then is freed immediately without waiting for an RCU grace period. A concurrent RCU traversal can therefore encounter invalid list state or freed memory.
Which code path can traverse the affected list concurrently?
The described RCU walker is br_multicast_list_adjacent(). The report states that this function had always been unsafe because the multicast group list was not properly converted to RCU.
What does the fix change?
The fix converts the multicast group list to RCU handling and moves its initialization after the Ethernet address initialization. It also uses RCU_INIT_POINTER for the next pointer during initialization of the unpublished structure.