1
$\begingroup$

I'm using PBKDF2 SHA 256 with 100 000 iterations to generate a secret.

I want to increase the cost of brute forcing the passphrase I use to generate the secret.

I'm thinking of using scrypt after the pbkdf2 computation.

scrypt(pbkdf2(passphrase, salt))

Is there a better way?

$\endgroup$
3
$\begingroup$

I would recommend you use Argon2, which is both a slow KDF like PBKDF2, as well as a memory-hard function designed to improve resistance to GPUs and FPGAs like scrypt. You can select both the number of iterations and amount of memory used in Argon2, and they can be changed independently (unlike scrypt, where the memory and time difficulties cannot be modified separately, and high time implies high memory-usage). This can be done on existing password hashes to maintain backward compatibility, but I would suggest you convert the old scheme (PBKDF2 with scrypt) into one using just Argon2 as soon as a user next logs in and supplies their password.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.