Sudo Customization- Change Password Prompt of Sudo

Hello All,

I have created a local root user named lroot with less previlage compared to root.
How can i make sudo to ask for lroot password instead of root password when executing commands with sudo

Regards,
Hamerins

Use the user (-u) option:

sudo  -u lroot *command*

On 09/12/2012 12:16 PM, Hamerins wrote:
>
> Hello All,
>
>
> I have created a local root user named lroot with less previlage
> compared to root.
> How can i make sudo to ask for lroot password instead of root password
> when executing commands with sudo
>
> Regards,
> Hamerins
>
>

lets start over with you tell what it is you are actually trying to
accomplish (as well as your operating system, version, and desktop
environment [if any] and version)…

i say that because i think maybe you don’t understand that sudo itself
can be tuned to give various different users different amounts of root
powers…

that is, root can be all powerful while You (as user) using sudo can
have less privileges and Someone_else (a different user) using sudo can
also have less privileges than both root AND You, while TrustedGuru (a
third user) using sudo could have less than root powers but more and/or
different than Someone_else…

so, what i think is you have created lroot and don’t need it–you just
need to tune sudo to do as you want!

yes, i know that the default sudo in openSUSE (and many others) grant
full root privileges to any who provoke it AND know the root
password…but, if Someone_else provokes sudo and gives her password
(and you have tuned sudoers to limit her powers) she will get ONLY the
power that You (the system administrator) grants her…

see man sudo and man sudoers

by the way: i have no idea how to answer your question as given…if i
misunderstand exactly what you are trying to do, maybe i can do
better…which is why i ask you to explain what you want to end with,
rather than ask “How can i make sudo to ask for lroot password”…sudo
is always ready to accept any user’s password–but, you must teach it to
do that, through sudoers.


dd http://goo.gl/PUjnL

Like @dd, I am a bit curious about what you want and are doing.
I do for example not understand how you can create a user with less privileges then *root, *apart from a ordinary user.

In Unix/Linux there are only two types of users: root (with userid 0) and all others. That is of course a bit black and white and thus mechanisms were build to allow certain users to do things as *root, *at the same time not allowing this user to do other things as *root, *nor allowing other users to do the same things as the privileged user. The most well know of these mechanisms is sudo.

Thus sudo creates a sort of extention of privileges to ordinary users. But you say you have created a user with less provileges then root. I am curious.