Filip Skokan
207ffbeb07
crypto: use CryptoKey internal slots in Web Cryptography
...
PR-URL: https://github.com/nodejs/node/pull/59538
Fixes: https://github.com/nodejs/node/issues/59535
Fixes: https://github.com/nodejs/node/issues/59534
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com >
2025-08-21 19:01:15 +02:00
Filip Skokan
4276516781
crypto: normalize RsaHashedKeyParams publicExponent
...
Fixes: https://github.com/nodejs/node/issues/59535
PR-URL: https://github.com/nodejs/node/pull/59538
Fixes: https://github.com/nodejs/node/issues/59534
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com >
2025-08-21 19:01:15 +02:00
Node.js GitHub Bot
0821b446fb
deps: update undici to 7.14.0
...
PR-URL: https://github.com/nodejs/node/pull/59507
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Matthew Aitken <maitken033380023@gmail.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com >
Reviewed-By: Richard Lau <richard.lau@ibm.com >
2025-08-21 19:01:15 +02:00
Tim Perry
dafee05358
http2: add support for raw header arrays in h2Stream.respond()
...
PR-URL: https://github.com/nodejs/node/pull/59455
Reviewed-By: Ethan Arrowood <ethan@arrowood.dev >
Reviewed-By: Gerhard Stöbich <deb2001-github@yahoo.de >
2025-08-21 19:01:14 +02:00
Khafra
8dc6f5b696
stream: add brotli support to CompressionStream and DecompressionStream
...
Refs: https://github.com/whatwg/compression/issues/34
PR-URL: https://github.com/nodejs/node/pull/59464
Reviewed-By: Mattias Buelens <mattias@buelens.com >
Reviewed-By: Jason Zhang <xzha4350@gmail.com >
Reviewed-By: Ethan Arrowood <ethan@arrowood.dev >
2025-08-21 19:01:14 +02:00
Pietro Marchini
ed339580af
test: lazy-load internalTTy
...
PR-URL: https://github.com/nodejs/node/pull/59517
Reviewed-By: Moshe Atlow <moshe@atlow.co.il >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Chemi Atlow <chemi@atlow.co.il >
2025-08-21 19:01:14 +02:00
Pietro Marchini
99da7fbe11
tools: avoid parsing test files twice
...
PR-URL: https://github.com/nodejs/node/pull/59526
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com >
2025-08-21 19:01:14 +02:00
Antoine du Hamel
fe86bc6da8
test: fix test-setproctitle status when ps is not available
...
PR-URL: https://github.com/nodejs/node/pull/59523
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
2025-08-21 19:01:14 +02:00
Rafael Gonzaga
1784c35a49
doc: add security incident reponse plan
...
PR-URL: https://github.com/nodejs/node/pull/59470
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Ulises Gascón <ulisesgascongonzalez@gmail.com >
2025-08-21 19:01:13 +02:00
Joyee Cheung
2fafe4c3bb
esm: link modules synchronously when no async loader hooks are used
...
When no async loader hooks are registered, perform the linking as
synchronously as possible to reduce the chance of races from the
the shared module loading cache.
PR-URL: https://github.com/nodejs/node/pull/59519
Fixes: https://github.com/nodejs/node/issues/59366
Refs: https://github.com/abejfehr/node-22.18-issue-repro
Reviewed-By: Geoffrey Booth <webadmin@geoffreybooth.com >
Reviewed-By: Filip Skokan <panva.ip@gmail.com >
Reviewed-By: Chengzhong Wu <legendecas@gmail.com >
2025-08-21 19:01:13 +02:00
Joyee Cheung
5347c4997a
esm: show race error message for inner module job race
...
The race can not only happen when the ESM is loaded by
the CommonJS loader, but can also happen to inner
module jobs in the dependency graph.
PR-URL: https://github.com/nodejs/node/pull/59519
Fixes: https://github.com/nodejs/node/issues/59366
Refs: https://github.com/abejfehr/node-22.18-issue-repro
Reviewed-By: Geoffrey Booth <webadmin@geoffreybooth.com >
Reviewed-By: Filip Skokan <panva.ip@gmail.com >
Reviewed-By: Chengzhong Wu <legendecas@gmail.com >
2025-08-21 19:01:13 +02:00
Filip Skokan
14741539a7
crypto: support ML-KEM, DHKEM, and RSASVE key encapsulation mechanisms
...
PR-URL: https://github.com/nodejs/node/pull/59491
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com >
2025-08-21 19:01:13 +02:00
Richard Lau
89dd770889
build: do not set -mminimal-toc with clang
...
This is a gcc-only option, do not pass to clang.
PR-URL: https://github.com/nodejs/node/pull/59484
Refs: https://github.com/nodejs/build/issues/4091
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Darshan Sen <raisinten@gmail.com >
2025-08-21 19:01:12 +02:00
Krishnadas PC
b4a23d6a69
http: trim off brackets from IPv6 addresses with string operations
...
This is simpler than using regular expressions.
PR-URL: https://github.com/nodejs/node/pull/59420
Reviewed-By: Daniel Lemire <daniel@lemire.me >
Reviewed-By: Vinícius Lourenço Claro Cardoso <contact@viniciusl.com.br >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
2025-08-21 19:01:12 +02:00
Lee Jiho
027b861ca1
benchmark, test: replace CRLF variable with string literal
...
PR-URL: https://github.com/nodejs/node/pull/59466
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com >
Reviewed-By: Paolo Insogna <paolo@cowtech.it >
Reviewed-By: Tim Perry <pimterry@gmail.com >
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com >
Reviewed-By: Daeyeon Jeong <daeyeon.dev@gmail.com >
2025-08-21 19:01:12 +02:00
Pietro Marchini
e517792973
test: add parseTestMetadata support
...
PR-URL: https://github.com/nodejs/node/pull/59503
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Reviewed-By: Chemi Atlow <chemi@atlow.co.il >
2025-08-21 19:01:12 +02:00
Alex Yang
b962560240
doc: clarify maxRSS unit in process.resourceUsage()
...
PR-URL: https://github.com/nodejs/node/pull/59511
Fixes: https://github.com/nodejs/node/issues/59508
Reviewed-By: Daeyeon Jeong <daeyeon.dev@gmail.com >
Reviewed-By: Chengzhong Wu <legendecas@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2025-08-21 19:01:11 +02:00
d3afc63c44
crypto: add argon2() and argon2Sync() methods
...
Co-authored-by: Filip Skokan <panva.ip@gmail.com >
Co-authored-by: James M Snell <jasnell@gmail.com >
PR-URL: https://github.com/nodejs/node/pull/50353
Reviewed-By: Ethan Arrowood <ethan@arrowood.dev >
Reviewed-By: Filip Skokan <panva.ip@gmail.com >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
2025-08-21 19:01:11 +02:00
RANDRIAMANANTENA Narindra Tiana Annaick
e6a6cdb9df
doc: add missing Zstd strategy constants
...
PR-URL: https://github.com/nodejs/node/pull/59312
Fixes: https://github.com/nodejs/node/issues/59290
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
2025-08-21 19:01:11 +02:00
Node.js GitHub Bot
31092972d6
test: update WPT for WebCryptoAPI to ff26d9b307
...
PR-URL: https://github.com/nodejs/node/pull/59497
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Filip Skokan <panva.ip@gmail.com >
Reviewed-By: Jason Zhang <xzha4350@gmail.com >
2025-08-21 19:01:11 +02:00
hotpineapple
e13de4542f
child_process: remove unsafe array iteration
...
PR-URL: https://github.com/nodejs/node/pull/59347
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
2025-08-21 19:01:11 +02:00
Filip Skokan
4fe383e45a
crypto: support ML-DSA spki/pkcs8 key formats in Web Cryptography
...
PR-URL: https://github.com/nodejs/node/pull/59365
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Ethan Arrowood <ethan@arrowood.dev >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
2025-08-21 19:01:10 +02:00
Filip Skokan
93fc80a1e2
lib: refactor kSupportedAlgorithms
...
PR-URL: https://github.com/nodejs/node/pull/59365
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Ethan Arrowood <ethan@arrowood.dev >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
2025-08-21 19:01:10 +02:00
Filip Skokan
a95386fbf9
crypto: subject some algorithms in Web Cryptography on BoringSSL absence
...
PR-URL: https://github.com/nodejs/node/pull/59365
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Ethan Arrowood <ethan@arrowood.dev >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
2025-08-21 19:01:10 +02:00
Filip Skokan
3f47a2fb63
crypto: add ChaCha20-Poly1305 Web Cryptography algorithm
...
PR-URL: https://github.com/nodejs/node/pull/59365
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Ethan Arrowood <ethan@arrowood.dev >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
2025-08-21 19:01:10 +02:00
Filip Skokan
16afd103cc
test: add Web Cryptography wrap/unwrap vectors
...
PR-URL: https://github.com/nodejs/node/pull/59365
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Ethan Arrowood <ethan@arrowood.dev >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
2025-08-21 19:01:09 +02:00
Filip Skokan
a6a31cb467
doc: compress Web Cryptography Algorithm matrix
...
PR-URL: https://github.com/nodejs/node/pull/59365
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Ethan Arrowood <ethan@arrowood.dev >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
2025-08-21 19:01:09 +02:00
Filip Skokan
5598baf34e
test: cleanup test-webcrypto-supports
...
PR-URL: https://github.com/nodejs/node/pull/59365
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Ethan Arrowood <ethan@arrowood.dev >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
2025-08-21 19:01:09 +02:00
Filip Skokan
6fcce9058a
crypto: add subtle.getPublicKey() utility function in Web Cryptography
...
PR-URL: https://github.com/nodejs/node/pull/59365
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Ethan Arrowood <ethan@arrowood.dev >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
2025-08-21 19:01:09 +02:00
Filip Skokan
76cde76429
crypto: add SHA-3 Web Cryptography digest algorithms
...
PR-URL: https://github.com/nodejs/node/pull/59365
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Ethan Arrowood <ethan@arrowood.dev >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
2025-08-21 19:01:08 +02:00
Filip Skokan
247d017501
crypto: add SHAKE Web Cryptography digest algorithms
...
PR-URL: https://github.com/nodejs/node/pull/59365
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Ethan Arrowood <ethan@arrowood.dev >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
2025-08-21 19:01:08 +02:00
Filip Skokan
f4fbcca5ce
crypto: add SubtleCrypto.supports feature detection in Web Cryptography
...
PR-URL: https://github.com/nodejs/node/pull/59365
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Ethan Arrowood <ethan@arrowood.dev >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
2025-08-21 19:01:08 +02:00
Filip Skokan
a55382214f
crypto: support ML-DSA in Web Cryptography
...
PR-URL: https://github.com/nodejs/node/pull/59365
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Ethan Arrowood <ethan@arrowood.dev >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
2025-08-21 19:01:08 +02:00
Ruben Bridgewater
b68e0d1eca
util: fix error's namespaced node_modules highlighting using inspect
...
When inspecting errors, node_modules are highlighted with an
underscore. So far namespaced modules only highlighted the namespace
but not the rest of the module name. This is fixed by matching the
full name.
As drive-by it improves the performance slightly by removing the
regular expression in favor of indexOf to identify the right spot.
PR-URL: https://github.com/nodejs/node/pull/59446
Reviewed-By: Jordan Harband <ljharb@gmail.com >
2025-08-21 19:01:07 +02:00
Shima Ryuhei
ebe9272dae
inspector: initial support websocket inspection
...
Refs: https://github.com/nodejs/node/issues/53946
PR-URL: https://github.com/nodejs/node/pull/59404
Reviewed-By: Chengzhong Wu <legendecas@gmail.com >
2025-08-21 19:01:07 +02:00
Mark S. Miller
15ae21b88a
util: add some additional error classes to wellKnownPrototypes
...
PR-URL: https://github.com/nodejs/node/pull/59456
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
2025-08-21 19:01:07 +02:00
Moshe Atlow
e076f7857c
test_runner: add option to rerun only failed tests
...
PR-URL: https://github.com/nodejs/node/pull/59443
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: Pietro Marchini <pietro.marchini94@gmail.com >
Reviewed-By: Chemi Atlow <chemi@atlow.co.il >
2025-08-21 19:01:07 +02:00
Filip Skokan
2b7a7a525e
doc,crypto: add supported asymmetric key types section
...
PR-URL: https://github.com/nodejs/node/pull/59492
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
2025-08-21 19:01:07 +02:00
BCD1me
e7809d6ddb
test: make test-debug-process locale-independent
...
The test `test/parallel/test-debug-process.js` fails on non-English
Windows systems due to a locale-dependent error message string.
The test asserts that a call to `process._debugProcess()` on a
terminated process throws an error with the message
`'The system cannot find the file specified.'`.
While this holds true on an English Windows system,
the test fails on systems with a different display language.
The underlying `WinapiErrnoException` function correctly retrieves the
localized error message from the OS. For example, on a Korean system,
the message is "지정된 파일을 찾을 수 없습니다.". This mismatch causes
an `AssertionError`.
This behavior can be verified directly in PowerShell:
# On Windows with English (US) display language
PS> (New-Object System.ComponentModel.Win32Exception 2).Message
The system cannot find the file specified.
# On Windows with Korean display language
PS> (New-Object System.ComponentModel.Win32Exception 2).Message
지정된 파일을 찾을 수 없습니다.
To make the test robust and environment-agnostic, this commit changes
the assertion to check the language-independent `error.errno` property,
which is consistently `2` for this type of error, instead of the
localized `error.message`.
PR-URL: https://github.com/nodejs/node/pull/59254
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Reviewed-By: Stefan Stojanovic <stefan.stojanovic@janeasystems.com >
2025-08-21 19:01:06 +02:00
Allon Murienik
8f8960cfcb
doc: fix the version tls.DEFAULT_CIPHERS was added
...
42be7f6a03 (originally included in 19.8.0
and later backported to 18.16.0) added documentation on how to use
`tls.DEFAULT_CIPHERS`.
However, that commit added the documentation with the version specified
as `REAPLCEME`, causing the published documentation to state that
`tls.DEFAULT_CIPHERS` was added in 19.8.0 and 18.16.0, which is
incorrect - that commit states that `tls.DEFAULT_CIPHERS` already
existed, and the only thing it added was an explanation on how to use
it.
In fact, by examining the git log, it can be seen that
`tls.DEFAULT_CIPHERS` was added by commit
af80e7bc6e , which was included in 0.11.3.
Fixes: https://github.com/nodejs/node/issues/59246
PR-URL: https://github.com/nodejs/node/pull/59247
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2025-08-21 19:01:06 +02:00
hotpineapple
9e76089f1a
doc: clarify glob's exclude option behavior
...
Add a note that negation patterns are not supported.
PR-URL: https://github.com/nodejs/node/pull/59245
Reviewed-By: Moshe Atlow <moshe@atlow.co.il >
2025-08-21 19:01:06 +02:00
Joyee Cheung
ca7856e73c
test: mark test-wasi-pthread as flaky
...
It has been flaking the CI for two months with no one working on
a fix. Mark it as flaky.
PR-URL: https://github.com/nodejs/node/pull/59488
Reviewed-By: Filip Skokan <panva.ip@gmail.com >
Reviewed-By: Chengzhong Wu <legendecas@gmail.com >
2025-08-21 19:01:06 +02:00
Joyee Cheung
0ecd82197f
test: split test-wasi.js
...
There is a flake in the tests. Split them so that people stop
piling more test cases that flake the monolith.
PR-URL: https://github.com/nodejs/node/pull/59488
Reviewed-By: Filip Skokan <panva.ip@gmail.com >
Reviewed-By: Chengzhong Wu <legendecas@gmail.com >
2025-08-21 19:01:05 +02:00
Tobias Nießen
716750fcf8
src: fix order of CHECK_NOT_NULL/dereference
...
`ASYNC_THROW_IF_INSUFFICIENT_PERMISSIONS` may dereference
`req_wrap_async`, so `CHECK_NOT_NULL(req_wrap_async)` should be used
before and not after.
PR-URL: https://github.com/nodejs/node/pull/59487
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Richard Lau <richard.lau@ibm.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Ulises Gascón <ulisesgascongonzalez@gmail.com >
2025-08-21 19:01:05 +02:00
Tobias Nießen
99e4a12731
sqlite: avoid useless call to FromMaybe()
...
PR-URL: https://github.com/nodejs/node/pull/59490
Reviewed-By: Zeyu "Alex" Yang <himself65@outlook.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com >
2025-08-21 19:01:05 +02:00
Chengzhong Wu
65c870e6cb
node-api: clarify enum value ABI stability
...
PR-URL: https://github.com/nodejs/node/pull/59085
Refs: https://github.com/nodejs/node/pull/58879
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Vladimir Morozov <vmorozov@microsoft.com >
2025-08-21 19:01:05 +02:00
Rich Trott
9a6a8e319b
tools: update coverage GitHub Actions to fixed version
...
Refs: https://github.com/codecov/codecov-action/pull/1859
Refs: https://github.com/codecov/codecov-action/issues/1858
PR-URL: https://github.com/nodejs/node/pull/59512
Reviewed-By: Filip Skokan <panva.ip@gmail.com >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Zeyu "Alex" Yang <himself65@outlook.com >
Reviewed-By: Moshe Atlow <moshe@atlow.co.il >
Reviewed-By: Daeyeon Jeong <daeyeon.dev@gmail.com >
Reviewed-By: Pietro Marchini <pietro.marchini94@gmail.com >
2025-08-21 19:01:05 +02:00
Asaf Federman
44a8ecf8d4
src: assert memory calc for max-old-space-size-percentage
...
Add validation to ensure that --max-old-space-size-percentage cannot
be used when available memory cannot be calculated, preventing
undefined behavior when memory detection fails.
Also enhance test-process-constrained-memory.js to support testing
in constrained environments where memory calculation may fail.
PR-URL: https://github.com/nodejs/node/pull/59460
Reviewed-By: theanarkh <theratliter@gmail.com >
Reviewed-By: Moshe Atlow <moshe@atlow.co.il >
2025-08-21 19:01:04 +02:00
0hm☘️
3462b46fca
src: use simdjson::pad
...
PR-URL: https://github.com/nodejs/node/pull/59391
Refs: https://github.com/nodejs/node/issues/59389
Reviewed-By: Daniel Lemire <daniel@lemire.me >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2025-08-21 19:01:04 +02:00
Joyee Cheung
0930c218d6
test: deflake connection refused proxy tests
...
Previously the tests tries to use UDP ports to fabricate
ECONNREFUSED which is incorrect - UDP ports use different
namespaces, so the port can have valid TCP listeners.
This patch updates the test to fabricate the ECONNREFUSED
error by using the port of a recently closed HTTP server.
If the ephemeral port happens to be still open, try to get
a different one until we succeed.
PR-URL: https://github.com/nodejs/node/pull/59476
Refs: https://github.com/nodejs/reliability/issues/1287
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Filip Skokan <panva.ip@gmail.com >
2025-08-21 19:01:04 +02:00