Home_greyopenFATE - openSUSE feature tracking > #314778
Dashboard | Search | Sign up | Login

Please login or register to be able to edit or vote this feature.

Use polkit for YaST privilege management

Feature state

openSUSE Distribution


At the moment of writing, YaST relies on having root privileges through a graphical sudo in order to view and carry out most tasks. However, there is no reason why simply displaying those tasks should be restricted like that.
YaST should always be started with user privileges, and only ask for additional privileges when they are truly needed - when the selected tasks should be carried out.

This can be achieved by using polkit. It also brings a lot of other benefits.

User benefit:

Using polkit, the graphical interface of YaST would always be run as a normal user. That means that code that should not have elevated privileges - like GUI - would not run with them.

More could be done without needing to enter the root password - package information query, printer setup, device information overview, reviewing network configuration options etc.

In a restrictive environment, the system administrator could set certain tasks to be available for use by regular users, or to allow certain tasks to be run by certain users only.

The authentication screen would provide more information about what tasks are about to be carried out for increased security. For instance, if a custom YaST module requests permission to modify the partition table, while it claims to only set up the date and time, it would be clear to the user that the module is either fraudulent or is malfunctioning.

In order to not have to authenticate after every single change a module wishes to do, a global queue for the changes could be created (like what is shown by the /etc/sysconfig editor once its changes are to be applied). Once the global "apply" button is pressed, the user would be informed of what actions will be carried out and what privileges will be given to carry them out. Then, once the user confirms that by supplying a password, all the changes are applied.



Users who do not have access to the root password currently also do not have access to a lot of functionality that does not actually require the password, such as searching for package information.

Users that do administrative tasks are also subjecting the system to possible security risks by running YaST with full root privileges. Using polkit would increase security and prevent potential user mistakes.


icons/user_comment.png H. H. wrote: (5 years ago)

This is also one of Linus Torvalds' main objection with openSUSE, see for instance this article about it:

Would be great if trivial tasks in openSUSE no longer require root.

icons/user_comment.png J. S. wrote: (4 years ago)

This would require some major change in YaST architecture, that would be able to divide part that can be run by any user from the part run by privileged user only.
There were some attempts already (e.g. Gloves project), but none was finished.

icons/user_comment.png D. M. wrote: (4 years ago)

Really? It seems to me that it would just need a few privilege-awareness changes. Instead of presuming that each module runs as root, you instead queue up the changes that the module wants to do to the system, then pressing the Finish button asks for the password and applies the changes. The workflow stays pretty much the same, because that's already what most YaST modules do as it is. The only thing that is missing is a way to integrate the queue with polkit, and review the actions that each module wishes to take (so that it wouldn't always require a password when one is not needed, and would ask only for the necessary amount of privileges they need).

Even without the extensive review, it would already be an improvement over what we have now, since at least the GUI would always run as the user, and not root, for added security and theme consistency with the desktop.

Last change: 4 years ago
Score: 6
  • Negative: 1
  • Neutral: 0
  • Positive: 7
Feature Export
Application-xmlXML   Text-x-logPlaintext   PrinterPrint