Fill BigInt with a random number with size of bitsize If set_high_bit is true, the highest bit will be set, which causes the entropy to be bits-1. Otherwise the highest bit is randomly choosen by the rng, causing the entropy to be bits.
the random number generator to use
number of bits the created random value should have
if true, the highest bit is always set
See Implementation
Fill BigInt with a random number with size of bitsize If set_high_bit is true, the highest bit will be set, which causes the entropy to be bits-1. Otherwise the highest bit is randomly choosen by the rng, causing the entropy to be bits.