CVE-2025-21702
pfifo_tail_enqueue: Drop new packet when sch->limit == 0
Reported by linux · Published February 18, 2025
In the Linux kernel, the following vulnerability has been resolved: pfifo_tail_enqueue: Drop new packet when sch->limit == 0 Expected behaviour: In case we reach scheduler's limit, pfifo_tail_enqueue() will drop a packet in scheduler's queue and decrease scheduler's qlen by one. Then, pfifo_tail_enqueue() enqueue new packet and increase scheduler's qlen by one. Finally, pfifo_tail_enqueue() return `NET_XMIT_CN` status code. Weird behaviour: In case we set `sch->limit == 0` and trigger pfifo_tail_enqueue() on a scheduler that has no packet, the 'drop a packet' step will do nothing. This means the scheduler's qlen still has value equal 0. Then, we continue to enqueue new packet and increase scheduler's qlen by one. In summary, we can leverage pfifo_tail_enqueue() to increase qlen by one and return `NET_XMIT_CN` status code. The problem is: Let's say we have two qdiscs: Qdisc_A and Qdisc_B. - Qdisc_A's type must have '->graft()' function to create parent/child relationship. Let's say Qdisc_A's type is `hfsc`. Enqueue packet to this qdisc will trigger `hfsc_enqueue`. - Qdisc_B's type is pfifo_head_drop. Enqueue packet to this qdisc will trigger `pfifo_tail_enqueue`. - Qdisc_B is configured to have `sch->limit == 0`. - Qdisc_A is configured to route the enqueued's packet to Qdisc_B. Enqueue packet through Qdisc_A will lead to: - hfsc_enqueue(Qdisc_A) -> pfifo_tail_enqueue(Qdisc_B) - Qdisc_B->q.qlen += 1 - pfifo_tail_enqueue() return `NET_XMIT_CN` - hfsc_enqueue() check for `NET_XMIT_SUCCESS` and see `NET_XMIT_CN` => hfsc_enqueue() don't increase qlen of Qdisc_A. The whole process lead to a situation where Qdisc_A->q.qlen == 0 and Qdisc_B->q.qlen == 1. Replace 'hfsc' with other type (for example: 'drr') still lead to the same problem. This violate the design where parent's qlen should equal to the sum of its childrens'qlen. Bug impact: This issue can be used for user->kernel privilege escalation when it is reachable.
Fixed versions
Upgrade to a fixed version or later. Language registries are listed first, then Linux distributions, then vendor products.
| Package | Ecosystem | Fixed in |
|---|---|---|
| kernel-libbpf-devel | Amazon Linux | 6.1.130-139.222.amzn2023 |
| kernel | Amazon Linux | 6.1.130-139.222.amzn2023 |
| kernel-libbpf-static | Amazon Linux | 6.1.130-139.222.amzn2023 |
| kernel-livepatch-6.1.130-139.222 | Amazon Linux | 1.0-0.amzn2023 |
| perf | Amazon Linux | 6.1.130-139.222.amzn2023 |
Risk scores
Affected products
| Vendor | Product | Versions |
|---|---|---|
| Linux | Linux | 57dbb2d83d100ea601c54fe129bfde0678db5dee, 57dbb2d83d100ea601c54fe129bfde0678db5dee, 57dbb2d83d100ea601c54fe129bfde0678db5dee |
| Linux | Linux | 2.6.34, 0, 5.4.291 |
| amazon:2023 | kernel-libbpf-devel | 0 |
| amazon:2023 | kernel | 0 |
| amazon:2023 | kernel-libbpf-static | 0 |
| amazon:2023 | kernel-livepatch-6.1.130-139.222 | 0 |
| amazon:2023 | perf | 0 |
| Linux | Linux | 6.12.14, 6.6.83, 6.1.130 |
| amazon:2023 | kernel-modules-extra | 0 |
| amazon:2 | perf | 0 |
| amazon:2023 | kernel-tools-devel | 0 |
| Siemens | SIMATIC S7-1500 CPU 1518F-4 PN/DP MFP | 3.1.6, 3.1.7, 3.1.5 |
| amazon:2 | kernel | 0 |
| amazon:2023 | bpftool | 0 |
| amazon:2 | python-perf | 0 |
| amazon:2023 | kernel-libbpf | 0 |
| amazon:2023 | kernel-headers | 0 |
| amazon:2023 | kernel-tools | 0 |
| amazon:2023 | kernel-modules-extra-common | 0 |
| amazon:2023 | python3-perf | 0 |
…and 10 more
Timeline
- Feb 18, 2025 Coalition ESS Score (13 in total, the first dated here)
- Feb 18, 2025 CVE Published
- Feb 19, 2025 EPSS Score (30 in total, the first dated here)
- Dec 18, 2025 PoC Published
- Dec 22, 2025 Security Advisory (96 in total, the first dated here)
- Apr 29, 2026 Distribution Patch (67 in total, the first dated here)
Query this with the API
The same record, from the CLI:
vulnetix vdb vuln CVE-2025-21702
vulnetix vdb fixes CVE-2025-21702
Or with curl, using the org id and key from your account page:
curl -s -H "Authorization: ApiKey ${VULNETIX_ORG_ID}:${VULNETIX_API_KEY}" \
"https://api.vdb.vulnetix.com/v2/vuln/CVE-2025-21702/fixes/registry"
The Community plan is free and allows 50 queries a day. Get a free API key · API quickstart
References
- https://lists.debian.org/debian-lts-announce/2025/05/msg00045.html url
- https://lists.debian.org/debian-lts-announce/2025/05/msg00030.html url
- https://cert-portal.siemens.com/productcert/html/ssa-082556.html url
- https://cert-portal.siemens.com/productcert/html/ssa-019113.html url
- https://cert-portal.siemens.com/productcert/html/ssa-457936.html url
- https://cert-portal.siemens.com/productcert/html/ssa-784472.html url