Bug 1705937 (CVE-2019-11599)

Summary: CVE-2019-11599 kernel: fix race condition between mmget_not_zero()/get_task_mm() and core dumping
Product: [Other] Security Response Reporter: msiddiqu
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, brdeoliv, bskeggs, dhoward, dvlasenk, esammons, fhrbata, hdegoede, hkrzesin, iboverma, ichavero, itamar, jarodwilson, jeremy, jforbes, jglisse, jkacur, john.j5live, jonathan, josef, jross, jstancek, jwboyer, kernel-maint, kernel-mgr, labbott, lgoncalv, linville, matt, mchehab, mcressma, mjg59, mlangsdo, nmurray, plougher, rt-maint, rvrbovsk, steved, williams, wmealing
Target Milestone: ---Keywords: Security
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: kernel 5.0.10 Doc Type: If docs needed, set a value
Doc Text:
A flaw was found in the Linux kernel where the coredump implementation does not use locking or other mechanisms to prevent vma layout or vma flags changes while it runs. This allows local users to obtain sensitive information, cause a denial of service (DoS), or possibly have unspecified other impact by triggering a race condition with mmget_not_zero or get_task_mm calls.
Story Points: ---
Clone Of: Environment:
Last Closed: 2019-08-06 13:22:25 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Bug Depends On: 1696084, 1720782, 1772263, 1772264, 1772265, 1696079, 1696080, 1696081, 1696082, 1696083, 1705938, 1772266    
Bug Blocks: 1696007, 1696223    

Description msiddiqu 2019-05-03 09:05:35 UTC
The coredump implementation in the Linux kernel before 5.0.10 does not use locking or other mechanisms to prevent vma layout or vma flags changes while it runs, which allows local users to obtain sensitive information, cause a denial of service, or possibly have unspecified other impact by triggering a race condition with mmget_not_zero or get_task_mm calls. This is related to fs/userfaultfd.c, mm/mmap.c, fs/proc/task_mmu.c, and drivers/infiniband/core/uverbs_main.c.

References:

https://bugs.chromium.org/p/project-zero/issues/detail?id=1790 
https://cdn.kernel.org/pub/linux/kernel/v4.x/ChangeLog-4.14.114 
https://cdn.kernel.org/pub/linux/kernel/v4.x/ChangeLog-4.19.37 
https://cdn.kernel.org/pub/linux/kernel/v5.x/ChangeLog-5.0.10

Upstream patch:

https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=04f5866e41fb70690e28397487d8bd8eea7d712a
https://github.com/torvalds/linux/commit/04f5866e41fb70690e28397487d8bd8eea7d712a

Comment 1 msiddiqu 2019-05-03 09:05:57 UTC
Created kernel tracking bugs for this issue:

Affects: fedora-all [bug 1705938]

Comment 2 msiddiqu 2019-05-03 09:11:53 UTC
*** Bug 1696015 has been marked as a duplicate of this bug. ***

Comment 3 Justin M. Forbes 2019-05-03 14:22:19 UTC
This is fixed for Fedora with the 5.0.10 stable updates.

Comment 7 💾 Wade Mealing 💾 2019-05-17 04:31:48 UTC
Acknowledgments:

Name: Andrea Arcangeli (Red Hat Engineering)

Comment 12 errata-xmlrpc 2019-08-06 12:04:42 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 7

Via RHSA-2019:2029 https://access.redhat.com/errata/RHSA-2019:2029

Comment 13 errata-xmlrpc 2019-08-06 12:07:08 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 7

Via RHSA-2019:2043 https://access.redhat.com/errata/RHSA-2019:2043

Comment 14 Product Security DevOps Team 2019-08-06 13:22:25 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-2019-11599

Comment 16 errata-xmlrpc 2019-11-05 20:35:25 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 8

Via RHSA-2019:3309 https://access.redhat.com/errata/RHSA-2019:3309

Comment 17 errata-xmlrpc 2019-11-05 21:06:08 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 8

Via RHSA-2019:3517 https://access.redhat.com/errata/RHSA-2019:3517