Bug 1832876 (CVE-2020-12659)

Summary: CVE-2020-12659 kernel: xdp_umem_reg in net/xdp/xdp_umem.c has an out-of-bounds write which could result in crash and data coruption
Product: [Other] Security Response Reporter: Michael Kaplan <mkaplan>
Component: vulnerabilityAssignee: Red Hat Product Security <security-response-team>
Status: CLOSED ERRATA QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: unspecifiedCC: acaringi, airlied, bhu, blc, bmasney, brdeoliv, bskeggs, dhoward, dvlasenk, esammons, fhrbata, hdegoede, hkrzesin, iboverma, ichavero, itamar, jarodwilson, jeremy, jforbes, jglisse, jlelli, john.j5live, jonathan, josef, jross, jshortt, jstancek, jwboyer, kcarcia, kernel-maint, kernel-mgr, lgoncalv, linville, masami256, matt, mchehab, mcressma, mjg59, mlangsdo, nmurray, ptalbert, qzhao, rkeshri, rt-maint, rvrbovsk, steved, williams
Target Milestone: ---Keywords: Security
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: kernel 5.6.7 Doc Type: If docs needed, set a value
Doc Text:
An out-of-bounds (OOB) memory access flaw was found in the Network XDP (the eXpress Data Path) module in the Linux kernel's xdp_umem_reg function in net/xdp/xdp_umem.c. When a user with special user privilege of CAP_NET_ADMIN (or root) calls setsockopt to register umem ring on XDP socket, passing the headroom value larger than the available space in the chunk, it leads to an out-of-bounds write, causing panic or possible memory corruption. This flaw may lead to privilege escalation if a local end-user is granted permission to influence the execution of code in this manner.
Story Points: ---
Clone Of: Environment:
Last Closed: 2020-11-04 02:25:20 UTC 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: 1832878, 1833461, 1833462, 1838075    
Bug Blocks: 1833238    

Description Michael Kaplan 2020-05-07 12:33:43 UTC
An out-of-bounds (OOB) memory access flaw was found in the Network XDP (the eXpress Data Path) module in the Linux kernel's xdp_umem_reg in net/xdp/xdp_umem.c.  When a user with special user privilege of CAP_NET_ADMIN (or root) calls setsockopt to register umem ring on XDP socket,  passing the headroom value larger than the available space in the chunk can leads to an out of bound write causing a panic or possible memory corruption.  This may lead to privilege escalation if a local end user is granted permissions to influence the execution of code in this manner.

Reference:
https://bugzilla.kernel.org/show_bug.cgi?id=207225
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=99e3a236dd43d06c65af0a2ef9cb44306aef6e02

Comment 1 Michael Kaplan 2020-05-07 12:34:14 UTC
Created kernel tracking bugs for this issue:

Affects: fedora-all [bug 1832878]

Comment 3 Justin M. Forbes 2020-05-07 22:02:03 UTC
This was fixed for Fedora with the 5.6.7 stable kernel update.

Comment 8 Rohit Keshri 2020-05-08 17:35:24 UTC
Mitigation:

Mitigation for this issue is either not available or the currently available options don't meet the Red Hat Product Security criteria comprising ease of use and deployment, applicability to widespread installation base or stability.

Comment 9 Jiri Benc 2020-05-15 10:08:24 UTC
I don't see how this is a security issue. It needs root privileges to invoke the crash; root has plenty of other ways to crash the system. If this is a CVE, then the 'poweroff' command is a security issue, too.

This does not deserve a CVE, it's a minor bug. Could the CVE assignment be invalidated?

Comment 12 errata-xmlrpc 2020-11-04 00:51:08 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 8

Via RHSA-2020:4431 https://access.redhat.com/errata/RHSA-2020:4431

Comment 13 errata-xmlrpc 2020-11-04 02:23:28 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 8

Via RHSA-2020:4609 https://access.redhat.com/errata/RHSA-2020:4609

Comment 14 Product Security DevOps Team 2020-11-04 02:25:20 UTC
This bug is now closed. Further updates for individual products will be reflected on the CVE page(s):

https://access.redhat.com/security/cve/cve-2020-12659