Allow restricting layer-shell and emulated input protocol access to whitelisted applications #2698
Replies: 2 comments 1 reply
-
|
Labwc has the infrastructure to block specific protocols or only allow a subset of protocols. This infrastructure is currently used for applications using the security-context protocol (flatpak likely being the most known one). The idea was always to additionally expose config options for it as well but its not implemented yet. For reference see #2398. As for the layershell protocol in particular, you could likely do the exact same thing with any random transparent window. The virtual input protocols are way more relevant in this case. |
Beta Was this translation helpful? Give feedback.
-
|
In addition to creating a transparent surface, anyone can launch |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Right now, labwc seems to more-or-less grant layer-shell and emulated input protocol access to any application that tries to use it. This is convenient, but it breaks Wayland's input isolation goals. Any application can pop open a full-screen layer shell surface, record keystrokes and mouse events that are received by that surface, then destroy the surface and forward the original input event to whatever the intended application was by using an emulated input event. (This assumes focus returns to the appropriate window when the layer shell surface is destroyed, but I believe labwc will do that.) Using this functionality, it's likely possible to write a keylogger (and possibly also a mouse tracker) for labwc and other wlroots-based compositors.
Miriway has a feature where any applications that are going to need to access the layer shell protocol must be listed in a configuration file, where they will be started when the compositor starts. While this mode of operation probably isn't suitable for all labwc users, it might be suitable for some of them, and it would prevent arbitrary applications from sniffing the user's keystrokes and other input data. Maybe this sort of "restricted protocol access" could be added as an optional mode, settable using one of labwc's config files?
Beta Was this translation helpful? Give feedback.
All reactions