- (dtucker) [configure.ac session.c] Some platforms (eg some SCO) require

the username to be passed to the passwd command when changing expired
   passwords.  ok djm@
This commit is contained in:
Darren Tucker 2005-02-09 22:17:28 +11:00
parent c7e38d59e9
commit 33370e0287
3 changed files with 11 additions and 2 deletions

View File

@ -23,6 +23,9 @@
to resolve it for binaries other than sshd. ok djm@
- (dtucker) [configure.ac] Bug #854: prepend pwd to relative --with-ssl-dir
paths. ok djm@
- (dtucker) [configure.ac session.c] Some platforms (eg some SCO) require
the username to be passed to the passwd command when changing expired
passwords. ok djm@
20050208
- (dtucker) [regress/test-exec.sh] Bug #912: Set _POSIX2_VERSION for the
@ -2112,4 +2115,4 @@
- (djm) Trim deprecated options from INSTALL. Mention UsePAM
- (djm) Fix quote handling in sftp; Patch from admorten AT umich.edu
$Id: ChangeLog,v 1.3646 2005/02/09 11:12:30 dtucker Exp $
$Id: ChangeLog,v 1.3647 2005/02/09 11:17:28 dtucker Exp $

View File

@ -1,4 +1,4 @@
# $Id: configure.ac,v 1.238 2005/02/09 11:12:31 dtucker Exp $
# $Id: configure.ac,v 1.239 2005/02/09 11:17:28 dtucker Exp $
#
# Copyright (c) 1999-2004 Damien Miller
#
@ -403,6 +403,7 @@ mips-sony-bsd|mips-sony-newsos4)
AC_DEFINE(BROKEN_SETREGID)
AC_DEFINE(WITH_ABBREV_NO_TTY)
AC_DEFINE(BROKEN_UPDWTMPX)
AC_DEFINE(PASSWD_NEEDS_USERNAME, 1, [must supply username to passwd])
AC_CHECK_FUNCS(getluid setluid)
MANTYPE=man
TEST_SHELL=ksh

View File

@ -1346,7 +1346,12 @@ do_pwchange(Session *s)
if (s->ttyfd != -1) {
fprintf(stderr,
"You must change your password now and login again!\n");
#ifdef PASSWD_NEEDS_USERNAME
execl(_PATH_PASSWD_PROG, "passwd", s->pw->pw_name,
(char *)NULL);
#else
execl(_PATH_PASSWD_PROG, "passwd", (char *)NULL);
#endif
perror("passwd");
} else {
fprintf(stderr,