I'm trying to edit
visudo, but I don't know how to change the root rights.
I want root to be prompted for the user1's password, when he tries to use
Well, it's not really a good idea, but it IS possible. As somebody here pointed out, you can't prevent root from being the computer's god, but you can modify the "su" program to ask for passwords. It can prevent root from re-logging to other accounts unless he compiles his own version of su and uses it.
First, you'll need a compiler to be able to re-build su. As a root, perform:
Then, download and prepare the GNU Coreutils:
Now access the src directory and locate the su.c file. In line 223, you'll find:
Change it to:
Now, back in the coreutils-8.20 directory, run make. Compilation might take long time. Once it's done, overwrite the current su binary with the new one:
And again - you're doing it wrong.
Root can become any user without requiring any authentication. Even if the
On Ubuntu (and many other systems that use PAM), the absence of a password prompt when root runs