summaryrefslogtreecommitdiff
path: root/auth-passwd.c
diff options
context:
space:
mode:
authorDamien Miller <djm@mindrot.org>2000-09-16 15:39:56 +1100
committerDamien Miller <djm@mindrot.org>2000-09-16 15:39:56 +1100
commit606f880e0fd1a31f5beb3b37ece0c12317a9ed61 (patch)
treeb4afe2d6f8b77d73d309b3ed6ea2b89ad768d820 /auth-passwd.c
parente4340be5b3ff16f4d9ba5e3ea7e449dc1b6fa7a8 (diff)
- (djm) Shadow expiry check fix from Pavel Troller <patrol@omni.sinus.cz>
- (djm) Re-enable int64_t types - we need them for sftp - (djm) Use libexecdir from configure , rather than libexecdir/ssh - (djm) Update Redhat SPEC file accordingly - (djm) Add Kevin Steves <stevesk@sweden.hp.com> HP/UX contrib files - (djm) Add Charles Levert <charles@comm.polymtl.ca> getpgrp patch - (djm) Fix password auth on HP/UX 10.20. Patch from Dirk De Wachter <Dirk.DeWachter@rug.ac.be> - (djm) Fixprogs and entropy list fixes from Larry Jones <larry.jones@sdrc.com> - (djm) Fix for SuSE spec file from Takashi YOSHIDA <tyoshida@gemini.rc.kyushu-u.ac.jp>
Diffstat (limited to 'auth-passwd.c')
-rw-r--r--auth-passwd.c14
1 files changed, 11 insertions, 3 deletions
diff --git a/auth-passwd.c b/auth-passwd.c
index 27824165..055a0362 100644
--- a/auth-passwd.c
+++ b/auth-passwd.c
@@ -111,6 +111,9 @@ auth_password(struct passwd * pw, const char *password)
#ifdef HAVE_GETPWANAM
struct passwd_adjunct *spw;
#endif
+# ifdef HAVE_HPUX_TRUSTED_SYSTEM_PW
+ struct pr_passwd *prpw;
+#endif
#ifdef WITH_AIXAUTHENTICATE
char *authmsg;
char *loginmsg;
@@ -167,12 +170,17 @@ auth_password(struct passwd * pw, const char *password)
}
#endif
+# ifdef HAVE_HPUX_TRUSTED_SYSTEM_PW
+ prpw = getprpwnam(pw->pw_name);
+ pw_password = prpw->ufld.fd_encrypt;
+#else
+ pw_password = pw->pw_passwd;
+#endif
+
/* Check for users with no password. */
- if (strcmp(password, "") == 0 && strcmp(pw->pw_passwd, "") == 0)
+ if (strcmp(password, "") == 0 && strcmp(pw_password, "") == 0)
return 1;
- pw_password = pw->pw_passwd;
-
#if defined(HAVE_SHADOW_H) && !defined(DISABLE_SHADOW)
spw = getspnam(pw->pw_name);
if (spw != NULL)