-
-
Notifications
You must be signed in to change notification settings - Fork 33.9k
crypto: remove webcrypto HKDF and PBKDF2 default-applied lengths #44945
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
crypto: remove webcrypto HKDF and PBKDF2 default-applied lengths #44945
Conversation
|
Review requested:
|
a761f04 to
924d59d
Compare
924d59d to
7f61102
Compare
aduh95
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM with or without my suggestion
| let result; | ||
| try { | ||
| result = await pbkdf2Promise(raw, salt, iterations, length / 8, hash); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| let result; | |
| try { | |
| result = await pbkdf2Promise(raw, salt, iterations, length / 8, hash); | |
| try { | |
| const { buffer } = await pbkdf2Promise(raw, salt, iterations, length / 8, hash); | |
| return buffer; |
| resolve(result.buffer); | ||
| }); | ||
| }); | ||
| return result.buffer; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| return result.buffer; |
|
Landed in 40a0757 |
PR-URL: #44945 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com> Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
PR-URL: #44945 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com> Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Both HKDF and PBKDF2 do not specify a default-applied length, this removes a possibly forgotten default used for initial development?