CVE-2024-45020
Severity CVSS v4.0:
Pending analysis
Type:
CWE-787
Out-of-bounds Write
Publication date:
11/09/2024
Last modified:
13/09/2024
Description
In the Linux kernel, the following vulnerability has been resolved:<br />
<br />
bpf: Fix a kernel verifier crash in stacksafe()<br />
<br />
Daniel Hodges reported a kernel verifier crash when playing with sched-ext.<br />
Further investigation shows that the crash is due to invalid memory access<br />
in stacksafe(). More specifically, it is the following code:<br />
<br />
if (exact != NOT_EXACT &&<br />
old->stack[spi].slot_type[i % BPF_REG_SIZE] !=<br />
cur->stack[spi].slot_type[i % BPF_REG_SIZE])<br />
return false;<br />
<br />
The &#39;i&#39; iterates old->allocated_stack.<br />
If cur->allocated_stack allocated_stack the out-of-bound<br />
access will happen.<br />
<br />
To fix the issue add &#39;i >= cur->allocated_stack&#39; check such that if<br />
the condition is true, stacksafe() should fail. Otherwise,<br />
cur->stack[spi].slot_type[i % BPF_REG_SIZE] memory access is legal.
Impact
Base Score 3.x
5.50
Severity 3.x
MEDIUM
Vulnerable products and versions
| CPE | From | Up to |
|---|---|---|
| cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* | 6.6.15 (including) | 6.6.48 (excluding) |
| cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* | 6.7 (including) | 6.10.7 (excluding) |
| cpe:2.3:o:linux:linux_kernel:6.11:rc1:*:*:*:*:*:* | ||
| cpe:2.3:o:linux:linux_kernel:6.11:rc2:*:*:*:*:*:* | ||
| cpe:2.3:o:linux:linux_kernel:6.11:rc3:*:*:*:*:*:* |
To consult the complete list of CPE names with products and versions, see this page



