CVE-2024-50262

bpf: Fix out-of-bounds write in trie_get_next_key()

HIGH
7.8
CVSS Score
Published: November 9, 2024 at 10:17 AM UTC
Updated: October 15, 2026 at 01:19 AM UTC
15 products affected across 2 vendorsLinux KernelSIMATIC S7-1500 CPU 1518-4 Pn /dp MFP FirmwareSiplus S7-1500 CPU 1518-4 Pn /dp MFP Firmware

Using Linux by Linux?

Get instant alerts when new vulnerabilities affect Linux - before attackers find them.

Real-time alertsTrack your software stackFree plan available
Severity
HIGH7.8
Exploit prediction
EPSS 0.3%
SSVC
No known exploit

Description

In the Linux kernel, the following vulnerability has been resolved: bpf: Fix out-of-bounds write in trie_get_next_key() trie_get_next_key() allocates a node stack with size trie->max_prefixlen, while it writes (trie->max_prefixlen + 1) nodes to the stack when it has full paths from the root to leaves. For example, consider a trie with max_prefixlen is 8, and the nodes with key 0x00/0, 0x00/1, 0x00/2, ... 0x00/8 inserted. Subsequent calls to trie_get_next_key with _key with .prefixlen = 8 make 9 nodes be written on the node stack with size 8.

Affected

Our own answer: ranges merged, affected separated from platform-only, with confidence and review flags.

4.16 ≤ v < 4.19.3234.20 ≤ v < 5.4.2855.11 ≤ v < 5.15.1715.16 ≤ v < 6.1.1165.5 ≤ v < 5.10.2296.2 ≤ v < 6.6.606.7 ≤ v < 6.11.76.126.12 rc16.12 rc26.12 rc36.12 rc46.12 rc5b471f2f1de8b816f1e799b80aa92588f3566e4bd
Vendor states this is fixed in 13400ac8fb80c57c2bfb12ebd35ee121ce9b4d21 (fixed)
Vendor states this is fixed in 590976f921723d53ac199c01d5b7b73a94875e68 (fixed)
Vendor states this is fixed in 86c8ebe02d8806dd8878d0063e8e185622ab6ea6 (fixed)
Vendor states this is fixed in 90a6e0e1e151ef7a9282e78f54c3091de2dcc99c (fixed)
Vendor states this is fixed in 91afbc0eb3c90258ae378ae3c6ead3d2371e926d (fixed)
Vendor states this is fixed in a035df0b98df424559fd383e8e1a268f422ea2ba (fixed)
Vendor states this is fixed in c4b4f9a9ab82238cb158fa4fe61a8c0ae21a4980 (fixed)
Vendor states this is fixed in e8494ac079814a53fbc2258d2743e720907488ed (fixed)
Vendor states this is fixed in 4.16 (unaffected)
Vendor states this is fixed in 4.19.323 (unaffected)
Vendor states this is fixed in 5.10.229 (unaffected)
Vendor states this is fixed in 5.15.171 (unaffected)
Vendor states this is fixed in 5.4.285 (unaffected)
Vendor states this is fixed in 6.1.116 (unaffected)
Vendor states this is fixed in 6.11.7 (unaffected)
Vendor states this is fixed in 6.12 (unaffected)
Vendor states this is fixed in 6.6.60 (unaffected)
v < V3.2
Affected range stops below V3.2, so it looks safe — our inference, not a vendor statement
v < V3.2
Affected range stops below V3.2, so it looks safe — our inference, not a vendor statement
v < V3.2
Affected range stops below V3.2, so it looks safe — our inference, not a vendor statement
v < V3.2
Affected range stops below V3.2, so it looks safe — our inference, not a vendor statement
v < V3.2
Affected range stops below V3.2, so it looks safe — our inference, not a vendor statement
v < V3.2
Affected range stops below V3.2, so it looks safe — our inference, not a vendor statement
v < V3.2
Affected range stops below V3.2, so it looks safe — our inference, not a vendor statement
v < V3.2
Affected range stops below V3.2, so it looks safe — our inference, not a vendor statement
v < V3.2
Affected range stops below V3.2, so it looks safe — our inference, not a vendor statement

References (13)

Patch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/13400ac8fb80c57c2bfb12ebd35ee121ce9b4d21
Patch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/590976f921723d53ac199c01d5b7b73a94875e68
Patch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/86c8ebe02d8806dd8878d0063e8e185622ab6ea6
Patch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/90a6e0e1e151ef7a9282e78f54c3091de2dcc99c
Patch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/91afbc0eb3c90258ae378ae3c6ead3d2371e926d
Patch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/a035df0b98df424559fd383e8e1a268f422ea2ba
Patch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/c4b4f9a9ab82238cb158fa4fe61a8c0ae21a4980
Patch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/e8494ac079814a53fbc2258d2743e720907488ed

SSVC — Action Prioritization

SSVCNo known exploitNot automatableTotal impact

SSVC signals action urgency (what to patch first), separate from CVSS which measures severity.

CVSS

7.8HIGHLinux
Vector?

Quick Info

StatusMODIFIED
CWE
CWE-787

Get alerted

Stop reading CVE feeds looking for your own stack

Track the products you run and VulnTracker tells you when a new CVE affects them — with what is known about fixing it, and nothing about the rest.

Free plan, no card