summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDarren Tucker <dtucker@zip.com.au>2005-02-09 17:08:23 +1100
committerDarren Tucker <dtucker@zip.com.au>2005-02-09 17:08:23 +1100
commit92170a862634bf9ebe958cc75911658d18e30538 (patch)
tree397fc75d254e3227db28dc532527179f21645acb
parent96d4710e3838af8c03a55ce37913568877dd0283 (diff)
- (dtucker) [auth-passwd.c openbsd-compat/port-aix.c] Don't call
disable_forwarding() from compat library. Prevent linker errrors trying to resolve it for binaries other than sshd. ok djm@
-rw-r--r--ChangeLog7
-rw-r--r--auth-passwd.c12
-rw-r--r--openbsd-compat/port-aix.c1
3 files changed, 12 insertions, 8 deletions
diff --git a/ChangeLog b/ChangeLog
index 98cdf96aa..633d70c36 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -18,6 +18,11 @@
18 - dtucker@cvs.openbsd.org 2005/02/08 22:24:57 18 - dtucker@cvs.openbsd.org 2005/02/08 22:24:57
19 [sshd.c] 19 [sshd.c]
20 Provide reason in error message if getnameinfo fails; ok markus@ 20 Provide reason in error message if getnameinfo fails; ok markus@
21 - (dtucker) [auth-passwd.c openbsd-compat/port-aix.c] Don't call
22 disable_forwarding() from compat library. Prevent linker errrors trying
23 to resolve it for binaries other than sshd. ok djm@
24
25 when
21 26
2220050208 2720050208
23 - (dtucker) [regress/test-exec.sh] Bug #912: Set _POSIX2_VERSION for the 28 - (dtucker) [regress/test-exec.sh] Bug #912: Set _POSIX2_VERSION for the
@@ -2107,4 +2112,4 @@
2107 - (djm) Trim deprecated options from INSTALL. Mention UsePAM 2112 - (djm) Trim deprecated options from INSTALL. Mention UsePAM
2108 - (djm) Fix quote handling in sftp; Patch from admorten AT umich.edu 2113 - (djm) Fix quote handling in sftp; Patch from admorten AT umich.edu
2109 2114
2110$Id: ChangeLog,v 1.3644 2005/02/08 22:53:48 dtucker Exp $ 2115$Id: ChangeLog,v 1.3645 2005/02/09 06:08:23 dtucker Exp $
diff --git a/auth-passwd.c b/auth-passwd.c
index fb14f5ce4..27ece3f72 100644
--- a/auth-passwd.c
+++ b/auth-passwd.c
@@ -73,7 +73,7 @@ int
73auth_password(Authctxt *authctxt, const char *password) 73auth_password(Authctxt *authctxt, const char *password)
74{ 74{
75 struct passwd * pw = authctxt->pw; 75 struct passwd * pw = authctxt->pw;
76 int ok = authctxt->valid; 76 int result, ok = authctxt->valid;
77#if defined(USE_SHADOW) && defined(HAS_SHADOW_EXPIRE) 77#if defined(USE_SHADOW) && defined(HAS_SHADOW_EXPIRE)
78 static int expire_checked = 0; 78 static int expire_checked = 0;
79#endif 79#endif
@@ -110,14 +110,14 @@ auth_password(Authctxt *authctxt, const char *password)
110#if defined(USE_SHADOW) && defined(HAS_SHADOW_EXPIRE) 110#if defined(USE_SHADOW) && defined(HAS_SHADOW_EXPIRE)
111 if (!expire_checked) { 111 if (!expire_checked) {
112 expire_checked = 1; 112 expire_checked = 1;
113 if (auth_shadow_pwexpired(authctxt)) { 113 if (auth_shadow_pwexpired(authctxt))
114 disable_forwarding();
115 authctxt->force_pwchange = 1; 114 authctxt->force_pwchange = 1;
116 }
117 } 115 }
118#endif 116#endif
119 117 result = sys_auth_passwd(authctxt, password);
120 return (sys_auth_passwd(authctxt, password) && ok); 118 if (authctxt->force_pwchange)
119 disable_forwarding();
120 return (result && ok);
121} 121}
122 122
123#ifdef BSD_AUTH 123#ifdef BSD_AUTH
diff --git a/openbsd-compat/port-aix.c b/openbsd-compat/port-aix.c
index 27ab06158..b16988543 100644
--- a/openbsd-compat/port-aix.c
+++ b/openbsd-compat/port-aix.c
@@ -196,7 +196,6 @@ sys_auth_passwd(Authctxt *ctxt, const char *password)
196 break; 196 break;
197 case 1: /* expired, password change required */ 197 case 1: /* expired, password change required */
198 ctxt->force_pwchange = 1; 198 ctxt->force_pwchange = 1;
199 disable_forwarding();
200 break; 199 break;
201 default: /* user can't change(2) or other error (-1) */ 200 default: /* user can't change(2) or other error (-1) */
202 logit("Password can't be changed for user %s: %.100s", 201 logit("Password can't be changed for user %s: %.100s",