Re: configure and have crypt or DES_crypt

[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

 



On Tue, 3 Mar 2015, Roumen Petrov wrote:

> Damien Miller wrote:
>
> > I think that might break some systems that configure --without-openssl,
> > so it probably better to move the test out of the if-else entirely.
> I take this into account. This is reason to point to code where is used - only
> lines
> # if defined(WITH_OPENSSL) && !defined(HAVE_CRYPT) && defined(HAVE_DES_CRYPT)
> #  include <openssl/des.h>
> #  define crypt DES_crypt
> # endif
> 
> Build without openssl should not be impacted. On those system SSH cannot be
> build without libcrypto.

ok, I've committed this because it might be surprising that HAVE_CRYPT
is not defined on platforms that do have it.

diff --git a/configure.ac b/configure.ac
index 2ef9db6..b4d6598 100644
--- a/configure.ac
+++ b/configure.ac
@@ -2572,6 +2572,7 @@ if test "x$openssl" = "xyes" ; then
 	if test "x$check_for_libcrypt_later" = "x1"; then
 		AC_CHECK_LIB([crypt], [crypt], [LIBS="$LIBS -lcrypt"])
 	fi
+	AC_CHECK_FUNCS([crypt DES_crypt])
 
 	# Search for SHA256 support in libc and/or OpenSSL
 	AC_CHECK_FUNCS([SHA256_Update EVP_sha256], ,
@@ -2710,7 +2711,7 @@ if test "x$openssl" = "xyes" ; then
 	AC_SUBST([COMMENT_OUT_ECC])
 else
 	AC_CHECK_LIB([crypt], [crypt], [LIBS="$LIBS -lcrypt"])
-	AC_CHECK_FUNCS([crypt DES_crypt])
+	AC_CHECK_FUNCS([crypt])
 fi
 
 AC_CHECK_FUNCS([ \
_______________________________________________
openssh-unix-dev mailing list
openssh-unix-dev@xxxxxxxxxxx
https://lists.mindrot.org/mailman/listinfo/openssh-unix-dev




[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux