I want to prevent the users from using the su command, and so I blocked the command in /etc/sudoers file as below:
%group ALL=(ALL:ALL) NOPASSWD:!/bin/su
But with this rule in sudoers, they are unable to execute sudo <command> commands, resulting in the error:
Sorry, user xxxx is not allowed to execute 'command' as root on <host>
Is there any way that the program sudo relies on su?
sudoandsu). – Kusalananda May 22 '23 at 13:16/etc/sudoersso they can runvi." User startsviviasudoand then enters:!/bin/bash. Instantrootshell. That's just one example. That's why there's auditing... – Andrew Henle May 23 '23 at 04:39