diff options
Diffstat (limited to 'auth1.c')
-rw-r--r-- | auth1.c | 10 |
1 files changed, 8 insertions, 2 deletions
@@ -92,7 +92,7 @@ do_authloop(Authctxt *authctxt) | |||
92 | #elif defined(HAVE_OSF_SIA) | 92 | #elif defined(HAVE_OSF_SIA) |
93 | 0) { | 93 | 0) { |
94 | #else | 94 | #else |
95 | auth_password(pw, "")) { | 95 | auth_password(authctxt, "")) { |
96 | #endif | 96 | #endif |
97 | auth_log(authctxt, 1, "without authentication", ""); | 97 | auth_log(authctxt, 1, "without authentication", ""); |
98 | return; | 98 | return; |
@@ -262,7 +262,7 @@ do_authloop(Authctxt *authctxt) | |||
262 | password); | 262 | password); |
263 | #else /* !USE_PAM && !HAVE_OSF_SIA */ | 263 | #else /* !USE_PAM && !HAVE_OSF_SIA */ |
264 | /* Try authentication with the password. */ | 264 | /* Try authentication with the password. */ |
265 | authenticated = auth_password(pw, password); | 265 | authenticated = auth_password(authctxt, password); |
266 | #endif /* USE_PAM */ | 266 | #endif /* USE_PAM */ |
267 | 267 | ||
268 | memset(password, 0, strlen(password)); | 268 | memset(password, 0, strlen(password)); |
@@ -303,6 +303,12 @@ do_authloop(Authctxt *authctxt) | |||
303 | log("Unknown message during authentication: type %d", type); | 303 | log("Unknown message during authentication: type %d", type); |
304 | break; | 304 | break; |
305 | } | 305 | } |
306 | #ifdef BSD_AUTH | ||
307 | if (authctxt->as) { | ||
308 | auth_close(authctxt->as); | ||
309 | authctxt->as = NULL; | ||
310 | } | ||
311 | #endif | ||
306 | if (!authctxt->valid && authenticated) | 312 | if (!authctxt->valid && authenticated) |
307 | fatal("INTERNAL ERROR: authenticated invalid user %s", | 313 | fatal("INTERNAL ERROR: authenticated invalid user %s", |
308 | authctxt->user); | 314 | authctxt->user); |