- (dtucker) [configure.ac openbsd-compat/xcrypt.c] bz#2112: fall back to

using openssl's DES_crpyt function on platorms that don't have a native
   one, eg Android.  Based on a patch from Nathan Osman.
This commit is contained in:
Darren Tucker 2013-06-02 06:28:03 +10:00
parent efdf534214
commit c0c3373216
3 changed files with 16 additions and 4 deletions

View File

@ -1,7 +1,13 @@
20130529
20130601
- (dtucker) [configure.ac openbsd-compat/xcrypt.c] bz#2112: fall back to
using openssl's DES_crpyt function on platorms that don't have a native
one, eg Android. Based on a patch from Nathan Osman.
20130529
- (dtucker) [configure.ac openbsd-compat/bsd-misc.h] bz#2087: Add a null
implementation of endgrent for platforms that don't have it (eg Android).
Loosely based on a patch from Nathan Osman, ok djm
20130517
- (dtucker) OpenBSD CVS Sync
- djm@cvs.openbsd.org 2013/03/07 00:20:34

View File

@ -1,4 +1,4 @@
# $Id: configure.ac,v 1.525 2013/05/29 22:29:09 dtucker Exp $
# $Id: configure.ac,v 1.526 2013/06/01 20:28:04 dtucker Exp $
#
# Copyright (c) 1999-2004 Damien Miller
#
@ -15,7 +15,7 @@
# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
AC_INIT([OpenSSH], [Portable], [openssh-unix-dev@mindrot.org])
AC_REVISION($Revision: 1.525 $)
AC_REVISION($Revision: 1.526 $)
AC_CONFIG_SRCDIR([ssh.c])
AC_LANG([C])
@ -2388,6 +2388,7 @@ fi
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], [TEST_SSH_SHA256=yes],

View File

@ -55,7 +55,12 @@
# if defined(HAVE_MD5_PASSWORDS) && !defined(HAVE_MD5_CRYPT)
# include "md5crypt.h"
# endif
# endif
# if !defined(HAVE_CRYPT) && defined(HAVE_DES_CRYPT)
# include <openssl/des.h>
# define crypt DES_crypt
# endif
char *
xcrypt(const char *password, const char *salt)