Skip to contentSkip to conversation

CVE-2025-21703: netem: Update sch->q.qlen before qdisc_tree_reduce_backlog()

DISCUSSION Greg Kroah-Hartman 1 participant 1 message Feb 18, 2025

lore
Share & tools
lore
#0 lore raw

Description
===========

In the Linux kernel, the following vulnerability has been resolved:

netem: Update sch->q.qlen before qdisc_tree_reduce_backlog()

qdisc_tree_reduce_backlog() notifies parent qdisc only if child qdisc becomes empty, therefore we need to reduce the backlog of the child qdisc before calling it. Otherwise it would miss the opportunity to call cops->qlen_notify(), in the case of DRR, it resulted in UAF since DRR uses ->qlen_notify() to maintain its active list.

The Linux kernel CVE team has assigned CVE-2025-21703 to this issue.

Affected and fixed versions
===========================

	Issue introduced in 6.6.67 with commit 3824c5fad18eeb7abe0c4fc966f29959552dca3e and fixed in 6.6.78 with commit 1f8e3f4a4b8b90ad274dfbc66fc7d55cb582f4d5
	Issue introduced in 6.12.6 with commit 356078a5c55ec8d2061fcc009fb8599f5b0527f9 and fixed in 6.12.14 with commit 6312555249082d6d8cc5321ff725df05482d8b83
	Issue introduced in 6.13 with commit f8d4bc455047cf3903cd6f85f49978987dbb3027 and fixed in 6.13.3 with commit 839ecc583fa00fab785fde1c85a326743657fd32
	Issue introduced in 6.13 with commit f8d4bc455047cf3903cd6f85f49978987dbb3027 and fixed in 6.14-rc2 with commit 638ba5089324796c2ee49af10427459c2de35f71
	Issue introduced in 5.4.288 with commit 83c6ab12f08dcc09d4c5ac86fdb89736b28f1d31
	Issue introduced in 5.10.232 with commit 216509dda290f6db92c816dd54b83c1df9da9e76
	Issue introduced in 5.15.175 with commit c2047b0e216c8edce227d7c42f99ac2877dad0e4
	Issue introduced in 6.1.121 with commit 10df49cfca73dfbbdb6c4150d859f7e8926ae427

Please see https://www.kernel.org for a full list of currently supported kernel versions by the kernel community.

Unaffected versions might change over time as fixes are backported to older supported kernel versions. The official CVE entry at

	https://cve.org/CVERecord/?id=CVE-2025-21703

will be updated if fixes are backported, please check that for the most up to date information about this issue.

Affected files
==============

The file(s) affected by this issue are:
net/sched/sch_netem.c

Mitigation
==========

The Linux kernel CVE team recommends that you update to the latest stable kernel version for this, and many other bugfixes. Individual changes are never tested alone, but rather are part of a larger kernel release. Cherry-picking individual commits is not recommended or supported by the Linux kernel community at all. If however, updating to the latest release is impossible, the individual changes to resolve this issue can be found at these commits:

	https://git.kernel.org/stable/c/1f8e3f4a4b8b90ad274dfbc66fc7d55cb582f4d5
	https://git.kernel.org/stable/c/6312555249082d6d8cc5321ff725df05482d8b83
	https://git.kernel.org/stable/c/839ecc583fa00fab785fde1c85a326743657fd32
	https://git.kernel.org/stable/c/638ba5089324796c2ee49af10427459c2de35f71