GitHub’s Advisory Database has published a batch of security notices for the npm tar package, also known as node-tar, covering weaknesses in archive parsing, extraction and symbolic-link handling. The notices were added to GitHub’s database on December 2, after the related CVE records appeared in the National Vulnerability Database on December 1. The package maintainer had posted the underlying repository advisories on November 28, the same day the project released node-tar 8.0.0.
Several of the reported issues carry high severity ratings. CVE-2026-140238 affects the way node-tar reads POSIX PAX extended-header records. The parser splits records at newline characters instead of following the byte lengths defined by the archive format. A crafted archive can use that difference to forge file attributes, including the path where an entry is extracted. The maintainer’s advisory documents a Windows npm installation test in which the issue overwrote a package’s package.json file and executed an injected postinstall script. That demonstrated installation chain applies to Windows, rather than every npm installation environment.
Other advisories describe different ways a crafted archive can disrupt software that uses the library. CVE-2026-140241 can cause an uncaught exception that terminates a Node.js process when a four-byte Zstandard signature is read by the asynchronous listing or extraction API on runtimes without native Zstandard support. CVE-2026-140242 involves a PAX size value set to Infinity, which can make the parser consume later archive entries as file data and can trigger a crash when an affected archive is repacked. The advisory lists versions from 7.0.0 up to, but not including, 7.5.24 as affected by that issue.
Further notices cover NUL-byte and newline handling in archive names, disagreements between node-tar and other TAR tools over which files an archive contains, and symbolic links that can be created outside the intended extraction directory. The issues include CVE-2026-140234, CVE-2026-140235, CVE-2026-140236, CVE-2026-140237 and CVE-2026-140245. Depending on how an application processes an archive, these flaws can cause a process to crash, hide entries from a security scanner, alter extracted files or leave a link that points beyond the extraction folder.
The advisories generally identify node-tar 8.0.0 as the fixed release, while the notice for CVE-2026-140242 lists 7.5.24 as patched. The 8.0.0 release notes describe fixes for PAX record framing, metadata handling, NUL-terminated names and symbolic-link containment. The release also introduces breaking changes: it drops support for Node.js versions older than 22 and removes the package’s previous callback and Node.js stream interfaces. Applications may therefore need code changes before moving to the new major version.
The findings are relevant to Node.js applications that unpack files supplied by users or external services, including package-processing tools, upload handlers, CI pipelines and backup systems. Abijita previously reported a separate TorchVision archive path-traversal flaw that could allow a malicious TAR file to write outside its intended extraction directory.
GitHub Flags Multiple Node-Tar Security Flaws




