oss-sec mailing list archives

Re: Re: CVE Request: NVidia Linux driver


From: Tavis Ormandy <taviso () cmpxchg8b com>
Date: Wed, 1 Aug 2012 20:27:04 +0200

Marcus Meissner <meissner () suse de> wrote:

On Wed, Aug 01, 2012 at 09:32:44AM -0400, Marc Deslauriers wrote:
On Wed, 2012-08-01 at 15:12 +0200, Tavis Ormandy wrote:
Marc Deslauriers
<marc.deslauriers () canonical com> wrote:

Hello,

Could a CVE please be assigned to the following issue:

The binary NVidia Linux driver allows local users to access
arbitrary memory locations by leveraging GPU device-node read/write
privileges, and escalate privileges to root. Possibly an incomplete
fix for CVE-2012-0946.

See:

http://seclists.org/fulldisclosure/2012/Aug/4

Thanks,

Marc.

I know that at least Gentoo does this since ~2006:

35 # !!! SECURITY WARNING !!! 36 # DO NOT MODIFY OR REMOVE THE DEVICE
FILE RELATED OPTIONS UNLESS YOU KNOW 37 # WHAT YOU ARE DOING. 38 #
ONLY ADD TRUSTED USERS TO THE VIDEO GROUP, THESE USERS MAY BE ABLE TO
CRASH, 39 # COMPROMISE, OR IRREPARABLY DAMAGE THE MACHINE. 40 options
nvidia NVreg_DeviceFileMode=432 NVreg_DeviceFileUID=0
NVreg_DeviceFileGID=VIDEOGID NVreg_ModifyDeviceFiles=1



http://sources.gentoo.org/cgi-bin/viewvc.cgi/gentoo-x86/x11-drivers/nvidia-drivers/files/nvidia?revision=1.3&view=markup


Well, getting rid of static groups like that is what consolekit and udev
are for. Ideally, permissions would be granted on the device based on
which user is at the console, as it currently done with other devices.
Unfortunately, the design of the binary driver makes it hard to do, as
it resets permissions itself when X loads.


https://bugs.launchpad.net/ubuntu/+source/nvidia-graphics-drivers/+bug/979307

The NVIDIA is explicitly not allowed to use the udev device structure, as
udev device handling requires GPL interfaces and can only be called from
GPL drivers.

Thats why it is strange this way.

And yes, the exploit turns "I have a bad feeling about this" about this
device definitely into "this is bad".


Yes, but even without this neat exploit, I suspect unprivileged users would
have been able to physically set the machine on fire if you didn't trust
them.

(E.g. disable all fans via nvidiactl, overclock like crazy then submit heavy
workload).

This is why we disabled it in Gentoo, a user reported that one of his users
overclocked a card and disabled the fans, resulting in a big (physical)
mess.

Tavis.

-- 
-------------------------------------
taviso () cmpxchg8b com | pgp encrypted mail preferred
-------------------------------------------------------


Current thread: