Prototype Pollution in Cached-Path-Relative Project
CVE-2021-23518
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
Vulnerability class: Prototype Pollution
Published · last modified .
CVSS v3 metric
CVSS v3 base score 7.3 (High). Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:L.
EPSS exploit prediction
EPSS 0.020, 81.2th percentile (last changed ); unchanged over 30 days. About EPSS.
Affected products
- Cached-Path-Relative Project
- Debian Linux — versions 10.0
- Cached-Path-Relative — versions unspecified
Weakness classification (CWE)
References
- snyk.io/vuln/SNYK-JS-CACHEDPATHRELATIVE-2342653 (Exploit, Patch, Third Party Advisory, Issue Tracking)
- snyk.io/vuln/SNYK-JAVA-ORGWEBJARSNPM-2348246 (Exploit, Patch, Third Party Advisory, Issue Tracking)
- github.com/ashaffer/cached-path-relative/commit/40c73bf70c58add5aec7d11e4f36b93… (Patch, Third Party Advisory)
- [debian-lts-announce] 20221204 [SECURITY] [DLA 3221-1] node-cached-path-relative security update (mailing-list, Mailing List, Third Party Advisory)