PBKDF2 Key Derivation
Derive cryptographic keys from passwords using PBKDF2.
About PBKDF2 Key Derivation
PBKDF2 Key Derivation implements the Password-Based Key Derivation Function 2 (RFC 2898, PKCS#5 v2.0), transforming a password and a cryptographic salt into a derived key by iterating an HMAC pseudorandom function hundreds of thousands of times. This key-stretching process makes brute-force and dictionary attacks computationally expensive, since an attacker must repeat the entire iteration count for every password guess. PBKDF2 with HMAC-SHA-256 is a NIST-recommended algorithm used in WPA2 Wi-Fi authentication, iOS data protection, and many database password hashing implementations. This browser tool computes PBKDF2-derived keys using the Web Crypto API for trustworthy in-browser computation without sending your password anywhere.
How to Use
Enter your password in the password field and provide a cryptographic salt, or click the random salt button to generate a secure 16-byte random salt. Select the HMAC hash algorithm, choosing SHA-256 for general use or SHA-512 for a higher security margin. Set the iteration count following NIST guidance of at least 600,000 iterations for HMAC-SHA-256, and specify the output key length in bytes such as 16 for AES-128 or 32 for AES-256. Click Derive to compute and display the result in hexadecimal or Base64, then copy the output for cross-implementation testing or compliance documentation.
Common Use Cases
- Deriving AES-256 encryption keys from user-supplied passwords for encrypting files or sensitive application data stored at rest
- Testing and tuning PBKDF2 iteration counts and salt lengths during the security design phase of new authentication systems
- Verifying that a given password and salt reproduce the expected derived key stored in a legacy database or configuration archive
- Comparing derived key outputs across HMAC-SHA-256, HMAC-SHA-384, and HMAC-SHA-512 to select the right algorithm for compliance requirements
- Demonstrating key stretching and salting concepts interactively in applied cryptography courses and developer security workshops