6.8. C++11 Random Numbers
According to CERT, function
rand does not have “good statistical properties” and can be predictable, which makes programs that use
rand less secure (CERT guideline MSC30-CPP). As we mentioned in Section 6.6, C++11 provides a new, more secure library of random-number capabilities that can produce nondeterministic random numbers for simulations and security scenarios where predictability is undesirable. These new capabilities are located in the C++ Standard Library’s
Random-number generation is a mathematically sophisticated topic for which mathematicians have developed many random-number generation algorithms ...