Questions: Random Number Generation in Cryptography

5 questions to test your understanding

Score: 0 / 5
Question 1 Short Answer

The Debian OpenSSL bug (2006-2008) commented out a line that mixed process memory into the random seed, reducing the effective entropy to the process ID (~15 bits). What was the practical impact?

Think about your answer, then reveal below.
Question 2 Multiple Choice

A developer seeds a PRNG with the current time in seconds. Why is this insecure even if the PRNG algorithm itself is cryptographically strong?

AThe current time changes too fast for the PRNG to process
BTime in seconds provides at most ~20-30 bits of entropy (the attacker can estimate when the key was generated to within a plausible time window). A CSPRNG cannot create entropy — it can only expand existing entropy. If the seed has 30 bits of entropy, the output has 30 bits of entropy regardless of the PRNG quality
CTime-based seeds cause the PRNG to produce negative numbers
DThe PRNG algorithm needs at least 256 bits of input to function
Question 3 Multiple Choice

Why should developers use OS-provided CSPRNGs (/dev/urandom on Linux, BCryptGenRandom on Windows) rather than implementing their own?

AOS CSPRNGs are faster than user-space implementations
BOS CSPRNGs continuously mix entropy from multiple hardware sources, are maintained by security experts, are hardened against state compromise, and have been extensively audited. Custom implementations are likely to have entropy collection bugs, reseeding failures, or state leakage that the developer won't detect
CUser-space PRNGs are illegal in most jurisdictions
DOS CSPRNGs use quantum random number generators
Question 4 True / False

/dev/random and /dev/urandom on Linux differ in that /dev/random blocks when the entropy pool is estimated to be depleted, while /dev/urandom never blocks. For cryptographic key generation, /dev/urandom is the correct choice.

TTrue
FFalse
Question 5 Short Answer

Dual_EC_DRBG was standardized by NIST in 2006 and later revealed to contain a likely NSA backdoor. What made the backdoor possible?

Think about your answer, then reveal below.