News for hackers. Stuff that matters.
Re:Random in the wild by jacobparker on Tuesday December 09, 2014 @04:54PM (#8726077)
Language lawyer note: std::random_device isn't guaranteed to be hardware-based, or anything in particular:

http://en.cppreference.com/w/cpp/numeric/random/random_devic...

(GNU libstdc++ will use rdrand if possible, otherwise it will read from /dev/urandom: https://gcc.gnu.org/git/?p=gcc.git;a=blob_plain;f=libstdc%2B...)

Re:Random in the wild by sjolsen on Tuesday December 09, 2014 @05:30PM (#8726295)
You are correct; and of course, any hardware-level behaviour is likely to be implementation defined. I should note that MSVC [1] guarantees "non-deterministic and cryptographically secure" behaviour; and that libc++ [2] uses the "cryptographically secure" rand_s [3] on Windows, NaCl on other platforms where NaCl is available, and /dev/urandom where it isn't.

[1] http://msdn.microsoft.com/en-us/library/bb982250.aspx

[2] https://github.com/llvm-mirror/libcxx/blob/master/src/random...

[3] http://msdn.microsoft.com/en-us/library/sxtz2fa8.aspx