Vulnerability in Kernel
AI summary
Produced by SecPulse using an external AI model; it may contain mistakes. Check the original description and references below before acting on it.
A vulnerability tracked as CVE-2025-40251 has been found in Kernel.
Attackers can target a specific entry point like rate_leaf_parent_set over the network to misuse the product.
Successful exploitation can lead to full system takeover. CVSS score: 7.8/10.
What to do: upgrade Kernel to 6.1.164, 6.6.118, 6.12.60, 6.17.10 or later.
If unsure, ask your IT team or search "Kernel CVE-2025-40251" on the vendor's site.
CVE-2025-40251 (Kernel) — CWE-476 / CVSS v3 7.8
Attack vector: local / no user interaction
Attack surface: rate_leaf_parent_set / rate_node_parent_set / devlink_rate / devlink_nl_rate_parent_node_set
Patched: 6.1.164, 6.6.118, 6.12.60, 6.17.10 — apply immediately
Plan: 1) Audit SBOM/dependencies, 2) Stage→prod upgrade, 3) Add WAF/proxy monitoring on affected endpoints, 4) Hunt IOCs in logs.
Refs: see the GHSA / vendor advisory / patched release linked on this page.
A vulnerability (CWE-476) exists in Kernel. Attackers reach the vulnerable code path via rate_leaf_parent_set.
Check the vendor advisory for the affected versions of Kernel. Attack surface: rate_leaf_parent_set / rate_node_parent_set / devlink_rate / devlink_nl_rate_parent_node_set.
Severity: High (CVSS 7.8/10). Successful exploitation can lead to full system takeover.
Update to 6.1.164, 6.6.118, 6.12.60, 6.17.10.
Until the patch is applied: disable the affected feature, apply WAF rules, or restrict access via network ACLs.
Search webserver/proxy logs for unusual request patterns matching this CVE's known IOCs. Run grep -r 'Kernel' . against your dependency files (package-lock.json, requirements.txt, go.sum) to find affected services.
Response actions
Concrete steps and command examples for SOC/SRE teams to execute in order
-
1
Identify exposureidentify
grep -r 'Kernel' . | grep -v node_modulesリポジトリと本番環境の依存ファイル (package-lock.json / requirements.txt / go.sum / Gemfile.lock 等) で
Kernelを grep し、稼働しているサービス・バージョンを把握する。 -
2
Apply patchpatch
Upgrade Kernel to 6.1.164, 6.6.118, 6.12.60, 6.17.10ステージング環境で 6.1.164, 6.6.118, 6.12.60, 6.17.10 に上げて回帰テスト → 本番反映。回帰テストはアプリの主要ハッピーパスを含めること。
-
3
Post-deployment verificationverify
Confirm patched version is live in productionパッチ適用後、ステージングで PoC または同等の悪用パターンを再現して脆弱性が閉じたことを確認。本番ではアクセスログ・WAF でアラート再発が無いか継続監視。
Affected packages
| Package | Affected → Fixed | |
|---|---|---|
| LinuxKernel |
≥ 5.14.0, < 6.1.164→ 6.1.164 ≥ 6.2.0, < 6.6.118→ 6.6.118 ≥ 6.7.0, < 6.12.60→ 6.12.60 ≥ 6.13.0, < 6.17.10→ 6.17.10 |
6.1.164 6.6.118 6.12.60 6.17.10 |
Fix status by distribution
Records published by each distribution for this CVE. Fixed versions differ by release; check each link.
- BellSoft Alpaquita BELL-CVE-2025-40251 linux-lts Fix available
- Debian DEBIAN-CVE-2025-40251 linux-6.1, linux Fix available
- Ubuntu UBUNTU-CVE-2025-40251 linux-xilinx, linux-riscv-6.17, linux-riscv-6.8 +41 more Fix available
Original description The description as published by the source.
In the Linux kernel, the following vulnerability has been resolved:
devlink: rate: Unset parent pointer in devl_rate_nodes_destroy
The function devl_rate_nodes_destroy is documented to "Unset parent for
all rate objects". However, it was only calling the driver-specific
rate_leaf_parent_set or rate_node_parent_set ops and decrementing
the parent's refcount, without actually setting the
devlink_rate->parent pointer to NULL.
This leaves a dangling pointer in the devlink_rate struct, which cause
refcount error in netdevsim[1] and mlx5[2]. In addition, this is
inconsistent with the behavior of devlink_nl_rate_parent_node_set,
where the parent pointer is correctly cleared.
This patch fixes the issue by explicitly setting devlink_rate->parent
to NULL after notifying the driver, thus fulfilling the function's
documented behavior for all rate objects.
[1]
repro steps:
echo 1 > /sys/bus/netdevsim/new_device
devlink dev eswitch set netdevsim/netdevsim1 mode switchdev
echo 1 > /sys/bus/netdevsim/devices/netdevsim1/sriov_numvfs
devlink port function rate add netdevsim/netdevsim1/test_node
devlink port function rate set netdevsim/netdevsim1/128 parent test_node
echo 1 > /sys/bus/netdevsim/del_device
dmesg:
refcount_t: decrement hit 0; leaking memory.
WARNING: CPU: 8 PID: 1530 at lib/refcount.c:31 refcount_warn_saturate+0x42/0xe0
CPU: 8 UID: 0 PID: 1530 Comm: bash Not tainted 6.18.0-rc4+ #1 NONE
Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS rel-1.16.0-0-gd23955…
Source: NIST National Vulnerability Database NVD GitHub Advisory
References
- advisory nvd.nist.gov
- advisory github.com
- package git.kernel.org
- web git.kernel.org
- web git.kernel.org
- web git.kernel.org
- web git.kernel.org
- web git.kernel.org
- web cert-portal.siemens.com
- web github.com