[WBEL-users] Prevent users from shutdown

pedro cañadilla pedro.canadilla at gmail.com
Sun Feb 13 08:14:12 CST 2005


Hi,

Sorry for the delay.

I think that you don't have any need to delete anything.

For example, to prevent my users to reboot the machine, I changed the
/etc/pam.d/reboot as follows:

#%PAM-1.0
auth       sufficient   pam_rootok.so
#auth       required     pam_console.so
#auth       required    pam_stack.so service=system-auth
account    required     pam_permit.so

In this manner, you have to be root to reboot the machine from a gnome
session (of course, you can do it from the gdm). The user can select
the restart machine but the real efect is logout.

Instead, if you want to be prompted for root's password, the following
can help you:

cat /etc/pam.d/reboot
#%PAM-1.0
auth       sufficient   pam_rootok.so
#auth       required    pam_console.so
auth       required     pam_stack.so service=system-auth
session    required     pam_permit.so
account    required     pam_permit.so

cat /etc/security/console.apps/reboot
USER=root
FALLBACK=true

As you can see, you have several options from the PAM aware apps. I
hope this is useful to you :-)

Best Regards and nice Sunday,
P.C.


More information about the Whitebox-users mailing list