Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Display PAM messages #286

Closed
DamienCassou opened this issue Aug 29, 2020 · 7 comments
Closed

Display PAM messages #286

DamienCassou opened this issue Aug 29, 2020 · 7 comments

Comments

@DamienCassou
Copy link

I'm submitting a…

[x] Bug
[ ] Feature Request
[ ] Other (Please describe in detail)

Current Behavior

When I install i3lock from nixpkgs on Debian (or another non-NixOS distribution), after the screen is locked, my password is not accepted.

Expected Behavior

When I type my password, it is accepted.

Reproduction Instructions

  1. install Debian (or another non-NixOS Linux distribution)
  2. install i3lock from nixpkgs
  3. run i3lock
  4. type your password

Expected: my computer being unlocked
Actual: a failed attempt

Other face the same problem: https://gist.github.com/rossabaker/f6e5e89fd7423e1c0730fcd950c0cd33.

Workaround: Install i3lock from Debian instead of Nixpkgs.

If you believe there is nothing for you to fix, I would at least appreciate an error message on the lock screen giving the reason why i3lock is failing.

Environment

Output of i3lock --version:

i3lock version: 2.11.1
@kpcyrd
Copy link

kpcyrd commented Aug 29, 2020

I'm not sure if there's anything i3lock can do on systems with a broken pam setup. Installing nix in debian seems to result in a (partially) broken system.

@stapelberg stapelberg changed the title Incompatibilty between nixpkgs and non-NixOS systems Display PAM messages Aug 30, 2020
@stapelberg
Copy link
Member

We could display PAM messages.

A reason why we aren’t already doing so is because it is not obvious how to implement the visual side of this.

I think a good first start might be to display rectangular boxes with text in them, with line wrapping for long messages. Think smart phone notifications. These could show up above (or below?) the unlock indicator.

@DamienCassou
Copy link
Author

DamienCassou commented Aug 30, 2020 via email

@smrqdt
Copy link

smrqdt commented Oct 8, 2020

I also have another use case for this: Arch Linux recently enabled pam_faillock by default which leads to a temporary 10 minutes account lock after 3 failed password attempts (by default). It took me some time to recognize this was the reason i3lock didn’t unlock after typing my password. I only understood after switching to an tty which shows a notice when trying to log in.

It would be very useful, if i3lock could show that notice too.

@yyy33
Copy link

yyy33 commented Jan 19, 2022

We could display PAM messages.

A reason why we aren’t already doing so is because it is not obvious how to implement the visual side of this.

I think a good first start might be to display rectangular boxes with text in them, with line wrapping for long messages. Think smart phone notifications. These could show up above (or below?) the unlock indicator.

After my ARCH system was updated, I could not unlock it normally if I entered the correct password. What information should I provide to rule out this error

❯ i3lock -v
i3lock: version 2.13.c.4 © 2010 Michael Stapelberg, © 2015 Cassandra Fox, © 2021 Raymond Li

@stapelberg
Copy link
Member

Please file a separate issue. Your problem sounds unrelated.

@stapelberg
Copy link
Member

I looked at implementing PAM messages (see #217 for an update), but it turns out that for this particular mis-configuration, PAM just logs an error to syslog and does not return a PAM message via its API.

I’m closing this issue because implementing support for PAM messages doesn’t help with this issue. If you’re interested in better PAM support for other reasons, follow #217

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants