]> git.ipfire.org Git - thirdparty/systemd.git/commit
pam_systemd: process the two new capabilities user records fields in pam_systemd
authorLennart Poettering <lennart@poettering.net>
Fri, 17 Feb 2023 21:49:16 +0000 (22:49 +0100)
committerLennart Poettering <lennart@poettering.net>
Tue, 28 Feb 2023 20:42:29 +0000 (21:42 +0100)
commitbf1b9ae487b65b1cb1639b222724fab95e508cf5
tree0672ac19ebde02266115215d6e44f435041381a4
parentfada2c75a4ced4f8275a57ec2227389c070238f2
pam_systemd: process the two new capabilities user records fields in pam_systemd

And also: by default, for the systemd-user service and for local
sessions (i.e. those assigned to a seat): let's imply CAP_WAKE_SYSTEM
for them by default. Yes, let's pass one specific capability by default to local
unprivileged users.

The capability services exactly once purpose: to allow system wake-up
from suspend via alarm clocks, hence is relatively limited in focus. By
adding this tools such as GNOME's Alarm Clock app can simply allocate a
CLOCK_REALTIME_ALARM (or ask systemd --user to do this) timer and it
will wake up the system as necessary.

Note that systemd --user will not pass the ambient caps on by default,
so even with this change, individual services need to use
AmbientCapabilities= to pass this on to the individual programs.

Fixes: #17564 #21382
man/pam_systemd.xml
src/login/pam_systemd.c