diff --git a/modules/csfx-agent.nix b/modules/csfx-agent.nix index 7310012..560364e 100644 --- a/modules/csfx-agent.nix +++ b/modules/csfx-agent.nix @@ -140,8 +140,15 @@ in subject.user == "csfx-agent") { return polkit.Result.YES; } - if ((action.id == "org.freedesktop.login1.reboot" || - action.id == "org.freedesktop.login1.power-off") && + var powerActions = [ + "org.freedesktop.login1.reboot", + "org.freedesktop.login1.reboot-multiple-sessions", + "org.freedesktop.login1.reboot-ignore-inhibit", + "org.freedesktop.login1.power-off", + "org.freedesktop.login1.power-off-multiple-sessions", + "org.freedesktop.login1.power-off-ignore-inhibit" + ]; + if (powerActions.indexOf(action.id) !== -1 && subject.user == "csfx-agent") { return polkit.Result.YES; }