On 9/23/07, Todd Alan Smith <[EMAIL PROTECTED]> wrote: > On 9/23/07, Douglas A. Tutty <[EMAIL PROTECTED]> wrote: > > On Sun, Sep 23, 2007 at 05:23:37PM -0600, Chris Kuethe wrote: > > > On 9/23/07, Todd Alan Smith <[EMAIL PROTECTED]> wrote: > > > > Does "lock -nv" not work? I just read about this in "BSD Hacks" last > > > > night, oddly enough. > > > > > > # lock -nv > > > lock: unknown option -- v > > > usage: lock [-np] [-a style] [-t timeout] > > > > > > -np will at least lock the terminal with your password and no timeout.... > > > > > > > Right, but I want it to prevent me from changing to another virtual > > terminal. > > Referring back to the "BSD Hacks" book (page 22) by Dru Lavigne, I see > now that the lock command to which she refers comes with FreeBSD, > although she states that it's available for NetBSD and OpenBSD. > > I'm an OpenBSD newbie, so I'd enjoy learning why a different version > of lock is employed in OpenBSD. If anyone in the know wants to > elaborate, that'd be great.
It's not necessarily a different version; all BSDs document in the lock(1) manual page that the implementation came from the 3.0BSD release. Indeed, all of them implement similar options with slight variance in the additional command line switches: FreeBSD adds a -v option to prevent switching virtual terminals during a lock. It notes that only syscons(4) terminals are supported here. (Note it's not saying that all other terminals are locked, just that you can't switch to them. So under OpenBSD you might workaround for similar behavior by logging into a single terminal session and running screen(1) or similar to load others, then locking one in essence locks them all.) http://www.freebsd.org/cgi/man.cgi?query=lock&apropos=0&sektion=0&manpath=FreeBSD+6.2-RELEASE&format=html OpenBSD doesn't support -v, but it doesn't use syscons either so that's not really a consideration. But it does add a -a option to extend authentication using the BSD auth subsystem, giving you additional flexibility. http://www.openbsd.org/cgi-bin/man.cgi?query=lock&apropos=0&sektion=0&manpath=OpenBSD+Current&arch=i386&format=html NetBSD is the least featureful of the implementations as it has neither a -v nor a -a option. http://netbsd.gw.com/cgi-bin/man-cgi?lock++NetBSD-3.0 DS

