CVE-2021-47125
Severity CVSS v4.0:
Pending analysis
Type:
Unavailable / Other
Publication date:
15/03/2024
Last modified:
07/01/2025
Description
In the Linux kernel, the following vulnerability has been resolved:<br />
<br />
sch_htb: fix refcount leak in htb_parent_to_leaf_offload<br />
<br />
The commit ae81feb7338c ("sch_htb: fix null pointer dereference<br />
on a null new_q") fixes a NULL pointer dereference bug, but it<br />
is not correct.<br />
<br />
Because htb_graft_helper properly handles the case when new_q<br />
is NULL, and after the previous patch by skipping this call<br />
which creates an inconsistency : dev_queue->qdisc will still<br />
point to the old qdisc, but cl->parent->leaf.q will point to<br />
the new one (which will be noop_qdisc, because new_q was NULL).<br />
The code is based on an assumption that these two pointers are<br />
the same, so it can lead to refcount leaks.<br />
<br />
The correct fix is to add a NULL pointer check to protect<br />
qdisc_refcount_inc inside htb_parent_to_leaf_offload.
Impact
Base Score 3.x
5.50
Severity 3.x
MEDIUM
Vulnerable products and versions
| CPE | From | Up to |
|---|---|---|
| cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* | 5.12 (including) | 5.12.10 (excluding) |
| cpe:2.3:o:linux:linux_kernel:5.13:rc1:*:*:*:*:*:* | ||
| cpe:2.3:o:linux:linux_kernel:5.13:rc2:*:*:*:*:*:* | ||
| cpe:2.3:o:linux:linux_kernel:5.13:rc3:*:*:*:*:*:* | ||
| cpe:2.3:o:linux:linux_kernel:5.13:rc4:*:*:*:*:*:* |
To consult the complete list of CPE names with products and versions, see this page



