Generate a random number from 0 to limit using a secure RNG.
@eryx/crypto/hazmat/random Module
JSON
Summary
Functions
API Reference
Functions
random.integer
Parameters
The upper bound for the random number
random.choice
Securely select at random a single item from options
random.choice<T>(options: { T }) → T
Parameters
options: { T }
The options to chose from
random.bits
Generate a random number of size k bits
Parameters
The number of bits the returned number should be. Integer from 1 to 53
random.bytes
Generate a buffer of k random bytes
Parameters
The number of bytes long the returned buffer should be