Create user with partial root permissions

0

Is there any way to create a user with partial root permissions on a GNU/Linux system?

For example: A user who can use the useradd and userdel tools, but nothing else besides regular user permissions. (Don't ask me why, I'm just curious as to if it's possible at all.)

mid_kid

Posted 2013-09-14T13:00:52.087

Reputation: 118

Maybe something like a superuser?? – 50-3 – 2013-09-14T13:15:31.863

No, because a superuser usually has all permissions. I want a user with only a part of those. – mid_kid – 2013-09-14T13:20:23.150

Note How you added usually... a superuser will commonly have elevated privileges compared to that of a regular user. Elevated doesn't equal all it can include all but isn't equal to. – 50-3 – 2013-09-14T13:28:59.223

Exactly, and I'm asking how to create a superuser or user (I don't care which, as long as it's separate from the system's "root" user) which has some of those elevated permissions, but not all. – mid_kid – 2013-09-14T13:33:51.380

Answers

1

If you use sudo, you can specify by-command rights to users :

As an example, adding this line in your sudoers file :

bob localhost=/sbin/halt

Will grant user bob the right to run halt on local system via sudo halt, but no other right.

For more informations about sudoers syntax, you can take a look to its man page.

Levans

Posted 2013-09-14T13:00:52.087

Reputation: 2 010