I'm attempting to implement sudo on an HP-UX server.
I have certain commands that must be executed as a particular user, and can not use sudo to execute those commands directly, as the environment variables aren't picked up properly.
So, I am trying to authorize certain users to "su -" to those application specific user IDs to execute the commands directly...
I do NOT want to give out the application specific passwords, as I don't want anyone to login to these application specific user accounts directly...
What I am attempting is this:
visudo
# The following entry should allow members of the "users" group, or the user "user01", to "su -" to application specific user accounts, without knowing or entering a password:
%users localhost = NOPASSWD: /usr/bin/su - <APP_ID>
- OR -
user01 localhost = NOPASSWD: /usr/bin/su - <APP_ID>
Visudo doesn't complain about any syntax related errors when I exit and save the session...
When I login as "user01" and then type "su - <APP_ID>", I'm still prompted for a password...
When I login as any other user, that belongs to the "users" group, I'm still prompted for a password...
I've tried using the actual system name in place of localhost...
I've tried using the full PATH to "su" ( /usr/bin/su )...
I don't know what else to try...
Is this a bug, or am I doing something wrong?
Any help would be much appreciated...
Again, this is on an HP-UX system, running 11.11 or 11.i...
TIA
Jxfish2
I have certain commands that must be executed as a particular user, and can not use sudo to execute those commands directly, as the environment variables aren't picked up properly.
So, I am trying to authorize certain users to "su -" to those application specific user IDs to execute the commands directly...
I do NOT want to give out the application specific passwords, as I don't want anyone to login to these application specific user accounts directly...
What I am attempting is this:
visudo
# The following entry should allow members of the "users" group, or the user "user01", to "su -" to application specific user accounts, without knowing or entering a password:
%users localhost = NOPASSWD: /usr/bin/su - <APP_ID>
- OR -
user01 localhost = NOPASSWD: /usr/bin/su - <APP_ID>
Visudo doesn't complain about any syntax related errors when I exit and save the session...
When I login as "user01" and then type "su - <APP_ID>", I'm still prompted for a password...
When I login as any other user, that belongs to the "users" group, I'm still prompted for a password...
I've tried using the actual system name in place of localhost...
I've tried using the full PATH to "su" ( /usr/bin/su )...
I don't know what else to try...
Is this a bug, or am I doing something wrong?
Any help would be much appreciated...
Again, this is on an HP-UX system, running 11.11 or 11.i...
TIA
Jxfish2