From 466cc0fb0b1a072584c26f0949d377510c440d0d Mon Sep 17 00:00:00 2001 From: Jack Lloyd Date: Sat, 28 Nov 2015 11:43:00 -0500 Subject: Push the hardcoded entropy estimates up to build.h Defaults should be fine for everyone but it makes the values more transparent --- src/lib/rng/system_rng/system_rng.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'src/lib/rng/system_rng/system_rng.cpp') diff --git a/src/lib/rng/system_rng/system_rng.cpp b/src/lib/rng/system_rng/system_rng.cpp index 02ad07736..50ec696a0 100644 --- a/src/lib/rng/system_rng/system_rng.cpp +++ b/src/lib/rng/system_rng/system_rng.cpp @@ -40,17 +40,17 @@ class System_RNG_Impl : public RandomNumberGenerator void clear() override {} std::string name() const override { return "system"; } - size_t reseed_with_sources(Entropy_Sources& srcs, - size_t poll_bits, - std::chrono::milliseconds poll_timeout) override + size_t reseed_with_sources(Entropy_Sources&, + size_t /*poll_bits*/, + std::chrono::milliseconds /*timeout*/) override { + // We ignore it and assert the PRNG is seeded. + // TODO: could poll and write it to /dev/urandom to help seed it return 0; } void add_entropy(const byte[], size_t) override { - // We could write this back to /dev/urandom to help seed the PRNG - // Unclear if this is valuable on current systems } private: -- cgit v1.2.3