Fingerprint stopped working with cinnamon-screensaver

On my Lenovo ThinkPad T14 G1, I have set up my EndeavourOS with the Cinnamon DE and fingerprint detection, as described in Using a fingerprint reader with Cinnamon, possibly other DEs.

This has been working fine since over a year, but suddenly, about one or two weeks ago, it stopped working for the Cinnamon Screensaver. It now only asks me for password, the text “Put your right index finger on the fingerprint reader” is gone.

I noticed that I got a .pacnew update for my /etc/pam.d/cinnamon-screensaver, which added the line

-auth       optional     pam_oo7.so

I believe this came with cinnamon-screensaver 6.8.0 or 6.8.1, so I merged it in, resulting in this new /etc/pam.d/cinnamon-screensaver file:

#%PAM-1.0

# Fedora & Arch
auth       sufficient   pam_fprintd.so
-auth      sufficient   pam_selinux_permit.so
auth       include      system-auth
-auth       optional     pam_gnome_keyring.so
-auth       optional     pam_oo7.so
account    include      system-auth
password   include      system-auth
session    include      system-auth

# SuSE/Novell
#auth       include      common-auth
#auth       optional     pam_gnome_keyring.so
#account    include      common-account
#password   include      common-password
#session    include      common-session

Note that everything else (lightdm-greeter, sudo, etc.) all still works fine with PAM and fingerprints, just not the cinnamon-screensaver.

I am very much used to just opening my laptop and touching the fingerprint reader to continue working, so this really bugs me.

Help much appreciated!

Needs some log, to see where it fails.

systemctl status fprintd.service

fprintd-list "$USER"

fprintd-verify

Temporarily add debug to the pam_fprintd.so line in /etc/pam.d/cinnamon-screensaver:

auth sufficient pam_fprintd.so debug

When there is a pacnew file present there also should be a .bak file present being a backup for the original file.
Maybe compare those two files to see if there is another change made during the merge.
Also some information about the oo7 thing.

$ systemctl status fprintd.service 
○ fprintd.service - Fingerprint Authentication Daemon
     Loaded: loaded (/usr/lib/systemd/system/fprintd.service; static)
     Active: inactive (dead)
       Docs: man:fprintd(1)

Dez 02 06:30:51 t14-mch systemd[1]: Starting Fingerprint Authentication Daemon...
Dez 02 06:30:52 t14-mch fprintd[1043]: Device responded with error: 789 retry: 1
Dez 02 06:30:52 t14-mch systemd[1]: Started Fingerprint Authentication Daemon.
Dez 02 06:31:24 t14-mch systemd[1]: fprintd.service: Deactivated successfully.
Dez 02 06:32:45 t14-mch systemd[1]: Starting Fingerprint Authentication Daemon...
Dez 02 06:32:45 t14-mch systemd[1]: Started Fingerprint Authentication Daemon.
Dez 02 06:33:18 t14-mch systemd[1]: fprintd.service: Deactivated successfully.
Dez 02 20:42:35 t14-mch systemd[1]: Starting Fingerprint Authentication Daemon...
Dez 02 20:42:36 t14-mch systemd[1]: Started Fingerprint Authentication Daemon.
Dez 02 20:43:35 t14-mch systemd[1]: fprintd.service: Deactivated successfully.
$ 
$ fprintd-list "$USER" root
found 1 devices
Device at /net/reactivated/Fprint/Device/0
Using device /net/reactivated/Fprint/Device/0
Fingerprints for user matthias on Synaptics Sensors (press):
 - #0: right-index-finger
Fingerprints for user root on Synaptics Sensors (press):
 - #0: right-middle-finger
$ 
$ fprintd-verify 
Using device /net/reactivated/Fprint/Device/0
Listing enrolled fingers:
 - #0: right-index-finger
Verify started!
Verifying: right-index-finger
Verify result: verify-match (done)
$ 

debug added, where do I see the logs?

This is how it looks like now: Only password entry, two obscure new buttons at the bottom, no prompt to lay your finger on the reader anymore:

Lightdm (on first boot or when changing users) still works fine:

Here is a little log (journalctl --since 20:50 --grep pam > journal.pam.log):

