diff options
author | Jack Lloyd <[email protected]> | 2016-07-01 08:46:10 -0400 |
---|---|---|
committer | Jack Lloyd <[email protected]> | 2016-07-17 10:43:41 -0400 |
commit | 4db84ab7e8a4328bca04966f77cae47712bbf427 (patch) | |
tree | 080414561b1d446b2950c4fc436bc206cf345996 /src/lib/entropy/entropy_src.h | |
parent | 9e6013809d63f3365023e6047fa31865db4e556d (diff) |
Move poll logic to Entropy_Sources
Diffstat (limited to 'src/lib/entropy/entropy_src.h')
-rw-r--r-- | src/lib/entropy/entropy_src.h | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/src/lib/entropy/entropy_src.h b/src/lib/entropy/entropy_src.h index 539df809a..1726d05b8 100644 --- a/src/lib/entropy/entropy_src.h +++ b/src/lib/entropy/entropy_src.h @@ -1,6 +1,6 @@ /* * EntropySource -* (C) 2008,2009,2014,2015 Jack Lloyd +* (C) 2008,2009,2014,2015,2016 Jack Lloyd * * Botan is released under the Simplified BSD License (see license.txt) */ @@ -10,10 +10,13 @@ #include <botan/secmem.h> #include <string> +#include <chrono> #include <functional> namespace Botan { +class RandomNumberGenerator; + /** * Class used to accumulate the poll results of EntropySources */ @@ -109,7 +112,10 @@ class BOTAN_DLL Entropy_Sources final std::vector<std::string> enabled_sources() const; - void poll(Entropy_Accumulator& accum); + size_t poll(RandomNumberGenerator& rng, + size_t bits, + std::chrono::milliseconds timeout); + bool poll_just(Entropy_Accumulator& accum, const std::string& src); Entropy_Sources() {} |