Re: [RFC] Let non-root users eject their ipods?

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

 



On Tue, Dec 20 2005, Ben Collins wrote:
> On Tue, 2005-12-20 at 08:46 +0100, Jens Axboe wrote:
> > On Mon, Dec 19 2005, john stultz wrote:
> > > All,
> > > 	I'm getting a little tired of my roommates not knowing how to safely
> > > eject their usb-flash disks from my system and I'd personally like it if
> > > I could avoid bringing up a root shell to eject my ipod. Sure, one could
> > > suid the eject command, but that seems just as bad as changing the
> > > permissions in the kernel (eject wouldn't be able to check if the user
> > > has read/write permissions on the device, allowing them to eject
> > > anything).
> > 
> > This just came up yesterday, eject isn't opening the device RDWR hence
> > you have a permission problem with a command requiring write
> > permissions. So just fix eject, there's no need to suid eject or run it
> > as root.
> 
> Yep, and here's the patch to do it:
> 
> http://bugzilla.ubuntu.com/attachment.cgi?id=5415
> 
> Still, this whole issue with ALLOW_MEDIUM_REMOVAL. Would be nice if
> CDROMEJECT just did the right thing.

I would tend to agree, but you are bypassing the checks that are in
there by doing so which isn't very nice. Then we might as well just mark
ALLOW_MEDIUM_REMOVAL as safe-for-read in the first place.

-- 
Jens Axboe

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux