summaryrefslogtreecommitdiff
path: root/usr.bin/ssh/auth2-none.c
diff options
context:
space:
mode:
authorMarkus Friedl <markus@cvs.openbsd.org>2003-07-31 09:21:03 +0000
committerMarkus Friedl <markus@cvs.openbsd.org>2003-07-31 09:21:03 +0000
commit53cf0add15f57ea8a3fb082687b333e745c835ce (patch)
treeb0d63c3dffbab655530c1c0125557462e0589572 /usr.bin/ssh/auth2-none.c
parent841e39c7e814589e16825a80ccb3368b95a020a1 (diff)
check whether passwd auth is allowd, similar to proto 1; rob@pitman.co.za
ok henning
Diffstat (limited to 'usr.bin/ssh/auth2-none.c')
-rw-r--r--usr.bin/ssh/auth2-none.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/usr.bin/ssh/auth2-none.c b/usr.bin/ssh/auth2-none.c
index d54d5173fa5..1b557b96c24 100644
--- a/usr.bin/ssh/auth2-none.c
+++ b/usr.bin/ssh/auth2-none.c
@@ -23,7 +23,7 @@
*/
#include "includes.h"
-RCSID("$OpenBSD: auth2-none.c,v 1.4 2002/06/27 10:35:47 deraadt Exp $");
+RCSID("$OpenBSD: auth2-none.c,v 1.5 2003/07/31 09:21:02 markus Exp $");
#include "auth.h"
#include "xmalloc.h"
@@ -96,7 +96,9 @@ userauth_none(Authctxt *authctxt)
none_enabled = 0;
packet_check_eom();
userauth_banner();
- return (authctxt->valid ? PRIVSEP(auth_password(authctxt, "")) : 0);
+ if (options.password_authentication && authctxt->valid)
+ return (PRIVSEP(auth_password(authctxt, "")));
+ return (0);
}
Authmethod method_none = {