Dez 02 20:50:00 t14-mch crond[19352]: pam_unix(crond:session): session opened for user root(uid=0) by root(uid=0)
Dez 02 20:50:14 t14-mch CROND[18887]: pam_unix(crond:session): session closed for user root
Dez 02 20:51:00 t14-mch crond[19557]: pam_unix(crond:session): session opened for user root(uid=0) by root(uid=0)
Dez 02 20:51:16 t14-mch CROND[19105]: pam_unix(crond:session): session closed for user root
Dez 02 20:51:31 t14-mch cinnamon-screensaver-pam-helper[19516]: pam_unix(cinnamon:auth): conversation failed
Dez 02 20:51:31 t14-mch cinnamon-screensaver-pam-helper[19516]: pam_unix(cinnamon:auth): auth could not identify password for [matthias]
Dez 02 20:52:00 t14-mch crond[19750]: pam_unix(crond:session): session opened for user root(uid=0) by root(uid=0)
Dez 02 20:52:07 t14-mch cinnamon-screensaver-pam-helper[19669]: gkr-pam: unlocked login keyring
Dez 02 20:52:07 t14-mch cinnamon-screensaver-pam-helper[20179]: pam_unix(cinnamon:account): setuid failed: Die Operation ist nicht erlaubt
Dez 02 20:52:13 t14-mch CROND[19352]: pam_unix(crond:session): session closed for user root
Dez 02 20:53:00 t14-mch crond[22993]: pam_unix(crond:session): session opened for user root(uid=0) by root(uid=0)
Dez 02 20:53:14 t14-mch CROND[19557]: pam_unix(crond:session): session closed for user root
Dez 02 20:54:00 t14-mch crond[24971]: pam_unix(crond:session): session opened for user root(uid=0) by root(uid=0)
Dez 02 20:54:16 t14-mch CROND[19750]: pam_unix(crond:session): session closed for user root
Dez 02 20:55:00 t14-mch crond[25470]: pam_unix(crond:session): session opened for user root(uid=0) by root(uid=0)
Dez 02 20:55:13 t14-mch CROND[22993]: pam_unix(crond:session): session closed for user root
Dez 02 20:56:00 t14-mch crond[25707]: pam_unix(crond:session): session opened for user root(uid=0) by root(uid=0)
Dez 02 20:56:15 t14-mch CROND[24971]: pam_unix(crond:session): session closed for user root
Dez 02 20:57:00 t14-mch crond[25898]: pam_unix(crond:session): session opened for user root(uid=0) by root(uid=0)
Dez 02 20:57:16 t14-mch CROND[25470]: pam_unix(crond:session): session closed for user root
Dez 02 20:58:00 t14-mch crond[26086]: pam_unix(crond:session): session opened for user root(uid=0) by root(uid=0)
Dez 02 20:58:13 t14-mch CROND[25707]: pam_unix(crond:session): session closed for user root
Dez 02 20:59:00 t14-mch crond[26278]: pam_unix(crond:session): session opened for user root(uid=0) by root(uid=0)
Dez 02 20:59:07 t14-mch lightdm[26386]: pam_unix(lightdm-greeter:session): session opened for user lightdm(uid=966) by (uid=0)
Dez 02 20:59:07 t14-mch (systemd)[26417]: pam_warn(systemd-user:setcred): function=[pam_sm_setcred] flags=0x8002 service=[systemd-user] terminal=[] user=[lightdm] ruser=[<unknown>] rhost=[<unknown>]
Dez 02 20:59:07 t14-mch (systemd)[26417]: pam_unix(systemd-user:session): session opened for user lightdm(uid=966) by lightdm(uid=0)
Dez 02 20:59:14 t14-mch sudo[26598]: pam_unix(sudo:session): session opened for user lightdm(uid=966) by (uid=0)
Dez 02 20:59:15 t14-mch CROND[25898]: pam_unix(crond:session): session closed for user root
Dez 02 20:59:15 t14-mch lightdm[26386]: pam_unix(lightdm-greeter:session): session closed for user lightdm
Dez 02 20:59:16 t14-mch sudo[26804]: pam_unix(sudo:session): session opened for user matthias(uid=1000) by (uid=0)
Dez 02 20:59:17 t14-mch cinnamon-screensaver-pam-helper[26303]: pam_unix(cinnamon:auth): conversation failed
Dez 02 20:59:17 t14-mch cinnamon-screensaver-pam-helper[26303]: pam_unix(cinnamon:auth): auth could not identify password for [matthias]
Dez 02 20:59:26 t14-mch (sd-pam)[26421]: pam_unix(systemd-user:session): session closed for user lightdm
Dez 02 20:59:56 t14-mch lightdm[27566]: pam_unix(lightdm-greeter:session): session opened for user lightdm(uid=966) by (uid=0)
Dez 02 20:59:56 t14-mch (systemd)[27593]: pam_warn(systemd-user:setcred): function=[pam_sm_setcred] flags=0x8002 service=[systemd-user] terminal=[] user=[lightdm] ruser=[<unknown>] rhost=[<unknown>]
Dez 02 20:59:56 t14-mch (systemd)[27593]: pam_unix(systemd-user:session): session opened for user lightdm(uid=966) by lightdm(uid=0)
Dez 02 21:00:00 t14-mch crond[27755]: pam_unix(crond:session): session opened for user root(uid=0) by root(uid=0)
Dez 02 21:00:00 t14-mch crond[27754]: pam_unix(crond:session): session opened for user matthias(uid=1000) by matthias(uid=0)
Dez 02 21:00:00 t14-mch CROND[27754]: pam_unix(crond:session): session closed for user matthias
Dez 02 21:00:03 t14-mch sudo[27814]: pam_unix(sudo:session): session opened for user lightdm(uid=966) by (uid=0)
Dez 02 21:00:16 t14-mch CROND[26086]: pam_unix(crond:session): session closed for user root
Dez 02 21:00:34 t14-mch lightdm[27733]: pam_unix(lightdm:auth): authentication failure; logname= uid=0 euid=0 tty=:1 ruser= rhost=  user=matthias
Dez 02 21:00:41 t14-mch lightdm[27566]: pam_unix(lightdm-greeter:session): session closed for user lightdm
Dez 02 21:00:42 t14-mch sudo[28169]: pam_unix(sudo:session): session opened for user matthias(uid=1000) by (uid=0)
Dez 02 21:00:43 t14-mch cinnamon-screensaver-pam-helper[27481]: pam_unix(cinnamon:auth): conversation failed
Dez 02 21:00:43 t14-mch cinnamon-screensaver-pam-helper[27481]: pam_unix(cinnamon:auth): auth could not identify password for [matthias]
Dez 02 21:00:52 t14-mch (sd-pam)[27595]: pam_unix(systemd-user:session): session closed for user lightdm
Dez 02 21:01:00 t14-mch crond[28384]: pam_unix(crond:session): session opened for user root(uid=0) by root(uid=0)
Dez 02 21:01:13 t14-mch CROND[26278]: pam_unix(crond:session): session closed for user root
Dez 02 21:02:00 t14-mch crond[30454]: pam_unix(crond:session): session opened for user root(uid=0) by root(uid=0)
Dez 02 21:02:15 t14-mch CROND[27755]: pam_unix(crond:session): session closed for user root
Dez 02 21:03:00 t14-mch crond[31116]: pam_unix(crond:session): session opened for user root(uid=0) by root(uid=0)
Dez 02 21:03:16 t14-mch CROND[28384]: pam_unix(crond:session): session closed for user root
Dez 02 21:04:00 t14-mch crond[31501]: pam_unix(crond:session): session opened for user root(uid=0) by root(uid=0)
Dez 02 21:04:14 t14-mch CROND[30454]: pam_unix(crond:session): session closed for user root
Dez 02 21:05:00 t14-mch crond[31999]: pam_unix(crond:session): session opened for user root(uid=0) by root(uid=0)
Dez 02 21:05:15 t14-mch CROND[31116]: pam_unix(crond:session): session closed for user root
Dez 02 21:06:00 t14-mch crond[32768]: pam_unix(crond:session): session opened for user root(uid=0) by root(uid=0)
Dez 02 21:06:17 t14-mch CROND[31501]: pam_unix(crond:session): session closed for user root
Dez 02 21:07:00 t14-mch crond[32990]: pam_unix(crond:session): session opened for user root(uid=0) by root(uid=0)
Dez 02 21:07:14 t14-mch CROND[31999]: pam_unix(crond:session): session closed for user root
Dez 02 21:08:00 t14-mch crond[33178]: pam_unix(crond:session): session opened for user root(uid=0) by root(uid=0)
Dez 02 21:08:15 t14-mch CROND[32768]: pam_unix(crond:session): session closed for user root
Dez 02 21:09:00 t14-mch crond[33366]: pam_unix(crond:session): session opened for user root(uid=0) by root(uid=0)
Dez 02 21:09:13 t14-mch CROND[32990]: pam_unix(crond:session): session closed for user root
Dez 02 21:10:00 t14-mch crond[33551]: pam_unix(crond:session): session opened for user root(uid=0) by root(uid=0)
Dez 02 21:10:14 t14-mch CROND[33178]: pam_unix(crond:session): session closed for user root
Dez 02 21:11:00 t14-mch crond[33741]: pam_unix(crond:session): session opened for user root(uid=0) by root(uid=0)
Dez 02 21:11:16 t14-mch CROND[33366]: pam_unix(crond:session): session closed for user root
Dez 02 21:12:00 t14-mch crond[33933]: pam_unix(crond:session): session opened for user root(uid=0) by root(uid=0)
Dez 02 21:12:13 t14-mch CROND[33551]: pam_unix(crond:session): session closed for user root
Dez 02 21:13:00 t14-mch crond[34207]: pam_unix(crond:session): session opened for user root(uid=0) by root(uid=0)
Dez 02 21:13:14 t14-mch CROND[33741]: pam_unix(crond:session): session closed for user root
Dez 02 21:14:00 t14-mch crond[34407]: pam_unix(crond:session): session opened for user root(uid=0) by root(uid=0)
Dez 02 21:14:16 t14-mch CROND[33933]: pam_unix(crond:session): session closed for user root
Dez 02 21:15:00 t14-mch crond[34612]: pam_unix(crond:session): session opened for user root(uid=0) by root(uid=0)
Dez 02 21:15:00 t14-mch crond[34611]: pam_unix(crond:session): session opened for user matthias(uid=1000) by matthias(uid=0)
Dez 02 21:15:00 t14-mch CROND[34611]: pam_unix(crond:session): session closed for user matthias
Dez 02 21:15:13 t14-mch CROND[34207]: pam_unix(crond:session): session closed for user root
Dez 02 21:16:00 t14-mch crond[34830]: pam_unix(crond:session): session opened for user root(uid=0) by root(uid=0)
Dez 02 21:16:15 t14-mch CROND[34407]: pam_unix(crond:session): session closed for user root
Dez 02 21:17:00 t14-mch crond[35026]: pam_unix(crond:session): session opened for user root(uid=0) by root(uid=0)
Dez 02 21:17:16 t14-mch CROND[34612]: pam_unix(crond:session): session closed for user root
Dez 02 21:18:00 t14-mch crond[35214]: pam_unix(crond:session): session opened for user root(uid=0) by root(uid=0)
Dez 02 21:18:13 t14-mch CROND[34830]: pam_unix(crond:session): session closed for user root
Dez 02 21:19:00 t14-mch crond[35404]: pam_unix(crond:session): session opened for user root(uid=0) by root(uid=0)
Dez 02 21:19:15 t14-mch CROND[35026]: pam_unix(crond:session): session closed for user root
Dez 02 21:20:00 t14-mch crond[35589]: pam_unix(crond:session): session opened for user root(uid=0) by root(uid=0)
Dez 02 21:20:16 t14-mch CROND[35214]: pam_unix(crond:session): session closed for user root

