Operating System - HP-UX
1832864 Members
2944 Online
110048 Solutions
New Discussion

root access via su to be restricted

 
SOLVED
Go to solution
Sanjiv Sharma_1
Honored Contributor

root access via su to be restricted

Hi,

I want to allow root access via "su" to be restricted only to the members of the following two groups, say "adm" and "sap". How can I achieve this? No other users or group can su to root.
Everything is possible
3 REPLIES 3
A. Clay Stephenson
Acclaimed Contributor

Re: root access via su to be restricted

Very simple. Change the root password and only tell the members of those groups. Seriously, the fundmental problem is that far too many people know your root password.

A safer method would be to identify just those tasks that need to be run as root and create a set of very explicit sudo'ed commands.
If it ain't broke, I can fix that.
Patrick Wallek
Honored Contributor
Solution

Re: root access via su to be restricted

Have a look at the man page for 'security'. There is functionality within the /etc/default/security file called 'su_root_group', or something very similar. This will do precisely what you require.
Sanjiv Sharma_1
Honored Contributor

Re: root access via su to be restricted

In /etc/default/security, SU_ROOT_GROUP=adm does help. Thanks
Everything is possible