PBKDF2 vs Argon2 - which is better?

The effect of KDF on unlock speed is independent of the number of items in your vault, since the KDF is only used to extract the account encryption key using your master password. The decryption of your vault contents using the account encryption key always happens after the KDF algorithm has been completed.

One disadvantage of PBKDF2 over Argon2id is that the former only has one adjustment parameter (the number of iterations), and the cost (in terms of key derivation time) increases in equal proportion for you and your attacker as you increase the number of iterations. In contrast, using the Argon2id memory setting, you can disproportionately penalize an attacker by increasing the memory cost. Thus, compared to PBKDF2, you may benefit from setting iterations to a low value (e.g., 2), and increasing the memory setting until you get a reasonable unlock time. If you set iterations=2, parallelism=1, and memory=19 MB, then the cost to an attacker is equivalent to what you will get with the default PBKDF2 setting (600000 iterations). Start from there and increase the memory setting if possible without degrading your unlock time.

1 Like