Filip Skokan
45550ee0f3
test: update tests to run with OpenSSL >= 3.0 FIPS mode
...
Signed-off-by: Filip Skokan <panva.ip@gmail.com >
PR-URL: https://github.com/nodejs/node/pull/64960
Fixes: https://github.com/nodejs/node/issues/48379
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Aviv Keller <me@aviv.sh >
2026-08-05 15:38:11 +00:00
Filip Skokan
d90d9d55ad
crypto: limit KangarooTwelveParams customization to 512 bytes
...
To align with a future OpenSSL-imposed limit.
Signed-off-by: Filip Skokan <panva.ip@gmail.com >
PR-URL: https://github.com/nodejs/node/pull/64557
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2026-07-19 15:58:25 +00:00
Node.js GitHub Bot
fd3f870219
test: update WPT for WebCryptoAPI to ec2fee39a4
...
PR-URL: https://github.com/nodejs/node/pull/64435
Reviewed-By: Filip Skokan <panva.ip@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2026-07-14 00:55:29 +00:00
Filip Skokan
29890721cd
crypto: reject small-order EdDSA points during verify
...
Return false for Ed25519 and Ed448 one-shot verification when the public
key or signature R component is a known low-order point. This keeps key
import behavior unchanged while making WebCrypto verification match WPT
expectations across OpenSSL variants.
Remove the stale WPT expected-failure entry and add focused regression
coverage for both curves.
Closes: https://github.com/nodejs/node/issues/54572
Signed-off-by: Filip Skokan <panva.ip@gmail.com >
PR-URL: https://github.com/nodejs/node/pull/64026
Fixes: https://github.com/nodejs/node/issues/54572
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
2026-06-23 20:44:57 +02:00
Node.js GitHub Bot
bb3f7e80b2
test: update WPT for WebCryptoAPI to 0c413fb56b
...
PR-URL: https://github.com/nodejs/node/pull/63647
Reviewed-By: Filip Skokan <panva.ip@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2026-06-01 19:03:32 +00:00
Node.js GitHub Bot
b5659d14ab
test: update WPT for WebCryptoAPI to 97bbc7247a
...
PR-URL: https://github.com/nodejs/node/pull/63417
Reviewed-By: Filip Skokan <panva.ip@gmail.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2026-05-20 20:21:23 +00:00
Filip Skokan
550f195277
crypto: wire ML-DSA and ML-KEM for use when using BoringSSL
...
Signed-off-by: Filip Skokan <panva.ip@gmail.com >
PR-URL: https://github.com/nodejs/node/pull/63255
Refs: https://github.com/electron/electron/issues/36256
Refs: https://github.com/electron/electron/issues/41720
Refs: https://github.com/electron/electron/pull/51127
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
2026-05-17 18:18:14 +00:00
Filip Skokan
be9f78f0dc
crypto: wire ChaCha20-Poly1305 in Web Cryptography when using BoringSSL
...
Signed-off-by: Filip Skokan <panva.ip@gmail.com >
PR-URL: https://github.com/nodejs/node/pull/63255
Refs: https://github.com/electron/electron/issues/36256
Refs: https://github.com/electron/electron/issues/41720
Refs: https://github.com/electron/electron/pull/51127
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
2026-05-17 18:18:13 +00:00
Filip Skokan
07431982bb
crypto: wire AES-KW in Web Cryptography when using BoringSSL
...
Signed-off-by: Filip Skokan <panva.ip@gmail.com >
PR-URL: https://github.com/nodejs/node/pull/63255
Refs: https://github.com/electron/electron/issues/36256
Refs: https://github.com/electron/electron/issues/41720
Refs: https://github.com/electron/electron/pull/51127
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
2026-05-17 18:18:11 +00:00
Filip Skokan
e107f3c3c0
src: add BoringSSL EVP enumeration fallback
...
BoringSSL declares EVP_CIPHER_do_all_sorted and
EVP_MD_do_all_sorted, but stock no-decrepit builds do not provide
those symbols. Add a Node build flag that keeps ncrypto and its
dependents on a local BoringSSL fallback list when libdecrepit is
absent.
Keep embedders that provide the EVP enumeration symbols on the normal
OpenSSL-compatible path, matching Electron's patched BoringSSL build.
Signed-off-by: Filip Skokan <panva.ip@gmail.com >
PR-URL: https://github.com/nodejs/node/pull/63206
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
2026-05-11 15:36:55 +00:00
Filip Skokan
0bd46c151b
crypto: improve accuracy of SubtleCrypto.supports
...
Signed-off-by: Filip Skokan <panva.ip@gmail.com >
PR-URL: https://github.com/nodejs/node/pull/63104
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
2026-05-06 13:49:06 +00:00
Filip Skokan
e0cab9dcf7
crypto: add TurboSHAKE and KangarooTwelve Web Cryptography algorithms
...
PR-URL: https://github.com/nodejs/node/pull/62183
Refs: https://wicg.github.io/webcrypto-modern-algos/#kangarootwelve
Refs: https://wicg.github.io/webcrypto-modern-algos/#turboshake
Refs: https://www.rfc-editor.org/rfc/rfc9861.html
Refs: https://redirect.github.com/openssl/openssl/issues/30304
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
2026-03-26 22:04:32 +01:00
Node.js GitHub Bot
1baafcc882
test: update WPT resources, interfaces and WebCryptoAPI
...
PR-URL: https://github.com/nodejs/node/pull/62389
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2026-03-26 10:47:22 +01:00
Filip Skokan
b328bf74bd
lib,src: implement QuotaExceededError as DOMException-derived interface
...
Implement QuotaExceededError as a DOMException-derived interface per the
WebIDL specification update.
QuotaExceededError is now a proper constructor exposed as a global
[Exposed=*] interface that extends DOMException with optional `quota`
and `requested` attributes (both nullable doubles, defaulting to null).
The constructor validates that quota and requested are finite,
non-negative, and that requested is not less than quota when both are
provided.
QuotaExceededError is [Serializable] and supports structuredClone,
preserving the quota and requested values across the serialization
boundary.
Callers updated:
- crypto.getRandomValues() now throws a QuotaExceededError instance
- WebStorage (C++) now constructs QuotaExceededError directly
Refs: https://redirect.github.com/whatwg/webidl/pull/1465
Fixes: https://github.com/nodejs/node/issues/58987
PR-URL: https://github.com/nodejs/node/pull/62293
Reviewed-By: Mattias Buelens <mattias@buelens.com >
Reviewed-By: Chengzhong Wu <legendecas@gmail.com >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2026-03-19 14:41:50 +01:00
Node.js GitHub Bot
597fc3a7f5
test: update WPT for WebCryptoAPI to c58b6f4e0e
...
PR-URL: https://github.com/nodejs/node/pull/60702
Reviewed-By: Filip Skokan <panva.ip@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Richard Lau <richard.lau@ibm.com >
2025-11-15 12:52:12 +00:00
Filip Skokan
8e5c5b3b04
test: update WPT resources,WebCryptoAPI,webstorage
...
PR-URL: https://github.com/nodejs/node/pull/59311
Refs: https://github.com/nodejs/node/issues/58987
Refs: https://github.com/nodejs/node/issues/59310
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2025-08-03 11:31:39 +00:00
Livia Medeiros
c11c7be36e
crypto: forbid passing Float16Array to getRandomValues()
...
PR-URL: https://github.com/nodejs/node/pull/57880
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Filip Skokan <panva.ip@gmail.com >
2025-04-17 07:26:53 +00:00
Filip Skokan
0116e80827
crypto: allow non-multiple of 8 in SubtleCrypto.deriveBits
...
PR-URL: https://github.com/nodejs/node/pull/55296
Reviewed-By: James M Snell <jasnell@gmail.com >
2024-11-23 08:22:12 -08:00
Filip Skokan
c63255b0c0
test,crypto: update WebCryptoAPI WPT
...
PR-URL: https://github.com/nodejs/node/pull/55512
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2024-10-26 07:41:27 +00:00
Filip Skokan
fc02b88f89
test,crypto: update WebCryptoAPI WPT
...
Refs: #54572
Refs: #54468
PR-URL: https://github.com/nodejs/node/pull/54593
Refs: https://github.com/nodejs/node/issues/54572
Refs: https://github.com/nodejs/node/pull/54468
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2024-08-29 16:46:40 +00:00