1 /* pam_winbind header file
2 (Solaris needs some macros from Linux for common PAM code)
16 #include <sys/types.h>
23 #define MODULE_NAME "pam_winbind"
25 #define PAM_SM_ACCOUNT
26 #define PAM_SM_PASSWORD
28 #if defined(SUNOS5) || defined(SUNOS4)
30 /* Solaris always uses dynamic pam modules */
31 #define PAM_EXTERN extern
32 #include <security/pam_appl.h>
34 #define PAM_AUTHTOK_RECOVER_ERR PAM_AUTHTOK_RECOVERY_ERR
37 #ifdef HAVE_SECURITY_PAM_MODULES_H
38 #include <security/pam_modules.h>
41 #ifdef HAVE_SECURITY__PAM_MACROS_H
42 #include <security/_pam_macros.h>
44 /* Define required macros from (Linux PAM 0.68) security/_pam_macros.h */
45 #define _pam_drop_reply(/* struct pam_response * */ reply, /* int */ replies) \
49 for (reply_i=0; reply_i<replies; ++reply_i) { \
50 if (reply[reply_i].resp) { \
51 _pam_overwrite(reply[reply_i].resp); \
52 free(reply[reply_i].resp); \
59 #define _pam_overwrite(x) \
61 register char *__xx__; \
68 * Don't just free it, forget it too.
71 #define _pam_drop(X) SAFE_FREE(X)
73 #define x_strdup(s) ( (s) ? strdup(s):NULL )
76 #define PAM_DEBUG_ARG (1<<0)
77 #define PAM_USE_AUTHTOK_ARG (1<<1)
78 #define PAM_UNKNOWN_OK_ARG (1<<2)
80 #include "winbind_nss_config.h"
81 #include "winbindd_nss.h"