Bug 1341716 (CVE-2016-4470)

Summary: CVE-2016-4470 kernel: Uninitialized variable in request_key handling causes kernel crash in error handling path
Product: [Other] Security Response Reporter: Adam Mariš <amaris>
Component: vulnerabilityAssignee: Red Hat Product Security <security-response-team>
Status: CLOSED ERRATA QA Contact:
Severity: high Docs Contact:
Priority: high    
Version: unspecifiedCC: aquini, bhu, carnil, dhoward, dhowells, fhrbata, iboverma, jkacur, joelsmith, jross, kernel-mgr, kstutsma, lgoncalv, matt, mcressma, nmurray, plougher, pmatouse, ppandit, rvrbovsk, security-response-team, slawomir, tfrazier, williams, wmealing
Target Milestone: ---Keywords: Security
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
A flaw was found in the Linux kernel's keyring handling code: the key_reject_and_link() function could be forced to free an arbitrary memory block. An attacker could use this flaw to trigger a use-after-free condition on the system, potentially allowing for privilege escalation.
Story Points: ---
Clone Of: Environment:
Last Closed: 2019-06-08 02:53:10 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: 1341352, 1345935, 1345937, 1345938, 1345939, 1345940, 1345941, 1345945, 1345946, 1346626, 1348118, 1348119, 1348362, 1348363, 1350384, 1350385, 1350386, 1350387, 1350388, 1354270    
Bug Blocks: 1341718    

Description Adam Mariš 2016-06-01 14:59:25 UTC
A local user can trigger a flaw in the Linux kernel's handling of key lookups in the keychain subsystem.

The key_reject_and_link() function contains an error in which a key-lookup can fail and in an attempt to cache the failed lookup may attempt to free memory which can still be in use.

This could crash the system or at worse free a memory block which would then be re-used by another kernel mechanism causing a user after free.

Product bug:

https://bugzilla.redhat.com/show_bug.cgi?id=1341352

Upstream patch:

https://www.spinics.net/lists/linux-kernel-janitors/msg26069.html

Comment 1 Adam Mariš 2016-06-01 14:59:40 UTC
Acknowledgements:

Name: David Howells (Red Hat)

Comment 6 Wade Mealing 2016-06-13 13:18:16 UTC
Statement:

This issue affects the Linux kernels as shipped with Red Hat Enterprise Linux 6 and may be addressed in a future update.

This issue does not affect the Linux kernel packages as shipped with Red Hat
Enterprise Linux 7 and Red Hat Enterprise MRG 2 as the due updates to fix
this issue have been shipped now.

Comment 9 Wade Mealing 2016-06-15 06:23:49 UTC
Created kernel tracking bugs for this issue:

Affects: fedora-all [bug 1346626]

Comment 14 Fedora Update System 2016-06-30 21:23:58 UTC
kernel-4.6.3-300.fc24 has been pushed to the Fedora 24 stable repository. If problems still persist, please make note of it in this bug report.

Comment 15 Fedora Update System 2016-07-02 19:24:18 UTC
kernel-4.5.7-202.fc23 has been pushed to the Fedora 23 stable repository. If problems still persist, please make note of it in this bug report.

Comment 17 Fedora Update System 2016-07-19 07:18:52 UTC
kernel-4.4.14-200.fc22 has been pushed to the Fedora 22 stable repository. If problems still persist, please make note of it in this bug report.

Comment 18 errata-xmlrpc 2016-08-02 13:54:41 UTC
This issue has been addressed in the following products:

  MRG for RHEL-6 v.2

Via RHSA-2016:1532 https://rhn.redhat.com/errata/RHSA-2016-1532.html

Comment 19 errata-xmlrpc 2016-08-02 18:31:26 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 7

Via RHSA-2016:1539 https://rhn.redhat.com/errata/RHSA-2016-1539.html

Comment 20 errata-xmlrpc 2016-08-02 18:36:12 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 7

Via RHSA-2016:1541 https://rhn.redhat.com/errata/RHSA-2016-1541.html

Comment 22 errata-xmlrpc 2016-08-23 16:12:39 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 7.1 Extended Update Support

Via RHSA-2016:1657 https://rhn.redhat.com/errata/RHSA-2016-1657.html

Comment 23 errata-xmlrpc 2016-10-04 21:08:30 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 6

Via RHSA-2016:2006 https://rhn.redhat.com/errata/RHSA-2016-2006.html

Comment 24 errata-xmlrpc 2016-10-18 11:09:26 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 6.5 Advanced Update Support

Via RHSA-2016:2074 https://rhn.redhat.com/errata/RHSA-2016-2074.html

Comment 25 errata-xmlrpc 2016-10-18 14:31:36 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 6.7 Extended Update Support

Via RHSA-2016:2076 https://rhn.redhat.com/errata/RHSA-2016-2076.html

Comment 28 errata-xmlrpc 2016-10-31 16:01:48 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 6.6 Extended Update Support

Via RHSA-2016:2128 https://rhn.redhat.com/errata/RHSA-2016-2128.html

Comment 31 errata-xmlrpc 2016-11-01 10:58:25 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 6.4 Advanced Update Support

Via RHSA-2016:2133 https://rhn.redhat.com/errata/RHSA-2016-2133.html