CVE-2025-38108: net_sched: red: fix a race in __red_change()
In the Linux kernel, the following vulnerability has been resolved:
netsched: red: fix a race in redchange()
Gerrard Tai reported a race condition in RED, whenever SFQ perturb timer fires at the wrong time.
The race is as follows:
CPU 0 CPU 1 [1]: lock root [2]: qdisctreeflushbacklog() [3]: unlock root | | [5]: lock root | [6]: rehash | [7]: qdisctreereducebacklog() | [4]: qdiscput()
This can be abused to underflow a parent's qlen.
Calling qdiscpurgequeue() instead of qdisctreeflushbacklog() should fix the race, because all packets will be purged from the qdisc before releasing the lock.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade
debian/linuxto a version that resolves this vulnerability.Fixed in 6.1.176-1Fixed in 6.1.190-1Fixed in 6.12.107-1Fixed in 6.12.113-1Fixed in 7.2.12-1Fixed in 7.2.13-1 - Configuration
Call qdisc_purge_queue() instead of qdisc_tree_flush_backlog() before releasing the lock, so all packets are purged from the qdisc before the lock is released.
Linux kernel net_sched RED queue purge function in __red_change() = qdisc_purge_queue()
Event History
Frequently Asked Questions
What is the severity of CVE-2025-38108?
CVE-2025-38108 has been classified as a medium severity vulnerability due to the potential for a race condition affecting packet scheduling.
How do I fix CVE-2025-38108?
To fix CVE-2025-38108, it is recommended to update to the latest version of the Linux kernel where the vulnerability has been addressed.
What systems are affected by CVE-2025-38108?
CVE-2025-38108 affects various versions of the Linux kernel that implement RED queuing disciplines.
What are the potential impacts of CVE-2025-38108?
The potential impact of CVE-2025-38108 includes data packet loss or network instability due to the race condition in scheduling.
Who reported the CVE-2025-38108 vulnerability?
The CVE-2025-38108 vulnerability was reported by Gerrard Tai.