Essential Metrics for Evaluating Token Randomness
Token unguessability is measured by entropy bits, with OWASP recommending at least 64 bits for session IDs and 128 bits for custom CSPRNG-generated IDs. Statistical randomness tests, like those in Burp Sequencer (e.g., FIPS monobit, runs, character distribution), also assess deviation from true random behavior.
The top 3
- Top 3 Statistical Test Suites for Randomness: The most recognized statistical test suites for evaluating token randomness are Dieharder, NIST SP 800-22, and TestU01. These suites apply numerous tests to assess properties like uniform distribution, independence, and unpredictability, crucial for cryptographic security.
- True Random vs. Pseudo-Random: Entropy's Role: True Random Number Generators (TRNGs) derive randomness from unpredictable physical phenomena like thermal noise or atmospheric noise, essential for high-security applications. Pseudo-Random Number Generators (PRNGs) use deterministic algorithms, appearing random but predictable if the seed is known, making them suitable for less sensitive uses or stretching TRNG output.
- NIST SP 800-90: The Standard for Secure Randomness: The NIST SP 800-90 series provides critical standards for cryptographic random bit generation. This includes SP 800-90A for deterministic random bit generators, SP 800-90B for entropy sources, and SP 800-90C for random bit generator constructions, ensuring high-quality randomness for security applications.
Sources
Open the full topic