Skip to content
Noroxi
NVD / CVE Program· CNA GitHub_M

CVE-2021-37701: Arbitrary File Creation/Overwrite via insufficient symlink protection due to directory cache poisoning using symbolic links

Noroxi assessment

Priority: Monitor (action score 35/100)

  • The sources we track (CISA KEV, Exploit-DB, Metasploit, Nuclei, GitHub) show no public exploit code or exploitation in the wild.
  • Probability of exploitation in the next 30 days: 3.2% (FIRST EPSS); higher than 88.4% of all records.
  • Someone with local access to the system can trigger it. No account or password is required. A user must open a link or visit a page. No special conditions are required; it is repeatable.
  • Fixed version: nodejs (AlmaLinux:8) 1:14.18.2-2.module_el8.5.0+2618+8d46dafd, 1:14.18.2-2.module_el8.5.0+254+b4526b16; nodejs-devel (AlmaLinux:8) 1:14.18.2-2.module_el8.5.0+254+b4526b16, 1:14.18.2-2.module_el8.5.0+2618+8d46dafd; nodejs-docs (AlmaLinux:8) 1:14.18.2-2.module_el8.5.0+254+b4526b16, 1:14.18.2-2.module_el8.5.0+2618+8d46dafd.
  • Mentioned 2 times in Turkish national cyber security advisories (siberguvenlik.gov.tr).

Low priority for now. Upgrade to nodejs (AlmaLinux:8) 1:14.18.2-2.module_el8.5.0+2618+8d46dafd, 1:14.18.2-2.module_el8.5.0+254+b4526b16; nodejs-devel (AlmaLinux:8) 1:14.18.2-2.module_el8.5.0+254+b4526b16, 1:14.18.2-2.module_el8.5.0+2618+8d46dafd; nodejs-docs (AlmaLinux:8) 1:14.18.2-2.module_el8.5.0+254+b4526b16, 1:14.18.2-2.module_el8.5.0+2618+8d46dafd or later.

Generated automatically from the record's data: CVSS (NVD and CNA), CISA KEV and SSVC, FIRST EPSS, exploit sources, fixed versions. How we calculate it

Primary sources: NVD · CVE.org · FIRST EPSS

