adjustment to compatibility in random.h file

This commit is contained in:
Jacob Barthelmeh
2015-01-07 14:45:11 -07:00
parent 252390a476
commit bdb37d0da9
2 changed files with 10 additions and 12 deletions

View File

@ -23,7 +23,16 @@
#ifndef CTAO_CRYPT_RANDOM_H
#define CTAO_CRYPT_RANDOM_H
#include <wolfssl/wolfcrypt/random.h>
/* for random.h compatibility */
#include <wolfssl/wolfcrypt/random.h>
#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 */

View File

@ -46,17 +46,6 @@
* using old function calls
*/
#ifndef HAVE_FIPS
/* for random.h compatibility */
#include <wolfssl/wolfcrypt/random.h>
#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 <wolfssl/wolfcrypt/aes.h>
#define AesSetKey wc_AesSetKey