Bug 824345 (CVE-2012-2390) - CVE-2012-2390 kernel: huge pages: memory leak on mmap failure
Summary: CVE-2012-2390 kernel: huge pages: memory leak on mmap failure
Keywords:
Status: CLOSED ERRATA
Alias: CVE-2012-2390
Product: Security Response
Classification: Other
Component: vulnerability
Version: unspecified
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Red Hat Product Security
QA Contact:
URL:
Whiteboard:
Depends On: 824350 824351 824352 824353 824354
Blocks: 824358
TreeView+ depends on / blocked
 
Reported: 2012-05-23 10:18 UTC by Petr Matousek
Modified: 2021-02-23 14:44 UTC (History)
15 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-08-24 12:45:29 UTC
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2012:1150 0 normal SHIPPED_LIVE Moderate: kernel-rt security and bug fix update 2012-08-08 20:31:44 UTC
Red Hat Product Errata RHSA-2012:1304 0 normal SHIPPED_LIVE Moderate: kernel security and bug fix update 2012-09-25 22:58:04 UTC

Description Petr Matousek 2012-05-23 10:18:19 UTC
Description of problem:
When called for anonymous (non-shared) mappings, hugetlb_reserve_pages() does a resv_map_alloc().  It depends on code in hugetlbfs's vm_ops->close() to release that allocation.

However, in the mmap() failure path, we do a plain unmap_region() without the remove_vma() which actually calls vm_ops->close(). 

An unprivileged local user could use this flaw to crash the system.

References:
http://www.spinics.net/lists/linux-mm/msg34763.html

Proposed upstream fix:
https://lkml.org/lkml/2012/5/21/385

Comment 3 Petr Matousek 2012-05-23 10:24:08 UTC
Created kernel tracking bugs for this issue

Affects: fedora-all [bug 824352]

Comment 4 Kurt Seifried 2012-05-23 18:05:10 UTC
Added CVE as per http://www.openwall.com/lists/oss-security/2012/05/23/14

Comment 5 Petr Matousek 2012-05-30 11:01:45 UTC
Upstream commits:
 c50ac050811d6485616a193eb0f37bfbd191cc89
 4523e1458566a0e8ecfaff90f380dd23acc44d27

Comment 9 Fedora Update System 2012-06-07 02:33:21 UTC
kernel-3.4.0-1.fc17 has been pushed to the Fedora 17 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 10 Fedora Update System 2012-06-13 21:30:08 UTC
kernel-3.3.8-1.fc16 has been pushed to the Fedora 16 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 11 Fedora Update System 2012-06-22 08:37:59 UTC
kernel-2.6.43.8-1.fc15 has been pushed to the Fedora 15 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 12 Petr Matousek 2012-07-04 05:30:12 UTC
Statement:

This issue did not affect the versions of the Linux kernel as shipped with Red Hat Enterprise Linux 5 as they did not include the upstream commit 84afd99b that introduced this issue. Future kernel updates for Red Hat Enterprise Linux 6 may address this issue.

This has been addressed in Red Hat Enterprise Linux Red Hat Enterprise MRG 2 via https://rhn.redhat.com/errata/RHSA-2012-1150.html

Comment 13 errata-xmlrpc 2012-08-08 16:35:17 UTC
This issue has been addressed in following products:

  MRG for RHEL-6 v.2

Via RHSA-2012:1150 https://rhn.redhat.com/errata/RHSA-2012-1150.html

Comment 14 errata-xmlrpc 2012-09-25 18:59:58 UTC
This issue has been addressed in following products:

  Red Hat Enterprise Linux 6

Via RHSA-2012:1304 https://rhn.redhat.com/errata/RHSA-2012-1304.html


Note You need to log in before you can comment on or make changes to this bug.