hyprwm / hyprlock

Hyprland's GPU-accelerated screen locking utility
BSD 3-Clause "New" or "Revised" License
605 stars 52 forks source link

[Bug] pam_module not seems to work properly? #314

Closed rtgiskard closed 2 months ago

rtgiskard commented 2 months ago

hyprlock: 0.3.0.r18.g21226c12

I'm using 2fa for system-local-login, with greetd/regreet, it works well, but with hyprlock, the PAM PROMPT is always Password: even if set pam_module = greetd.

Here is my /etc/pam.d/system-local-login:

#%PAM-1.0

auth      include   hack_2fa

auth      include   system-login
account   include   system-login
password  include   system-login
session   include   system-login

the hack_2fa module:

# plugin 2fa: fallback to password login if 1st otp failed, or login with 2 level OTP
auth  [success=ok default=1] pam_google_authenticator.so ...
auth  [success=done default=die] pam_oath.so ...
rtgiskard commented 2 months ago

My mistake on configuring pam_google_auth, hyprlock failed to change user id for pam_google_auth