in reply to Re: Predictable Randomness
in thread Predictable Randomness
Just as a side note, generating random numbers for network usage is much harder than it seems.
In the above case security and true unpredictability are not fundamental, so it might be enough to feed srand with the current time. It's at least advisable to XOR it (the current time) with the process ID: busy Web server are likely to respond to more than one request per second, which is the resolution returned by time and similar.
When security is a concern, this RFC can be very useful. It's an interesting reading anyway.
-- TMTOWTDI
|
|---|