node-tar, the package that unpacks archives in Node.js, got 18 security advisories in one day: a crafted archive can place a link outside the extraction folder; the fix is tar 8, which needs Node 22
Between the evening of 1 December and the early hours of 2 December 2026, 18 advisories were published for node-tar, 17 of them rated high (the tar package on npm). The most serious: with default options, extracting a crafted archive can create a symbolic link that points outside the extraction folder, so system files could be read. Others crash the process or exhaust its memory or CPU. The fixes are in tar 8.x (8.0.5 is the latest), which requires Node 22 or later; the 7.x line has no fix. No exploitation is reported.
How urgent
Plan this week
Who is affected
Node.js programs that extract tar archives from a source you do not fully control using the tar package (node-tar) before 8.0.0, or before 8.0.2 for the memory and CPU problems. That includes many build tools and installers; the npm command line itself bundles tar 7.5.22. On Windows the symbolic link flaw described here does not apply; other flaws do
What to do
Run npm ls tar in each project and in your CI images; update direct and indirect copies to the latest 8.x (8.0.5 on 2 Dec 2026), which needs Node 22 or later; if you cannot move to Node 22, do not extract archives from sources you do not trust with tar 7.x, and extract them in a throwaway folder or container
Published 2 Dec 2026 · Sources last checked 2 Dec 2026No. 153 / 168
Watch the short video
The video loads from YouTube (privacy-enhanced mode) only when you press play.
What happened
node-tar is the tar package on npm: the code many Node.js tools use to unpack tar archives. Between about 19:30 UTC on 1 December 2026 and 02:00 UTC on 2 December, 18 advisories (17 rated high, one medium) were published for it in one batch.
The main problem
The best documented advisory (GHSA-hqgx-p3r3-2cfg) says that on Linux and macOS, extracting a crafted archive with the default options can create a symbolic link whose target is outside the extraction folder. The library promises that links are not allowed to do that. With such a link, a system file such as the account list could be read, according to the advisory. The cause is that the check and the creation of the link treat a backslash differently.
The rest of the batch covers other ways a crafted archive can cause trouble: more ways to escape the folder through links, mismatched reading of PAX headers and long names, and a small archive that makes the process use up memory or CPU or crash.
Why the fix is awkward
- The fixes are in tar 8.x: most advisories say before 8.0.0, the memory and CPU one before 8.0.2, and the maintainers kept releasing parser fixes (8.0.5 on 2 December is the latest).
- tar 8 needs Node 22 or later. The 7.x line, which works with Node 18, has no fix (its last version is 7.5.22).
- The package is everywhere: about 113 million downloads in the week of 24 to 30 November, and the npm command line itself bundles tar 7.5.22, which is inside the affected range. We do not know whether npm's own use of it can be exploited, and we did not test it.
What to do
- Run
npm ls tarin your projects and in the images your CI uses, to see which versions you have, directly or through other packages. - Update to the latest 8.x where you can (Node 22 or later).
- If you are stuck on an older Node, do not extract archives from sources you do not trust with tar 7.x. If you must, do it in a throwaway folder or container with no secretsSecret (API key, token, password) Any piece of text that proves to a service that you are allowed in, such as an API key, a database password or an access token. Tap again to open the glossary.
- Keep your tools and Node up to date: other packages that bundle tar need their own update.
What we could not confirm
No exploitation is reported. The attack needs a program to extract an archive an attacker made, so the risk depends on what each program unpacks. We read the advisories and the package data, not every one of the 18 in detail, and we did not test the flaws.
Related
Glossary: vulnerabilityVulnerability A weakness in software, a setting or a process that an attacker could use to get in or do harm. Tap again to open the glossary, patchPatch (security update) A fix released by the maker of a piece of software to close a flaw or a bug. Tap again to open the glossary, dependency. See also our free tool trust check.
Keep reading
More stories on the same topic or from the same area.
- cross-spawn, an npm package inside countless Node.js projects: command injection on Windows when running .bat or .cmd files; update again, to 7.1.2 or 6.0.10Plan this week 1 Dec 2026
- AWS fixes five flaws in the engine behind Amazon Q Developer's IDE plugins: a crafted project could make the AI agent run commands, and approved MCP servers could be changed without a new prompt; update and restart your IDE (CVE-2026-137931 to CVE-2026-137935)Plan this week 1 Dec 2026
- Laravel: a few crafted JSON requests can take an app offline without logging in. Update to 12.74.0 or 13.44.1 (CVE-2026-142612)Plan this week 3 Dec 2026
Comments
No account needed. Add a nickname if you like, or leave it empty to comment anonymously. Comments are reviewed before they appear. Links are not allowed.
We store your comment, your nickname and a scrambled form of your connection that we use only to limit spam. We do not store your IP address or set cookies. Cloudflare Turnstile checks that you are not a bot.
Sources and verification
- GitHub Advisory GHSA-hqgx-p3r3-2cfg, node-tar: SymbolicLink extraction escapes the extraction directory on non-Windows (2 Dec 2026, official advisory; read 2 Dec 2026) (opens in a new tab)
- GitHub Advisory GHSA-7c32-79xj-j3jp, node-tar: a small archive exhausts memory or CPU through path-reservation bookkeeping (2 Dec 2026, official advisory; read 2 Dec 2026) (opens in a new tab)
- node-tar releases on GitHub, v8.0.5 (2 Dec 2026, official; read 2 Dec 2026) (opens in a new tab)
- npm registry, tar and npm package metadata (versions, Node requirement, bundled dependency, weekly downloads 24 to 30 Nov 2026; read 2 Dec 2026) (opens in a new tab)
We use primary sources first and say when we rely on a news report. Dates are the day we last checked each source.
Spotted a mistake? Email [email protected] and we will correct it and note the change.