-
Notifications
You must be signed in to change notification settings - Fork 212
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Max Salt Length Issue? #1723
Comments
Further digging and this does appear to be a very intentional choice and in conflict with the traits/password-hash/src/salt.rs Lines 55 to 78 in 8bb3381
I'd very much like to see this limit up-ed, anyone that decided to use >64byte salts via another implementation cannot properly compare their old hashes via this library. Further:
I'm open to other suggestions, hoping this is as simple as changing the defined max size constant. Please help my poor orphaned and unverifiable hashes that used big-salts. |
This restriction applies only to the PHC format. You can call methods on the |
Yes, the cap in the PHC format is mandated by the spec, and as @newpavlov said, if you want to avoid that don't go through the PHC string format APIs. |
I see we've capped the max salt length to 64 bytes.
traits/password-hash/src/salt.rs
Line 112 in 8bb3381
I am re-implementing an old argon2id hash implementation that used salt of length of ~410bytes. As far as I was aware there is no max-salt length for argon2id but perhaps I'm mistaken?
EDIT: Quick google search and it does appear we should be able to use salts much larger than 64 bytes. Sorry if this is the wrong place to ask about this, new to rust and crates ecosystem.
The text was updated successfully, but these errors were encountered: