hyprwm / hyprlock

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

Hitting enter with empty password hangs app #95

Closed odama626 closed 8 months ago

odama626 commented 9 months ago

it freezes on authenticating when hitting enter with an empty password

alba4k commented 8 months ago

what does /etc/pam.d/su contain?

TinBlock50 commented 8 months ago

@alba4k

The content of /etc/pam.d/su after the freeze is.

# Account management.
account required pam_unix.so # unix (order 10900)

# Authentication management.
auth sufficient pam_rootok.so # rootok (order 10200)
auth required pam_faillock.so # faillock (order 10400)
auth sufficient pam_unix.so likeauth try_first_pass # unix (order 11500)
auth required pam_deny.so # deny (order 12300)

# Password management.
password sufficient pam_unix.so nullok yescrypt # unix (order 10200)

# Session management.
session required pam_env.so conffile=/etc/pam/environment readenv=0 # env (order 10100)
session required pam_unix.so # unix (order 10200)
session optional pam_xauth.so systemuser=99 xauthpath=/nix/store/qwr03843lp6cgnixzd4pjijq7acc90mk-xauth-1.1.2/bin/xauth # xauth (order 12100)

Dangerous. Save you work before trying. To try it out for yourself, simply start Hyprlock and then click enter if the password is empty. The file /etc/pam.d/su can then be read in another tty. The Hyprland instance can only be reopened with a restart.

edit Can be unlocked with the following command in tty. Thanks @alba4k

killall -SIGUSR1 hyprlock

alba4k commented 8 months ago

killall -SIGUSR1 hyprlock

Does anything change if you try installing from the latest commit?

TinBlock50 commented 8 months ago

I did add Hyprlock to my flake.nix and configuration.nix. Now i can spam the enter key as often as i like and still unlock it with my Password. Thanks. And how do you add .nix formatted code in markdown? I could not get it to work. :)

b4shful commented 8 months ago

Not entirely sure this is fixed yet, however it should be covered by #138 and can be tracked there I think

fjueic commented 2 months ago

Not entirely sure this is fixed yet, however it should be covered by #138 and can be tracked there I think

happened today with me

i can't aggressively save my work everytime to prepare for it

i will try someother thing for sometime

b4shful commented 2 months ago

Not entirely sure this is fixed yet, however it should be covered by #138 and can be tracked there I think

happened today with me

i can't aggressively save my work everytime to prepare for it

i will try someother thing for sometime

@fjueic what's your /etc/pam.d/hyprlock file atm?

fjueic commented 2 months ago

@b4shful

IMG20240902203607.jpg

PaideiaDilemma commented 2 months ago

Can you please clarify the symptoms, maybe post some logs and system info?

The original issue description is very broad.

alba4k commented 2 months ago

@fjueic why would you have to save your work every time? sending SIGUSR1 to hyprlock from kdeconnect or from a separate tty will unlock safely

not sure if it will work in this scenario but should. waiting a bit for pam to do smth should also work

fjueic commented 2 months ago

@fjueic why would you have to save your work every time? sending SIGUSR1 to hyprlock from kdeconnect or from a separate tty will unlock safely

not sure if it will work in this scenario but should. waiting a bit for pam to do smth should also work

that works only if it didn't hang

wait I'm on the wrong issue(so dumb) my issue is that it hangs after I hit enter with the password in the field