Update dependency tar to v7 [SECURITY] - abandoned#166
Update dependency tar to v7 [SECURITY] - abandoned#166renovate[bot] wants to merge 2 commits intomasterfrom
Conversation
|
Luckily I've just done May make a PR later today that bumps this dep while the |
|
Well I take it back, the errors here stem from bumping So any fixes would actually need to be applied there, or otherwise we would have to revisit if that's all still needed now that we are on a modern NodeJS version. |
Updated `tar` dependency claims compatibility only with Node 18+. Ignore this requirement and install anyway. If it functionally breaks anything, we can fix that, but would like to run CI through first to find out, without hitting the engines check and bailing early.
Edited/Blocked NotificationRenovate will not automatically rebase this PR, because it does not recognize the last commit author and assumes somebody else may have edited the PR. You can manually request rebase by checking the rebase/retry box above. |
|
I updated the workaround for this sort of Should let CI progress far enough to see if we get actual test failures or if anything blows up. |
Autoclosing SkippedThis PR has been flagged for autoclosing. However, it is being skipped due to the branch being already modified. Please close/delete it manually or report a bug if you think this is in error. |
This PR contains the following updates:
^6.1.2→^7.0.0^6.0.5→^7.0.0GitHub Vulnerability Alerts
CVE-2026-26960
Summary
tar.extract()in Nodetarallows an attacker-controlled archive to create a hardlink inside the extraction directory that points to a file outside the extraction root, using default options.This enables arbitrary file read and write as the extracting user (no root, no chmod, no
preservePaths).Severity is high because the primitive bypasses path protections and turns archive extraction into a direct filesystem access primitive.
Details
The bypass chain uses two symlinks plus one hardlink:
a/b/c/up -> ../..a/b/escape -> c/up/../..exfil(hardlink) ->a/b/escape/<target-relative-to-parent-of-extract>Why this works:
Linkpath checks are string-based and do not resolve symlinks on disk for hardlink target safety.
STRIPABSOLUTEPATHlogic in:../tar-audit-setuid - CVE/node_modules/tar/dist/commonjs/unpack.js:255../tar-audit-setuid - CVE/node_modules/tar/dist/commonjs/unpack.js:268../tar-audit-setuid - CVE/node_modules/tar/dist/commonjs/unpack.js:281Hardlink extraction resolves target as
path.resolve(cwd, entry.linkpath)and then callsfs.link(target, destination).../tar-audit-setuid - CVE/node_modules/tar/dist/commonjs/unpack.js:566../tar-audit-setuid - CVE/node_modules/tar/dist/commonjs/unpack.js:567../tar-audit-setuid - CVE/node_modules/tar/dist/commonjs/unpack.js:703Parent directory safety checks (
mkdir+ symlink detection) are applied to the destination path of the extracted entry, not to the resolved hardlink target path.../tar-audit-setuid - CVE/node_modules/tar/dist/commonjs/unpack.js:617../tar-audit-setuid - CVE/node_modules/tar/dist/commonjs/unpack.js:619../tar-audit-setuid - CVE/node_modules/tar/dist/commonjs/mkdir.js:27../tar-audit-setuid - CVE/node_modules/tar/dist/commonjs/mkdir.js:101As a result,
exfilis created inside extraction root but linked to an external file. The PoC confirms shared inode and successful read+write viaexfil.PoC
hardlink.js
Environment used for validation:
v25.4.07.5.7tar.extract({ file, cwd }))Steps:
Prepare/locate a
tarmodule. Ifrequire('tar')is not available locally, setTAR_MODULEto an absolute path to a tar package directory.Run:
TAR_MODULE="$(cd '../tar-audit-setuid - CVE/node_modules/tar' && pwd)" node hardlink.jsInterpretation:
same_inode=true: extractedexfiland external secret are the same file object.read_ok=true: readingexfilleaks external content.write_ok=true: writingexfilmodifies external file.Impact
Vulnerability type:
Who is impacted:
tardefaults.Potential outcomes:
Release Notes
isaacs/node-tar (tar)
v7.5.8Compare Source
v7.5.7Compare Source
v7.5.6Compare Source
v7.5.5Compare Source
v7.5.4Compare Source
v7.5.3Compare Source
v7.5.2Compare Source
v7.5.1Compare Source
v7.5.0Compare Source
v7.4.4Compare Source
v7.4.3Compare Source
v7.4.2Compare Source
v7.4.1Compare Source
v7.4.0Compare Source
v7.3.0Compare Source
v7.2.0Compare Source
v7.1.0Compare Source
v7.0.1Compare Source
v7.0.0Compare Source
Configuration
📅 Schedule: Branch creation - "" (UTC), Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about these updates again.
This PR was generated by Mend Renovate. View the repository job log.