X-Git-Url: http://andersk.mit.edu/gitweb/openssh.git/blobdiff_plain/ed81415f003a45e54d9a23e938b3107cbd6a51b4..HEAD:/auth-passwd.c diff --git a/auth-passwd.c b/auth-passwd.c index 654e0b82..b1c6ce09 100644 --- a/auth-passwd.c +++ b/auth-passwd.c @@ -1,3 +1,4 @@ +/* $OpenBSD: auth-passwd.c,v 1.43 2007/09/21 08:15:29 djm Exp $ */ /* * Author: Tatu Ylonen * Copyright (c) 1995 Tatu Ylonen , Espoo, Finland @@ -36,12 +37,20 @@ */ #include "includes.h" -RCSID("$OpenBSD: auth-passwd.c,v 1.33 2005/01/24 11:47:13 dtucker Exp $"); + +#include + +#include +#include +#include +#include #include "packet.h" #include "buffer.h" #include "log.h" #include "servconf.h" +#include "key.h" +#include "hostfile.h" #include "auth.h" #include "auth-options.h" @@ -93,7 +102,7 @@ auth_password(Authctxt *authctxt, const char *password) } #endif #ifdef HAVE_CYGWIN - if (is_winnt) { + { HANDLE hToken = cygwin_logon_user(pw, password); if (hToken == INVALID_HANDLE_VALUE) @@ -163,6 +172,8 @@ sys_auth_passwd(Authctxt *authctxt, const char *password) as = auth_usercheck(pw->pw_name, authctxt->style, "auth-ssh", (char *)password); + if (as == NULL) + return (0); if (auth_getstate(as) & AUTH_PWEXPIRED) { auth_close(as); disable_forwarding();