Limit Sudo to specific commands

Limit Sudo to specific commands

Limit Sudo to specific commands

In this scenario, we have SUDO already setup, howewever we want to be a bit more restrictive as to what can be run via sudo. Login, and su to root

sudo restriction: In this scenario, we have SUDO already setup, howewever we want to be a bit more restrictive as to…

the first thing we need to do is determine the full path of the binary we want to sudo user to have access to. The best way to do this is with the “whereis” command. In this case, we are lookin up yum

sudo restriction: the first thing we need to do is determine the full path of the binary we want to sudo user to have…

as we can see yum is stored in /usr/bin/yum

now edit the sudo config

sudo restriction: edit the sudo config

in this case we are graning the “sudo” LDAP group with the capability of not having to enter a password, and ability to update via YUM using /usr/bin/yum binary.

sudo restriction: in this case we are graning the "sudo" LDAP group with the capability of not having to enter a…

That’s it!

Hosted Linux Servers at www.zwiegnet.com/go

Related guides: 389 Sudo LDAP Integration CentOS 6 | Configure SSH Key Authentication Only

Leave a Reply

Your email address will not be published. Required fields are marked *