mirror of
https://github.com/wolfSSL/wolfssl.git
synced 2025-08-01 03:34:39 +02:00
Add option --enable-ip-alt-name
This commit adds the configure option `--enable-ip-alt-name` that enables support for the IP alternative subject name parsing in `wolfcrypt/src/asn.c:DecodeAltNames`.
This commit is contained in:
12
configure.ac
12
configure.ac
@@ -528,6 +528,18 @@ then
|
||||
AM_CFLAGS="$AM_CFLAGS -DWOLFSSL_OPENSSH -DHAVE_EX_DATA -DWOLFSSL_BASE16"
|
||||
fi
|
||||
|
||||
#IP alternative name Support
|
||||
AC_ARG_ENABLE([ip-alt-name],
|
||||
[AS_HELP_STRING([--enable-ip-alt-name],[Enable IP subject alternative name (default: disabled)])],
|
||||
[ ENABLE_IP_ALT_NAME=$enableval ],
|
||||
[ ENABLE_IP_ALT_NAME=no ]
|
||||
)
|
||||
|
||||
if test "$ENABLE_IP_ALT_NAME" = "yes"
|
||||
then
|
||||
AM_CFLAGS="$AM_CFLAGS -DWOLFSSL_IP_ALT_NAME"
|
||||
fi
|
||||
|
||||
#Qt Support
|
||||
AC_ARG_ENABLE([qt],
|
||||
[AS_HELP_STRING([--enable-qt],[Enable qt (default: disabled)])],
|
||||
|
@@ -20521,7 +20521,7 @@ static void test_wolfSSL_ASN1_TIME_print(void)
|
||||
sizeof_client_cert_der_2048, WOLFSSL_FILETYPE_ASN1));
|
||||
AssertIntEQ(ASN1_TIME_print(bio, X509_get_notBefore(x509)), 1);
|
||||
AssertIntEQ(BIO_read(bio, buf, sizeof(buf)), 24);
|
||||
AssertIntEQ(XMEMCMP(buf, "Apr 13 15:23:09 2018 GMT", sizeof(buf) - 1), 0);
|
||||
AssertIntEQ(XMEMCMP(buf, "May 7 07:39:03 2020 GMT", sizeof(buf) - 1), 0);
|
||||
|
||||
/* create a bad time and test results */
|
||||
AssertNotNull(t = X509_get_notAfter(x509));
|
||||
|
@@ -7798,7 +7798,7 @@ static int DecodeAltNames(const byte* input, int sz, DecodedCert* cert)
|
||||
length -= strLen;
|
||||
idx += strLen;
|
||||
}
|
||||
#if defined(WOLFSSL_QT) || defined(OPENSSL_ALL)
|
||||
#if defined(WOLFSSL_QT) || defined(OPENSSL_ALL) || defined(WOLFSSL_IP_ALT_NAME)
|
||||
else if (b == (ASN_CONTEXT_SPECIFIC | ASN_IP_TYPE)) {
|
||||
DNS_entry* ipAddr;
|
||||
int strLen;
|
||||
|
Reference in New Issue
Block a user