You are not logged in.

#1 2013-12-03 08:16:31

AndreasEr
Member
Registered: 2013-12-03
Posts: 17

pam_usb authentication issue

Hello.

I've been trying to get pam_usb authentication working with a usb drive but i've run into some issues.
I've been following this documentation : https://github.com/aluzzardi/pam_usb/wi … ng-Started

The pam check gives no errors and tells me everything is alright (i've tried boht root and regular user, no error messages):

[andreas@arch-linux ~]$ pamusb-check andreas
* Authentication request for user "andreas" (pamusb-check)
[src/local.c:037] Checking whether the caller is local or not...
[src/local.c:046] Authentication request from tty pts/0
[src/local.c:054] No utmp entry found for tty "pts/0"
[src/device.c:057] Connecting to HAL...
[src/device.c:034] Searching for "usbauth" in the hardware database...
* Device "usbauth" is connected (good).
* Performing one time pad verification...
[src/volume.c:100] Searching for volume with uuid 22C7-B8B1
[src/volume.c:128] Found volume 22C7-B8B1
[src/volume.c:085] Device /org/freedesktop/UDisks/devices/sdb1 is mounted on /run/media/andreas/22C7-B8B1
[src/volume.c:132] Volume is already mounted.
[src/pad.c:234] Loading device pad...
[src/pad.c:236] Loading system pad...
[src/pad.c:242] Pad match.
[src/pad.c:140] Checking whether pads are expired or not...
[src/pad.c:170] Pads were generated 2068 seconds ago, not updating.
* Access granted.

The documentation is telling me to set up the module in /etc/pam.d/common-auth which does not exist. But i figured it might have changed to /etc/pam.d/system-auth? So i made the changes there ..

#%PAM-1.0

auth    sufficient      pam_usb.so
auth    required        pam_unix.so nullok_secure
auth      optional  pam_permit.so
auth      required  pam_env.so

account   required  pam_unix.so
account   optional  pam_permit.so
account   required  pam_time.so

password  required  pam_unix.so     try_first_pass nullok sha512 shadow
password  optional  pam_permit.so

session   required  pam_limits.so
session   required  pam_unix.so
session   optional  pam_permit.so

I've tried both sufficient and required for pam_usb.so
Now to my issue, when i try to run "su" it still only asks me for my password and it doesent realy seams to work out. Does anyone have any idea how i can solve this? I'm a brand new arch (and linux) user. Thanks.

Last edited by AndreasEr (2013-12-03 08:34:11)

Offline

#2 2013-12-03 08:43:44

AndreasEr
Member
Registered: 2013-12-03
Posts: 17

Re: pam_usb authentication issue

Wow, and of course i figured it out right when i've made the post. I had to make the changes in /etc/pam.d/su too.

Offline

Board footer

Powered by FluxBB