From owner-freebsd-questions Thu Sep 17 01:21:21 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id BAA21068 for freebsd-questions-outgoing; Thu, 17 Sep 1998 01:21:21 -0700 (PDT) (envelope-from owner-freebsd-questions@FreeBSD.ORG) Received: from seattle.3com.com (seattle.3com.com [129.213.128.97]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id BAA21048 for ; Thu, 17 Sep 1998 01:21:02 -0700 (PDT) (envelope-from Florian_Uhl@3com.com) From: Florian_Uhl@3com.com Received: from new-york.3com.com (new-york.3com.com [129.213.157.12]) by seattle.3com.com (8.8.8/8.8.8) with ESMTP id BAA20168 for ; Thu, 17 Sep 1998 01:20:38 -0700 (PDT) Received: from hqoutbound.ops.3com.com (hqoutbound.OPS.3Com.COM [139.87.48.104]) by new-york.3com.com (8.8.8/8.8.8) with SMTP id BAA28577 for ; Thu, 17 Sep 1998 01:20:38 -0700 (PDT) Received: by hqoutbound.ops.3com.com(Lotus SMTP MTA v4.6.1 (569.2 2-6-1998)) id 88256682.00390A83 ; Thu, 17 Sep 1998 01:19:42 -0700 X-Lotus-FromDomain: 3COM To: freebsd-questions@FreeBSD.ORG Message-ID: Date: Thu, 17 Sep 1998 10:18:55 +0200 Subject: RE: Mount a music cd? Mount not root? Mime-Version: 1.0 Content-type: text/plain; charset=us-ascii Content-Disposition: inline Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Donald, he was talking about "read-only". I would suggest, he installs 'sudo' and gives the users restricted rights. /usr/local/etc/sudoers will probably contain something like # User alias specification User_Alias USERS=%users # Cmnd alias specification Cmnd_Alias MOUNT=/sbin/mount -t msdos -o ro /dev/wd0s1 /mnt/dos_c # User privilege specification USERS ALL=(root) NOPASSWD: MOUNT This _should_ give the local group "users" (from /etc/group) the rights to mount the DOS partition. Read the man page before enabling this as I'm sitting at an NT box right now and cannot check the syntax. Additional benefit: this will get logged via syslogd and the guys can only do what you want them to do. Somebody correct me if this is blatantly wrong, insecure or otherwise a stupid thing to do. Cheers ... -- florian Not talking for or on behalf of 3Com. To: Dave Ason cc: freebsd-questions@FreeBSD.ORG Subject: RE: Mount a music cd? Mount not root? My secret spy satellite informs me that on 16-Sep-98, Dave Ason wrote: > Hi there, > > I've got two questions related to mounting file systems. > 1)How do you mount a music cd? I've tried it with the -t cd9660 > option as with data cd's but with no luck. Uhh, you can't. Audio CD's can only be played. If you want to grab the digital data off of an audio CD and stuff it on your hard drive, use the /usr/ports/audio/tosha port. > 2)Is it possible for a user who is not root to mount a file system? > I'd like to setup a FAT file system so that any user can mount it read > only. I don't think so. Linux has the "user" mount option to do this, but (AFAIK) FreeBSD does not. There is a little trick you can use, though, to get around this. Just make the /sbin/mount and /sbin/umount binaries setuid to root, chgrp it to a group (make a new group "mounters" for this purpose), then make these executables NOT executable by everyone else. Then, to allow a user to mount and unmount stuff, just add him/her to the "mounters" group. The permissions of the binaries should look like this: -r-s--x--- 1 root mounters 73728 Jul 22 01:13 /sbin/mount* -r-s--x--- 1 root mounters 126976 Jul 22 01:13 /sbin/umount* --- Donald Burr *NEW EMAIL ADDRESS!* | PGP: Your WWW HomePage: http://DonaldBurr.base.org/ ICQ#16997506 | right to Address: P.O. Box 91212, Santa Barbara, CA 93190-1212 | 'Net privacy. Phone: (805) 957-9666 FAX: (800) 492-5954 | USE IT. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message