diff options
Diffstat (limited to 'src/build-data')
-rw-r--r-- | src/build-data/buildh.in | 27 | ||||
-rw-r--r-- | src/build-data/policy/bsi.txt | 9 | ||||
-rw-r--r-- | src/build-data/policy/modern.txt | 6 |
3 files changed, 19 insertions, 23 deletions
diff --git a/src/build-data/buildh.in b/src/build-data/buildh.in index c84698804..c5912e4ed 100644 --- a/src/build-data/buildh.in +++ b/src/build-data/buildh.in @@ -106,12 +106,6 @@ #define BOTAN_RNG_AUTO_RESEED_TIMEOUT std::chrono::milliseconds(10) #define BOTAN_RNG_RESEED_DEFAULT_TIMEOUT std::chrono::milliseconds(50) -/** -* Controls how AutoSeeded_RNG is instantiated -*/ -#define BOTAN_AUTO_RNG_DRBG HMAC_DRBG -#define BOTAN_AUTO_RNG_HMAC "HMAC(SHA-384)" - /* * Specifies (in order) the list of entropy sources that will be used * to seed an in-memory RNG. The first few in the default list @@ -121,8 +115,7 @@ */ #define BOTAN_ENTROPY_DEFAULT_SOURCES \ { "timestamp", "rdseed", "rdrand", "proc_info", \ - "darwin_secrandom", "dev_random", "win32_cryptoapi", "egd", \ - "proc_walk", "system_stats", "unix_procs" } + "darwin_secrandom", "dev_random", "win32_cryptoapi", "proc_walk", "system_stats" } /* * These control the RNG used by the system RNG interface @@ -273,6 +266,24 @@ Each read generates 32 bits of output */ %{local_config} +/** +* Controls how AutoSeeded_RNG is instantiated +*/ +#if !defined(BOTAN_AUTO_RNG_HMAC) + + #if defined(BOTAN_HAS_SHA2_64) + #define BOTAN_AUTO_RNG_HMAC "HMAC(SHA-384)" + #elif defined(BOTAN_HAS_SHA2_32) + #define BOTAN_AUTO_RNG_HMAC "HMAC(SHA-256)" + #elif defined(BOTAN_HAS_SHA3) + #define BOTAN_AUTO_RNG_HMAC "HMAC(SHA-3(256))" + #elif defined(BOTAN_HAS_SHA1) + #define BOTAN_AUTO_RNG_HMAC "HMAC(SHA-1)" + #endif + // Otherwise, no hash found: leave BOTAN_AUTO_RNG_HMAC undefined + +#endif + // Append to macros living outside of functions, so that invocations must end with a semicolon. // The struct is only declared to force the semicolon, it is never defined. #define BOTAN_FORCE_SEMICOLON struct BOTAN_DUMMY_STRUCT diff --git a/src/build-data/policy/bsi.txt b/src/build-data/policy/bsi.txt index 62be245d0..8e6012c64 100644 --- a/src/build-data/policy/bsi.txt +++ b/src/build-data/policy/bsi.txt @@ -55,7 +55,6 @@ aes_ssse3 clmul # entropy sources -beos_stats cryptoapi_rng darwin_secrandom dev_random @@ -150,12 +149,4 @@ poly1305 siphash x919_mac -# rng -hmac_rng -x931_rng - -# entropy sources -egd -unix_procs - </prohibited> diff --git a/src/build-data/policy/modern.txt b/src/build-data/policy/modern.txt index 95c198658..29198950c 100644 --- a/src/build-data/policy/modern.txt +++ b/src/build-data/policy/modern.txt @@ -68,7 +68,6 @@ rdrand_rng system_rng # entropy sources -beos_stats cryptoapi_rng darwin_secrandom dev_random @@ -112,12 +111,7 @@ gost_3410 emsa_x931 pbkdf1 prf_x942 -x931_rng passhash9 cryptobox - -# questionable entropy sources -egd -unix_procs </prohibited> |