Browse Source

[multiple] include mbedtls/config.h after select

include mbedtls/config.h crypto lib config
after selecting crypto lib to use
master
Glenn Strauss 6 months ago
parent
commit
6fb63fa8d6
  1. 1
      src/mod_mbedtls.c
  2. 2
      src/rand.c
  3. 2
      src/sys-crypto-md.h
  4. 1
      src/sys-crypto.h

1
src/mod_mbedtls.c

@ -56,6 +56,7 @@
#include <stdio.h> /* vsnprintf() */
#include <string.h>
#include <mbedtls/config.h>
#include <mbedtls/ctr_drbg.h>
#include <mbedtls/dhm.h>
#include <mbedtls/error.h>

2
src/rand.c

@ -20,7 +20,7 @@
#include <time.h>
#include <unistd.h>
#include "sys-crypto.h" /* USE_LIB_CRYPTO */
#include "sys-crypto-md.h" /* USE_LIB_CRYPTO and additional crypto lib config */
#ifdef USE_NETTLE_CRYPTO
#undef USE_MBEDTLS_CRYPTO
#undef USE_WOLFSSL_CRYPTO

2
src/sys-crypto-md.h

@ -129,6 +129,8 @@ SHA512_256_Update(SHA512_CTX *ctx, const void *data, size_t length)
#elif defined(USE_MBEDTLS_CRYPTO)
#include <mbedtls/config.h>
#ifdef MBEDTLS_MD4_C
#define USE_LIB_CRYPTO_MD4
#include <mbedtls/md4.h>

1
src/sys-crypto.h

@ -40,7 +40,6 @@
#ifdef HAVE_LIBMBEDCRYPTO
#define USE_LIB_CRYPTO
#define USE_MBEDTLS_CRYPTO
#include <mbedtls/config.h>
#endif
#ifdef HAVE_NSS3_NSS_H

Loading…
Cancel
Save