Questions tagged [polkit]
Polkit (formerly PolicyKit) is a component for controlling system-wide privileges in Unix-like operating systems.
110
questions
0
votes
0
answers
14
views
Allow udisksctl loop-setup without authentication for specific users
I have some tests that verify the behavior of a program under conditions where it runs out of disk space. Previously I've used dd to create a small-ish file then mkfs to make a filesystem on it, then ...
0
votes
0
answers
17
views
Cannot shutdown computer or connect to Wi-Fi when /proc is mounted with hidepid=noaccess
When I modify /etc/fstab for security and privacy purposes to mount /proc like so:
# grep proc /etc/fstab
proc /proc proc rw,nosuid,nodev,noexec,relatime,hidepid=noaccess 0 0
then I cannot connect ...
0
votes
0
answers
20
views
No Authentication Agent Found Although Already Running
I have an Alpine-Linux based system (PostmarketOS) running with the LXQT DE.
Ever since I set up the system, out of the box it came with a bunch of problems with user authentication. I have various ...
2
votes
1
answer
54
views
Sudo password dialogue not showing up for some apps over XRDP
It happens in both Ubuntu 22.04 and Manjaro (Gnome). If I install XRDP on it and connect to it via XRDP, for some apps the sudo password dialogue is working, and for some other apps, it does not work. ...
3
votes
0
answers
78
views
Alternative to "gksu" in "su" mode for non-root users
On an Oracle Linux 8 installation, I am trying to implement a desktop launcher for the GNOME shell where the (graphical) program is to be run as a different (non-root) user. However, I want to enforce ...
0
votes
0
answers
33
views
Arch linux -- polkit auth_admin_keep setting doesn't remember authorization?
Today, after I entered the password for the service shutdown/start process with systemctl, I wanted to set it to not ask for permission for 5-10 minutes. That's why when I entered the policy settings, ...
0
votes
0
answers
26
views
Can't start emacsclient via RDP and got error about XDG_RUNTIME_DIR
Please be aware that this question is not only about how to fix that specific problem but also about the underlying big picture or concept.
The Problem
When I am logged in via RDP (using Windows 10 ...
0
votes
1
answer
115
views
Cant get right to add wifi in nmcli / polkit
I am remote on an ubuntu 16.04 system via ssh.
I added the following content to /etc/polkit-1/localauthority/90-mandatory.d/99-network.pkla
[Allow netdev users to modify all network states and ...
4
votes
1
answer
2k
views
What is the consequence of chmod 0755 for pkexec
I understand that one way to quickly mitigate CVE-2021-4034 is to chmod 0755 /usr/bin/pkexec (ie remove the SUID bit from it).
I am unclear exactly what the real world consequence of this is. (And, ...
0
votes
0
answers
259
views
Polkit rule to allow a user restart systemd service
I created /etc/polkit-1/rules.d/00-manage-docker-daemon.rules file with following rule to allow members of "agroup" to administer (stop/start/restart) docker.service (Centos 7):
// Allow ...
3
votes
1
answer
119
views
If make isn't supposed to run as root, then how can I install a policy file?
I understand that a Makefile should not require the user to be root. So I'm using /usr/local like this:
PREFIX=/usr/local
install:
install -D example $(PREFIX)/bin/example
That works fine. But I ...
0
votes
0
answers
59
views
How can I make pkexec behave more like sudo (specifically to set a guid)?
I am trying to execute certain programs as a different group, since I have implemented some security controls around that group.
The interactive shell use case works fine with sudo, since I can type ...
1
vote
0
answers
108
views
Python tkinter GUI is being pushed behind GDM3 polkit password window
It seems that my Python PAM RFID solution development has come to an end 🎉 and I finally finished developing kind of working GUI solution as well.
Issue
But, of course I ran into one final issue 😑 - ...
0
votes
1
answer
178
views
pkexec shows in command line instead of GUI pop-up [closed]
I just hopped to Pop!_os yesterday and pkexec executes in terminal.
It also ran into the error:
polkit-agent-helper-1: error response to PolicyKit daemon: GDBus.Error:org.freedesktop.PolicyKit1.Error....
0
votes
1
answer
850
views
How can I repair PolKit?
First let me describe my system. It's Mint 19.0 (Tara). Mint itself isn't the problem, but it's upgrade mechanism seem to have triggered the issue. It came after upgrading from Mint 18.3 to 19.0. I ...
1
vote
1
answer
188
views
Unable to connect to an existing X session w/ Nomachine
I've used Nomachine for years to connect my 2 Linux laptops. The client machine A has always connected to an existing X session in the server machine B displaying it in both A and B. However, lately ...
0
votes
0
answers
30
views
Untraceble authentication popup
I have this peculiar problem, which I hope some one can help me to solve it.
I use xubuntu 20.05, up to date (on Asus prime x470-pro MB, BIOS V5843)
Every time I login, there is a popup requesting for ...
3
votes
1
answer
164
views
Why I am asked for the password of a different account when trying to mount a disk?
I am on Debian 10 Buster.
When using Nautilus (aka Files), I am always asked for my password when trying to mount another HDD. All normal.
A few days ago, I am not asked for my account password ...
0
votes
0
answers
36
views
Is it ok to chmod a+w files under sys/platform in a desktop env?
I developed and maintain a keyboard backlight CLI/GUI for Linux-running Clevo laptops (https://github.com/webketje/tuxedo-backlight-control). Some of the files this CLI/GUI needs to alter are under /...
2
votes
2
answers
124
views
Make Kate to ask password only once, instead of asking it at every file saving?
I am using KDE and Kate editor. When I want to edit some common system files such as configs in /etc, I am asked for password to save my edits.
When I am editing files, I often do several changes, ...
1
vote
1
answer
208
views
What does polkit authorization do to a process?
I want to let my user edit a configuration file in /etc from my graphical C application. One method is:
fprintf( fopen("/tmp/tmpfile", "w+") , "content\n"); // Write to ...
1
vote
1
answer
737
views
dwm - session polkit
I am really struggling to get the session polkit to work.
I am not really familiar with how it works, but I have been using gnome before switching to dwm and in gnome it worked perfectly, so I wanted ...
0
votes
0
answers
1k
views
No polkit authentication agent found in AwesomeWM
I have Ubuntu 20.04 installed on my computer, and recently I've abandoned Gnome in favor of AwesomeWM. I've since learned that a DE is much more fleshed-out than just using a WM, so I've had to rice ...
1
vote
0
answers
231
views
Mount usb drive as regular user in debian/sid
I'm using debian sid, and since one of the upgrades I cannot normally mount usb drive (sdcard).
In dolphin it results in message saying "Not authorized to perform operation"
So after some ...
1
vote
0
answers
260
views
polkit.Result.AUTH_ADMIN_KEEP not working with fprintd
I'm currently configuring fprintd on my computer. It is a powerful tool that makes the fingerprint authorization possible on Unix-like systems. However, a user can add modify and delete fingerprints ...
3
votes
1
answer
628
views
Polkit rule for systemd template files - how to
I am trying to use polkit to allow specific user to start/stop/restart specific services. Those services are defined via systemd template, so for example user can run this command:
systmctl stop my-...
3
votes
1
answer
449
views
Polkit not working when trying to reload nmcli connection
I'm currently working on an Archlinux system and I try to configure rules used by polkit so users inside network group are able to run nmcli commands.
I've create a polkit rule as follow :
polkit....
2
votes
0
answers
300
views
DBus NameOwnerChanged
When i run dbus-monitor --system, i got these 20 events per second:
signal time=1585510053.359267 sender=org.freedesktop.DBus -> destination=(null destination) serial=2019 path=/org/freedesktop/...
0
votes
1
answer
2k
views
Can't start polkit-mate-authentication-agent
I'm using Mate on Parabola GNU/Linux (based on Arch). I have the polkit-mate-authentication-agent installed and it is supposed to be autostarting on login to the desktop; however, it doesn't seem to ...
0
votes
1
answer
160
views
GDBus/PolicyKit error in LXDE
I am using LXDE with Parabola (a libre derivative of Arch Linux). When I log in to the desktop environment, a window pops up with the following error:
GDBus.Error:org.freedesktop.PolicyKit1.Error....
0
votes
1
answer
107
views
Does "Polkit" make use of linux capabilities?
I know that some authentication programs like KDE's KAuth can use polkit as the backend.And what makes polkit special is that it can grant some specific privileges to a non-privileged process.A ...
1
vote
0
answers
258
views
polkit on OpenBSD
I use xfce which came with a polkit action org.xfce.thunar.policy in /usr/local/share/polkit-1/actions/.
This action allow to run thunar as root if you can give the root password.
On debian with ...
-1
votes
1
answer
483
views
CentOS 8: Gparted requires polkit, where may I find it?
In a previous question I asked for help finding polkit so I could install gparted. The one answer I received allowed gparted's install by adding another repository, but led to other problems.
Now ...
2
votes
2
answers
3k
views
CentOS 8 install gparted fails
In CentOS 8.0 Server with desktop, I am trying to install gparted. It's not in the native software app, so I tried:
sudo yum install epel-release
sudo yum install gparted
and when I ran the latter, ...
2
votes
0
answers
3k
views
How to avoid polkit error/timeout "Authorization not available" when restarting systemd services as root
On a very small server I have polkit and dbus daemons/services not running in order to save resources and harden the server (these are not needed for normal running and they increase the attack ...
0
votes
0
answers
95
views
Cannot modify system configuration
why i cannot add user after install vnc and add the polkit?
if i remove the polkit i able to add user from console but rdp didn't work.
please help.
here is the capture:
i am using ubuntu 18.04, ...
1
vote
1
answer
300
views
How to achieve Linux privilege escalation by polkitd without password but with Yes/No prompt?
I want to implement Window's UAC like access control using polkit(d). So if I open Network manager or printers, it should ask me yes/no. No password prompt but window must be showed to user.
I tried ...
2
votes
1
answer
1k
views
Controlling systemd system service as user
I have several services that need to be user-controlled and I can't use them as user services (their requirement is system service with root access), plus there is weird GROUP/216 bug that I haven't ...
1
vote
0
answers
347
views
How to get rid of nag screen "Authentication is required to set one's own greeter properties"?
After a recent update on my Linux system I get a dialogue window every few (5?) minutes with the same message:
Authentication is required to set one's own greeter properties.
It has a password ...
10
votes
1
answer
8k
views
system policy prevents control of network connections
When we log into a KDE seesion using X2Go client, the user is greeted with a dialog asking for a sudo password. I do not want the user to have a sudo password and I would like to prevent the dialog ...
6
votes
3
answers
22k
views
How can I reboot a server with systemctl if systemctl reboot fails?
I tried rebooting my CentOS 7 server but it gives ridiculous error messages.
As root (of course):
# systemctl reboot
Authorization not available. Check if polkit service is running or see debug ...
1
vote
1
answer
693
views
Setup .pkla rule for polkit
I'd like to start a systemd service using DBus in one of my apps which is run as non-root user myuser. For that I need to set up a PolicyKit where I'm using polkit 0.105 and added the following .pkla ...
0
votes
1
answer
437
views
What JavaScript interpreter does Polkit use to interpret rules.d files?
What JavaScript interpreter does Polkit use to interpret rules.d files?
The source code at time of writing links to a defuct Wikipedia heading "ECMAScript.2C_5th_Edition", however that would only be ...
-1
votes
2
answers
695
views
What is polkitd doing when it is pinning 2 out of 4 CPUs for many hours?
I run a park of machines for a charity and do not get paid for this. We have a zoo of various OSs running on machines donated by sponsors. They are wiped clean and installed what is best expected to ...
0
votes
0
answers
50
views
Error when installing software using a GUI
I'm running Feren OS which is based off of Ubuntu, Linux Mint, and Debian. Whenever I try to install or update software using a GUI like Store or Update Manager, I get this error:
org.freedesktop....
0
votes
1
answer
85
views
Does polkit.Result.NO deny actions even to the root user?
E.g. in this example from the Arch Wiki, does systemd-logind still permit the root user to request suspend and hibernation?
The following rule disables suspend and hibernate for all users.
/...
0
votes
1
answer
250
views
polkit rule: determine if user is an admin?
polkit is configured using rules files, written in javascript.
You write custom functions, and pass them as the argument to polkit.addRule(). When a polkit action is performed, the functions are ...
1
vote
1
answer
1k
views
The *correct* way to require root for changes via nmcli to NetworkManager
What is the correct way, with a single command or a small polkit addition, to limit all unprivileged users to read-only usage of nmcli?
Edit: Allowing only a privileged unix group, in addition to ...
-1
votes
1
answer
82
views
polkit pins CPU for prolonged periods of time
Whenever I start the system, polkitd pins 1 core at 100% during at least 4-6 hours with high disk IO and gradual increase in memory consumption. Is polkit in the recent Linuxae a malware?
After ...
5
votes
2
answers
1k
views
systemd service management using pkla equivalents to polkit's rules on Debian
I'm trying to allow users of a somegroup to manage someunit systemd service.
In polkit (>=0.106), this can be done by adding rules:
/etc/polkit-1/rules.d/20-someunit.rules
---
polkit.addRule(...