summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog7
-rw-r--r--auth.c8
-rw-r--r--configure.ac11
-rw-r--r--defines.h5
-rw-r--r--openbsd-compat/port-uw.c6
-rw-r--r--openbsd-compat/port-uw.h2
-rw-r--r--openbsd-compat/xcrypt.c2
-rw-r--r--session.c4
8 files changed, 28 insertions, 17 deletions
diff --git a/ChangeLog b/ChangeLog
index 7b23fc332..af88bbe1a 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
120070326
2 - (tim) [auth.c configure.ac defines.h session.c openbsd-compat/port-uw.c
3 openbsd-compat/port-uw.h openbsd-compat/xcrypt.c] Rework libiaf test/defines
4 to account for IRIX having libiaf but not set_id(). Patch with & ok dtucker@
5
120070325 620070325
2 - (dtucker) [Makefile.in configure.ac] Replace single-purpose LIBSELINUX, 7 - (dtucker) [Makefile.in configure.ac] Replace single-purpose LIBSELINUX,
3 LIBWRAP and LIBPAM variables in Makefile with the general-purpose 8 LIBWRAP and LIBPAM variables in Makefile with the general-purpose
@@ -2868,4 +2873,4 @@
2868 OpenServer 6 and add osr5bigcrypt support so when someone migrates 2873 OpenServer 6 and add osr5bigcrypt support so when someone migrates
2869 passwords between UnixWare and OpenServer they will still work. OK dtucker@ 2874 passwords between UnixWare and OpenServer they will still work. OK dtucker@
2870 2875
2871$Id: ChangeLog,v 1.4648 2007/03/25 08:26:01 dtucker Exp $ 2876$Id: ChangeLog,v 1.4649 2007/03/26 16:35:28 tim Exp $
diff --git a/auth.c b/auth.c
index 505102f8a..c1e0f4812 100644
--- a/auth.c
+++ b/auth.c
@@ -115,11 +115,11 @@ allowed_user(struct passwd * pw)
115 /* grab passwd field for locked account check */ 115 /* grab passwd field for locked account check */
116#ifdef USE_SHADOW 116#ifdef USE_SHADOW
117 if (spw != NULL) 117 if (spw != NULL)
118#if defined(HAVE_LIBIAF) && !defined(BROKEN_LIBIAF) 118#ifdef USE_LIBIAF
119 passwd = get_iaf_password(pw); 119 passwd = get_iaf_password(pw);
120#else 120#else
121 passwd = spw->sp_pwdp; 121 passwd = spw->sp_pwdp;
122#endif /* HAVE_LIBIAF && !BROKEN_LIBIAF */ 122#endif /* USE_LIBIAF */
123#else 123#else
124 passwd = pw->pw_passwd; 124 passwd = pw->pw_passwd;
125#endif 125#endif
@@ -141,9 +141,9 @@ allowed_user(struct passwd * pw)
141 if (strstr(passwd, LOCKED_PASSWD_SUBSTR)) 141 if (strstr(passwd, LOCKED_PASSWD_SUBSTR))
142 locked = 1; 142 locked = 1;
143#endif 143#endif
144#if defined(HAVE_LIBIAF) && !defined(BROKEN_LIBIAF) 144#ifdef USE_LIBIAF
145 free(passwd); 145 free(passwd);
146#endif /* HAVE_LIBIAF && !BROKEN_LIBIAF */ 146#endif /* USE_LIBIAF */
147 if (locked) { 147 if (locked) {
148 logit("User %.100s not allowed because account is locked", 148 logit("User %.100s not allowed because account is locked",
149 pw->pw_name); 149 pw->pw_name);
diff --git a/configure.ac b/configure.ac
index a2a988c7d..4413ae343 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,4 +1,4 @@
1# $Id: configure.ac,v 1.374 2007/03/25 08:26:01 dtucker Exp $ 1# $Id: configure.ac,v 1.375 2007/03/26 16:35:28 tim Exp $
2# 2#
3# Copyright (c) 1999-2004 Damien Miller 3# Copyright (c) 1999-2004 Damien Miller
4# 4#
@@ -15,7 +15,7 @@
15# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. 15# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
16 16
17AC_INIT(OpenSSH, Portable, openssh-unix-dev@mindrot.org) 17AC_INIT(OpenSSH, Portable, openssh-unix-dev@mindrot.org)
18AC_REVISION($Revision: 1.374 $) 18AC_REVISION($Revision: 1.375 $)
19AC_CONFIG_SRCDIR([ssh.c]) 19AC_CONFIG_SRCDIR([ssh.c])
20 20
21AC_CONFIG_HEADER(config.h) 21AC_CONFIG_HEADER(config.h)
@@ -1977,7 +1977,12 @@ fi
1977# Search for SHA256 support in libc and/or OpenSSL 1977# Search for SHA256 support in libc and/or OpenSSL
1978AC_CHECK_FUNCS(SHA256_Update EVP_sha256) 1978AC_CHECK_FUNCS(SHA256_Update EVP_sha256)
1979 1979
1980AC_CHECK_LIB(iaf, ia_openinfo) 1980saved_LIBS="$LIBS"
1981AC_CHECK_LIB(iaf, ia_openinfo, [
1982 LIBS="$LIBS -liaf"
1983 AC_CHECK_FUNCS(set_id, [SSHDLIBS="$SSHDLIBS -liaf"])
1984])
1985LIBS="$saved_LIBS"
1981 1986
1982### Configure cryptographic random number support 1987### Configure cryptographic random number support
1983 1988
diff --git a/defines.h b/defines.h
index 8a4e2c73e..1e3d68d17 100644
--- a/defines.h
+++ b/defines.h
@@ -25,7 +25,7 @@
25#ifndef _DEFINES_H 25#ifndef _DEFINES_H
26#define _DEFINES_H 26#define _DEFINES_H
27 27
28/* $Id: defines.h,v 1.138 2006/09/21 13:13:30 dtucker Exp $ */ 28/* $Id: defines.h,v 1.139 2007/03/26 16:35:28 tim Exp $ */
29 29
30 30
31/* Constants */ 31/* Constants */
@@ -696,7 +696,8 @@ struct winsize {
696# define CUSTOM_SYS_AUTH_PASSWD 1 696# define CUSTOM_SYS_AUTH_PASSWD 1
697#endif 697#endif
698 698
699#ifdef HAVE_LIBIAF 699#if defined(HAVE_LIBIAF) && defined(HAVE_SET_ID) && !defined(BROKEN_LIBIAF)
700# define USE_LIBIAF
700# define CUSTOM_SYS_AUTH_PASSWD 1 701# define CUSTOM_SYS_AUTH_PASSWD 1
701#endif 702#endif
702 703
diff --git a/openbsd-compat/port-uw.c b/openbsd-compat/port-uw.c
index 6f3523902..ebc229a6a 100644
--- a/openbsd-compat/port-uw.c
+++ b/openbsd-compat/port-uw.c
@@ -79,7 +79,7 @@ sys_auth_passwd(Authctxt *authctxt, const char *password)
79#endif /* UNIXWARE_LONG_PASSWORDS */ 79#endif /* UNIXWARE_LONG_PASSWORDS */
80 result = (strcmp(xcrypt(password, salt), pw_password) == 0); 80 result = (strcmp(xcrypt(password, salt), pw_password) == 0);
81 81
82#if !defined(BROKEN_LIBIAF) 82#ifdef USE_LIBIAF
83 if (authctxt->valid) 83 if (authctxt->valid)
84 free(pw_password); 84 free(pw_password);
85#endif 85#endif
@@ -127,7 +127,7 @@ nischeck(char *namep)
127 functions that call shadow_pw() will need to free 127 functions that call shadow_pw() will need to free
128 */ 128 */
129 129
130#if !defined(BROKEN_LIBIAF) 130#ifdef USE_LIBIAF
131char * 131char *
132get_iaf_password(struct passwd *pw) 132get_iaf_password(struct passwd *pw)
133{ 133{
@@ -144,6 +144,6 @@ get_iaf_password(struct passwd *pw)
144 else 144 else
145 fatal("ia_openinfo: Unable to open the shadow passwd file"); 145 fatal("ia_openinfo: Unable to open the shadow passwd file");
146} 146}
147#endif /* !BROKEN_LIBIAF */ 147#endif /* USE_LIBIAF */
148#endif /* HAVE_LIBIAF */ 148#endif /* HAVE_LIBIAF */
149 149
diff --git a/openbsd-compat/port-uw.h b/openbsd-compat/port-uw.h
index 3589b2e44..263d8b5a7 100644
--- a/openbsd-compat/port-uw.h
+++ b/openbsd-compat/port-uw.h
@@ -24,7 +24,7 @@
24 24
25#include "includes.h" 25#include "includes.h"
26 26
27#if defined(HAVE_LIBIAF) && !defined(BROKEN_LIBIAF) 27#ifdef USE_LIBIAF
28char * get_iaf_password(struct passwd *pw); 28char * get_iaf_password(struct passwd *pw);
29#endif 29#endif
30 30
diff --git a/openbsd-compat/xcrypt.c b/openbsd-compat/xcrypt.c
index 14899321f..d8636bb39 100644
--- a/openbsd-compat/xcrypt.c
+++ b/openbsd-compat/xcrypt.c
@@ -98,7 +98,7 @@ shadow_pw(struct passwd *pw)
98 pw_password = spw->sp_pwdp; 98 pw_password = spw->sp_pwdp;
99# endif 99# endif
100 100
101#if defined(HAVE_LIBIAF) && !defined(BROKEN_LIBIAF) 101#ifdef USE_LIBIAF
102 return(get_iaf_password(pw)); 102 return(get_iaf_password(pw));
103#endif 103#endif
104 104
diff --git a/session.c b/session.c
index 4c97c4a7d..32e592adb 100644
--- a/session.c
+++ b/session.c
@@ -1361,11 +1361,11 @@ do_setusercontext(struct passwd *pw)
1361# ifdef _AIX 1361# ifdef _AIX
1362 aix_usrinfo(pw); 1362 aix_usrinfo(pw);
1363# endif /* _AIX */ 1363# endif /* _AIX */
1364#if defined(HAVE_LIBIAF) && !defined(BROKEN_LIBIAF) 1364#ifdef USE_LIBIAF
1365 if (set_id(pw->pw_name) != 0) { 1365 if (set_id(pw->pw_name) != 0) {
1366 exit(1); 1366 exit(1);
1367 } 1367 }
1368#endif /* HAVE_LIBIAF && !BROKEN_LIBIAF */ 1368#endif /* USE_LIBIAF */
1369 /* Permanently switch to the desired uid. */ 1369 /* Permanently switch to the desired uid. */
1370 permanently_set_uid(pw); 1370 permanently_set_uid(pw);
1371#endif 1371#endif