Prototype Pollution
Description
All versions of js-data are vulnerable to Prototype Pollution via the deepFillIn and set functions, allowing attackers to inject properties into Object.prototype.
AI Insight
LLM-synthesized narrative grounded in this CVE's description and references.
All versions of js-data are vulnerable to Prototype Pollution via the deepFillIn and set functions, allowing attackers to inject properties into Object.prototype.
Vulnerability
The js-data package (all versions) is vulnerable to Prototype Pollution through the deepFillIn and set functions [1]. This is an incomplete fix of CVE-2020-28442 [3]. The vulnerability occurs because these functions do not properly sanitize user-controlled object keys, allowing an attacker to set properties on Object.prototype via __proto__, constructor, or prototype paths. The affected code path is reachable whenever an application passes untrusted data to deepFillIn or set without prior validation.
Exploitation
An attacker needs to supply a crafted object to either deepFillIn or set with a property like __proto__ or constructor.prototype containing malicious payloads [3]. For example, calling deepFillIn(target, { '__proto__': { 'polluted': true } }) will pollute the global Object.prototype. No authentication or special network position is required if the application exposes these functions to user input (e.g., via JSON parsing or API parameters).
Impact
Successful exploitation results in Prototype Pollution, which can lead to denial of service (e.g., unexpected exceptions), property injection that alters application behavior, and in some contexts remote code execution if the polluted properties are used in security-sensitive operations [3]. The attacker can affect all objects in the runtime, potentially bypassing security checks or modifying default configurations.
Mitigation
As of the publication date (2021-12-24), no patched version of js-data has been released [1]. The vulnerability is a known incomplete fix of an earlier issue. Users should avoid passing untrusted data to deepFillIn and set, or consider migrating to an alternative library that is not susceptible to Prototype Pollution. The vulnerability is tracked in Snyk databases [3].
AI Insight generated on May 21, 2026. Synthesized from this CVE's description and the cited reference URLs; citations are validated against the source bundle.
Affected packages
Versions sourced from the GitHub Security Advisory.
| Package | Affected versions | Patched versions |
|---|---|---|
js-datanpm | <= 3.0.10 | — |
Affected products
2- js-data/js-datadescription
Patches
0No patches discovered yet.
Vulnerability mechanics
AI mechanics synthesis has not run for this CVE yet.
References
8- github.com/advisories/GHSA-c6h4-gc3f-hgjqghsaADVISORY
- nvd.nist.gov/vuln/detail/CVE-2021-23574ghsaADVISORY
- github.com/js-data/js-data/blob/master/dist/js-data.js%23L472ghsax_refsource_MISCWEB
- github.com/js-data/js-data/issues/576ghsax_refsource_MISCWEB
- github.com/js-data/js-data/issues/577ghsax_refsource_MISCWEB
- snyk.io/vuln/SNYK-JAVA-ORGWEBJARSBOWER-2320790ghsax_refsource_MISCWEB
- snyk.io/vuln/SNYK-JAVA-ORGWEBJARSNPM-2320791ghsax_refsource_MISCWEB
- snyk.io/vuln/SNYK-JS-JSDATA-1584361ghsax_refsource_MISCWEB
News mentions
0No linked articles in our index yet.