I have written a PAM
module that is intended to authenticate against a local database. It's
very simple. It calls pam_get_user() to retrieve the username and then
calls pam_get_item() to retrieve the password as follows:
const char
*pass = NULL;
int st =
pam_get_item(pamh, PAM_AUTHTOK, (const void **) &pass);
I set up my
/etc/pam.d/login file to call my pam module in place of pam_unix.so and test
using telnet with a PAM-aware telnetd. Telnet only asks for my username,
and never asks for the password. So it's no surprise that when I look at
my debug log output, pam_get_user() succeeds and returns the correct username,
but although pam_get_item() returns a success status, the 'pass' parameter
comes back NULL.
Does anyone have any
ideas as to why I would not be asked for my password when I supply my custom
module in place of the pam_unix.so (note that the pam_unix.so module worked
fine)?
Any help would be
much appreciated!
Thanks,
Dan Lanz
DISCLAIMER: The information contained in this e-mail is confidential and is intended solely for the review of the named addressee, and in conjunction with specific Acopia Networks business. Any review, retransmission, dissemination or other use of, or taking of any action in reliance upon, this information by persons or entities other than the intended recipient is prohibited. If you are unable to treat this information accordingly, or are not the intended recipient, please notify us immediately by returning the e-mail to the originator.