Thanks for helping!

P.S.: My gut feeling says the Linux Mint guys might have messed up the Cinnamon Screensaver again—there was a similar problem with PAM auth stacks a few years back, I seem to remember…

yes it is generally working fine it seems only the lockscreen / screensaver …

logs reveal: cinnamon-screensaver-pam-helper is failing with pam_unix(cinnamon:account): setuid failed: Die Operation ist nicht erlaubt

ls -l /usr/lib/cinnamon-screensaver/cinnamon-screensaver-pam-helper

If the file is not there, locate it with

find /usr -name cinnamon-screensaver-pam-helper

If the permissions show -rwxr-xr-x instead of -rwsr-xr-x (missing the s), restore the SUID bit:

sudo chmod u+s /usr/lib/cinnamon-screensaver/cinnamon-screensaver-pam-helper

or.. wait if package gets fixed

Hm, will try. It seems they had this problem a while back (not keeping the SUID bit in some debian packager). I tried that already, actually, and it didn’t help:

$ ls -la /usr/lib/cinnamon-screensaver/cinnamon-screensaver-pam-helper 
-rwsr-xr-x 1 root root 18656  8. Nov 18:45 /usr/lib/cinnamon-screensaver/cinnamon-screensaver-pam-helper
$ 
$ journalctl --since 21:40 --grep cinnamon

