Repository navigation
fix(deps)!: update tar to 8 and pacote/arborist to the npm 11 stack - #6243
Open
edusperoni wants to merge 1 commit into
Open
edusperoni wants to merge 1 commit into
edusperoni wants to merge 1 commit into
Conversation
|
Note Currently processing new changes in this PR. This may take a few minutes, please wait...
|
3 of 5 tasks
tar 7 is affected by a set of extraction advisories (symlink escapes, PAX header injection, memory amplification) that are fixed only in 8.x. pacote 21 and @npmcli/arborist 9 pull in sigstore, tuf-js, npm-packlist and ignore-walk releases affected by the minimatch DoS; pacote 22 and arborist 10 clear those. tar 8 replaces the stream API with promises, so extractPackage passes the tarball as the `input` option of tar.x() and awaits it. The extractPackage tests now extract a real tarball instead of a stubbed stream, and run instead of being skipped. All three packages require Node ^22.22.2 || ^24.15.0 || >=26.0.0, so the engines range, the test matrix and the release workflow move with them. The doctor package keeps its own Node 20 leg. BREAKING CHANGE: Node.js 20 is no longer supported. The CLI requires Node ^22.22.2 || ^24.15.0 || >=26.0.0.
edusperoni
force-pushed
the
chore/npm11-node22-deps
branch
from
December 4, 2026 03:52
9e409ac to
25492be
Compare
edusperoni
marked this pull request as ready for review
December 4, 2026 03:53
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

PR Checklist
I have read the CLA and I hereby sign the CLA).What is the current behavior?
Stacked on #6242. After that PR, a fresh install of the published manifest still reports 13 advisories:
tar7.5.22 (high). About 20 extraction advisories: symlink escapes, PAX header injection, path-reservation memory amplification and others. Almost all are fixed only in 8.x. The CLI extracts every template and platform package withtar.x()inPacoteService.extractPackage.pacote21 and@npmcli/arborist9 (moderate). They pull insigstore,tuf-js,@tufjs/models,npm-packlist,ignore-walkand@npmcli/metavuln-calculatorreleases that sit on the vulnerableminimatch10.What is the new behavior?
tar7.5.22 → 8.1.2,pacote21.5.1 → 22.0.2,@npmcli/arborist9.1.8 → 10.0.5. The lockfile changes stay inside npm's own package stack, and no dev dependencies change.extractPackagenow passes the tarball as theinputoption oftar.x()and awaits it, instead of piping into a writable stream. The previous version also kept going after a failedpacote.tarball(), which now just throws.extractPackagetests weredescribe.skip. They now run and extract a real tarball: the strip ofpackage/, thefilteroption, a fetch error and a corrupt archive.engines.nodebecomes^22.22.2 || ^24.15.0 || >=26.0.0, which matches whatpacote22 and@npmcli/arborist10 declare. The CLI test matrix drops 20.x. The CLI release workflow moves from Node 22.14.0, which is outside the range, to 22.23.5. The doctor package's jobs are unchanged and keep their Node 20 leg.Audit: a fresh consumer install goes from 13 to 3 (2 moderate, 1 high). All three come from npm's own packages and can only be fixed upstream:
tar7.5.24 (high), viapacote22 (^7.4.3) andnode-gyp13 (^7.5.4). The CLI's own extraction uses tar 8.minimatch10.2.6, via@npmcli/arborist10 and its workspace and package-json helpers (^10.0.3). This is also why@npmcli/arboristitself is flagged.Verification:
npm testpasses (141 files, 2450 passed, 0 skipped), and so doestsc -p tsconfig.release.json. I also ranns createend to end with the built CLI and@nativescript/template-blank-ts, which fetches and extracts throughpacote22 andtar8.Notes for review
IPacoteExtractOptions.filterinlib/definitions/pacote-service.d.tsnow receives atar.ReadEntryinstead oftar.FileStat, which tar 8 no longer exports. No caller in the CLI passes a filter.BREAKING CHANGES:
The CLI no longer supports Node.js 20, which reached end of life in April 2026. The supported range also excludes 22.x before 22.22.2, 24.x before 24.15.0, and the odd releases 23 and 25. On an unsupported version the CLI prints the "Support for Node.js … is not verified" warning, but it still runs. The hard floor in
verify-node-version.tsis unchanged.Migration steps:
Upgrade to Node.js 22.22.2 or later on 22.x, 24.15.0 or later on 24.x, or Node.js 26 and later.
Summary by CodeRabbit
packagedirectory and supports filtering entries with their full archive entry details.