jbuchermn / newm

Wayland compositor

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

How should custom lock panels be implemented?

tewkanz opened this issue · comments

I'm trying to update my newm configuration to use gtklock as my lock panel. newm doesn't expose the input inhibitor protocol, it just locks the screen itself. It also takes care of displaying the window, so we don't need the layer shell protocol. Both of those things are fine and gtklock's handling for them can be disabled through command line options.

However, when I enter my password and dismiss the lock window, my screen doesn't unlock. Do I need to redirect the password to the org.newm.auth.Request bus?

It does work if I write a little script that starts gtklock, then calls newm-cmd unlock after it exits. I don't love that though because it decouples the authentication from the screen unlock -- we don't really know why gtklock exited.

Basically, how was this intended to be used? :) It doesn't seem unreasonable to require programs to send their credentials through newm. However, I'm not sure how to make that happen without directly modifying the lock screen program.

Maybe we could write a pam module that sends credentials to newm's authentication bus that you plug into the lock screen? Getting a bit out of my comfort zone.

Unfortunetaly that's indeed not possible at the moment due to a missing protocol in pywm (see jbuchermn/pywm#18). Once I come around to implementing that, other lock screens should / could work (I suspect there's a little bit more to do, but we will see...)

You could possibly work round org.newm.auth.Request and newm-cmd unlock, but the latter is really only intended for debugging purposes...