Getting hotplugd to work
I'm trying to make OpenBSD automount USB and optical media, so that I don't have to bother with kern.usermount and associated insecurity. Because I'm trying to keep things simple and avoid using regexps, I just want to mount stuff by device name.
My /etc/hotplug/attach file looks like this:
#!/bin/sh DEVCLASS=$1 DEVNAME=$2 case $DEVCLASS in 2) # disk devices case $DEVNAME in sd1) # USB drives mount -o nodev,nosuid /dev/sd1i /mnt/flash ;; cd0) # CD drives mount -o nodev,nosuid /dev/cd0a /mnt/optical ;; esac esac
How can I get it to mount a CD or DVD? And what's the best way to apply sane permissions to the USB drive, without changing the permissions on the device node?
Edit: okay, major "Duh" moment on the USB permissions problem. The solution is to make the mount directory writeable by whoever needs to write to it.
Still haven't figured out the CD drive though.
Last edited by GullibleJones; 8th January 2013 at 10:01 PM. Reason: One problem solved.
|Thread||Thread Starter||Forum||Replies||Last Post|
|why won't my table work?||tomp||OpenBSD Security||3||25th August 2011 01:23 PM|
|nspluginwrapper not work...||marduk||NetBSD Installation and Upgrading||4||3rd January 2011 10:23 PM|
|ATI Catalyst.... Does it work?||echoblack||OpenBSD Installation and Upgrading||10||17th June 2009 10:04 AM|
|Crossplatform UI Work||Turophile||Programming||9||22nd October 2008 12:56 AM|
|Getting Qt4 to work on FreeBSD||enpey||FreeBSD Ports and Packages||6||6th May 2008 08:20 AM|