polkit (formerly PolicyKit) is a toolkit for defining and handling authorizations. It is used for allowing unprivileged processes to speak to privileged processes.
Describe the bug
The pidfd tracking feature added in polkit 124 causes e.g. pkexec echo hi to show a terminal password prompt instead of the gnome password modal dialog that it would show on previous versions.
Expected behaviorpkexec should show the gnome authentication dialog, even with pidfd tracking on.
Screenshots
polkit 124:
previous polkit versions or polkit 124 with pidfd tracking disabled:
Desktop (please complete the following information):
OS (including version): Chimera Linux
Desktop Environment [Gnome, KDE, ...]: GNOME 46
Version of polkit: 124
Additional context
Notably. enough, this issue seems to only be happening with gnome's polkit auth agent. I could not reproduce the issue while running KDE Plasma with its polkit agent, and even while running gnome, starting polkit-mate-authentication-agent-1 or polkit-kde-authentication-agent-1 manually and then running pkexec echo hi would show the respective authentication dialog as expected.
Also, here are the options we're passing to meson:
Describe the bug The pidfd tracking feature added in polkit 124 causes e.g.
pkexec echo hi
to show a terminal password prompt instead of the gnome password modal dialog that it would show on previous versions.Commenting out this line to disable pidfd tracking fixes the issue and makes
pkexec echo hi
again show the gnome authentication dialog as it should: https://github.com/polkit-org/polkit/blob/82f0924dc0eb23b9df68e88dbaf9e07c81940a5a/meson.build#L226To Reproduce Steps to reproduce the behavior:
pkexec echo hi
Expected behavior
pkexec
should show the gnome authentication dialog, even with pidfd tracking on.Screenshots
polkit 124:![`pkexec echo hi` running in my terminal, showing a terminal password prompt](https://github.com/polkit-org/polkit/assets/32234660/8215c373-bdfb-4d1e-96df-b1c874d85640)
previous polkit versions or polkit 124 with pidfd tracking disabled:![gnome authentication dialog shown on previous versions of polkit](https://github.com/polkit-org/polkit/assets/32234660/079cb972-59f9-4e33-bf0d-49f56c743596)
Desktop (please complete the following information):
Additional context Notably. enough, this issue seems to only be happening with gnome's polkit auth agent. I could not reproduce the issue while running KDE Plasma with its polkit agent, and even while running gnome, starting
polkit-mate-authentication-agent-1
orpolkit-kde-authentication-agent-1
manually and then runningpkexec echo hi
would show the respective authentication dialog as expected.Also, here are the options we're passing to meson: