Replies: 3 comments 1 reply
-
Hello @seriousme Your assessment is somewhat incorrect. The plan is to drop the Node.js special handling in a new major release when all Active / Maintained Node.js LTS releases have WebCryptoAPI non-experimental and global-enabled. The earliest that statement is true is April 2025 (https://github.com/nodejs/Release/) since LTS/18 does not have webcrypto enabled as global (which is why that test flag IS relevant and needed) |
Beta Was this translation helpful? Give feedback.
-
I just tried 18.20.4: $ node
Welcome to Node.js v18.20.4.
Type ".help" for more information.
> const { subtle} = crypto;
undefined
> subtle
SubtleCrypto {}
> |
Beta Was this translation helpful? Give feedback.
-
Interesting! You are right, in a script it behaves differently. |
Beta Was this translation helpful? Give feedback.
-
I noticed that this project uses 2 source trees for the runtime:
However NodeJS as of v18.17 has full support for Webcrypto
Maybe its an idea to remove the special handing of node:crypto and switch to webcrypto for Nodejs as well.
I replaced runtime/node by a symlink to runtime/browser, ran:
and all tests passed.
I also noticed:
jose/.node_flags.sh
Lines 7 to 9 in 8916c26
Which is not so relevant anymore ;-)
Kind regards,
Hans
Beta Was this translation helpful? Give feedback.
All reactions