mount.cifs: don't allow it to be run as setuid root program
commitd06bf1173728c32f9067c84eb28b21281f1c85e7
authorJeff Layton <jlayton@redhat.com>
Tue, 26 Jan 2010 13:36:11 +0000 (26 08:36 -0500)
committerKarolin Seeger <kseeger@samba.org>
Mon, 29 Mar 2010 07:41:00 +0000 (29 09:41 +0200)
tree61145f25b5433557bb958575bd4da12415862e5b
parented18be92ed14de689b6493d534e65dfa3855fbc2
mount.cifs: don't allow it to be run as setuid root program

mount.cifs has been the subject of several "security" fire drills due to
distributions installing it as a setuid root program. This program has
not been properly audited for security and the Samba team highly
recommends that it not be installed as a setuid root program at this
time.

To make that abundantly clear, this patch forcibly disables the ability
for mount.cifs to run as a setuid root program. People are welcome to
trivially patch this out, but they do so at their own peril.

A security audit and redesign of this program is in progress and we hope
that we'll be able to remove this in the near future.

Signed-off-by: Jeff Layton <jlayton@redhat.com>
The last 3 patches address bug #6853 (mount.cifs race that allows user to
replace mountpoint with a symlink).
(cherry picked from commit e6c856ac84ee18a192edc3e8a6547e2e9387a1b5)
client/mount.cifs.c