Hi
As the title says, I would like to su without giving the password
I'm using fedora 7 with gnome
I have already setup sudo without a password for my normal user but I would still like a normal root terminal while avoiding the password
the info on su does not provide any information about passing the password as a parameter. I suppose that is out of the question
I tried making a file /etc/default/su and writing the line
PROMPT=No (or no, I tried both) which according to many websites was supposed to do it, but it doesnt
So does anybody know? I dont care about security at this point. The box is just for experimental toying around, I dont care about being compromised.
this is a script to open a root terminal in the current directory (right-click on a directory)
Code:
#!/bin/sh
base="`echo $NAUTILUS_SCRIPT_CURRENT_URI | cut -d'/' -f3- | sed 's/%20/ /g'`"
if [ -z "$NAUTILUS_SCRIPT_SELECTED_FILE_PATHS" ]; then
dir="$base"
else
while [ ! -z "$1" -a ! -d "$base/$1" ]; do shift; done
dir="$base/$1"
fi
gnome-terminal --working-directory="$dir" --command su
It is placed in ~/.gnome2/nautilus-scripts and it works ok, prompting for a password of course
What I'm really looking for is to remove the password requirement
Trying
sudo gnome-terminal --working-directory="$dir"
instead of
gnome-terminal --working-directory="$dir" --command su
does not work at all on the script, although it does work on an open terminal
Trying
gnome-terminal --working-directory="$dir" --command "sudo gnome-terminal --working-directory="$dir""
works but it opens 2 terminals, the original which is unusable and a second one which is usable. But this is rather ugly