diff --git a/cyassl/ctaocrypt/random.h b/cyassl/ctaocrypt/random.h index cb3e953a2..11634fc61 100644 --- a/cyassl/ctaocrypt/random.h +++ b/cyassl/ctaocrypt/random.h @@ -23,7 +23,16 @@ #ifndef CTAO_CRYPT_RANDOM_H #define CTAO_CRYPT_RANDOM_H -#include + /* for random.h compatibility */ + #include + #define InitRng wc_InitRng + #define RNG_GenerateBlock wc_RNG_GenerateBlock + #define RNG_GenerateByte wc_RNG_GenerateByte + + #if defined(HAVE_HASHDRBG) || defined(NO_RC4) + #define FreeRng wc_FreeRng + #define RNG_HealthTest wc_RNG_HealthTest + #endif /* HAVE_HASHDRBG || NO_RC4 */ #endif /* CTAO_CRYPT_RANDOM_H */ diff --git a/cyassl/ctaocrypt/settings_comp.h b/cyassl/ctaocrypt/settings_comp.h index bd96da2a2..770befe00 100644 --- a/cyassl/ctaocrypt/settings_comp.h +++ b/cyassl/ctaocrypt/settings_comp.h @@ -46,17 +46,6 @@ * using old function calls */ #ifndef HAVE_FIPS - /* for random.h compatibility */ - #include - #define InitRng wc_InitRng - #define RNG_GenerateBlock wc_RNG_GenerateBlock - #define RNG_GenerateByte wc_RNG_GenerateByte - - #if defined(HAVE_HASHDRBG) || defined(NO_RC4) - #define FreeRng wc_FreeRng - #define RNG_HealthTest wc_RNG_HealthTest - #endif /* HAVE_HASHDRBG || NO_RC4 */ - #ifndef NO_AES #include #define AesSetKey wc_AesSetKey