CVE-2025-40348
slab: Avoid race on slab->obj_exts in alloc_slab_obj_exts
Check your servers for CVE-2025-40348
The Vulnpocalypse collector sends the package list of each Linux server and of its container images once a day. Vulnpocalypse shows every server where CVE-2025-40348 affects the running kernel, with the command that installs the fix. The free plan covers one server and one domain and does not need a credit card.
Description
In the Linux kernel, the following vulnerability has been resolved:
slab: Avoid race on slab->obj_exts in alloc_slab_obj_exts
If two competing threads enter alloc_slab_obj_exts() and one of them fails to allocate the object extension vector, it might override the valid slab->obj_exts allocated by the other thread with OBJEXTS_ALLOC_FAIL. This will cause the thread that lost this race and expects a valid pointer to dereference a NULL pointer later on.
Update slab->obj_exts atomically using cmpxchg() to avoid slab->obj_exts overrides by racing threads.
Thanks for Vlastimil and Suren's help with debugging.
Exploitation
EPSS 0.21%: the probability of exploitation activity in the next 30 days, from the EPSS model of FIRST. The score is higher than 12.3% of all scored CVEs. Scores of 1 Dec 2026.
Affected products
As the CNA lists them.
| Product | Versions |
|---|---|
| Linux |
affected from 715b6a5b41dae39baeaa40d3386b548bb278b9c2, before c7af5300d78460fc5037ddc77113ba3dbfe77dc0 affected from 07e38a54cabd9b4de7ceb7f075f29ffa463e458a, before 7c34feda6a9a203c9744281f1b6671b7dad2012d affected from f7381b9116407ba2a429977c80ff8df953ea9354, before 6ed8bfd24ce1cb31742b09a3eb557cd008533eec
Other versions: unaffected
|
| Linux |
affected from 6.12.54, before 6.12.56 affected from 6.17.4, before 6.17.6
Other versions: unaffected
|
Is my server affected?
This CVE is in the Linux kernel. Compare the running kernel with the fixed kernel version of your distribution, and reboot after a kernel update:
uname -r
# Debian, Ubuntu: does the changelog of the running kernel name the CVE?
zgrep -l CVE-2025-40348 /usr/share/doc/linux-image-$(uname -r)/changelog.Debian.gz
# RHEL, Rocky, Alma
rpm -q --changelog kernel | grep CVE-2025-40348
With Trivy, on the host and for a container image. When a package is affected, it prints the installed and the fixed version:
trivy rootfs --scanners vuln / | grep CVE-2025-40348
trivy image --scanners vuln IMAGE | grep CVE-2025-40348
Vulnpocalypse makes this comparison every day for the package lists of your servers and container images, including language packages (npm, PyPI, Go, Maven and others), and sends the command that installs the fix. Start free with one server and one domain or read how to install the collector.
References
Other references
- https://git.kernel.org/stable/c/c7af5300d78460fc5037ddc77113ba3dbfe77dc0 git.kernel.org
- https://git.kernel.org/stable/c/7c34feda6a9a203c9744281f1b6671b7dad2012d git.kernel.org
- https://git.kernel.org/stable/c/6ed8bfd24ce1cb31742b09a3eb557cd008533eec git.kernel.org
Source: the record CVE-2025-40348 of the CVE List (CVE Program), CVE Terms of Use; EPSS of FIRST. The text of the record is shown as published. Data sources and licences.
Vulnpocalypse