> > How about creating a quick script '/etc/threefingersalute', like the one
> > below:
> > - -
> > if [ $USERNAME = "ROOT" ]; then
>
> $USER $USERNAME or $LOGNAME, bash manpages will give you info on what each
> is, the "ROOT" should be "root" it's case sensitive. This might work, but
> without double checking i'm pretty sure it'll be a problem that init runs
> as root and this does not actualy run on the current console when you
> call it with.
It doesn't have to be root. If you wanted to, you could change root's
name to something else by hacking the /etc/passwd file. The superuser
(usually root) is the one with the user id of 0. You could write a GAWK
program that would scan for the line with the user id of 0 and print the
corresponding username (and you would capture the output and compare it
to $USERNAME).
Hmm. Maybe root isn't the only user who wants to shut down the system
when he presses Ctrl+Alt+Del. Try comparing the $USERNAME against the
names in shutdown.allow (a la a GAWK script). Would that work, guys?