CVE-2021-23518: cached-path-relative_project cached-path-relative Prototype Pollution
Vulnerability summary
CVE-2021-23518 is a critical (CVSS 9.8) Prototype Pollution vulnerability in cached-path-relative_project cached-path-relative. EPSS estimates a 1.94% chance of exploitation in the next 30 days, higher than 79.8% of scored vulnerabilities. 2 public exploits are recorded.
Advisory lineage
Upstream 0 · Downstream 1Timeline
- 21-01-2022PublishedVulnerability first disclosed.
- 16-09-2024Last modifiedVulnerability information updated.
Description
The package cached-path-relative before 1.1.0 are vulnerable to Prototype Pollution via the cache variable that is set as {} instead of Object.create(null) in the cachedPathRelative function, which allows access to the parent prototype properties when the object is used to create the cached relative path. When using the origin path as __proto__, the attribute of the object is accessed instead of a path. **Note:** This vulnerability derives from an incomplete fix in https://security.snyk.io/vuln/SNYK-JS-CACHEDPATHRELATIVE-72573
CVSS metrics
6 scores · 5 sources · 2 versions- CVE.orgCNA7.3HighCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:L/E:PDiffers
- OSV · UbuntuEcosystem advisory · calculated9.8CriticalCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
- OSV · DebianEcosystem advisory · calculated9.8CriticalCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
- OSV · NpmEcosystem advisory · calculated7.3HighCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:LDiffers
EPSS trend
Probability
1.94%
Chance of exploitation in the next 30 days
Percentile
80%
Versus all other CVEs
30-day change
0.00 pp
From 1.94% on 19-09-2026
Known exploited
Compare KEV catalogsNot in any of the 3 tracked catalogs.
Public exploits
2 foundExploit Reference (snyk.io)
Maturity: unknown
Exploit Reference (snyk.io)
Maturity: unknown
Weaknesses
CWE · root causeAffected systems
Debian2 products
- node-cached-path-relative< 1.1.0+~1.0.0-1
- debian_linuxEOL10.0
Cached-path-relative_project1 product
- cached-path-relative< 1.1.0
Npm1 product
- cached-path-relative< 1.1.0
Ubuntu1 product
- node-cached-path-relativeAll versions (No fix recorded)
4 vendors · 5 products
References
9 links- snyk.io/vuln/SNYK-JS-CACHEDPATHRELATIVE-2342653REPORTWEBExploitIssue TrackingPatchThird Party Advisory
- github.com/ashaffer/cached-path-relative/commit/40c73bf70c58add5aec7d11e4f36b93d144bb760REPORTWEBPatchThird Party Advisory