4 ms·
> At least /dev/urandom should be used for seeding purposes in applications where you need an unguessable PRNG. I usually consume /dev/urandom and convert it t
by carbocation 14y ago
> At least /dev/urandom should be used for seeding purposes in applications where you need an unguessable PRNG.
I usually consume /dev/urandom and convert it to the base I require, using that directly as my random number. When you say you should use it for seeding purposes, are you referring to using /dev/urandom as a seed for something like PHP's rand(), or do you mean something else?
- tptacek 14y agoSeeding is largely a problem you have if you're building (or retrofitting in) your own CSPRNG, which you shouldn't do. The random/urandom interface Unixes provide will allow you to shovel in high-entropy data, but I think you're more likely to do harm than good (it's a marginal impact in either direction, though). You're doing the right thing already.
- carbocation 14y agoAha, that makes sense. Thanks!