CVE-2026-89564: ip: orphan prefetched skbs before multicast forwarding
In the Linux kernel, the following vulnerability has been resolved:
ip: orphan prefetched skbs before multicast forwarding
IPv4 and IPv6 input preserve an skb->sk association installed by bpfskassign() so that local delivery can use the selected socket under RCU. Both address families can also prefetch a socket in UDP early demux. In both paths (BPF and UDP early demux) a reference is not guaranteed to be held on the socket.
When a multicast packet is not locally deliverable, IPv6 hands the original skb to ip6mrinput(). IPv4's ipmrinput() similarly keeps the original skb when local delivery is not needed. Either path can put the skb on an unresolved multicast route queue or forward it after the receive-side RCU section ends.
After the prefetched socket is destroyed, a later skb free invokes sockpfree() and dereferences the stale skb->sk. Orphan the skb before each non-local multicast forwarding path. Local delivery retains the original skb; the existing skbclone() calls provide multicast forwarding with a socket-free clone.
Affected Software
Event History
Frequently Asked Questions
Which systems are exposed to this issue?
Systems that perform IPv4 or IPv6 multicast forwarding are exposed when a multicast packet is not locally deliverable and is queued for an unresolved multicast route or forwarded after the receive-side RCU section. The stale socket association can originate from either BPF socket assignment or UDP early demux.
What conditions are needed to trigger the stale socket reference?
A packet must retain an skb->sk association without a guaranteed socket reference, then take a non-local multicast forwarding path. If the associated socket is destroyed before the skb is later freed, sock_pfree() can dereference the stale skb->sk pointer.
Are locally delivered multicast packets affected?
The described fix preserves the original skb for local delivery. The problematic paths are the non-local multicast forwarding paths, where the skb must be orphaned before it can be queued or forwarded.
What mitigation is available if the fix cannot be applied immediately?
The provided information identifies multicast forwarding as the affected path. Limiting or disabling non-local IPv4 and IPv6 multicast forwarding would avoid the described forwarding and unresolved-route queue handling, where the stale association can outlive the socket.