freedesktop Use the PolicyKit framework (sys-auth/polkit) to get authorization for suspend/shutdown.