entropy

A measure of how unpredictable a value is; high-entropy secrets are long and truly random so they cannot be guessed.

In more detail

High-entropy values come from a cryptographically secure random generator, not from timestamps or Math.random. Tokens, session identifiers and keys all need high entropy.

Example

PKCE code verifiers, session IDs and CSRF tokens use crypto.getRandomValues.

Related terms

Taught in

References