mcdope/pam_usb

[Feature] Optional "wait for device" timer

Closed this issue · 3 comments

mcdope commented

Understood

Yes, this is not a bug report / support request

Text

Some pam clients autoselect an user, which starts the authentication request / chain. This was discovered in #211

Yes lightdm, I'm looking at you! wth...

If this happens while your device is not yet plugged it makes pam_usb fail - like intended when the device is not present.

To avoid this:

  • add new config option "wait_for_device_timeout", default value 0 = disabled
  • interpret option in seconds
  • change auth to call pam_info() with a info message
  • loop until device present or timeout reached, then act accordingly

I wonder if this could maybe solved with a service specific probe_timeout set?