I am currently using Debian 7 (Wheezy) and I am trying to disable the
su command only when the target user is root and not a privileged user.
For example, let's suppose the following users exist:
root would of course be able to
su, without restrictions.
public should be able to
privileged but not to
privileged should be able to
su to root (or any user).
So far I have only been able to disable
su to anyone but
privileged, appending to
/etc/pam.d/su the following line:
auth required pam_wheel.so 1005
Assuming 1005 is
However, this makes
public unable to use
How could I make it?