+/* $OpenBSD: auth2-passwd.c,v 1.7 2006/03/25 13:17:01 djm Exp $ */
/*
* Copyright (c) 2000 Markus Friedl. All rights reserved.
*
*/
#include "includes.h"
-RCSID("$OpenBSD: auth2-passwd.c,v 1.5 2003/12/31 00:24:50 dtucker Exp $");
#include "xmalloc.h"
#include "packet.h"
if (change)
logit("password change not supported");
- else if (PRIVSEP(auth_password(authctxt, password)) == 1
+ else if (PRIVSEP(auth_password(authctxt, password)) == 1)
+ authenticated = 1;
#ifdef HAVE_CYGWIN
- && check_nt_auth(1, authctxt->pw)
+ if (check_nt_auth(1, authctxt->pw) == 0)
+ authenticated = 0;
#endif
- )
- authenticated = 1;
memset(password, 0, len);
xfree(password);
return authenticated;