-
-
Notifications
You must be signed in to change notification settings - Fork 48
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open menus prevent screen lock #3898
Comments
Similarly, having the Applications Menu or a Launcher menu open prevents using a keyboard shortcut to lock the screen:
|
I can reproduce this on R4. I have the same power saving settings (lock & suspend on lid close). If I open the application menu and close the lid, it does not suspend. As I open the lid, it is unlocked (I can see all open windows as if it were unlocked), but then locks within 1 or 2 seconds. However, as you point out, this problem is not exclusive to the application menu. When I open "Screensaver Preferences", and click the dropdown for "Mode", leave the dropdown open, and close the lid, it does not suspend or lock. Ctrl+Alt+Delete does not lock the screen as well when the dropdown is open. I wonder if it has to do with the fact that it tries to both lock and suspend at the same time (maybe?), when it should instead lock first then suspend. Just a guess. |
I have found more information that may prove relevant: Per the ArchLinux wiki, an alternative is
|
Background: the problem here is because inherent problem with X11. Open menus and some other things can get GrabKeyboard, preventing other applications from receiving keys (and switching focus), and also from getting GrabKeyboard. This means that:
Note that thanks to Qubes GUI, this all is accessible only to dom0 application. light-locker might indeed be an option, as it starts separate X server for the locker application, so it isn't blocked by anything in the original one (as long as screenlock is triggered). At least in theory. But starting second X server in dom0 cause problems on Qubes. I think it should be better in 4.0 (thanks to QubesOS/qubes-gui-daemon@a333f7c), but for 3.2 it isn't that simple. |
Well, at least I can confirm this not happening in KDE which also seems more stable and reliable in Qubes 4 than 3.2. |
This issue is being closed because:
If anyone believes that this issue should be reopened, please let us know in a comment here. |
@andrewdavidwong This issue is still present in R4.0 as well, and also likely present in R4.1 unless the update to Xfce 4.14 (#5330) fixed it. |
Who ever will fix this, might want to look at this one: |
Yes, makes sense. |
Duplicate of #1917 |
Still being reported as a problem: https://forum.qubes-os.org/t/9557 I'm not sure if I entirely agree with closing this as a duplicate of #1917, but I can understand the reason why. |
Reopening as #1917 is locked. |
This is really a problem with X11. I have solutions in mine, but they all require patching both XScreenSaver and the X server. Specifically, a new X extension could allow a client to mark itself as critical. A critical client exiting would cause the server to exit too. The screen locker would mark itself as critical, and would then exit if it was not able to lock the screen. This would cause the server to exit and send the user to the login screen. The long-term solution is Wayland. |
Closing as duplicate. |
Minor side notes:
|
Marked as “not our bug”. This is a bug in X11, and the fixes involve either (1) killing the entire X session when the screen locker can’t work or (2) not using an X11-based screen locker. #1917 will fix that. |
I did oversee the original issue post here, resulting in my duplicate thread. Github Mobile has its own issues for me not refreshing past the first pages of a filtered search. After looking into the background of this bug, and the long timespan of it's existence in other distros, it definitely is not a Qubes OS bug, but stemming from X11 directly. If R4.2.0 will ship with X11 by default, and such issues still persist, perhaps the automatic screen locks could/should be changed from opt-out to opt-in, instead urging users during the post-install setup to physically lock the device during moments of laziness and inactivity using Ctrl+Alt+L / etc. |
The best fix is to switch to KDE’s Wayland session as the default in R4.2. @marmarek is this reasonable? |
Closing as “not our bug”. |
Qubes OS version:
R3.2
Affected component(s):
Xfce4 4.12 + XScreenSaver 5.36
Steps to reproduce the behavior:
Expected behavior:
The screen should lock properly regardless of which menus are open in dom0.
Actual behavior:
Having the Applications Menu open prevents the screen from locking. Similarly, having a "Launcher" menu open (a type of task bar widget for holding shortcut buttons) prevents screen locking in the same way.
On my machine, this is reliably reproducible every time.
General notes:
In Qubes, one of the main purposes of the screen locker is to protect the system from physical threats. For example, a user may need to quickly shut her laptop lid when confronted by an adversary, or a thief may close the laptop while snatching it from a user in a coffee shop. In both cases, if the user had the Applications Menu or a Launcher menu open when the lid was shut, an attacker with no technical skill would be able to gain full access to the system simply by opening the lid.
Related issues:
#1917
The text was updated successfully, but these errors were encountered: