summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog1
-rw-r--r--acconfig.h3
-rw-r--r--auth-passwd.c20
-rw-r--r--bsd-login.c8
-rw-r--r--configure.in4
-rw-r--r--contrib/redhat/openssh.spec2
-rw-r--r--contrib/suse/openssh.spec2
7 files changed, 37 insertions, 3 deletions
diff --git a/ChangeLog b/ChangeLog
index 9f7f21c13..9ca51be28 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,6 +1,7 @@
120000520 120000520
2 - Xauth fix from Markus Friedl <markus.friedl@informatik.uni-erlangen.de> 2 - Xauth fix from Markus Friedl <markus.friedl@informatik.uni-erlangen.de>
3 - Don't touch utmp if USE_UTMPX defined 3 - Don't touch utmp if USE_UTMPX defined
4 - SunOS 4.x support from Todd C. Miller <Todd.Miller@courtesan.com>
4 5
520000518 620000518
6 - Include Andre Lucas' fixprogs script. Forgot to "cvs add" it yesterday 7 - Include Andre Lucas' fixprogs script. Forgot to "cvs add" it yesterday
diff --git a/acconfig.h b/acconfig.h
index b3e11fe9c..308919f90 100644
--- a/acconfig.h
+++ b/acconfig.h
@@ -102,6 +102,9 @@
102/* Define if you want have trusted HPUX */ 102/* Define if you want have trusted HPUX */
103#undef HAVE_HPUX_TRUSTED_SYSTEM_PW 103#undef HAVE_HPUX_TRUSTED_SYSTEM_PW
104 104
105/* Define if you have getpwanam(3) [SunOS 4.x] */
106#undef HAVE_GETPWANAM
107
105/* Defined if in_systm.h needs to be included with netinet/ip.h (HPUX - <sigh/>) */ 108/* Defined if in_systm.h needs to be included with netinet/ip.h (HPUX - <sigh/>) */
106#undef NEED_IN_SYSTM_H 109#undef NEED_IN_SYSTM_H
107 110
diff --git a/auth-passwd.c b/auth-passwd.c
index e64e65682..b27c5bae8 100644
--- a/auth-passwd.c
+++ b/auth-passwd.c
@@ -11,7 +11,7 @@
11 11
12#ifndef USE_PAM 12#ifndef USE_PAM
13 13
14RCSID("$Id: auth-passwd.c,v 1.19 2000/04/29 14:47:29 damien Exp $"); 14RCSID("$Id: auth-passwd.c,v 1.20 2000/05/20 05:03:00 damien Exp $");
15 15
16#include "packet.h" 16#include "packet.h"
17#include "ssh.h" 17#include "ssh.h"
@@ -28,6 +28,11 @@ RCSID("$Id: auth-passwd.c,v 1.19 2000/04/29 14:47:29 damien Exp $");
28#ifdef HAVE_SHADOW_H 28#ifdef HAVE_SHADOW_H
29# include <shadow.h> 29# include <shadow.h>
30#endif 30#endif
31#ifdef HAVE_GETPWANAM
32# include <sys/label.h>
33# include <sys/audit.h>
34# include <pwdadj.h>
35#endif
31#if defined(HAVE_MD5_PASSWORDS) && !defined(HAVE_MD5_CRYPT) 36#if defined(HAVE_MD5_PASSWORDS) && !defined(HAVE_MD5_CRYPT)
32# include "md5crypt.h" 37# include "md5crypt.h"
33#endif /* defined(HAVE_MD5_PASSWORDS) && !defined(HAVE_MD5_CRYPT) */ 38#endif /* defined(HAVE_MD5_PASSWORDS) && !defined(HAVE_MD5_CRYPT) */
@@ -46,6 +51,9 @@ auth_password(struct passwd * pw, const char *password)
46#ifdef HAVE_SHADOW_H 51#ifdef HAVE_SHADOW_H
47 struct spwd *spw; 52 struct spwd *spw;
48#endif 53#endif
54#ifdef HAVE_GETPWANAM
55 struct passwd_adjunct *spw;
56#endif
49#ifdef WITH_AIXAUTHENTICATE 57#ifdef WITH_AIXAUTHENTICATE
50 char *authmsg; 58 char *authmsg;
51 char *loginmsg; 59 char *loginmsg;
@@ -99,6 +107,16 @@ auth_password(struct passwd * pw, const char *password)
99 pw_password = spw->sp_pwdp; 107 pw_password = spw->sp_pwdp;
100 } 108 }
101#endif /* defined(HAVE_SHADOW_H) && !defined(DISABLE_SHADOW) */ 109#endif /* defined(HAVE_SHADOW_H) && !defined(DISABLE_SHADOW) */
110#if defined(HAVE_GETPWANAM) && !defined(DISABLE_SHADOW)
111 if (issecure() && (spw = getpwanam(pw->pw_name)) != NULL)
112 {
113 /* Check for users with no password. */
114 if (strcmp(password, "") == 0 && strcmp(spw->pwa_passwd, "") == 0)
115 return 1;
116
117 pw_password = spw->pwa_passwd;
118 }
119#endif /* defined(HAVE_GETPWANAM) && !defined(DISABLE_SHADOW) */
102 120
103 if (pw_password[0] != '\0') 121 if (pw_password[0] != '\0')
104 salt = pw_password; 122 salt = pw_password;
diff --git a/bsd-login.c b/bsd-login.c
index de49214c0..ecd5e05af 100644
--- a/bsd-login.c
+++ b/bsd-login.c
@@ -60,6 +60,7 @@ static char *rcsid = "$OpenBSD: login.c,v 1.5 1998/07/13 02:11:12 millert Exp $"
60#include <stdio.h> 60#include <stdio.h>
61#include <string.h> 61#include <string.h>
62 62
63#ifdef USER_PROCESS
63/* 64/*
64 * find first matching slot in utmp, or "-1" for none 65 * find first matching slot in utmp, or "-1" for none
65 * 66 *
@@ -95,6 +96,13 @@ struct utmp * utp;
95#endif 96#endif
96 return(-1); 97 return(-1);
97} 98}
99#else
100int find_tty_slot( utp )
101struct utmp * utp;
102{
103 return(ttyslot());
104}
105#endif
98 106
99#if defined(HAVE_UTMPX_H) && defined(USE_UTMPX) 107#if defined(HAVE_UTMPX_H) && defined(USE_UTMPX)
100void 108void
diff --git a/configure.in b/configure.in
index 43749046c..60036c7b4 100644
--- a/configure.in
+++ b/configure.in
@@ -110,6 +110,10 @@ case "$host" in
110 need_dash_r=1 110 need_dash_r=1
111 AC_DEFINE(USE_UTMPX) 111 AC_DEFINE(USE_UTMPX)
112 ;; 112 ;;
113*-*-sunos4*)
114 CFLAGS="$CFLAGS -DSUNOS4"
115 AC_CHECK_FUNCS(getpwanam)
116 ;;
113*-*-sysv*) 117*-*-sysv*)
114 CFLAGS="$CFLAGS -I/usr/local/include" 118 CFLAGS="$CFLAGS -I/usr/local/include"
115 LDFLAGS="$LDFLAGS -L/usr/local/lib" 119 LDFLAGS="$LDFLAGS -L/usr/local/lib"
diff --git a/contrib/redhat/openssh.spec b/contrib/redhat/openssh.spec
index 415719f1c..bd628db44 100644
--- a/contrib/redhat/openssh.spec
+++ b/contrib/redhat/openssh.spec
@@ -1,5 +1,5 @@
1# Version of OpenSSH 1# Version of OpenSSH
2%define oversion 2.1.0p1 2%define oversion 2.1.0p2
3 3
4# Version of ssh-askpass 4# Version of ssh-askpass
5%define aversion 1.0 5%define aversion 1.0
diff --git a/contrib/suse/openssh.spec b/contrib/suse/openssh.spec
index 69ab4bda8..4c745ac80 100644
--- a/contrib/suse/openssh.spec
+++ b/contrib/suse/openssh.spec
@@ -1,6 +1,6 @@
1Summary: OpenSSH, a free Secure Shell (SSH) implementation 1Summary: OpenSSH, a free Secure Shell (SSH) implementation
2Name: openssh 2Name: openssh
3Version: 2.1.0p1 3Version: 2.1.0p2
4URL: http://www.openssh.com/ 4URL: http://www.openssh.com/
5Release: 1 5Release: 1
6Source0: openssh-%{version}.tar.gz 6Source0: openssh-%{version}.tar.gz