KDF

acronym

cryptography

Stands for: key derivation function

A function that turns a secret into one or more cryptographic keys.

A key derivation function stretches or transforms input keying material into keys. Password-oriented KDFs (bcrypt, scrypt, Argon2, PBKDF2) are deliberately slow and tunable so that guessing a password stays expensive.

A key derivation function turns input material into keys of the size and number you need. The two jobs are usually confused: deriving several keys from one strong secret, and stretching a weak human password into something expensive to attack.

The distinction determines which function to use. HKDF is right for the first, fast and designed to extract and expand existing entropy. Argon2, scrypt or bcrypt are right for the second, deliberately slow and memory-hard so that an attacker with a GPU array gains less advantage. Using a fast KDF on a password is the mistake that turns a database breach into a list of plaintext credentials.

Also known as: kdf

All glossary entries