CVE-2024-35846 Details
Description
In the Linux kernel, the following vulnerability has been resolved: mm: zswap: fix shrinker NULL crash with cgroup_disable=memory Christian reports a NULL deref in zswap that he bisected down to the zswap shrinker. The issue also cropped up in the bug trackers of libguestfs [1] and the Red Hat bugzilla [2]. The problem is that when memcg is disabled with the boot time flag, the zswap shrinker might get called with sc->memcg == NULL. This is okay in many places, like the lruvec operations. But it crashes in memcg_page_state() - which is only used due to the non-node accounting of cgroup's the zswap memory to begin with. Nhat spotted that the memcg can be NULL in the memcg-disabled case, and I was then able to reproduce the crash locally as well. [1] https://github.com/libguestfs/libguestfs/issues/139 [2] https://bugzilla.redhat.com/show_bug.cgi?id=2275252
A vulnerability in the Linux kernel's zswap component can lead to a NULL pointer dereference when the memory cgroup (memcg) feature is disabled via a boot-time flag. This issue arises because the zswap shrinker may be invoked with a NULL memcg reference, which is problematic when accessing certain memory cgroup statistics. The vulnerability has been reported in the context of libguestfs and Red Hat bugzilla.
Users can avoid this vulnerability by not disabling the memory cgroup feature at boot. If the vulnerability has been encountered, it can be addressed by updating to a patched version of the Linux kernel.
Metrics
CVSS 4.0 Severity and Vector Strings:
No CVSS 4.0 data is available for this CVE.
CVSS 3.x Severity and Vector Strings:
No data available for CVSS Version 2.0 on this CVE.
CISA-ADP
Assessed May 17, 2024References to Advisories, Solutions, and Tools
By selecting these links, you will be leaving this site. These are references gathered from the official CVE record and are not endorsed by Volerion.
Weakness Enumeration
| CWE-ID | CWE Name | Source |
|---|---|---|
| CWE-476 | NULL Pointer Dereference | [email protected] |
Affected Products
| Product | Versions |
|---|---|
| linux linux kernel | >= 6.8, < 6.8.9 6.9 rc1 6.9 rc2 6.9 rc3 6.9 rc4 6.9 rc5 |
CPE
Remediation
| |
Change History
6 change records found show changes
| Date | Action | Recorded By |
|---|---|---|
| Jun 17, 2026 | CVE Modified | kernel.org |
| Jun 17, 2026 | CVE Modified | CISA-ADP |
| Dec 30, 2024 | Initial Analysis | [email protected] |
| Nov 21, 2024 | CVE Modified | CVE |
| May 29, 2024 | CVE Modified | kernel.org |
| May 17, 2024 | New CVE Received | kernel.org |