Bug 2121800 (CVE-2022-2905)

Summary: CVE-2022-2905 kernel: slab-out-of-bound read in bpf
Product: [Other] Security Response Reporter: Marian Rehak <mrehak>
Component: vulnerabilityAssignee: Nobody <nobody>
Status: NEW --- QA Contact:
Severity: low Docs Contact:
Priority: low    
Version: unspecifiedCC: acaringi, adscvr, airlied, alciregi, allarkin, bhu, brdeoliv, chwhite, crwood, ddepaula, debarbos, dvlasenk, hdegoede, hkrzesin, hpa, jarod, jarodwilson, jburrell, jfaracco, jferlan, jforbes, jglisse, jlelli, joe.lawrence, jonathan, josef, jshortt, jstancek, jwboyer, jwyatt, kcarcia, kernel-maint, kernel-mgr, lgoncalv, linville, lzampier, masami256, mchehab, nmurray, ptalbert, qzhao, rvrbovsk, scweaver, steved, tyberry, vkumar, walters, williams
Target Milestone: ---Keywords: Security
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Linux kernel 6.0-rc4 Doc Type: If docs needed, set a value
Doc Text:
An out-of-bounds memory read flaw was found in the Linux kernel's BPF subsystem in how a user calls the bpf_tail_call function with a key larger than the max_entries of the map. This flaw allows a local user to gain unauthorized access to data.
Story Points: ---
Clone Of: Environment:
Last Closed: Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 2121801, 2124624, 2124625, 2124626, 2124627    
Bug Blocks: 2119814, 2119817    

Description Marian Rehak 2022-08-26 16:43:58 UTC
A  bug in the x86 BPF JIT compiler. A bpf_tail_call with a key larger than the max_entries of the map can cause an out-of-bound access when the x86 JIT compiler tries to index bpf_array->ptr using the invalid key.

References:

https://www.openwall.com/lists/oss-security/2022/08/26/1
https://lore.kernel.org/bpf/984b37f9fdf7ac36831d2137415a4a915744c1b6.1661462653.git.daniel@iogearbox.net/

Comment 1 Marian Rehak 2022-08-26 16:44:31 UTC
Created kernel tracking bugs for this issue:

Affects: fedora-all [bug 2121801]

Comment 4 Justin M. Forbes 2022-09-20 14:05:07 UTC
This was fixed for Fedora with the 5.19.6 stable kernel updates.