Changes

Jump to navigation Jump to search
no edit summary
To prevent reboot or shutdown over ssh, console or network.

chmod 700 /sbin/reboot
chmod 700 /sbin/shutdown

edit .bashrc for ALL users and root, set it to /etc/skel for new users too!
<pre>
alias reboot='echo Not allowed!'
alias shutdown='echo Not allowed!'
alias init='echo Not allowed!'
alias sh='echo Not allowed!'
alias dash='echo Not allowed!'

</pre>

then disable other shells for users
<pre>
chmod 700 /bin/sh
chmod 700 /bin/dash
</pre>

Navigation menu