diff options
-rw-r--r-- | ChangeLog | 6 | ||||
-rw-r--r-- | auth-pam.c | 27 |
2 files changed, 20 insertions, 13 deletions
@@ -1,3 +1,7 @@ | |||
1 | 20040113 | ||
2 | - (dtucker) [auth-pam.c] Relocate struct pam_ctxt and prototypes. No | ||
3 | functional changes. | ||
4 | |||
1 | 20040108 | 5 | 20040108 |
2 | - (dtucker) [auth-pam.c defines.h] Bug #783: move __unused to defines.h and | 6 | - (dtucker) [auth-pam.c defines.h] Bug #783: move __unused to defines.h and |
3 | only define if not already. From des at freebsd.org. | 7 | only define if not already. From des at freebsd.org. |
@@ -1655,4 +1659,4 @@ | |||
1655 | - Fix sshd BindAddress and -b options for systems using fake-getaddrinfo. | 1659 | - Fix sshd BindAddress and -b options for systems using fake-getaddrinfo. |
1656 | Report from murple@murple.net, diagnosis from dtucker@zip.com.au | 1660 | Report from murple@murple.net, diagnosis from dtucker@zip.com.au |
1657 | 1661 | ||
1658 | $Id: ChangeLog,v 1.3165 2004/01/08 13:19:25 dtucker Exp $ | 1662 | $Id: ChangeLog,v 1.3166 2004/01/13 11:35:58 dtucker Exp $ |
diff --git a/auth-pam.c b/auth-pam.c index 5c77edb66..fe2ae7711 100644 --- a/auth-pam.c +++ b/auth-pam.c | |||
@@ -31,7 +31,7 @@ | |||
31 | 31 | ||
32 | /* Based on $FreeBSD: src/crypto/openssh/auth2-pam-freebsd.c,v 1.11 2003/03/31 13:48:18 des Exp $ */ | 32 | /* Based on $FreeBSD: src/crypto/openssh/auth2-pam-freebsd.c,v 1.11 2003/03/31 13:48:18 des Exp $ */ |
33 | #include "includes.h" | 33 | #include "includes.h" |
34 | RCSID("$Id: auth-pam.c,v 1.88 2004/01/08 12:32:04 dtucker Exp $"); | 34 | RCSID("$Id: auth-pam.c,v 1.89 2004/01/13 11:35:59 dtucker Exp $"); |
35 | 35 | ||
36 | #ifdef USE_PAM | 36 | #ifdef USE_PAM |
37 | #if defined(HAVE_SECURITY_PAM_APPL_H) | 37 | #if defined(HAVE_SECURITY_PAM_APPL_H) |
@@ -68,10 +68,23 @@ extern int compat20; | |||
68 | */ | 68 | */ |
69 | typedef pthread_t sp_pthread_t; | 69 | typedef pthread_t sp_pthread_t; |
70 | #else | 70 | #else |
71 | typedef pid_t sp_pthread_t; | ||
72 | #endif | ||
73 | |||
74 | struct pam_ctxt { | ||
75 | sp_pthread_t pam_thread; | ||
76 | int pam_psock; | ||
77 | int pam_csock; | ||
78 | int pam_done; | ||
79 | }; | ||
80 | |||
81 | static void sshpam_free_ctx(void *); | ||
82 | static struct pam_ctxt *cleanup_ctxt; | ||
83 | |||
84 | #ifndef USE_POSIX_THREADS | ||
71 | /* | 85 | /* |
72 | * Simulate threads with processes. | 86 | * Simulate threads with processes. |
73 | */ | 87 | */ |
74 | typedef pid_t sp_pthread_t; | ||
75 | 88 | ||
76 | static void | 89 | static void |
77 | pthread_exit(void *value __unused) | 90 | pthread_exit(void *value __unused) |
@@ -124,16 +137,6 @@ static int sshpam_cred_established = 0; | |||
124 | static int sshpam_account_status = -1; | 137 | static int sshpam_account_status = -1; |
125 | static char **sshpam_env = NULL; | 138 | static char **sshpam_env = NULL; |
126 | 139 | ||
127 | struct pam_ctxt { | ||
128 | sp_pthread_t pam_thread; | ||
129 | int pam_psock; | ||
130 | int pam_csock; | ||
131 | int pam_done; | ||
132 | }; | ||
133 | |||
134 | static void sshpam_free_ctx(void *); | ||
135 | static struct pam_ctxt *cleanup_ctxt; | ||
136 | |||
137 | /* Some PAM implementations don't implement this */ | 140 | /* Some PAM implementations don't implement this */ |
138 | #ifndef HAVE_PAM_GETENVLIST | 141 | #ifndef HAVE_PAM_GETENVLIST |
139 | static char ** | 142 | static char ** |