From 6d7b2cd1a32efa2a40c97361065d357a2e60b716 Mon Sep 17 00:00:00 2001 From: Damien Miller Date: Fri, 12 Nov 1999 15:19:27 +1100 Subject: - Merged yet more changes from OpenBSD CVS - [auth-rh-rsa.c auth-rhosts.c auth-rsa.c channels.c clientloop.c] [ssh.c ssh.h sshconnect.c sshd.c] make all access to options via 'extern Options options' and 'extern ServerOptions options' respectively; options are no longer passed as arguments: * make options handling more consistent * remove #include "readconf.h" from ssh.h * readconf.h is only included if necessary - [mpaux.c] clear temp buffer - [servconf.c] print _all_ bad options found in configfile --- auth-rsa.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'auth-rsa.c') diff --git a/auth-rsa.c b/auth-rsa.c index dc1ad81a..6968df58 100644 --- a/auth-rsa.c +++ b/auth-rsa.c @@ -17,7 +17,7 @@ validity of the host key. #include "config.h" #include "includes.h" -RCSID("$Id: auth-rsa.c,v 1.4 1999/11/08 05:15:55 damien Exp $"); +RCSID("$Id: auth-rsa.c,v 1.5 1999/11/12 04:19:27 damien Exp $"); #include "rsa.h" #include "packet.h" @@ -25,6 +25,7 @@ RCSID("$Id: auth-rsa.c,v 1.4 1999/11/08 05:15:55 damien Exp $"); #include "ssh.h" #include "mpaux.h" #include "uidswap.h" +#include "servconf.h" #ifdef HAVE_OPENSSL #include @@ -100,7 +101,6 @@ auth_rsa_challenge_dialog(unsigned int bits, BIGNUM *e, BIGNUM *n) len = BN_num_bytes(challenge); if (len <= 0 || len > 32) fatal("auth_rsa_challenge_dialog: bad challenge length %d", len); - memset(buf, 0, 32); BN_bn2bin(challenge, buf + 32 - len); MD5_Init(&md); @@ -136,8 +136,9 @@ auth_rsa_challenge_dialog(unsigned int bits, BIGNUM *e, BIGNUM *n) successful. This may exit if there is a serious protocol violation. */ int -auth_rsa(struct passwd *pw, BIGNUM *client_n, int strict_modes) +auth_rsa(struct passwd *pw, BIGNUM *client_n) { + extern ServerOptions options; char line[8192]; int authenticated; unsigned int bits; @@ -172,7 +173,7 @@ auth_rsa(struct passwd *pw, BIGNUM *client_n, int strict_modes) return 0; } - if (strict_modes) { + if (options.strict_modes) { int fail=0; char buf[1024]; /* Check open file in order to avoid open/stat races */ -- cgit v1.2.1