2 * OpenSSH PAM authentication support.
11 #include <pwd.h> /* For struct passwd */
13 void start_pam(struct passwd *pw);
14 void finish_pam(void);
15 int auth_pam_password(struct passwd *pw, const char *password);
16 char **fetch_pam_environment(void);
17 int do_pam_account(char *username, char *remote_user);
18 void do_pam_session(char *username, const char *ttyname);
19 void do_pam_setcred(void);
20 void print_pam_messages(void);
21 int pam_password_change_required(void);
22 void do_pam_chauthtok(void);
24 struct inverted_pam_cookie {
25 int state; /* Which state have we reached? */
26 pid_t pid; /* PID of child process */
28 /* Only valid in state STATE_CONV */
29 int num_msg; /* Number of messages */
30 struct pam_message **msg; /* Message structures */
31 struct pam_response **resp; /* Response structures */
32 struct inverted_pam_userdata *userdata;
34 void ipam_free_cookie(struct inverted_pam_cookie *cookie);
35 struct inverted_pam_cookie *ipam_start_auth(const char *, const char *);
38 #endif /* AUTH_PAM_H */