CVE-2026-99742: mm/mempolicy: charge shared policy nodes

Published Nov 20, 2026
·
Updated

In the Linux kernel, the following vulnerability has been resolved:

mm/mempolicy: charge shared policy nodes

Any local user can bypass memory.max with mbind() on a tmpfs file, and allocate unbounded kernel memory.

mbind() sets a NUMA memory policy for a range of a mapping. If the mapping is of a shmem and friends, the kernel also stores the policy on the inode, in a tree with one entry per range of the file.

Each mbind() on a single page of a mapping can add one shared policy node (struct spnode) and one struct mempolicy to that tree. They outlive the mapping and stay around until the inode is destroyed. The tree is not bounded by the file size, so the file can be empty.

Memory that user space can allocate must be charged to a memory cgroup. A slab cache does that for all of its objects if it is created with SLABACCOUNT. numapolicyinit() creates the slab caches for both structs without SLABACCOUNT, so they are not charged to any cgroup.

Reproduced with mbind() on single pages of an empty tmpfs file, from a cgroup with memory.max=8M: the global OOM killer killed tasks owned by root, and the machine panicked.

Fix this by creating both caches with SLABACCOUNT. This change implies that mbind() can now fail when running into memcg limits. Further, the policycache also serves task and VMA policies, so they are similarly accounted now.

Note that per-file limits are not really helpful, as the user could simply use many files; having limits per user is tricky as well.

Fix generated by an LLM and submitted by Chris Mason in private.

[ david: smaller description tweaks ]

Affected Software

7 affected componentsFixes available
linux/kernel>=4.5.0<6.12.118
6.12.118
linux/kernel>=6.13.0<6.18.64
6.18.64
linux/kernel>=6.19.0<7.3.5
7.3.5
debian/linux*
debian/linux*
debian/linux*
debian/linux<=6.1.176-1, <=6.1.192-2, <=6.12.107-1, <=6.12.117-1, <=7.3.4-1
7.3.5-1

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade linux/Kernel to a version that resolves this vulnerability.

    Fixed in 6.12.118
  2. Upgrade

    Upgrade linux/Kernel to a version that resolves this vulnerability.

    Fixed in 6.18.64
  3. Upgrade

    Upgrade linux/Kernel to a version that resolves this vulnerability.

    Fixed in 7.3.5
  4. Upgrade

    Upgrade debian/linux to a version that resolves this vulnerability.

    Fixed in 7.3.5-1
  5. Configuration

    Create the slab caches for struct sp_node and struct mempolicy with SLAB_ACCOUNT so their allocations are charged to a memory cgroup.

    Linux kernel mm/mempolicy SLAB_ACCOUNT = enabled

Event History

Nov 20, 2026
CVE Published
via MITRE·05:51 AM
Data Sourced
via MITRE·05:51 AM
Description
Data Sourced
via OSV·05:51 AM
DescriptionAffected Software
Data Sourced
via NVD·06:18 AM
Description

Frequently Asked Questions

1

Who can exploit this issue?

Any local user who can use mbind() on a tmpfs-backed file mapping can trigger it. The described proof of concept runs from a memory cgroup with memory.max set to 8 MB.

2

What does an attacker need to do?

The attacker repeatedly applies mbind() to single-page ranges of an empty tmpfs file. Each operation can retain a shared-policy node and mempolicy object on the inode, even after the mapping is gone.

3

What is the likely impact?

The uncharged kernel allocations can bypass memory.max and grow without bound. The reported outcome was global OOM killing of root-owned tasks followed by a machine panic.

4

Is an empty or large tmpfs file required?

No. The shared-policy tree is not bounded by file size, and the issue was reproduced using an empty tmpfs file.

5

What changes in the fix?

The fix creates the slab caches for shared policy nodes and memory-policy objects with SLAB_ACCOUNT, causing their allocations to be charged to a memory cgroup.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203