diff --git a/configure.ac b/configure.ac index 3a901556e..7a9219be8 100644 --- a/configure.ac +++ b/configure.ac @@ -2980,6 +2980,7 @@ AS_CASE([$FIPS_VERSION], [ENABLED_SHA512="yes"; AM_CFLAGS="$AM_CFLAGS -DWOLFSSL_SHA512 -DWOLFSSL_SHA384"]) AS_IF([test "x$ENABLED_AESGCM" = "xno"], [ENABLED_AESGCM="yes"; AM_CFLAGS="$AM_CFLAGS -DHAVE_AESGCM"]) + AM_CFLAGS="$AM_CFLAGS -DWOLFSSL_ECDSA_SET_K" AM_CFLAGS="$AM_CFLAGS -DWOLFSSL_VALIDATE_FFC_IMPORT -DHAVE_FFDHE_Q" AM_CFLAGS="$AM_CFLAGS -DHAVE_FFDHE_3072 -DHAVE_FFDHE_4096 -DHAVE_FFDHE_6144 -DHAVE_FFDHE_8192 -DFP_MAX_BITS=16384" ], diff --git a/wolfcrypt/src/error.c b/wolfcrypt/src/error.c index b9ec96085..f5ee7b203 100644 --- a/wolfcrypt/src/error.c +++ b/wolfcrypt/src/error.c @@ -518,6 +518,9 @@ const char* wc_GetErrorString(int error) case ASN_SELF_SIGNED_E: return "ASN self-signed certificate error"; + case ECDSA_KAT_FIPS_E: + return "wolfcrypt FIPS ECDSA Known Answer Test Failure"; + default: return "unknown error number"; diff --git a/wolfssl/wolfcrypt/error-crypt.h b/wolfssl/wolfcrypt/error-crypt.h index 2cf6fcca7..b64a72ddc 100644 --- a/wolfssl/wolfcrypt/error-crypt.h +++ b/wolfssl/wolfcrypt/error-crypt.h @@ -234,8 +234,9 @@ enum { PSS_SALTLEN_RECOVER_E=-273, /* PSS slat length not recoverable */ CHACHA_POLY_OVERFLOW =-274, /* ChaCha20Poly1305 limit overflow */ ASN_SELF_SIGNED_E = -275, /* ASN self-signed certificate error */ + ECDSA_KAT_FIPS_E = -276, /* ECDSA KAT failure */ - WC_LAST_E = -275, /* Update this to indicate last error */ + WC_LAST_E = -276, /* Update this to indicate last error */ MIN_CODE_E = -300 /* errors -101 - -299 */ /* add new companion error id strings for any new error codes diff --git a/wolfssl/wolfcrypt/fips_test.h b/wolfssl/wolfcrypt/fips_test.h index dc4ce092b..46815b83e 100644 --- a/wolfssl/wolfcrypt/fips_test.h +++ b/wolfssl/wolfcrypt/fips_test.h @@ -43,6 +43,7 @@ enum FipsCastId { FIPS_CAST_ECC_CDH, FIPS_CAST_ECC_PRIMITIVE_Z, FIPS_CAST_DH_PRIMITIVE_Z, + FIPS_CAST_ECDSA, FIPS_CAST_ECDSA_PAIRWISE, FIPS_CAST_ECDSA_SHA3_PAIRWISE, FIPS_CAST_COUNT