Dez 02 21:42:13 t14-mch cinnamon-screensaver-pam-helper[4256]: pam_unix(cinnamon:account): setuid failed: Die Operation ist nicht erlaubt

you rebooted?

Sure did :wink:

Interesting: There are two cinnamon-screensaver-pam-helper:

$ ls -la `locate cinnamon-screensaver-pam-helper`
-rwxr-xr-x 1 root root 30944 26. Nov 18:39 /usr/lib/cinnamon/cinnamon-screensaver-pam-helper
-rwxr-xr-x 1 root root 18656  8. Nov 18:45 /usr/lib/cinnamon-screensaver/cinnamon-screensaver-pam-helper
$

But adding the SUID bit to any/all of these doesn’t help either.

I seem to have read somewhere that the pam-helper would try to de-elevate itself if run elevated, which sounds correct—it shouldn’t need SUID, in my opinion. I’d still guess they don’t handle the pam module stack correctly but instead try to communicate with PAM in some “bad” way, maybe only asking for a PW check.

I think (but I’m not sure because I ignored the bug for a while and kept entering passwords all the time) it ran correctly up to and including v6.6.1 of cinnamon-screensaver, so maybe an old bug was re-introduced.

Unfortunately, I can’t downgrade cinnamon-screensaver alone because of too many deps.

