diff --git a/Makefile b/Makefile index 1e1264619d24bb..961682e607272c 100644 --- a/Makefile +++ b/Makefile @@ -856,7 +856,7 @@ VERSION=v$(RAWVER) .PHONY: doc-only .NOTPARALLEL: doc-only -doc-only: $(apidoc_dirs) $(apidocs_html) $(apidocs_json) out/doc/api/all.html out/doc/api/all.json out/doc/apilinks.json ## Builds the docs with the local or the global Node.js binary. +doc-only: $(apidoc_dirs) $(apidocs_html) $(apidocs_json) out/doc/api/all.html out/doc/api/all.json out/doc/llms.txt out/doc/apilinks.json ## Builds the docs with the local or the global Node.js binary. .PHONY: doc doc: $(NODE_EXE) doc-only ## Build Node.js, and then build the documentation with the new binary. @@ -901,6 +901,22 @@ $(apidocs_html) $(apidocs_json) out/doc/api/all.html out/doc/api/all.json &: $(a fi endif +out/doc/llms.txt: $(apidoc_sources) tools/doc/node_modules | out/doc + @if [ "$(shell $(node_use_openssl_and_icu))" != "true" ]; then \ + echo "Skipping $@ (no crypto and/or no ICU)"; \ + else \ + $(call available-node, \ + $(DOC_KIT) generate \ + -t llms-txt \ + -i doc/api/*.md \ + --ignore $(skip_apidoc_files) \ + -o $(@D) \ + -c ./CHANGELOG.md \ + -v $(VERSION) \ + --type-map doc/type-map.json \ + ) \ + fi + out/doc/apilinks.json: $(wildcard lib/*.js) tools/doc/node_modules | out/doc @if [ "$(shell $(node_use_openssl_and_icu))" != "true" ]; then \ echo "Skipping $@ (no crypto and/or no ICU)"; \ diff --git a/SECURITY.md b/SECURITY.md index 0e88d7b50702fa..ef2509102fe6a3 100644 --- a/SECURITY.md +++ b/SECURITY.md @@ -85,6 +85,7 @@ When reporting security vulnerabilities, reporters must adhere to the following 4. **Report Quality** * Provide clear, detailed steps to reproduce the vulnerability. + * Include reproducible code written in JavaScript. * Include only the minimum proof of concept required to demonstrate the issue. * Remove any malicious payloads or components that could cause harm. diff --git a/doc/api/worker_threads.md b/doc/api/worker_threads.md index 8f4b152bc26a68..720c5640d2065a 100644 --- a/doc/api/worker_threads.md +++ b/doc/api/worker_threads.md @@ -1369,17 +1369,14 @@ port2.postMessage(new Foo()); // Prints: { c: 3 } ``` -This limitation extends to many built-in objects, such as the global `URL` -object: +Some built-in objects cannot be cloned at all. For example, posting a +`URL` object throws a `DataCloneError`: ```js const { port1, port2 } = new MessageChannel(); -port1.onmessage = ({ data }) => console.log(data); - port2.postMessage(new URL('https://example.org')); - -// Prints: { } +// Throws DataCloneError: Cannot clone object of unsupported type. ``` ### `port.hasRef()` diff --git a/test/parallel/test-webcrypto-crypto-job-mode.js b/test/parallel/test-webcrypto-crypto-job-mode.js index 7fd50de44f39b6..327c6a6f154cc4 100644 --- a/test/parallel/test-webcrypto-crypto-job-mode.js +++ b/test/parallel/test-webcrypto-crypto-job-mode.js @@ -163,7 +163,7 @@ async function withObjectPrototypeSetters(names, fn) { { name: 'AES-CBC', iv }, key, Buffer.alloc(16))); - ciphertext[ciphertext.length - 1] ^= 0xff; + ciphertext[0] ^= 0xff; await assert.rejects( subtle.decrypt({ name: 'AES-CBC', iv }, key, ciphertext), diff --git a/tools/eslint/package-lock.json b/tools/eslint/package-lock.json index 5855e2e04ac1f5..6ef33489e6b899 100644 --- a/tools/eslint/package-lock.json +++ b/tools/eslint/package-lock.json @@ -726,9 +726,9 @@ } }, "node_modules/brace-expansion": { - "version": "5.0.5", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-5.0.5.tgz", - "integrity": "sha512-VZznLgtwhn+Mact9tfiwx64fA9erHH/MCXEUfB/0bX/6Fz6ny5EGTXYltMocqg4xFAQZtnO3DHWWXi8RiuN7cQ==", + "version": "5.0.6", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-5.0.6.tgz", + "integrity": "sha512-kLpxurY4Z4r9sgMsyG0Z9uzsBlgiU/EFKhj/h91/8yHu0edo7XuixOIH3VcJ8kkxs6/jPzoI6U9Vj3WqbMQ94g==", "license": "MIT", "dependencies": { "balanced-match": "^4.0.2"