Remove user SU access

Discussion and support for all Linux distributions and Unix flavours (FreeBSD, OpenBSD, etc).
Post Reply
Kasyx
Registered User
Posts: 139
Joined: 13 Dec 2006, 02:00

Remove user SU access

Post by Kasyx »

Is there any way to remove the ability to SU on a per-user basis? The users are not part of the wheel group, so I am not really sure how to go about doing this. There are roughly 50 users that I need to remove su access for, and none of them are part of the wheel group which is odd.

Is there some command or something that can give users su access or something?

*sigh*
Nuke
Registered User
Posts: 3515
Joined: 28 Feb 2004, 02:00
Processor: Xeon E5620
Motherboard: Asus P6T6 Workstation
Graphics card: MSI GTX770
Memory: 24GB Hynix
Location: ::1

Re: Remove user SU access

Post by Nuke »

There must be a way. The 2nd user on my our home ubuntu pc can't SU while the first I created can. Will ask the other guys is is just out atm, he will most likely know, he told me where to enable the SU access.
Image
Kasyx
Registered User
Posts: 139
Joined: 13 Dec 2006, 02:00

Re: Remove user SU access

Post by Kasyx »

Awesome, thanks :)
User avatar
rustypup
Registered User
Posts: 8872
Joined: 13 Dec 2004, 02:00
Location: nullus pixius demonica
Contact:

Re: Remove user SU access

Post by rustypup »

my first choice would be to simply chown the sudo executable, changing ownership to the admin group...

<edit>
actually... before going there, have you checked the sudoers file?
</edit>
Most people would sooner die than think; in fact, they do so - Bertrand Russel
Kasyx
Registered User
Posts: 139
Joined: 13 Dec 2006, 02:00

Re: Remove user SU access

Post by Kasyx »

sudoers file is empty except for two lines allowing snmpd and snmptrap. Looks like changing the access on the sudo executable is the best bet.

Thanks for the help :)
User avatar
rustypup
Registered User
Posts: 8872
Joined: 13 Dec 2004, 02:00
Location: nullus pixius demonica
Contact:

Re: Remove user SU access

Post by rustypup »

Kasyx wrote:Looks like changing the access on the sudo executable is the best bet.
no!... it's the quick and nasty approach...

first try using visudo to repair the damaged sudoers file... if the issue persists, then fiddle with ownership...

be warned... recovering from a mucked sudoers file is... fun... use nano or visudo...
Most people would sooner die than think; in fact, they do so - Bertrand Russel
Kasyx
Registered User
Posts: 139
Joined: 13 Dec 2006, 02:00

Re: Remove user SU access

Post by Kasyx »

Oh great! Well as long as it is FUN! :roll:

Hehe, I will give it a shot and see what I can sort out. Thanks :P
lethe377
Registered User
Posts: 1
Joined: 20 Dec 2008, 11:42
Location: Durban

Re: Remove user SU access

Post by lethe377 »

What worries me is that you have 50 users with access to a shell. If they don't need access to bash, give them a false shell.
Post Reply