Simple PAM authentication code?

2005-09-30 Thread Brian J. McGovern
Could someone point me at a short, straight forward bit of code that validates a given username and password via PAM? I've tried writing a short app to make sure PAM is working the way I want to locally, but no matter how good the info, I'm getting an authentication denied, so I know I'm missing

Re: Simple PAM authentication code?

2005-09-30 Thread Rob Pitt
This is mostly taken from Linux Standards Base. Compile with -lpam - lpam_misc. HTH - RP #include security/pam_appl.h #include security/pam_misc.h #include stdio.h int main(int argc, char *argv[]) { static struct pam_conv conv; conv.conv = misc_conv; conv.appdata_ptr