3 ms·
> For example a "random number generator" that just has a large hardcoded list of random-looking values and loops over the list may pass a test if the list is l
by nvarsj 5y ago
> For example a "random number generator" that just has a large hardcoded list of random-looking values and loops over the list may pass a test if the list is long enough that the loop can't be detected, even though the values are decidedly not random.
Even cryptographically secure RNGs have fixed periods, they are not infinite. What's important is how long that "list" is. So for purposes of computer randomness, a long fixed list may indeed be okay if it is truly long enough. It will need to be truly massive to pass Diehard though.
- kevincox 5y agoFor sure. However most CSPRNGs have "huge" periods which would be infeasible to hardcode into a software implementation. Knowing your period is important any time you use a PRNG for cryptography.