forked from wolfSSL/wolfssl
Updated the configure.ac comments about big int being used for ECC and DH. Moved the checks for ecc/asn and psk/asn until after cryptonly value is set and fixed so those checks work for normal build and are excluded for crypt only builds.
This commit is contained in:
32
configure.ac
32
configure.ac
@@ -1034,7 +1034,7 @@ then
|
|||||||
AM_CFLAGS="$AM_CFLAGS -DNO_ASN -DNO_CERTS"
|
AM_CFLAGS="$AM_CFLAGS -DNO_ASN -DNO_CERTS"
|
||||||
if test "$ENABLED_DH" = "no" && test "$ENABLED_ECC" == "no"
|
if test "$ENABLED_DH" = "no" && test "$ENABLED_ECC" == "no"
|
||||||
then
|
then
|
||||||
# DH needs bigint
|
# DH and ECC need bigint
|
||||||
AM_CFLAGS="$AM_CFLAGS -DNO_BIG_INT"
|
AM_CFLAGS="$AM_CFLAGS -DNO_BIG_INT"
|
||||||
fi
|
fi
|
||||||
else
|
else
|
||||||
@@ -1056,20 +1056,7 @@ then
|
|||||||
AC_MSG_ERROR([please disable dsa if disabling asn.])
|
AC_MSG_ERROR([please disable dsa if disabling asn.])
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if test "x$ENABLED_CRYPTONLY" = "xyes"
|
# DH and ECC need bigint
|
||||||
then
|
|
||||||
if test "$ENABLED_ECC" = "yes" && test "$ENABLED_ASN" = "no"
|
|
||||||
then
|
|
||||||
AC_MSG_ERROR([please disable ecc if disabling asn.])
|
|
||||||
fi
|
|
||||||
|
|
||||||
if test "$ENABLED_PSK" = "no" && test "$ENABLED_ASN" = "no"
|
|
||||||
then
|
|
||||||
AC_MSG_ERROR([please enable psk if disabling asn.])
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
# DH needs bigint
|
|
||||||
if test "$ENABLED_ASN" = "no" && test "$ENABLED_DH" = "no" && test "$ENABLED_ECC" = "no"
|
if test "$ENABLED_ASN" = "no" && test "$ENABLED_DH" = "no" && test "$ENABLED_ECC" = "no"
|
||||||
then
|
then
|
||||||
ENABLED_FASTMATH=no
|
ENABLED_FASTMATH=no
|
||||||
@@ -2164,6 +2151,19 @@ fi
|
|||||||
|
|
||||||
AM_CONDITIONAL([BUILD_CRYPTONLY], [test "x$ENABLED_CRYPTONLY" = "xyes"])
|
AM_CONDITIONAL([BUILD_CRYPTONLY], [test "x$ENABLED_CRYPTONLY" = "xyes"])
|
||||||
|
|
||||||
|
if test "x$ENABLED_CRYPTONLY" = "xno"
|
||||||
|
then
|
||||||
|
if test "x$ENABLED_PSK" = "xno" && test "x$ENABLED_ASN" = "xno"
|
||||||
|
then
|
||||||
|
AC_MSG_ERROR([please enable psk if disabling asn.])
|
||||||
|
fi
|
||||||
|
|
||||||
|
if test "x$ENABLED_ECC" = "xyes" && test "x$ENABLED_ASN" = "xno"
|
||||||
|
then
|
||||||
|
AC_MSG_ERROR([please disable ecc if disabling asn.])
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
|
||||||
# set fastmath default
|
# set fastmath default
|
||||||
FASTMATH_DEFAULT=no
|
FASTMATH_DEFAULT=no
|
||||||
@@ -2182,7 +2182,7 @@ AC_ARG_ENABLE([fastmath],
|
|||||||
|
|
||||||
if test "x$ENABLED_FASTMATH" = "xyes"
|
if test "x$ENABLED_FASTMATH" = "xyes"
|
||||||
then
|
then
|
||||||
# turn off fastmth if leanpsk on or asn off (w/o dh)
|
# turn off fastmth if leanpsk on or asn off (w/o DH and ECC)
|
||||||
if test "$ENABLED_LEANPSK" = "yes" || test "$ENABLED_ASN" = "no"
|
if test "$ENABLED_LEANPSK" = "yes" || test "$ENABLED_ASN" = "no"
|
||||||
then
|
then
|
||||||
if test "$ENABLED_DH" = "no" && test "$ENABLED_ECC" = "no"
|
if test "$ENABLED_DH" = "no" && test "$ENABLED_ECC" = "no"
|
||||||
|
@@ -6172,7 +6172,8 @@ int ecc_test(void)
|
|||||||
WC_RNG rng;
|
WC_RNG rng;
|
||||||
byte sharedA[1024];
|
byte sharedA[1024];
|
||||||
byte sharedB[1024];
|
byte sharedB[1024];
|
||||||
#ifndef NO_ASN
|
#if !defined(NO_ASN) || (!defined(NO_SHA) && \
|
||||||
|
((defined(HAVE_ECC192) && defined(HAVE_ECC224)) || defined(HAVE_ALL_CURVES)))
|
||||||
byte sig[1024];
|
byte sig[1024];
|
||||||
int verify;
|
int verify;
|
||||||
#endif
|
#endif
|
||||||
|
Reference in New Issue
Block a user