From cbc8f4ce38b2b2504b6efde6f71d0ece1d382150 Mon Sep 17 00:00:00 2001 From: Eric Blankenhorn Date: Wed, 12 Dec 2018 09:48:34 -0600 Subject: [PATCH] Fix failing nightly tests --- wolfcrypt/src/asn.c | 3 ++- wolfcrypt/test/test.c | 8 ++++++-- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/wolfcrypt/src/asn.c b/wolfcrypt/src/asn.c index 2354a6142..8b79f81d2 100644 --- a/wolfcrypt/src/asn.c +++ b/wolfcrypt/src/asn.c @@ -9056,8 +9056,9 @@ int PemToDer(const unsigned char* buff, long longSz, int type, if (ret >= 0) { der->length = ret; - if (algId == ECDSAk) + if ((algId == ECDSAk) && (eccKey != NULL)) { *eccKey = 1; + } ret = 0; } #else diff --git a/wolfcrypt/test/test.c b/wolfcrypt/test/test.c index c913893cf..1b0e0d470 100644 --- a/wolfcrypt/test/test.c +++ b/wolfcrypt/test/test.c @@ -19320,7 +19320,9 @@ static int pkcs7enveloped_run_vectors(byte* rsaCert, word32 rsaCertSz, }; #endif -#if !defined(NO_PWDBASED) +#if !defined(NO_PWDBASED) && !defined(NO_AES) && \ + !defined(NO_SHA) && defined(WOLFSSL_AES_128) + char password[] = "password"; byte salt[] = { @@ -19871,7 +19873,9 @@ static int pkcs7authenveloped_run_vectors(byte* rsaCert, word32 rsaCertSz, }; #endif -#if !defined(NO_PWDBASED) +#if !defined(NO_PWDBASED) && !defined(NO_AES) && defined(HAVE_AESGCM) && \ + !defined(NO_SHA) && defined(WOLFSSL_AES_128) + char password[] = "password"; byte salt[] = {