Bug 841940 - (CVE-2012-3409) CVE-2012-3409 ecryptfs-utils: suid helper does not restrict mounting filesystems with nosuid,nodev leading to possible privilege escalation
CVE-2012-3409 ecryptfs-utils: suid helper does not restrict mounting filesyst...
Status: CLOSED ERRATA
Product: Security Response
Classification: Other
Component: vulnerability (Show other bugs)
unspecified
All Linux
medium Severity medium
: ---
: ---
Assigned To: Red Hat Product Security
impact=moderate,public=20120710,repor...
: Security
Depends On: 842512
Blocks: 841942
  Show dependency treegraph
 
Reported: 2012-07-20 11:25 EDT by Vincent Danen
Modified: 2012-08-03 07:28 EDT (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2012-07-24 00:54:33 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:


Attachments (Terms of Use)

  None (edit)
Description Vincent Danen 2012-07-20 11:25:56 EDT
It was reported [1] that the private ecryptfs mount helper (/sbin/mount.ecryptfs_private), which is setuid-root, could allow an unprivileged local user to mount user-controlled ecryptfs shares on the local system.  Because the ecryptfs helper does not mount filesystems with the "nosuid" and "nodev" flags, it would be possible for a user to mount a filesystem containing setuid-root binaries and/or device files that could lead to the escalation of their privileges.  This could be done via a USB device, if the user had physical access to the system.

It was however also noted [2] that this may only affect version 86 and later, as the encrypted home source and destination mount points were hard-coded up until that version.

Forcing MS_NOSUID and MS_NODEV mount flags was added to version 99 (commits [3],[4])


[1] http://www.openwall.com/lists/oss-security/2012/07/10/19
[2] http://www.openwall.com/lists/oss-security/2012/07/11/2
[3] http://bazaar.launchpad.net/~ecryptfs/ecryptfs/trunk/revision/705
[4] http://bazaar.launchpad.net/~ecryptfs/ecryptfs/trunk/revision/708
Comment 1 Vincent Danen 2012-07-20 11:30:39 EDT
I also forgot to note that on Fedora and RHEL, you need to be part of the ecryptfs group to even use the ecryptfs filesystems/utilities, which lowers the attack surface considerably.
Comment 3 Huzaifa S. Sidhpurwala 2012-07-24 00:53:07 EDT
Statement:

Not Vulnerable. This issue does not affect the version of ecryptfs-utils as shipped with Red Hat Enterprise Linux 5 and 6.
Comment 4 Huzaifa S. Sidhpurwala 2012-07-24 00:53:57 EDT
Created ecryptfs-utils tracking bugs for this issue

Affects: fedora-all [bug 842512]
Comment 5 Fedora Update System 2012-08-03 07:27:42 EDT
ecryptfs-utils-99-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 6 Fedora Update System 2012-08-03 07:28:20 EDT
ecryptfs-utils-99-1.fc16 has been pushed to the Fedora 16 stable repository.  If problems still persist, please make note of it in this bug report.

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