diff options
Diffstat (limited to 'src/random.h')
-rw-r--r-- | src/random.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/random.h b/src/random.h index 6a63d57429..c60ab36179 100644 --- a/src/random.h +++ b/src/random.h @@ -110,9 +110,15 @@ public: } } + /** Generate random bytes. */ + std::vector<unsigned char> randbytes(size_t len); + /** Generate a random 32-bit integer. */ uint32_t rand32() { return randbits(32); } + /** generate a random uint256. */ + uint256 rand256(); + /** Generate a random boolean. */ bool randbool() { return randbits(1); } }; @@ -134,4 +140,7 @@ void GetOSRand(unsigned char *ent32); */ bool Random_SanityCheck(); +/** Initialize the RNG. */ +void RandomInit(); + #endif // BITCOIN_RANDOM_H |