Skip to contentSkip to conversation

CVE-2026-93112: bpf: Require a BPF cpumask for bpf_cpumask_populate()

DISCUSSION Greg Kroah-Hartman 1 participant 1 message Sep 17

lore
Share & tools
lore
#0 lore raw

From: Greg Kroah-Hartman <[email protected]>

Description
===========

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

bpf: Require a BPF cpumask for bpf_cpumask_populate()

bpf_cpumask_populate() writes to its destination with bitmap_copy(), but the destination is typed as struct cpumask *. That allows the verifier to accept borrowed cpumask pointers returned by read-only kfuncs, such as scx_bpf_get_online_cpumask(), as a writable destination.

Make the destination a struct bpf_cpumask * so populate follows the same ownership rule as the other mutating cpumask kfuncs. Query kfuncs continue to accept const struct cpumask * inputs.

The Linux kernel CVE team has assigned CVE-2026-93112 to this issue.

Affected and fixed versions
===========================

	Issue introduced in 6.15 with commit 950ad93df2fce70445e655ed2e74f5c1a8653ab2 and fixed in 6.18.52 with commit 0cfc9348a045da64955af2dd6902e66dfc7d6469
	Issue introduced in 6.15 with commit 950ad93df2fce70445e655ed2e74f5c1a8653ab2 and fixed in 7.2.6 with commit b7e2a5c6519adc73be55c3de2cb545e095a0fbc5
	Issue introduced in 6.15 with commit 950ad93df2fce70445e655ed2e74f5c1a8653ab2 and fixed in 7.3-rc1 with commit 8740156ad33be5071b588b594c55f279457f667c

Please see https://www.kernel.org for a full list of currently supported kernel versions by the kernel community.

Unaffected versions might change over time as fixes are backported to older supported kernel versions. The official CVE entry at

	https://cve.org/CVERecord/?id=CVE-2026-93112

will be updated if fixes are backported, please check that for the most up to date information about this issue.

Affected files
==============

The file(s) affected by this issue are:
kernel/bpf/cpumask.c
tools/sched_ext/include/scx/compat.bpf.h

Mitigation
==========

The Linux kernel CVE team recommends that you update to the latest stable kernel version for this, and many other bugfixes. Individual changes are never tested alone, but rather are part of a larger kernel release. Cherry-picking individual commits is not recommended or supported by the Linux kernel community at all. If however, updating to the latest release is impossible, the individual changes to resolve this issue can be found at these commits:

	https://git.kernel.org/stable/c/0cfc9348a045da64955af2dd6902e66dfc7d6469
	https://git.kernel.org/stable/c/b7e2a5c6519adc73be55c3de2cb545e095a0fbc5
	https://git.kernel.org/stable/c/8740156ad33be5071b588b594c55f279457f667c