Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessReach app feature that accepts virtual field names
-
DeliverySubmit name with __proto__/constructor/prototype segment
-
Exploitvirtual() reducer walks prototype chain
-
ExecutionEnumerable property written to Object/Function.prototype
-
ImpactSpoof inherited authorization/property checks
Vulnerability Assessment
| Weakness |
CWE
ASVS 5.0
V3 - Web Frontend Security Prototype pollution prevention
MITRE ATT&CK
2 techniques across 2 tactics: Execution, Initial Access The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up. |
| Exploitation Conditions | Exploitation requires that the application allow attacker influence over the NAME argument passed to Schema.prototype.virtual() - specifically deployments using dynamic schemas, CMS/content-management form builders, or schema-as-code systems where virtual field names derive from untrusted input. The attacker must supply a name containing special segments (__proto__, constructor, or prototype), e.g. '__proto__.polluted'. The key LIMITING factor is that applications with hard-coded, developer-controlled virtual names are not exploitable, because the vulnerable path is never fed attacker-controlled segments. Affected versions are <6.13.12, 7.0.0-7.8.12, 8.0.0-8.24.6, and 9.0.0-9.11.3; the only complete fix is updating to 6.13.12, 7.8.13, 8.24.7, or 9.11.4, which add the specialProperties validation to virtual(). |
| Impact | This is a genuine but conditional-severity issue rather than a drop-everything emergency. The supplied CVSS vector (CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:L, 6.5) describes network reach with low complexity and no privileges, but that rating understates a critical precondition stated in the GHSA advisory: the attacker must be able to influence the field NAMES passed to Schema.prototype.virtual(), which only happens in applications built around dynamic schemas, CMS/form builders, or schema-as-code. In a typical app where virtual names are hard-coded by developers, the attack surface does not exist, so the network/low-complexity framing is optimistic for most deployments. No EPSS score and no KEV listing were provided, and the vuln.today decision label is 'this_month' (not act_now/emergency), all consistent with a real-but-not-actively-exploited library bug. A proof-of-concept is published inline in the GHSA advisory, so exploitation is demonstrably feasible, but PoC availability is distinct from active exploitation and none is indicated here. Impact is integrity/availability (spoofing of inherited property checks such as isAdmin/authorization flags, plus Function.prototype gadget state) with no direct confidentiality loss per C:N. Net: prioritize patching where attacker-controllable schema names are plausible; treat as lower urgency where virtual names are entirely developer-controlled. |
| Exploit ScenarioDerived | An application exposes a schema/form builder or dynamic-schema feature that lets users define virtual field names, and the server passes those names into Schema.prototype.virtual(). The attacker submits a name like '__proto__.polluted', 'constructor.prototype.opol', or 'hasOwnProperty.__proto__.fpol', causing Mongoose's virtual-path reducer to write enumerable properties onto Object.prototype or Function.prototype, which can then spoof inherited checks such as ({}).isAdmin elsewhere in the process. A working proof-of-concept demonstrating exactly this is published in the GHSA advisory. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Nov 09, 2026
Prototype pollution in Mongoose, the npm MongoDB object modeling library, lets unauthenticated attackers who can influence virtual field names write enumerable properties onto Object.prototype and Function.prototype through Schema.prototype.virtual(), which never received the specialProperties validation that Schema.path() and Schema.add() gained in the 2022 fix for CVE-2022-2564/CVE-2022-24304. Spoofed inherited properties can subvert checks such as authorization flags read from every object, and Function.prototype pollution gives other server-side JavaScript a known gadget primitive; a public proof-of-concept showing '__proto__.polluted' and 'constructor.prototype.opol' payloads is published in the upstream advisory. Exploitability is conditional rather than universal: applications with hard-coded, developer-controlled virtual names are not exposed, while dynamic schemas, CMS/content-management form builders and schema-as-code systems that derive virtual names from untrusted input are, which is why the assessment discounts the vector to AC:H despite the remote, no-authentication trigger.
RemediationAI
Vendor-released patch: upgrade to 6.13.12, 7.8.13, 8.24.7 or 9.11.4 (or the corresponding ^6.13.12, ^7.8.13, ^8.24.7, ^9.11.4 ranges), the releases that add the utils.specialProperties check to Schema.prototype.virtual() and to virtuals supplied via schema constructor options; release notes and the advisory are at https://github.com/Automattic/mongoose/security/advisories/GHSA-6972-9mcm-vhwj and https://github.com/Automattic/mongoose/releases/tag/6.13.12, /7.8.13, /8.24.7, /9.11.4, with the code changes in commits 318f7e09dd363a1dfddb8180878488dccd2796d1, 74df7769b5a8d89c4413b764029911ee915ea467, 7a2a6567abbb72c0430c8cc5b7942141844fecff and fb467e6d33174293dc0360649f20ce68d99117a9. Updating is the only complete fix; where upgrading must be staged, reduce exposure by ensuring that no untrusted input reaches the name argument of schema.virtual() or the virtuals constructor option - derive virtual names only from developer-defined constants or validate them against a strict allow-list that rejects the segments __proto__, constructor and prototype - since any deployment that keeps feeding user-controlled names into virtual() remains vulnerable.
Affected VersionsENISA
Affected Packages
Source: OSV (Open Source Vulnerabilities)
Affects your stack
Affects 1 package in npm
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
Mongoose builds schema paths by splitting a dotted name into segments and reducing them into the schema's internal tree object; each segment is dereferenced with mem[part] || (mem[part] = ...) before the value is assigned. Schema.path() and Schema.add() were hardened after CVE-2022-2564/CVE-2022-24304 by rejecting the special property names held in utils.specialProperties, but Schema.prototype.virtual() (lib/schema.js) kept the original unguarded reducer, so a name containing __proto__, constructor or prototype segments resolves through the prototype chain instead of creating an own property on the tree. Because the assignment lands on a prototype rather than the schema, the values become enumerable, inherited keys visible on every object ({}.polluted, {}.isAdmin) and on functions (Function.prototype pollution), the classic CWE-1321 gadget surface used by server-side JavaScript libraries. The upstream patch (commits 318f7e09, 74df7769, 7a2a6567, fb467e6d) moves the name.split('.') step earlier and throws MongooseError('Cannot set special property ...') for any segment present in utils.specialProperties, and the same validation is applied to the virtuals passed in Schema constructor options, which were reachable via a JSON-parsed {'virtuals': {'__proto__.polluted': {}}} object. The trigger is documented as attacker-influenced virtual names only; the advisory does not describe any other route into the vulnerable reducer, and the CPE entry (cpe:2.3:a:automattic:mongoose) covers all release trains of the package.
Know when Mongoose gets its next vulnerability
- Watch products and get an email when something new is published
- Check this CVE against your own stack and servers
- Exploit and PoC references, threat intelligence from 22 sources
No credit card · 7-day full trial
Severity by source
AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:L
AC:H because exploitation depends on the non-default condition that the app routes untrusted input into virtual() field names; C:N, with I:L/A:L for prototype-pollution-based spoofing and gadget state.
Primary rating from Vendor (GitHub_M).
CVSS VectorVendor: GitHub_M
Lifecycle Timeline
2DescriptionCVE.org
Mongoose is a MongoDB object modeling tool designed to work in an asynchronous environment. Prior to 6.13.12, 7.8.13, 8.24.7, and 9.11.4, Schema.prototype.virtual() builds nested virtual paths without applying the special-property validation already used by Schema.path() and Schema.add(). An attacker who can influence virtual field names in dynamic schemas, content-management form builders, or schema-as-code systems can supply path segments such as __proto__, constructor, or prototype, causing the virtual-path reducer to write enumerable properties to Object.prototype or Function.prototype. The resulting prototype pollution can spoof inherited property checks such as authorization flags and can provide function-prototype gadget state to other server-side JavaScript code. This issue is fixed in versions 6.13.12, 7.8.13, 8.24.7, and 9.11.4.
Blast Radius
ecosystem impact- 2 npm packages depend on mongoose (2 direct, 0 indirect)
Ecosystem-wide dependent count for version 7.0.0.
Threat Intelligence Overview
How this decision was reached
The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
Information disclosure occurs when an application unintentionally exposes sensitive data that aids attackers in reconnaissance or directly compromises security.
Mongoose ODM for Node.js before version 8.9.5 contains a search injection vulnerability when using $where filters with p
An exploitable stack buffer overflow vulnerability exists in the MQTT packet parsing functionality of Cesanta Mongoose 6
An exploitable use-after-free vulnerability exists in the HTTP server implementation of Cesanta Mongoose 6.8. Rated crit
An exploitable memory corruption vulnerability exists in the Websocket protocol implementation of Cesanta Mongoose 6.8.
An exploitable memory corruption vulnerability exists in the Websocket protocol implementation of Cesanta Mongoose 6.8.
Prototype Pollution in GitHub repository automattic/mongoose prior to 7.3.4. Rated critical severity (CVSS 9.8), this vu
Prototype Pollution in GitHub repository automattic/mongoose prior to 6.4.6. Rated critical severity (CVSS 9.8), this vu
An integer overflow in parse_mqtt in mongoose.c in Cesanta Mongoose 6.16 allows an attacker to achieve remote DoS (infin
Mongoose before 8.8.3 can improperly use $where in match, leading to search injection. Rated critical severity (CVSS 9.1
The mg_tls_init function in Cesanta Mongoose HTTPS server 7.0 (compiled with OpenSSL support) is vulnerable to remote OO
The mg_tls_init function in Cesanta Mongoose HTTPS server 7.0 and 6.7-6.18 (compiled with mbedTLS support) is vulnerable
The mg_http_serve_file function in Cesanta Mongoose HTTP server 7.0 is vulnerable to remote OOB write attack via connect
EUVD-2026-120501
GHSA-6972-9mcm-vhwj
NVD
CVE.org
EPSS
Exploit-DB