CVE-2025-21965

Source
https://nvd.nist.gov/vuln/detail/CVE-2025-21965
Import Source
https://storage.googleapis.com/osv-test-cve-osv-conversion/osv-output/CVE-2025-21965.json
JSON Data
https://api.test.osv.dev/v1/vulns/CVE-2025-21965
Downstream
Published
2025-04-01T15:47:01Z
Modified
2025-10-17T23:13:14.625151Z
Summary
sched_ext: Validate prev_cpu in scx_bpf_select_cpu_dfl()
Details

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

schedext: Validate prevcpu in scxbpfselectcpudfl()

If a BPF scheduler provides an invalid CPU (outside the nrcpuids range) as prevcpu to scxbpfselectcpu_dfl() it can cause a kernel crash.

To prevent this, validate prevcpu in scxbpfselectcpu_dfl() and trigger an scx error if an invalid CPU is specified.

References

Affected packages

Git / git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git

Affected ranges

Type
GIT
Repo
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
Events
Introduced
f0e1a0643a59bf1f922fa209cec86a170b784f3f
Fixed
752b56bb76e2471197d25d6948d85753043b10da
Type
GIT
Repo
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
Events
Introduced
f0e1a0643a59bf1f922fa209cec86a170b784f3f
Fixed
515680e76c536dd4aa8e2b5d674b0d441baddf5b
Type
GIT
Repo
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
Events
Introduced
f0e1a0643a59bf1f922fa209cec86a170b784f3f
Fixed
9360dfe4cbd62ff1eb8217b815964931523b75b3

Affected versions

v6.*

v6.10
v6.10-rc3
v6.10-rc4
v6.10-rc5
v6.10-rc6
v6.10-rc7
v6.11
v6.11-rc1
v6.11-rc2
v6.11-rc3
v6.11-rc4
v6.11-rc5
v6.11-rc6
v6.11-rc7
v6.12
v6.12-rc1
v6.12-rc2
v6.12-rc3
v6.12-rc4
v6.12-rc5
v6.12-rc6
v6.12-rc7
v6.12.1
v6.12.10
v6.12.11
v6.12.12
v6.12.13
v6.12.14
v6.12.15
v6.12.16
v6.12.17
v6.12.18
v6.12.19
v6.12.2
v6.12.3
v6.12.4
v6.12.5
v6.12.6
v6.12.7
v6.12.8
v6.12.9
v6.13
v6.13-rc1
v6.13-rc2
v6.13-rc3
v6.13-rc4
v6.13-rc5
v6.13-rc6
v6.13-rc7
v6.13.1
v6.13.2
v6.13.3
v6.13.4
v6.13.5
v6.13.6
v6.13.7

Linux / Kernel

Package

Name
Kernel

Affected ranges

Type
ECOSYSTEM
Events
Introduced
6.12.0
Fixed
6.12.20
Type
ECOSYSTEM
Events
Introduced
6.13.0
Fixed
6.13.8