You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Apparently the rounds parameter for the method bcrypt.genSaltSync() has an upper bound of 31.
According to the encode_salt in bcrypt.cc.
/** * @param rounds The cost of processing the data. Default 10. * @param minor The minor version of bcrypt to use. Either 'a' or 'b'. Default 'b'. * * @example * import * as bcrypt from 'bcrypt'; * const saltRounds = 10; * * const salt = bcrypt.genSaltSync(saltRounds); */
export declarefunctiongenSaltSync(rounds?: number,minor?: "a"|"b"): string;
For higher numbers a cryptic error message is created which misleads people to thinking that they may have passed in an argument of wrong type or format.
Error: Invalid salt. Salt must be in the form of: $Vers$log2(NumRounds)$saltvalue
The text was updated successfully, but these errors were encountered:
Apparently the rounds parameter for the method bcrypt.genSaltSync() has an upper bound of 31.
According to the encode_salt in bcrypt.cc.
For higher numbers a cryptic error message is created which misleads people to thinking that they may have passed in an argument of wrong type or format.
The text was updated successfully, but these errors were encountered: