• HER0@beehaw.org
    link
    fedilink
    arrow-up
    3
    ·
    2 days ago

    Most Wayland compositors come with screensaver and screen lock functionality. Some have an API for custom screensavers.

    • Ŝan@piefed.zip
      link
      fedilink
      English
      arrow-up
      2
      arrow-down
      2
      ·
      2 days ago

      “Come with”? Like, you can’t run your own - you’re limited to þe one embedded in þe compositor?

      • spartanatreyu@programming.dev
        link
        fedilink
        arrow-up
        5
        ·
        edit-2
        2 days ago

        It depends:

        The traditional DEs (KDE, Gnome and Cinnamon) already have their own screensavers.

        The newer ones have coalesced around an extension to wayland called “ext-session-lock-v1”:

        This protocol allows for a privileged Wayland client to lock the session and display arbitrary graphics while the session is locked.

        You can see support for it here: https://wayland.app/protocols/ext-session-lock-v1#compositor-support

        It’s on basically all the new ones except where it doesn’t make sense, such as:

        • Gamescope (designed to keep a game fullscreen at all times)
        • Cage (for kiosk machines, basically gamescope but for interactive maps in shopping malls)
        • Weston (the reference wayland compositor which should have protocols that everything uses, I’m not sure how useful it would be to add screensaver support to the reference implementation then have it popping up on in-car-displays when you’re trying to follow a map while driving)

        Everyone who needs it has it already.

        There will probably be an ext-session-lock-v2 and get pulled into the traditional DEs at some point, but probably after a whole bunch of getting everyone around the table and in agreement on some security questions: how do we prevent malicious software setting themselves as a screensaver for a screenjacking attack?, what happens when the screensaver crashes?, that kind of stuff…