Solved i3lock/xlock issues with PAM

MisterSlowly

New Member


Messages: 5

#1
I cannot log in after running i3lock or xlock.

I've tried modifying /etc/pam.d/other, /etc/pam.d/login, /etc/pam.d/i3lock, /usr/share/pam.d/i3lock.

Here is /etc/pam.d/i3lock, which I copied from /etc/pam.d/ssh:
Code:
# $FreeBSD: releng/11.2/etc/pam.d/sshd 197769 2009-10-05 09:28:54Z des $
#
# PAM configuration for the "sshd" service
#

# auth
auth            sufficient      pam_opie.so             no_warn no_fake_prompts
auth            requisite       pam_opieaccess.so       no_warn allow_local
#auth           sufficient      pam_krb5.so             no_warn try_first_pass
#auth           sufficient      pam_ssh.so              no_warn try_first_pass
auth            required        pam_unix.so             no_warn try_first_pass

# account
account         required        pam_nologin.so
#account        required        pam_krb5.so
account         required        pam_login_access.so
account         required        pam_unix.so

# session
#session        optional        pam_ssh.so              want_agent
session         required        pam_permit.so

# password
#password       sufficient      pam_krb5.so             no_warn try_first_pass
password        required        pam_unix.so             no_warn try_first_pass
 

k.jacker

Well-Known Member

Thanks: 231
Messages: 446

#2
It should work out of the box. I'd leave the PAM configuration alone.
Did you suspend you computer or is it just locked?
Does is work if you just run i3lock from the command line? Do you see the green circle and do you get feedback while typing?
 
OP
OP
MisterSlowly

MisterSlowly

New Member


Messages: 5

#3
I've only been running it manually from the command line.

i3lock responds to input, shows feedback, and otherwise seems to work correctly, other than not accepting a valid password for my account.
x11/xlockmore has the same issue. It looks like it works fine but I can't log in.
 

k.jacker

Well-Known Member

Thanks: 231
Messages: 446

#4
Do you use a foreign/none-english keyboard? Sounds like wrong keymap, Y and Z swapped and the like, depending on your password.
 
OP
OP
MisterSlowly

MisterSlowly

New Member


Messages: 5

#5
I'm using the keyboard on the Lenovo Thinkpad t430, just en_US locale.

Is there somewhere that I can ensure the locale or keymap for i3lock/xlock?

Note that I don't have this issue with x11/slock, which does not use PAM for authentication.
 

k.jacker

Well-Known Member

Thanks: 231
Messages: 446

#6
I would try to update i3lock and see if that helps.
It has always worked out of the box for me (I use it with XFCE though).

You could also try to run i3lock --debug from the command line.
That will echo your password to the console but you should be able to see if it actually gets the right input.
In case you can't quit from i3lock you might want to run something like sleep 20;pkill i3lock & before you start i3lock.
 

nihr43

Member

Thanks: 18
Messages: 45

#7
Sorry I don't have any advice for you, just here to say I run i3 and i3lock has always worked fine for me, from a command line or from dmenu. i've never had to mess with it.
 
Top