We have a script to stand up a new web server at my job. The script involves creating a number of accounts to run services, app pools etc.
We needed to create a password for each of these users -- i.e. generate a 32-or-so-character ASCII string to be used as a logon password.
We had a disagreement as to whether one ought to use a cryptographically-secure PRNG for this job, or whether using a non-cryptographically secure PRNG (with a time-dependent seed) would suffice (we work in .NET, so the concrete decision was between generating strings with System.Random
and using a RNGCryptoServiceProvider
-- however, this is not a language-specific issue).
Must one use cryptographically-secure randomness for generating passwords, or is a sensibly-seeded plain PRNG sufficient?