Bug 2129419 (CVE-2022-2785) - CVE-2022-2785 kernel: out-of-bounds read due to improper check of bpf_sys_bpf() arguments
Summary: CVE-2022-2785 kernel: out-of-bounds read due to improper check of bpf_sys_bpf...
Keywords:
Status: NEW
Alias: CVE-2022-2785
Product: Security Response
Classification: Other
Component: vulnerability
Version: unspecified
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Nobody
QA Contact:
URL:
Whiteboard:
Depends On: 2129420 2131595 2131596 2131597 2131598
Blocks: 2129421
TreeView+ depends on / blocked
 
Reported: 2022-09-23 17:09 UTC by Guilherme de Almeida Suckevicz
Modified: 2023-09-26 20:51 UTC (History)
49 users (show)

Fixed In Version: kernel 5.19 rc8
Doc Type: If docs needed, set a value
Doc Text:
An out-of-bounds (OOB) memory read problem was found in bpf in the Linux kernel's kernel/bpf/syscall.c function due to an improper check of bpf_sys_bpf() arguments. The bounds check failure allows a local attacker to access out-of-bounds memory, leading to a leak of internal kernel information.
Clone Of:
Environment:
Last Closed:
Embargoed:


Attachments (Terms of Use)

Description Guilherme de Almeida Suckevicz 2022-09-23 17:09:22 UTC
There exists an arbitrary memory read within the Linux Kernel BPF - Constants provided to fill pointers in structs passed in to bpf_sys_bpf are not verified and can point anywhere, including memory not owned by BPF. An attacker with CAP_BPF can arbitrarily read memory from anywhere on the system. We recommend upgrading past commit 86f44fcec22c.

References and upstream fix:
https://git.kernel.org/bpf/bpf/c/86f44fcec22c
https://lore.kernel.org/bpf/20220816205517.682470-1-zhuyifei@google.com/T/#t

Comment 1 Guilherme de Almeida Suckevicz 2022-09-23 17:09:43 UTC
Created kernel tracking bugs for this issue:

Affects: fedora-all [bug 2129420]

Comment 2 Justin M. Forbes 2022-09-23 19:01:15 UTC
This was fixed for Fedora with the 5.19.8 stable kernel updates.


Note You need to log in before you can comment on or make changes to this bug.