diff --git a/CREDITS b/CREDITS index f0be1263b..ac992e300 100644 --- a/CREDITS +++ b/CREDITS @@ -4,7 +4,7 @@ Aaron Campbell, Bob Beck, Markus Friedl, Niels Provos, Theo de Raadt, and Dug Song - Creators of OpenSSH Andrew Stribblehill - Bugfixes -Andre Lucas - Many portability fixes +Andre Lucas - build, login and many other fixes Ben Taylor - Solaris debugging and fixes Chip Salzenberg - Assorted patches Chris Saia - SuSE packaging diff --git a/ChangeLog b/ChangeLog index 259f7d8e2..14005e7aa 100644 --- a/ChangeLog +++ b/ChangeLog @@ -6,15 +6,19 @@ - [sshconnect.c] - disable agent fwding for proto 1.3, remove abuse of auth-rsa flags. - destroy keys earlier - - split key exchange (kex) and user authentication (user-auth), ok: provos@ + - split key exchange (kex) and user authentication (user-auth), + ok: provos@ - [sshd.c] - no need for poll.h; from bright@wintelcom.net - disable agent fwding for proto 1.3, remove abuse of auth-rsa flags. - - split key exchange (kex) and user authentication (user-auth), ok: provos@ + - split key exchange (kex) and user authentication (user-auth), + ok: provos@ - Big manpage and config file cleanup from Andre Lucas - Re-added latest (unmodified) OpenBSD manpages - Doc updates + - NetBSD patch from David Rankin and + Christos Zoulas 20000119 - SCO compile fixes from Gary E. Miller diff --git a/configure.in b/configure.in index 90ed2bb80..4158b99b2 100644 --- a/configure.in +++ b/configure.in @@ -51,6 +51,31 @@ if test "$GCC" = "yes"; then CFLAGS="$CFLAGS -Wall"; fi AC_C_INLINE +dnl Check for OpenSSL/SSLeay directories. +AC_MSG_CHECKING([for OpenSSL/SSLeay directory]) +for ssldir in $prefix /usr /usr/local/openssl /usr/lib/openssl /usr/local/ssl /usr/lib/ssl /usr/local $prefix /usr/pkg ; do + if test -f "$ssldir/include/openssl/crypto.h"; then + AC_DEFINE(HAVE_OPENSSL) + GOT_SSL="yes" + break + fi + if test -f "$ssldir/include/ssl/crypto.h"; then + AC_DEFINE(HAVE_SSL) + GOT_SSL="yes" + break + fi +done +if test -z "$GOT_SSL" ; then + AC_MSG_ERROR([Could not find SSLeay / OpenSSL libraries, please install]) +fi +AC_SUBST(ssldir) +AC_DEFINE_UNQUOTED(ssldir, "$ssldir") +if test "$ssldir" != "/usr"; then + CFLAGS="$CFLAGS -I$ssldir/include" + LDFLAGS="$LDFLAGS -L$ssldir/lib" +fi +AC_MSG_RESULT($ssldir) + dnl Check for some target-specific stuff case "$host" in *-*-aix*) @@ -87,6 +112,11 @@ case "$host" in *-*-linux*) no_dev_ptmx=1 ;; +*-*-netbsd*) + if test "$GOT_SSL" = "yes"; then + LDFLAGS="$LDFLAGS -R$ssldir/lib" + fi + ;; *-*-solaris*) AC_DEFINE(USE_UTMPX) ;; @@ -95,31 +125,6 @@ case "$host" in ;; esac -dnl Check for OpenSSL/SSLeay directories. -AC_MSG_CHECKING([for OpenSSL/SSLeay directory]) -for ssldir in $prefix /usr /usr/local/openssl /usr/lib/openssl /usr/local/ssl /usr/lib/ssl /usr/local $prefix /usr/pkg ; do - if test -f "$ssldir/include/openssl/crypto.h"; then - AC_DEFINE(HAVE_OPENSSL) - GOT_SSL="yes" - break - fi - if test -f "$ssldir/include/ssl/crypto.h"; then - AC_DEFINE(HAVE_SSL) - GOT_SSL="yes" - break - fi -done -if test -z "$GOT_SSL" ; then - AC_MSG_ERROR([Could not find SSLeay / OpenSSL libraries, please install]) -fi -AC_SUBST(ssldir) -AC_DEFINE_UNQUOTED(ssldir, "$ssldir") -if test "$ssldir" != "/usr"; then - CFLAGS="$CFLAGS -I$ssldir/include" - LDFLAGS="$LDFLAGS -L$ssldir/lib" -fi -AC_MSG_RESULT($ssldir) - dnl Check for RSAref library. AC_MSG_CHECKING([for RSAref library]) saved_LIBS="$LIBS" diff --git a/defines.h b/defines.h index 3db1d0d95..519ebbaa2 100644 --- a/defines.h +++ b/defines.h @@ -34,6 +34,10 @@ # include /* For __P() */ #endif +#ifdef HAVE_SYS_SYSMACROS_H +# include /* For MIN, MAX, etc */ +#endif + /* Constants */ #ifndef SHUT_RDWR diff --git a/log-client.c b/log-client.c index 4d40cf268..668aafff0 100644 --- a/log-client.c +++ b/log-client.c @@ -15,7 +15,7 @@ */ #include "includes.h" -RCSID("$Id: log-client.c,v 1.3 1999/11/24 13:26:22 damien Exp $"); +RCSID("$Id: log-client.c,v 1.4 2000/01/20 13:18:16 damien Exp $"); #include "xmalloc.h" #include "ssh.h" @@ -45,12 +45,12 @@ log_init(char *av0, LogLevel level, SyslogFacility ignored1, int ignored2) } } -#define MSGBUFSIZE 1024 +#define SSH_MSGBUFSIZE 1024 void do_log(LogLevel level, const char *fmt, va_list args) { - char msgbuf[MSGBUFSIZE]; + char msgbuf[SSH_MSGBUFSIZE]; if (level > log_level) return; diff --git a/log-server.c b/log-server.c index 34f77b2be..264288109 100644 --- a/log-server.c +++ b/log-server.c @@ -15,7 +15,7 @@ */ #include "includes.h" -RCSID("$Id: log-server.c,v 1.5 1999/11/24 13:26:22 damien Exp $"); +RCSID("$Id: log-server.c,v 1.6 2000/01/20 13:18:16 damien Exp $"); #include #include "packet.h" @@ -97,13 +97,13 @@ log_init(char *av0, LogLevel level, SyslogFacility facility, int on_stderr) log_on_stderr = on_stderr; } -#define MSGBUFSIZE 1024 +#define SSH_MSGBUFSIZE 1024 void do_log(LogLevel level, const char *fmt, va_list args) { - char msgbuf[MSGBUFSIZE]; - char fmtbuf[MSGBUFSIZE]; + char msgbuf[SSH_MSGBUFSIZE]; + char fmtbuf[SSH_MSGBUFSIZE]; char *txt = NULL; int pri = LOG_INFO; diff --git a/uidswap.c b/uidswap.c index d81fde9d2..ca9e28eb7 100644 --- a/uidswap.c +++ b/uidswap.c @@ -7,7 +7,7 @@ */ #include "includes.h" -RCSID("$Id: uidswap.c,v 1.3 1999/11/25 00:55:00 damien Exp $"); +RCSID("$Id: uidswap.c,v 1.4 2000/01/20 13:18:16 damien Exp $"); #include "ssh.h" #include "uidswap.h" @@ -25,11 +25,12 @@ RCSID("$Id: uidswap.c,v 1.3 1999/11/25 00:55:00 damien Exp $"); /* Lets assume that posix saved ids also work with seteuid, even though that is not part of the posix specification. */ #define SAVED_IDS_WORK_WITH_SETEUID -#endif /* _POSIX_SAVED_IDS */ /* Saved effective uid. */ static uid_t saved_euid = 0; +#endif /* _POSIX_SAVED_IDS */ + /* * Temporarily changes to the given uid. If the effective user * id is not root, this does nothing. This call cannot be nested.