Version: 4.7 (using KDE 4.7.2) OS: Linux KDE asks upowerd via DBUS to suspend/hibernate. This request is equivalent to something like this: dbus-send --system --dest=org.freedesktop.UPower --print-reply --type=method_call /org/freedesktop/UPower org.freedesktop.UPower.Hibernate Upowerd then asks polkitd to authenticate this action. Given that by default, this action is allowed to active sessions, KDE thinks that it will succeed anyway and locks the screen before getting answer from upowerd. However, if I change the authentication settings (e.g. by copying /var/lib/polkit-1/localauthority/10-vendor.d/org.freedesktop.upower.hibernate.pkla to /etc/polkit-1/localauthority/50-local.d and then editing it) and instruct the system to ask for authentication before Upower based shutdown, then polkit-kde-auth presents me with an authentication window. Now, the system won't hibernate until a successful authentication, but since the screen gets locked immediately after sending the request to upowerd, I don't see the authentication window. I may even thin that hibernation started, and by closing the lid and putting my notebook into its case I may even cause severe overheating, HDD damage or data corruption due to sudden power loss. If I realize that hibernation didn't start and unlock the screen and authenticate then hibernation succeeds, indeed, but the system will resume with an unlocked screen :-( This same bug applies to both hibernation and suspension. Reproducible: Always Steps to Reproduce: Configure PolicyKit to request authentication for Upower based suspension/hibernation. Actual Results: KDE locks the screen before PolicyKit authentication. Expected Results: KDE should only lock the screen after receiving the results from upowerd, AFAIK.
This has happened to me.
Ths should be fixed by the move to Logind in 5.2. PowerDevil now just tells Logind to suspend the session and it will deny that request or invoke the lock screen if configured to and then power down the system if locking has succeeded. PowerDevil no longer invokes the screen locker directly.