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

Re: How to disable certain usb device discovery



On Thu, Feb 09, 2006 at 02:59:48PM +0800, Kai Cui wrote:
> Hi!
> 
> Our server is running latest debian (3.1r1). I'd like to know how to config
> the environment to prevent the kernel from auto discovering and making
> available any hard drive or cdrom attached via usb. By the way, the keyboard
> is of usb kind too.

Well, the easiest way would be to remove the USB mass storage driver.

However, this isn't strictly necessary because if you turn off automounting,
and don't put any user options into your fstab, regular users won't
be able to use USB devices anyway (if you don't slap a user option
on a device in fstab, only root can mount it).

For safeties sake, don't use udev, or if you do, make sure it creates
USB mass storage device special files with root.root ownership, and
0600 permissions.

This allows root to still use USB mass storage for system administration,
purposes and is just as safe as removing the driver (since, after all,
root can always reinstall the driver, being root), while still retaining
useful functionality.

Thanks,
John S.

Attachment: signature.asc
Description: Digital signature


Reply to: