Michael C. Toren on Wed, 9 Feb 2000 11:11:24 -0500 (EST)


[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

Re: [PLUG] Letting non-root mount floppy/cdrom


> We recently got two new machines to run solely linux (woohoo!) down here in 
> the comp. sci. dept at St. Joe's.  I want to be able to give non-root users
> the ability to mount/umount cdroms and floppies and also powerdown.  I thought
> the easiest way to do this was to put a script owned by root in /usr/local/bin 
> to do 'mount /dev/fd0 /mnt/floppy -t vfat' or whatever, then 'chmod +s' it, 
> but that doesn't seem to be working.  Any suggestions ?

Shell scripts cannot be suid.  One way around this would be to write a
simple C wrapper, which checks to see if the caller's UID matches those
found in a compile-time specified list, and then exec's mount.

-mct