GPU VulnDB

Database/Kernel, userspace & hypervisor

Linux kernel BPF verifier: missing precision marking lets an out-of-bounds ringbuf access pass

CVSS 7.1CVE-2022-49961Kernel, userspace & hypervisorcurated

Impact

The verifier failed to propagate precision markers for ARG_CONST_ALLOC_SIZE_OR_ZERO arguments, so it could prune two states as equivalent when the constant that sets the returned PTR_TO_MEM size differed. A program that the verifier should reject - writing beyond the size actually reserved by bpf_ringbuf_reserve - can be accepted, giving an out-of-bounds kernel write or read. Reachable only by a loader that can get imprecise scalars, which means a privileged user holding CAP_BPF; without CAP_BPF the kernel marks registers precise unconditionally. On a GPU node that means a CAP_BPF-holding agent or privileged pod can escalate to corrupting kernel memory on a host shared with other tenants.

Who can reach it

Local user or container with CAP_BPF able to load its own BPF programs. Not reachable without BPF load privileges and not remote.

What to do

Run a kernel with the stable fix that calls mark_chain_precision for these arguments and reboot each node; this is an old fix, so most maintained kernels already carry it - confirm your running version rather than scheduling a window blindly. Mitigation in the meantime is to withdraw CAP_BPF from workloads.

References

Related entries

All Kernel, userspace & hypervisor entries

This entry is curated: imported from vendor advisories with machine assistance, not yet individually verified. Confirm against your vendor's advisory before acting, and report anything wrong.