- Fix password support on systems with a mixture of shadowed and

non-shadowed passwords (e.g. NIS). Report and fix from
   HARUYAMA Seigo <haruyama@nt.phys.s.u-tokyo.ac.jp>
This commit is contained in:
Damien Miller 1999-12-31 08:49:13 +11:00
parent 8bdeee25f8
commit 8eb0fd6d6f
2 changed files with 17 additions and 8 deletions

View File

@ -1,13 +1,22 @@
19991231
- Fix password support on systems with a mixture of shadowed and
non-shadowed passwords (e.g. NIS). Report and fix from
HARUYAMA Seigo <haruyama@nt.phys.s.u-tokyo.ac.jp>
19991230 19991230
- OpenBSD CVS updates: - OpenBSD CVS updates:
- [auth-passwd.c] - [auth-passwd.c]
check for NULL 1st check for NULL 1st
- Removed most of the pam code into its own file auth-pam.[ch]. This - Removed most of the pam code into its own file auth-pam.[ch]. This
cleaned up sshd.c up significantly. cleaned up sshd.c up significantly.
- PAM authentication was incorrectly interpreting
"PermitRootLogin without-password". Report from Matthias Andree
<ma@dt.e-technik.uni-dortmund.de
- Several other cleanups - Several other cleanups
- Merged Dante SOCKS support patch from David Rankin - Merged Dante SOCKS support patch from David Rankin
<drankin@bohemians.lexington.ky.us> <drankin@bohemians.lexington.ky.us>
- Updated documentation with ./configure options - Updated documentation with ./configure options
- Released 1.2.1pre23
19991229 19991229
- Applied another NetBSD portability patch from David Rankin - Applied another NetBSD portability patch from David Rankin

View File

@ -11,7 +11,7 @@
#ifndef USE_PAM #ifndef USE_PAM
RCSID("$Id: auth-passwd.c,v 1.13 1999/12/29 22:48:15 damien Exp $"); RCSID("$Id: auth-passwd.c,v 1.14 1999/12/30 21:49:13 damien Exp $");
#include "packet.h" #include "packet.h"
#include "ssh.h" #include "ssh.h"
@ -76,14 +76,14 @@ auth_password(struct passwd * pw, const char *password)
#if defined(HAVE_SHADOW_H) && !defined(DISABLE_SHADOW) #if defined(HAVE_SHADOW_H) && !defined(DISABLE_SHADOW)
spw = getspnam(pw->pw_name); spw = getspnam(pw->pw_name);
if (spw == NULL) if (spw != NULL)
return(0); {
/* Check for users with no password. */
if (strcmp(password, "") == 0 && strcmp(spw->sp_pwdp, "") == 0)
return 1;
/* Check for users with no password. */ pw_password = spw->sp_pwdp;
if (strcmp(password, "") == 0 && strcmp(spw->sp_pwdp, "") == 0) }
return 1;
pw_password = spw->sp_pwdp;
#endif /* defined(HAVE_SHADOW_H) && !defined(DISABLE_SHADOW) */ #endif /* defined(HAVE_SHADOW_H) && !defined(DISABLE_SHADOW) */
if (pw_password[0] != '\0') if (pw_password[0] != '\0')