]> git.ipfire.org Git - thirdparty/systemd.git/commit
logind: add io.systemd.Shutdown varlink interface (#41229)
authorLennart Poettering <lennart@amutable.com>
Fri, 10 Apr 2026 10:29:32 +0000 (12:29 +0200)
committerGitHub <noreply@github.com>
Fri, 10 Apr 2026 10:29:32 +0000 (12:29 +0200)
commit5401a1270af7e6a184d68f0ba3b48629dff0a40f
treeca49b2622d3d346d1be0cb2fe7229e894d6d9859
parent58b9e400a697c5190c3f7858df6fb5681c373b03
parent768b507adc08b47e0dfebb30e6dd0cb30c9a517d
logind: add io.systemd.Shutdown varlink interface (#41229)

The shutdown interface is currently only exposed via dbus. This PR
adds a comparable varlink implementation. It is inspired by the existing
dbus methods and implements PowerOff, Reboot, Halt, Kexec, SoftReboot
as varlink methods on a new io.systemd.Shutdown interface.

It is (intentional) simpler than the dbus for now, i.e. no Can* yet,
mostly
because I want to get feedback first (happy to do that in a followup).

The only real difficulty here is what to do about
verify_shutdown_creds()
as this is needed by both dbus and varlink and its dbus only. I went for
an ugly but (hopefully) pragmatic choice (see the commit message for
details). But I can totally understand if a refactor instead is
preferred.