Kirsle.net logo Kirsle.net

"Sudo" for Fedora GUI Admin Apps

February 22, 2010 by Noah
In Ubuntu Linux, all the graphical administrative applications (for example, user and group management) prompt you for your user password and not the root password. But in Fedora and many other Linux distributions, these apps always prompt for the root password.

Ubuntu by default follows some good security practices such as locking out the root password so that you can't log in directly as root (short of using sudo -i), but in Fedora systems if you lock out the root password, you can't use any of the graphical admin apps anymore since they ask for the root password.

So, here's how to set up Fedora to ask for the user password for graphical admin apps:

There are scripts in /etc/security/console.apps/ for most of the graphical admin apps, for example /etc/security/console.apps/system-config-users for the user & groups app. The general syntax for these files is like this:

USER=root
PROGRAM=/usr/share/system-config-users/system-config-users
SESSION=true
The general idea how to change it to ask for the user password is to add a line that says "UGROUPS=wheel" (where "wheel" is the name of a built-in group commonly used to give sysadmin capabilities to regular users). Then, any user who belongs to the "wheel" group will be asked to give their user password; all other users have to give the root password. Make sure your user belongs to the "wheel" group and you're all set.

On my Fedora 12 system though, all these scripts include /etc/security/console.apps/config-util first. So, my system-config-users script just said this:

. config-util
PROGRAM=/usr/share/system-config-users/system-config-users
SESSION=true
And my config-util file just said USER=root. So, I just added "UGROUPS=wheel" to config-util and now all my graphical admin apps ask me for my user password now, since all these files included config-util.
Tags:

Comments

There are 2 comments on this page. Add yours.

Avatar image
Chris posted on February 16, 2012 @ 14:32 UTC

This is what I was looking for, but it doesn't seem to work. I'm using Fedora 14 x86 with XFCE. I added "UGROUPS=wheel" to config-util, but I still only get asked for the root password. I haven't restarted my session yet, so perhaps the GUI needs to be reloaded before it will work?

Avatar image
Jim posted on April 4, 2012 @ 21:48 UTC

Worked a treat for me. Perhaps Chris did not add himself to the wheel group?

Assuming Chris's user name is chris, the command would be:

sudo usermod -a -G wheel chris

Add a Comment

Used for your Gravatar and optional thread subscription. Privacy policy.
You may format your message using GitHub Flavored Markdown syntax.