-
Notifications
You must be signed in to change notification settings - Fork 4.7k
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
[wasm] Use "node:crypto" to polyfill getRandomValues on older node #78696
Conversation
Tagging subscribers to 'arch-wasm': @lewing Issue Details
Fixes #77927
|
/azp run runtime-wasm |
Azure Pipelines successfully started running 1 pipeline(s). |
removing the insecure polyfill in the test runner breaks v8 |
/azp run runtime-wasm |
Azure Pipelines successfully started running 1 pipeline(s). |
/backport to release/7.0 |
Started backporting to release/7.0: https://github.com/dotnet/runtime/actions/runs/3532333494 |
@maraf you tested this on node v14, v17, and v19. Our tests should be running with v14 (from emsdk). Do we need to make sure that this doesn't break for 17/19/others? IOW, do we need to run a few tests with these different versions of node? |
I think this is a first such thing. @pavelsavara do you have an opinion? |
I would stick to v14 for bulk of the testing for Net8. Or should we make the |
Yeah, having |
@maraf Could you please open an issue to track this? |
"node:crypto"
whenglobalThis.crypto
is undefined or doesn't havegetRandomValues
.getRandomValues
fromwebcrypto
when availablegetRandomValues
usingrandomBytes
on even older nodeFixes #77927