Description
The npm package "tar" (aka node-tar) before versions 4.4.18, 5.0.10, and 6.1.9 has an arbitrary file creation/overwrite and arbitrary code execution vulnerability. node-tar aims to guarantee that any file whose location would be modified by a symbolic link is not extracted. This is, in part, achieved by ensuring that extracted directories are not symlinks. Additionally, in order to prevent unnecessary stat calls to determine whether a given path is a directory, paths are cached when directories are created. This logic was insufficient when extracting tar files that contained both a directory and a symlink with names containing unicode values that normalized to the same value. Additionally, on Windows systems, long path portions would resolve to the same file system entities as their 8.3 "short path" counterparts. A specially crafted tar archive could thus include a directory with one form of the path, followed by a symbolic link with a different string that resolves to the same file system entity, followed by a file using the first form. By first creating a directory, and then replacing that directory with a symlink that had a different apparent name that resolved to the same entry in the filesystem, it was thus possible to bypass node-tar symlink checks on directories, essentially allowing an untrusted tar file to symlink into an arbitrary location and subsequently extracting arbitrary files into that location, thus allowing arbitrary file creation and overwrite. These issues were addressed in releases 4.4.18, 5.0.10 and 6.1.9. The v3 branch of node-tar has been deprecated and did not receive patches for these issues. If you are still using a v3 release we recommend you update to a more recent version of node-tar. If this is not possible, a workaround is available in the referenced GHSA-qq89-hq3f-393p.
Affected products
| Vendor | Product | Affected | Fixed |
|---|---|---|---|
| npm | node-tar | < 4.4.18, >= 5.0.0, < 5.0.10, >= 6.0.0, < 6.1.9 | — |
Fixed in Linux distributions
Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.
Debian
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Debian 14 | node-tar | 6.1.11+~cs11.3.10-1 | — |
| Debian 13 | node-tar | 6.1.11+~cs11.3.10-1 | — |
| Debian 12 | node-tar | 6.1.11+~cs11.3.10-1 | — |
| Debian 11 | node-tar | 6.0.5+ds1+~cs11.3.9-1+deb11u2 | DSA-5008-1 |
| Debian 10 | node-tar | 4.4.6+ds1-3+deb10u2 | DLA-3237-1 |
Ubuntu
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Ubuntu 26.10 | node-tar | No fix yet | — |
| Ubuntu 26.04 LTS | node-tar | No fix yet | — |
| Ubuntu 25.10 | node-tar | No fix yet | — |
| Ubuntu 24.04 LTS | node-tar | No fix yet | — |
| Ubuntu 22.04 LTS | node-tar | No fix yet | — |
Show 4 more (older releases, extended support, other products)Fewer releases
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Ubuntu 18.04 LTS | node-tar | No fix yet | — |
| Ubuntu Pro 20.04 LTS | node-tar | No fix yet | — |
| Ubuntu Pro 16.04 LTS | node-tar | No fix yet | — |
| Ubuntu Pro 14.04 LTS | node-tar | No fix yet | — |
Red Hat
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| RHEL 8 | nodejs +3 | 1:12.22.12-1.module+el8.6.0+15324+1f2c5d8d | RHSA-2022:0350, RHEA-2022:5139 |
| RHEL 8 | nodejs-nodemon | 2.0.3-1.module+el8.4.0+11732+c668cc9f | RHSA-2022:0350, RHEA-2022:5139 |
| RHEL 8 | nodejs-packaging | 17-3.module+el8.1.0+3369+37ae6a45 | RHSA-2022:0350, RHEA-2022:5139 |
| RHEL 8 | npm | 1:6.14.15-1.14.18.2.2.module+el8.5.0+13644+8d46dafd | RHSA-2022:0350, RHEA-2022:5139 |
| RHEL 3 | rh-nodejs12-nodejs +2 | 12.22.12-2.el7 | RHSA-2022:4914 |
| RHEL 3 | rh-nodejs12-npm | 6.14.16-12.22.12.2.el7 | RHSA-2022:4914 |
| RHEL 3 | rh-nodejs14-nodejs +2 | 14.18.2-1.el7 | RHSA-2022:0041 |
| RHEL 3 | rh-nodejs14-nodejs-nodemon | 2.0.3-6.el7 | RHSA-2022:0041 |
| RHEL 3 | rh-nodejs14-npm | 6.14.15-14.18.2.1.el7 | RHSA-2022:0041 |
Show 3 more (older releases, extended support, other products)Fewer releases
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| RHEL 8.4 EUS | nodejs +3 | 1:12.22.12-1.module+el8.4.0+15323+4d1cc445 | RHSA-2022:0246, RHEA-2022:5615 |
| RHEL 8.4 EUS | nodejs-nodemon | 2.0.3-1.module+el8.4.0+11732+c668cc9f | RHSA-2022:0246, RHEA-2022:5615 |
| RHEL 8.4 EUS | nodejs-packaging | 17-3.module+el8.1.0+3369+37ae6a45 | RHSA-2022:0246, RHEA-2022:5615 |
| RHEL 8.4 EUS | npm | 1:6.14.15-1.14.18.2.2.module+el8.4.0+13643+6c0ebf22 | RHSA-2022:0246, RHEA-2022:5615 |
| RHEL 8.2 EUS | nodejs +3 | 1:12.22.12-1.module+el8.2.0+15322+a70ca0ab | RHEA-2022:5221 |
| RHEL 8.2 EUS | nodejs-nodemon | 1.18.3-1.module+el8.1.0+3369+37ae6a45 | RHEA-2022:5221 |
| RHEL 8.2 EUS | nodejs-packaging | 17-3.module+el8.1.0+3369+37ae6a45 | RHEA-2022:5221 |
| RHEL 8.2 EUS | npm | 1:6.14.16-1.12.22.12.1.module+el8.2.0+15322+a70ca0ab | RHEA-2022:5221 |
| RHEL 8.1 E4S | nodejs +3 | 1:12.22.12-1.module+el8.1.0+15296+87b2f6ad | RHEA-2022:4925 |
| RHEL 8.1 E4S | nodejs-nodemon | 1.18.3-1.module+el8.1.0+3369+37ae6a45 | RHEA-2022:4925 |
| RHEL 8.1 E4S | nodejs-packaging | 17-3.module+el8.1.0+3369+37ae6a45 | RHEA-2022:4925 |
| RHEL 8.1 E4S | npm | 1:6.14.16-1.12.22.12.1.module+el8.1.0+15296+87b2f6ad | RHEA-2022:4925 |
AlmaLinux
Errata ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| AlmaLinux 8 | nodejs +3 | 1:14.18.2-2.module_el8.5.0+254+b4526b16 | ALSA-2022:0350 |
| AlmaLinux 8 | nodejs-nodemon | 2.0.15-1.module_el8.5.0+2605+45d748af | ALSA-2022:0350 |
| AlmaLinux 8 | nodejs-packaging | 23-3.module_el8.4.0+2522+3bd42762 | ALSA-2022:0350 |
| AlmaLinux 8 | npm | 1:6.14.15-1.14.18.2.2.module_el8.5.0+254+b4526b16 | ALSA-2022:0350 |
Rocky Linux
Errata ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Rocky Linux 8 | nodejs | 1:14.18.2-2.module+el8.5.0+733+de4fee6c | RLSA-2022:0350 |
| Rocky Linux 8 | nodejs-nodemon | 2.0.15-1.module+el8.5.0+721+4c107270 | RLSA-2022:0350 |
| Rocky Linux 8 | nodejs-packaging | 23-3.module+el8.3.0+100+234774f7 | RLSA-2022:0350 |
SUSE
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| SLES 15 SP3 | nodejs12 | 12.22.7-4.22.1 | SUSE-SU-2021:3940-1 |
| SLES 15 SP3 | nodejs14 | 14.18.1-15.21.2 | SUSE-SU-2021:3964-1 |
| SLES 15 SP2 | nodejs12 | 12.22.7-4.22.1 | SUSE-SU-2021:3940-1 |
| SLES 15 SP2 | nodejs14 | 14.18.1-15.21.2 | SUSE-SU-2021:3964-1 |
| SLES 12 | nodejs12 | 12.22.9-1.38.1 | SUSE-SU-2022:0101-1 |
| SLES 12 | nodejs14 | 14.18.1-6.18.2 | SUSE-SU-2021:3886-1 |
openSUSE
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| openSUSE Leap 15.3 | nodejs12 | 12.22.7-4.22.1 | openSUSE-SU-2021:3940-1 |
| openSUSE Leap 15.3 | nodejs14 | 14.18.1-15.21.2 | openSUSE-SU-2021:3964-1 |
| openSUSE Leap 15.2 | nodejs12 | 12.22.7-lp152.3.21.1 | openSUSE-SU-2021:1574-1 |
| openSUSE Leap 15.2 | nodejs14 | 14.18.1-lp152.17.1 | openSUSE-SU-2021:1552-1 |
Alpine
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Alpine v3.24 | nodejs | 14.17.6-r0 | — |
| Alpine v3.23 | nodejs | 14.17.6-r0 | — |
| Alpine v3.22 | nodejs | 14.17.6-r0 | — |
| Alpine v3.21 | nodejs | 14.17.6-r0 | — |
| Alpine v3.20 | nodejs | 14.17.6-r0 | — |
Show 9 more (older releases, extended support, other products)Fewer releases
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Alpine v3.19 | nodejs | 14.17.6-r0 | — |
| Alpine v3.18 | nodejs | 14.17.6-r0 | — |
| Alpine v3.17 | nodejs | 14.17.6-r0 | — |
| Alpine v3.16 | nodejs | 14.17.6-r0 | — |
| Alpine v3.15 | nodejs | 14.17.6-r0 | — |
| Alpine v3.14 | nodejs | 14.17.6-r0 | — |
| Alpine v3.13 | nodejs | 14.17.6-r0 | — |
| Alpine v3.12 | nodejs | 12.22.6-r0 | — |
| Alpine v3.11 | nodejs | 12.22.6-r0 | — |
Oracle Linux
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Oracle Linux 8 | nodejs +3 | 1:14.18.2-2.module+el8.5.0+20489+261d51d3 | ELSA-2022-0350 |
| Oracle Linux 8 | nodejs-nodemon | 2.0.15-1.module+el8.5.0+20489+261d51d3 | ELSA-2022-0350 |
| Oracle Linux 8 | nodejs-packaging | 23-3.module+el8.3.0+7818+6cd30d85 | ELSA-2022-0350 |
| Oracle Linux 8 | npm | 1:6.14.15-1.14.18.2.2.module+el8.5.0+20489+261d51d3 | ELSA-2022-0350 |
Affected packages
| Ecosystem | Package | Affected | Fixed | Record |
|---|---|---|---|---|
| npm | tar | >= 3.0.0, < 4.4.18 | 4.4.18 | GHSA-qq89-hq3f-393p |
| npm | tar | >= 5.0.0, < 5.0.10 | 5.0.10 | GHSA-qq89-hq3f-393p |
| npm | tar | >= 6.0.0, < 6.1.9 | 6.1.9 | GHSA-qq89-hq3f-393p |
Advisories 30
- ALSA-2022:0350 Moderate: nodejs:14 security, bug fix, and enhancement update AlmaLinux Security Advisories · Oct 29, 2026
- RHSA-2022:4914 Red Hat Security Advisory: rh-nodejs12-nodejs security, bug fix, and enhancement update Red Hat Security Advisories (RHSA) · Oct 14, 2026
- RHSA-2022:0350 Red Hat Security Advisory: nodejs:14 security, bug fix, and enhancement update Red Hat Security Advisories (RHSA) · Oct 14, 2026
- RHSA-2022:0246 Red Hat Security Advisory: nodejs:14 security, bug fix, and enhancement update Red Hat Security Advisories (RHSA) · Oct 14, 2026
- RHEA-2022:5615 Red Hat Enhancement Advisory: nodejs:12 bug fix and enhancement update Red Hat Security Advisories (RHSA) · Oct 14, 2026
- RHSA-2022:0041 Red Hat Security Advisory: rh-nodejs14-nodejs and rh-nodejs14-nodejs-nodemon security update Red Hat Security Advisories (RHSA) · Oct 14, 2026
- RHEA-2022:5139 Red Hat Enhancement Advisory: nodejs:12 bug fix and enhancement update Red Hat Security Advisories (RHSA) · Oct 14, 2026
- RHEA-2022:5221 Red Hat Enhancement Advisory: nodejs:12 bug fix and enhancement update Red Hat Security Advisories (RHSA) · Oct 14, 2026
- RHEA-2022:4925 Red Hat Enhancement Advisory: nodejs:12 bug fix and enhancement update Red Hat Security Advisories (RHSA) · Oct 14, 2026
- WID-SEC-2022-1603 IBM Tivoli Netcool/OMNIbus: Mehrere Schwachstellen BSI CERT-Bund (WID) · Mar 24, 2026
- DSA-5008-1 node-tar - security update Debian Security (DSA / DLA) · Mar 9, 2026
- DLA-3237-1 node-tar - security update Debian Security (DSA / DLA) · Mar 9, 2026
- RLSA-2022:0350 Moderate: nodejs:14 security, bug fix, and enhancement update Rocky Linux Security Advisories · Feb 5, 2026
- openSUSE-SU-2021:1574-1 Security update for nodejs12 SUSE / openSUSE Security Updates · Feb 4, 2026
- SUSE-SU-2021:3940-1 Security update for nodejs12 SUSE / openSUSE Security Updates · Feb 4, 2026
- SUSE-SU-2021:3964-1 Security update for nodejs14 SUSE / openSUSE Security Updates · Feb 4, 2026
- openSUSE-SU-2021:1552-1 Security update for nodejs14 SUSE / openSUSE Security Updates · Feb 4, 2026
- SUSE-SU-2021:3886-1 Security update for nodejs14 SUSE / openSUSE Security Updates · Feb 4, 2026
- SUSE-SU-2022:0101-1 Security update for nodejs12 SUSE / openSUSE Security Updates · Feb 4, 2026
- FSA-202302 Festo: Several vulnerabilities in FactoryViews CERT@VDE · Feb 2, 2026
- openSUSE-SU-2021:3940-1 Security update for nodejs12 SUSE / openSUSE Security Updates · May 7, 2025
- openSUSE-SU-2021:3964-1 Security update for nodejs14 SUSE / openSUSE Security Updates · May 7, 2025
- ICSA-22-069-09 Siemens SINEC INS CISA ICS & IT advisories · May 6, 2025
- WID-SEC-2024-1591 Juniper JUNOS: Mehrere Schwachstellen BSI CERT-Bund (WID) · Nov 11, 2024
- WID-SEC-2022-0092 Node.js: Mehrere Schwachstellen ermöglichen Manipulation von Dateien BSI CERT-Bund (WID) · May 9, 2024
- WID-SEC-2023-0809 IBM QRadar SIEM: Mehrere Schwachstellen BSI CERT-Bund (WID) · Feb 19, 2024
- WID-SEC-2023-0857 IBM QRadar SIEM: Mehrere Schwachstellen BSI CERT-Bund (WID) · Apr 4, 2023
- WID-SEC-2023-0856 IBM QRadar SIEM: Mehrere Schwachstellen BSI CERT-Bund (WID) · Apr 4, 2023
- SSA-389290 SSA-389290: Third-Party Component Vulnerabilities in SINEC INS Siemens ProductCERT · Mar 8, 2022
- ELSA-2022-0350 Moderate: nodejs:14 security, bug fix, and enhancement update (Oracle Linux 8) Oracle Linux Security Advisories (ELSA) · Feb 2, 2022
References
- https://www.npmjs.com/package/tar
- https://github.com/npm/node-tar/security/advisories/GHSA-qq89-hq3f-393p
- https://www.oracle.com/security-alerts/cpuoct2021.html
- DSA-5008 vendor-advisory
- https://cert-portal.siemens.com/productcert/pdf/ssa-389290.pdf
- [debian-lts-announce] 20221212 [SECURITY] [DLA 3237-1] node-tar security update mailing-list