I guess you answered in the other thread.

/etc/pam.d/cinnamon didn’t have a .pacnew, so I didn’t modify it. I’m unsure if it’d need the fprintd line? It’s currently:

#%PAM-1.0

# Fedora & Arch
-auth      sufficient   pam_selinux_permit.so
auth       include      system-auth
-auth       optional     pam_gnome_keyring.so
-auth       optional     pam_oo7.so
account    include      system-auth
password   include      system-auth
session    include      system-auth

# SuSE/Novell
#auth       include      common-auth
#auth       optional     pam_gnome_keyring.so
#account    include      common-account
#password   include      common-password
#session    include      common-session

Let me check my old instruction thread…

EDIT: Hmm. Seems I never added the fprint to /etc/pam.d/cinnamon, so maybe it wasn’t needed (I have it in system-local-login).

@joekamprad: Ha! You nailed it! For some reason I’ll have to investigate, /etc/pam.d/cinnamon now also needs the fprintd.so line:

$ cat /etc/pam.d/cinnamon
#%PAM-1.0

# Fedora & Arch
auth       sufficient   pam_fprintd.so
-auth      sufficient   pam_selinux_permit.so
auth       include      system-auth
-auth       optional     pam_gnome_keyring.so
-auth       optional     pam_oo7.so
account    include      system-auth
password   include      system-auth
session    include      system-auth

# SuSE/Novell
#auth       include      common-auth
#auth       optional     pam_gnome_keyring.so
#account    include      common-account
#password   include      common-password
#session    include      common-session
$ 

… and suddenly I get the fingerprint prompt (this time even translated—was in English before):

(and no SUID bit juggling on mysterious modules!)

Thanks ever so much for your help!

It now even works as set up originally: 3x wrong fingerprint, then prompt me for a password instead:

WON-DER-FUL! (Sometimes even small things can make me happy.)

Thanks @keescase for your help, too, and the extra info on oo7!