Both SDDM and the lock screen (if that was what you meant) use system-auth. Most of the time system-auth and possibly sudo are the only files you would want to modify.
I use YubiKey and I'd like to use 2FA (password & challenge-response) for initial logins (via SDDM or console) but 1FA (Yubico OTP) for lock screen and sudo, so here's what I have in system-auth:
#!/usr/bin/env bash
CHK_USER="$1"
if [[ -z "$CHK_USER" ]]; then
CHK_USER="$PAM_USER"
fi
if [[ "$CHK_USER" =~ ^[0-9]+$ ]]; then
CHK_USER=`id -un "$CHK_USER"`
fi
if [[ -z `w -sh "$CHK_USER"` ]]; then
exit 1
else
exit 0
fi
So [success=2 default=ignore] means if isloggedin returns success, skip the following 2 lines and use pam_yubico.so id=xxx key=xxx for 1FA; otherwise silently ignore its result and proceed onto pam_unix.so and pam_yubico.so mode=challenge-response.
Back to your case, if you want your facial recognition only for lock screen, simply use my script and replace pam_yubico.so id=xxx key=xxx with yours.
It's a play of words.
愛情がズレた means 'love in the wrong place' and 'love has gone off the rails' at the same time, hence the blush becomes bruise in the image.
What about a write only USB stick https://github.com/agherzan/yubikey-full-disk-encryption
Joke aside I'm quite interested in secure boot + kernel lockdown, but my ZFS setup only makes it more difficult
Life's too short for Gentoo. But I'd probably still choose a Gentoo-based distro, e.g. Redcore Linux seems pretty decent.
Both SDDM and the lock screen (if that was what you meant) use
system-auth. Most of the timesystem-authand possiblysudoare the only files you would want to modify.I use YubiKey and I'd like to use 2FA (password & challenge-response) for initial logins (via SDDM or console) but 1FA (Yubico OTP) for lock screen and sudo, so here's what I have in
system-auth:btw
/usr/local/bin/isloggedin:So
[success=2 default=ignore]means ifisloggedinreturns success, skip the following 2 lines and usepam_yubico.so id=xxx key=xxxfor 1FA; otherwise silently ignore its result and proceed ontopam_unix.soandpam_yubico.so mode=challenge-response.Back to your case, if you want your facial recognition only for lock screen, simply use my script and replace
pam_yubico.so id=xxx key=xxxwith yours.What I have in my vimrc. I don't remember if macOS ships a built-in vim but if not those 2
finds can be merged I think.