The npm package "tar" (aka node-tar) before versions 4.4.16, 5.0.8, and 6.1.7 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 the same name as the directory, where the symlink and directory names in the archive entry used backslashes as a path separator on posix systems. The cache checking logic used both `\` and `/` characters as path separators, however `\` is a valid filename character on posix systems. By first creating a directory, and then replacing that directory with a symlink, 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. Additionally, a similar confusion could arise on case-insensitive filesystems. If a tar archive contained a directory at `FOO`, followed by a symbolic link named `foo`, then on case-insensitive file systems, the creation of the symbolic link would remove the directory from the filesystem, but _not_ from the internal directory cache, as it would not be treated as a cache hit. A subsequent file entry within the `FOO` directory would then be placed in the target of the symbolic link, thinking that the directory had already been created. These issues were addressed in releases 4.4.16, 5.0.8 and 6.1.7. 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-9r2w-394v-53qc.

HighCVSS 8.6 · v3.1—No exploit Fix available
Published
Aug 31, 2021
Updated
Jun 17, 2026
EPSS
3.2% · 88th percentile

Report tools

JSON

Action score

35

Monitor

Low priority for now.

CVSS
34 / 40 · 8.6 / 10
CISA KEV
0 / 30 · Not listed
EPSS
1 / 30 · 3.2%

CNA vs NVD score

NVD
8.6
CNA · GitHub_M
8.2
0.4 point gap

CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:C/C:H/I:H/A:N

The score given by the assigning authority versus NVD’s independent score. A gap means the severity is contested.

Get told when this record changes

  • Not in KEV: no record of exploitation in the wild
  • No public exploit code on record
  • A fix has been released

If any of these changes, we'll tell you in the daily email digest.

Follow CVE-2021-37701

When you'll hear from us

  • when it enters CISA KEV
  • when exploit code appears or is weaponized
  • when the record is updated (including a fixed version)
  • when EPSS rises 20 points in a week

One daily email digest (06:00 UTC); connect a webhook for KEV listings and weaponized exploits instantly.

Your free account also gets you

Running WordPress? Scan your site free with WP Lens

  • Stack alerts: add the products and versions you run, get the new CVEs that affect them
  • Uptime monitoring: 1 site, instant email when it goes down
  • Add your domain: subdomains and takeover risk scanned every week (1 domain)
  • 10 scans an hour on the security tools (3 a day without an account), an API key and MCP
  • All your scans in one panel: findings, what changed in the last scan, a report per domain or per client (PDF, share link)
All free tools

Sign up with email · Have an account? Sign in

Free account, no card. Unfollow any time.

Running WordPress? Scan your site free with WP Lens

Is your version affected? Check it

Noroxi analysis

What does it mean in your environment?

The assessment above is generated automatically from the record's data; it doesn't know your environment. Our team verifies on your systems whether this vulnerability is actually exploitable and which mitigation is enough.

We use this product, ask for help

Affected systems

Is your version affected?

Pick the product and type the version you run. It's compared with this record's version ranges in your browser; the version isn't sent anywhere.

VendorProduct
npmjstar
debiandebian linux
oraclegraalvm
siemenssinec infrastructure network services

Affected versions

NVD version ranges (for catalog products). Add the product to your stack with a version and matching uses these.

  • debian debian linux10.0
  • debian debian linux11.0
  • npmjs tar6.0.0 and later · before 6.1.7
  • npmjs tarbefore 4.4.16
  • npmjs tar5.0.0 and later · before 5.0.8
  • oracle graalvm20.3.3
  • oracle graalvm21.2.0
  • siemens sinec infrastructure network servicesbefore 1.0.1.1

Versions reported by the vendor

Affected version ranges reported by the assigning authority (GitHub_M). Independent of NVD's CPE analysis and usually ahead of it.

  • npm node-tar

    • < 4.4.16, >= 5.0.0, < 5.0.8, >= 6.0.0, < 6.1.7affected

Package-level exposure

OSV and GitHub Advisory data: ecosystem, package and range. SBOM matching uses this table.

EcosystemPackageAffected rangeFix
AlmaLinux:8nodejsbefore 1:14.18.2-2.module_el8.5.0+2618+8d46dafd1:14.18.2-2.module_el8.5.0+2618+8d46dafd
AlmaLinux:8nodejsbefore 1:14.18.2-2.module_el8.5.0+254+b4526b161:14.18.2-2.module_el8.5.0+254+b4526b16
AlmaLinux:8nodejs-develbefore 1:14.18.2-2.module_el8.5.0+254+b4526b161:14.18.2-2.module_el8.5.0+254+b4526b16
AlmaLinux:8nodejs-develbefore 1:14.18.2-2.module_el8.5.0+2618+8d46dafd1:14.18.2-2.module_el8.5.0+2618+8d46dafd
AlmaLinux:8nodejs-docsbefore 1:14.18.2-2.module_el8.5.0+254+b4526b161:14.18.2-2.module_el8.5.0+254+b4526b16
AlmaLinux:8nodejs-docsbefore 1:14.18.2-2.module_el8.5.0+2618+8d46dafd1:14.18.2-2.module_el8.5.0+2618+8d46dafd
AlmaLinux:8nodejs-full-i18nbefore 1:14.18.2-2.module_el8.5.0+254+b4526b161:14.18.2-2.module_el8.5.0+254+b4526b16
AlmaLinux:8nodejs-full-i18nbefore 1:14.18.2-2.module_el8.5.0+2618+8d46dafd1:14.18.2-2.module_el8.5.0+2618+8d46dafd
AlmaLinux:8nodejs-nodemonbefore 2.0.15-1.module_el8.6.0+2904+f21ad6f42.0.15-1.module_el8.6.0+2904+f21ad6f4
AlmaLinux:8nodejs-nodemonbefore 2.0.15-1.module_el8.5.0+2618+8d46dafd2.0.15-1.module_el8.5.0+2618+8d46dafd
AlmaLinux:8nodejs-nodemonbefore 2.0.15-1.module_el8.5.0+2605+45d748af2.0.15-1.module_el8.5.0+2605+45d748af
AlmaLinux:8nodejs-packagingbefore 23-3.module_el8.4.0+2522+3bd4276223-3.module_el8.4.0+2522+3bd42762
AlmaLinux:8nodejs-packagingbefore 23-3.module_el8.5.0+2618+8d46dafd23-3.module_el8.5.0+2618+8d46dafd
AlmaLinux:8npmbefore 1:6.14.15-1.14.18.2.2.module_el8.5.0+254+b4526b161:6.14.15-1.14.18.2.2.module_el8.5.0+254+b4526b16
AlmaLinux:8npmbefore 1:6.14.15-1.14.18.2.2.module_el8.5.0+2618+8d46dafd1:6.14.15-1.14.18.2.2.module_el8.5.0+2618+8d46dafd
Alpine:v3.11nodejsbefore 12.22.6-r012.22.6-r0
Alpine:v3.13nodejsbefore 14.17.6-r014.17.6-r0
Debian:10node-tarbefore 4.4.6+ds1-3+deb10u24.4.6+ds1-3+deb10u2
Debian:11node-tarbefore 6.0.5+ds1+~cs11.3.9-1+deb11u26.0.5+ds1+~cs11.3.9-1+deb11u2
Debian:12node-tarbefore 6.1.7+~cs11.3.10-16.1.7+~cs11.3.10-1
npmtarfrom 3.0.0 · before 4.4.164.4.16
npmtarfrom 5.0.0 · before 5.0.85.0.8
npmtarfrom 6.0.0 · before 6.1.76.1.7
openSUSE:Leap 15.2nodejs12before 12.22.7-lp152.3.21.112.22.7-lp152.3.21.1

+72

Other highest-scoring records for the same primary product.

  • CVE-2021-37712Arbitrary File Creation/Overwrite via insufficient symlink protection due to directory cache poisoning using symbolic links
    35Monitor
  • CVE-2021-37713Arbitrary File Creation/Overwrite on Windows via insufficient relative path sanitization
    34Monitor

Remediation

Which version to upgrade to

Fix versions compiled from the vendor, package registries and Microsoft. Verify the vendor's note before upgrading.

Product / packageFixed versionSource
almalinux:nodejs1:14.18.2-2.module_el8.5.0+2618+8d46dafd · AlmaLinux:8Package registry (OSV)
almalinux:nodejs-devel1:14.18.2-2.module_el8.5.0+2618+8d46dafd · AlmaLinux:8Package registry (OSV)
almalinux:nodejs-docs1:14.18.2-2.module_el8.5.0+2618+8d46dafd · AlmaLinux:8Package registry (OSV)
almalinux:nodejs-full-i18n1:14.18.2-2.module_el8.5.0+2618+8d46dafd · AlmaLinux:8Package registry (OSV)
almalinux:nodejs-nodemon2.0.15-1.module_el8.6.0+2904+f21ad6f4 · AlmaLinux:8Package registry (OSV)
almalinux:nodejs-packaging23-3.module_el8.5.0+2618+8d46dafd · AlmaLinux:8Package registry (OSV)
almalinux:npm1:6.14.15-1.14.18.2.2.module_el8.5.0+2618+8d46dafd · AlmaLinux:8Package registry (OSV)
alpine:nodejs12.22.6-r0 · Alpine:v3.11Package registry (OSV)
debian:node-tar6.1.7+~cs11.3.10-1 · Debian:12Package registry (OSV)
npm:tar4.4.16Package registry (OSV)
npm:tar5.0.8Package registry (OSV)
npm:tar6.1.7Package registry (OSV)
opensuse:nodejs1212.22.7-lp152.3.21.1 · openSUSE:Leap 15.2Package registry (OSV)
opensuse:nodejs1414.18.1-lp152.17.1 · openSUSE:Leap 15.2Package registry (OSV)
red hat:nodejs1:12.22.12-1.module+el8.1.0+15296+87b2f6ad · Red Hat:rhel_e4s:8.1::appstreamPackage registry (OSV)
red hat:nodejs-debuginfo1:12.22.12-1.module+el8.1.0+15296+87b2f6ad · Red Hat:rhel_e4s:8.1::appstreamPackage registry (OSV)
red hat:nodejs-debugsource1:12.22.12-1.module+el8.1.0+15296+87b2f6ad · Red Hat:rhel_e4s:8.1::appstreamPackage registry (OSV)
red hat:nodejs-devel1:12.22.12-1.module+el8.1.0+15296+87b2f6ad · Red Hat:rhel_e4s:8.1::appstreamPackage registry (OSV)
red hat:nodejs-docs1:12.22.12-1.module+el8.1.0+15296+87b2f6ad · Red Hat:rhel_e4s:8.1::appstreamPackage registry (OSV)
red hat:nodejs-full-i18n1:12.22.12-1.module+el8.1.0+15296+87b2f6ad · Red Hat:rhel_e4s:8.1::appstreamPackage registry (OSV)
red hat:nodejs-nodemon0:1.18.3-1.module+el8.1.0+3369+37ae6a45 · Red Hat:rhel_e4s:8.1::appstreamPackage registry (OSV)
red hat:nodejs-packaging0:17-3.module+el8.1.0+3369+37ae6a45 · Red Hat:rhel_e4s:8.1::appstreamPackage registry (OSV)
red hat:npm1:6.14.16-1.12.22.12.1.module+el8.1.0+15296+87b2f6ad · Red Hat:rhel_e4s:8.1::appstreamPackage registry (OSV)
red hat:rh-nodejs14-nodejs0:14.18.2-1.el7 · Red Hat:rhel_software_collections:3::el7Package registry (OSV)
red hat:rh-nodejs14-nodejs-debuginfo0:14.18.2-1.el7 · Red Hat:rhel_software_collections:3::el7Package registry (OSV)
red hat:rh-nodejs14-nodejs-devel0:14.18.2-1.el7 · Red Hat:rhel_software_collections:3::el7Package registry (OSV)
rocky linux:nodejs1:14.18.2-2.module+el8.5.0+733+de4fee6c · Rocky Linux:8Package registry (OSV)
rocky linux:nodejs-nodemon0:2.0.15-1.module+el8.5.0+721+4c107270 · Rocky Linux:8Package registry (OSV)
rocky linux:nodejs-packaging0:23-3.module+el8.7.0+1071+4bdda2a8 · Rocky Linux:8Package registry (OSV)
suse:nodejs1212.22.7-4.22.1 · SUSE:Linux Enterprise Module for Web and Scripting 15 SP2Package registry (OSV)

+1

Exploit status

No known public exploit

No public exploit has been observed yet. That doesn't mean you're safe, only that the bar is a little higher.

Research context

For pentesters and researchers: attack profile, score disagreement, timeline, patch commits, credits, variant and chain candidates, bug bounty scope. All derived from existing data; no exploit code.

Timeline

From publication to today: proof of concept, Metasploit module, CISA KEV and fix record. Dates are as reported by the sources.

No dated events beyond publication.

EPSS, last 120 days

FIRST EPSS daily score; only changes of 0.01 or more are recorded (step chart).

Patch and commit links

Commit, PR and diff links among the references. A starting point for patch-diffing and variant hunting; fixes, not exploits.

No commit or PR link among the references.

Finders, reporters and analysts named in the CNA record. Click a name for that researcher’s other records.

No credits in the CNA record.

Variant candidates

Same product, same weakness class, within 18 months. If the patch missed the root cause, the sibling bug is here.

No nightly-computed relations.

Chain candidates

An authentication bypass and a privilege-requiring bug in the same product, published close together: combined they may become an unauthenticated path.

—

Bug bounty scope

No known public program.

Source: bounty-targets-data (public HackerOne, Bugcrowd, Intigriti, YesWeHack listings).

National notice (Türkiye Cybersecurity Directorate / USOM)

Official security notices citing this record; remediation advice is on the agency's page.

All national notices →

Technical details

Attack conditions

  • Someone with local access to the system can trigger it.
  • No account or password is required.
  • A user must open a link or visit a page.
  • No special conditions are required; it is repeatable.

If successful

Confidentiality
high · data can be read
Integrity
high · data or configuration can be modified
Availability
high · the service can be disrupted

Impact can extend beyond the vulnerable component (scope changes).

Attack vector
Local
Attack complexity
Low
Privileges required
None
User interaction
Required
Scope
Changed
Confidentiality impact
High
Integrity impact
High
Availability impact
High

CVSS vector

CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:C/C:H/I:H/A:H

nvd-primary

Root cause

A user-supplied file name is joined with the allowed directory, but the result is never checked to confirm it is still inside that directory.

A representative example of this vulnerability class. Not the vendor's source code; it shows the faulty pattern and its fix.

Vulnerable

ts
const file = path.join(ROOT, req.query.name);res.sendFile(file);

Fixed

ts
const file = path.resolve(ROOT, req.query.name);if (!file.startsWith(ROOT + path.sep)) {  return res.sendStatus(400);}res.sendFile(file);

Change log

  1. Fix✗ → ✓

For records you follow, these changes also arrive as notifications. →

References

All records