Node.bcrypt.js: Salt rounds 20 not working

Created on 22 Jun 2019  路  2Comments  路  Source: kelektiv/node.bcrypt.js

Bcrypt doesn't seem to work when Salt round is passed 20

var token = await bcrypt.hash('abcxyz', 20);
// It just hangs there

But passing 10 works perfectly.

question

Most helpful comment

Salt rounds 20 will make 10^20, 2^20 rounds, this will take almost 6 years to return a result.

All 2 comments

Salt rounds 20 will make 10^20, 2^20 rounds, this will take almost 6 years to return a result.

Not really 6 years. More like 1 - 2 minutes depending on your CPU. And it's 2^20 rounds.

Was this page helpful?
0 / 5 - 0 ratings