![]() |
Bitcoin Core
28.1.0
P2P Digital Currency
|
#include <test/util/random.h>#include <logging.h>#include <uint256.h>#include <cstdlib>#include <string>Go to the source code of this file.
Functions | |
| void | MakeRandDeterministicDANGEROUS (const uint256 &seed) noexcept |
| Internal function to set g_determinstic_rng. More... | |
| void | SeedRandomForTest (SeedRand seedtype) |
| Seed the RNG for testing. More... | |
Variables | |
| FastRandomContext | g_insecure_rand_ctx |
| This global and the helpers that use it are not thread-safe. More... | |
|
noexcept |
Internal function to set g_determinstic_rng.
Only accessed from tests.
Definition at line 670 of file random.cpp.
| void SeedRandomForTest | ( | SeedRand | seed = SeedRand::SEED | ) |
Seed the RNG for testing.
This affects all randomness, except GetStrongRandBytes().
Definition at line 18 of file random.cpp.
| FastRandomContext g_insecure_rand_ctx |
This global and the helpers that use it are not thread-safe.
If thread-safety is needed, a per-thread instance could be used in the multi-threaded test.
Definition at line 14 of file random.cpp.
1.8.14