Bug 1474928 (CVE-2017-11600)

Summary: CVE-2017-11600 kernel: Out-of-bounds access via an XFRM_MSG_MIGRATE xfrm Netlink message
Product: [Other] Security Response Reporter: Andrej Nemec <anemec>
Component: vulnerabilityAssignee: Red Hat Product Security <security-response-team>
Status: CLOSED ERRATA QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: unspecifiedCC: aquini, bhu, blc, dhoward, dominik.mierzejewski, fhrbata, gansalmon, hkrzesin, hwkernel-mgr, iboverma, ichavero, itamar, jforbes, jkacur, jonathan, jross, jwboyer, kernel-maint, kernel-mgr, labbott, lgoncalv, madhu.chinakonda, matt, mchehab, mcressma, mlangsdo, mmilgram, nmurray, pholasek, plougher, ppandit, rt-maint, rvrbovsk, slawomir, vdronov, williams, xmu, yozone
Target Milestone: ---Keywords: Security
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
The xfrm_migrate() function in the net/xfrm/xfrm_policy.c file in the Linux kernel built with CONFIG_XFRM_MIGRATE does not verify if the dir parameter is less than XFRM_POLICY_MAX. This allows a local attacker to cause a denial of service (out-of-bounds access) or possibly have unspecified other impact by sending a XFRM_MSG_MIGRATE netlink message. This flaw is present in the Linux kernel since an introduction of XFRM_MSG_MIGRATE in 2.6.21-rc1, up to 4.13-rc3.
Story Points: ---
Clone Of: Environment:
Last Closed: 2019-06-08 03:18:01 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: 1474929, 1479417, 1479418, 1479419, 1479420, 1479421, 1479422, 1695808, 1695809    
Bug Blocks: 1474933    
Attachments:
Description Flags
xfrm_migrate_panic_dmesg.txt none

Description Andrej Nemec 2017-07-25 16:05:25 UTC
xfrm_migrate() function in net/xfrm/xfrm_policy.c file in the Linux kernel build with CONFIG_XFRM_MIGRATE does not check that the dir parameter is less than XFRM_POLICY_MAX. This allows a local attacker cause a denial of service (out-of-bounds access) or possibly have unspecified other impact by sending a XFRM_MSG_MIGRATE netlink message. This flaw is present in the Linux kernel since an introduction of XFRM_MSG_MIGRATE in 2.6.21-rc1 and upto 4.13-rc3.

References:

http://seclists.org/bugtraq/2017/Jul/30

http://marc.info/?t=150169629800003&r=1&w=2

http://marc.info/?l=linux-netdev&m=150169627919528&w=2

Suggested upstream patch:

https://git.kernel.org/pub/scm/linux/kernel/git/klassert/ipsec.git/commit/?id=7bab09631c2a303f87a7eb7e3d69e888673b9b7e

An upstream patch:

https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=7bab09631c2a303f87a7eb7e3d69e888673b9b7e

Comment 1 Andrej Nemec 2017-07-25 16:06:11 UTC
Created kernel tracking bugs for this issue:

Affects: fedora-all [bug 1474929]

Comment 2 Vladis Dronov 2017-08-02 16:16:06 UTC
Created attachment 1308338 [details]
xfrm_migrate_panic_dmesg.txt

Comment 6 Vladis Dronov 2017-08-08 14:30:20 UTC
Statement:

This issue does not affect the versions of the Linux kernel as shipped with Red Hat Enterprise Linux 5, 6 as the code with the flaw is not present in the products listed or is not exploitable.

This issue affects the versions of the Linux kernel as shipped with Red Hat Enterprise Linux 7 and Red Hat Enterprise MRG 2. Future kernel updates for these products may address this issue.

Comment 7 Justin M. Forbes 2018-01-29 16:27:54 UTC
This was fixed for Fedora with the 4.12.11 stable updates

Comment 11 errata-xmlrpc 2018-06-26 16:50:09 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 7

Via RHSA-2018:1965 https://access.redhat.com/errata/RHSA-2018:1965

Comment 12 errata-xmlrpc 2018-06-26 16:51:14 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 7

Via RHSA-2018:2003 https://access.redhat.com/errata/RHSA-2018:2003

Comment 14 errata-xmlrpc 2019-05-14 19:08:15 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 7.4 Extended Update Support

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

Comment 15 errata-xmlrpc 2019-05-14 20:26:33 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise MRG 2

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