CVE-2025-71097 ipv4: Fix reference count leak when using error routes with nexthop objects
A reference count leak in the Linux kernel IPv4 routing code can prevent network device removal, leading to resource exhaustion and denial of service.
- Exploited in the wild
- Not known
- Login needed
- Any signed-in user
- Attackable
- Local or same network only
- Victim action needed
- Not needed
- Fix
- Available
What is CVE-2025-71097?
CVE-2025-71097 is a medium-severity denial of service vulnerability in Linux kernel, published on 13 Jan 2026. It can only be exploited from the same machine or local network, with no action from the victim.
Official description
In the Linux kernel, the following vulnerability has been resolved:
ipv4: Fix reference count leak when using error routes with nexthop objects
When a nexthop object is deleted, it is marked as dead and then fib_table_flush() is called to flush all the routes that are using the dead nexthop.
The current logic in fib_table_flush() is to only flush error routes (e.g., blackhole) when it is called as part of network namespace dismantle (i.e., with flush_all=true). Therefore, error routes are not flushed when their nexthop object is deleted:
# ip link add name dummy1 up type dummy # ip nexthop add id 1 dev dummy1 # ip route add 198.51.100.1/32 nhid 1 # ip route add blackhole 198.51.100.2/32 nhid 1 # ip nexthop del id 1 # ip route show blackhole 198.51.100.2 nhid 1 dev dummy1
As such, they keep holding a reference on the nexthop object which in turn holds a reference on the nexthop device, resulting in a reference count leak:
# ip link del dev dummy1 [ 70.516258] unregister_netdevice: waiting for dummy1 to become free. Usage count = 2
Fix by flushing error routes when their nexthop is marked as dead.
IPv6 does not suffer from this problem.
Weakness: CWE-401
Which versions are affected by CVE-2025-71097?
It affects 1 product.
Products include Linux kernel.
How do I fix CVE-2025-71097?
Apply the vendor's patch.
Upgrade, then put limits on request size, rate and nesting depth so one client cannot exhaust the service. More about Denial of service.
Is CVE-2025-71097 being exploited?
There is no known exploitation of CVE-2025-71097 in the wild and no public exploit code.
Other vulnerabilities in Linux kernel
Sources
Also known as BELL-CVE-2025-71097, DEBIAN-CVE-2025-71097, GHSA-hc39-xg82-jgf4, ROOT-OS-DEBIAN-11-CVE-2025-71097, ROOT-OS-DEBIAN-12-CVE-2025-71097, ROOT-OS-DEBIAN-13-CVE-2025-71097 and 3 more.