Linux Kernel BPF Verifier Global Function Pointer Invalidation Vulnerability

Vulnerability

A vulnerability in the Linux kernel's BPF verifier allows certain global functions to improperly handle packet data pointers, potentially leading to unsafe memory access. This issue arises because the verifier fails to invalidate packet pointers when global sub-programs call specific helper functions that are supposed to change packet data. As a result, a crafted BPF program can manipulate packet data in a way that the verifier does not properly check, creating a risk of memory corruption or other unintended behavior.

Impact

Exploitation of this vulnerability could lead to memory corruption by allowing a BPF program to manipulate packet data pointers without proper verification, potentially causing unsafe memory access or corruption.

Reproduction

The vulnerability can be reproduced by creating a BPF program that uses the 'skb_pull_data' function to pull packet data while bypassing the verifiers checks on global function calls. This can be done by crafting a BPF program that calls 'skb_pull_data' from a global sub-program, which will not properly invalidate the packet data pointers in the caller's state. After pulling the data, the program can safely write to the invalidated pointer, demonstrating the vulnerability.

Added: Jun 9, 2025, 7:46 PM
Updated: Jun 9, 2025, 7:46 PM

Vulnerability Rating

Custom Algorithm
spread
9.0
impact
7.5
exploitability
5.7
remediation
0.0
relevance
0.0
threat
4.8
urgency
2.9
incentive
1.7

Our algorithm analyzes dozens of metrics to generate these 8 key vulnerability categories, which are then combined to calculate the overall risk score.