VYPR
High severityNVD Advisory· Published Nov 10, 2020· Updated Sep 16, 2024

Prototype Pollution

CVE-2020-7766

Description

The json-ptr npm package is vulnerable to prototype pollution via the set() operation with force flag enabled, allowing attackers to pollute Object.prototype.

AI Insight

LLM-synthesized narrative grounded in this CVE's description and references.

The json-ptr npm package is vulnerable to prototype pollution via the set() operation with force flag enabled, allowing attackers to pollute Object.prototype.

CVE-2020-7766 is a prototype pollution vulnerability in the json-ptr JavaScript package affecting all versions [1][3]. The flaw resides in the set() method when the force flag is set to true; the function recursively sets properties on the target object without proper validation of the key being set, enabling pollution of Object.prototype [1].

An attacker can exploit this by crafting a JSON pointer that includes prototype keys like __proto__ or constructor, causing the recursive property assignment to modify the global prototype chain [2][3]. No authentication is required if the attacker can supply input to the set() function, such as in applications that parse user-supplied JSON pointers with force mode enabled.

This can lead to denial of service, property injection, or potentially remote code execution if the polluted properties affect application logic [2][3]. The vulnerability has been addressed in a pull request [4] but the repository is archived and may no longer receive updates; users should switch to maintained alternatives or avoid using force flag with untrusted input.

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.

PackageAffected versionsPatched versions
json-ptrnpm
< 2.1.02.1.0

Affected products

2

Patches

1

Vulnerability mechanics

AI mechanics synthesis has not run for this CVE yet.

References

9

News mentions

0

No linked articles in our index yet.