passwd(1) and PAM

Jonathan McKeown jonathan+freebsd-hackers at hst.org.za
Mon Jul 30 17:57:02 UTC 2007


This seems to be almost a FAQ judging by the number of open/suspended PRs over 
several years, and the enquiry on this list back in March 2007 - but I 
haven't been able to find an answer yet.

Looking at /usr/src/usr.bin/passwd/passwd.c, it seems that passwd(1) was 
rewritten four years ago to use the PAM infrastructure (with options -l, -o 
and -y not actually doing anything any more).

It seems to be prevented from using, eg, pam_ldap, by the switch statement 
which uses constants defined in pam.h but commented there to be ``bogus''.

1. Is there any reason not to patch passwd.c locally, replacing the switch 
statement with printf and a single message?

2. When is this likely to make it into the official sources?

I'm in a mixed environment and looking at using LDAP for account information 
with pam_pgina for Windows users.

Oh, and if the answer is ``send a patch'', just let me know where!

Jonathan


More information about the freebsd-hackers mailing list