Skip to main content

Mongoose EUVDEUVD-2026-120501

| CVE-2026-125118 MEDIUM
Improperly Controlled Modification of Object Prototype Attributes (Prototype Pollution) (CWE-1321)
2026-11-09 GitHub_M GHSA-6972-9mcm-vhwj
6.5
CVSS 3.1 · Vendor: GitHub_M
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Reach app feature that accepts virtual field names
  2. Delivery
    Submit name with __proto__/constructor/prototype segment
  3. Exploit
    virtual() reducer walks prototype chain
  4. Execution
    Enumerable property written to Object/Function.prototype
  5. Impact
    Spoof 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.

This Month Plan within 30 days. Why: MEDIUM severity (CVSS 4.0-6.9).
Patch available 0.4% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – 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

Mongoose 7.0.0, < 7.8.13
Mongoose 9.0.0, < 9.11.4
Mongoose 8.0.0, < 8.24.7
Mongoose < 6.13.12

Affected Packages

npm mongoose fix: 6.13.12, 7.8.13, 8.24.7, 9.11.4

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

Vendor (GitHub_M) PRIMARY 6.5 MEDIUM
AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:L
vuln.today AI 4.8 MEDIUM

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.

3.1 AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:L/A:L
4.0 AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:L/VA:L/SC:N/SI:N/SA:N

Primary rating from Vendor (GitHub_M).

CVSS VectorVendor: GitHub_M

Attack Vector
Network
Attack Complexity
Low
Privileges Required
None
User Interaction
None
Scope
Unchanged
Confidentiality
None
Integrity
Low
Availability
Low

Lifecycle Timeline

2
Patch available
Nov 09, 2026 - 23:18 EUVD
CVE Published
Nov 09, 2026 - 22:29 cve.org
MEDIUM 6.5

DescriptionCVE.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
† from your stack dependencies † transitive graph · vuln.today resolves 4-path depth
  • 2 npm packages depend on mongoose (2 direct, 0 indirect)

Ecosystem-wide dependent count for version 7.0.0.

Threat Intelligence Overview

EPSS Score
0.4%
Top 65% exploitable
Prevalence
High
Mongoose is the dominant MongoDB ODM across Node.js server applications
Threat Intel
1
1 source
Social Media
1
Sightings
Data Quality
5 sources
Confidence: Medium

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.

SignalValue
Severity MEDIUM
CISA KEV No
Public POC No
EPSS 0.4%
Patch available Yes
Active threat No
Deciding rule
MEDIUM severity (CVSS 4.0-6.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Scheduled
Exploitation· derived
None
System Exposure· derived
Open
Automatable· derived
Yes
Human Impact· derived
High

Priority Score

32
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +32
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Information disclosure occurs when an application unintentionally exposes sensitive data that aids attackers in reconnaissance or directly compromises security.

CVE-2025-23061 CRITICAL POC
9.0 Jan 15

Mongoose ODM for Node.js before version 8.9.5 contains a search injection vulnerability when using $where filters with p

CVE-2017-2894 CRITICAL POC
9.8 Nov 07

An exploitable stack buffer overflow vulnerability exists in the MQTT packet parsing functionality of Cesanta Mongoose 6

CVE-2017-2891 CRITICAL POC
9.8 Nov 07

An exploitable use-after-free vulnerability exists in the HTTP server implementation of Cesanta Mongoose 6.8. Rated crit

CVE-2017-2922 CRITICAL POC
9.8 Nov 07

An exploitable memory corruption vulnerability exists in the Websocket protocol implementation of Cesanta Mongoose 6.8.

CVE-2017-2921 CRITICAL POC
9.8 Nov 07

An exploitable memory corruption vulnerability exists in the Websocket protocol implementation of Cesanta Mongoose 6.8.

CVE-2023-3696 CRITICAL POC
9.8 Jul 17

Prototype Pollution in GitHub repository automattic/mongoose prior to 7.3.4. Rated critical severity (CVSS 9.8), this vu

CVE-2022-2564 CRITICAL POC
9.8 Jul 28

Prototype Pollution in GitHub repository automattic/mongoose prior to 6.4.6. Rated critical severity (CVSS 9.8), this vu

CVE-2019-19307 CRITICAL POC
9.8 Nov 26

An integer overflow in parse_mqtt in mongoose.c in Cesanta Mongoose 6.16 allows an attacker to achieve remote DoS (infin

CVE-2024-53900 CRITICAL POC
9.1 Dec 02

Mongoose before 8.8.3 can improperly use $where in match, leading to search injection. Rated critical severity (CVSS 9.1

CVE-2021-26530 CRITICAL POC
9.1 Feb 08

The mg_tls_init function in Cesanta Mongoose HTTPS server 7.0 (compiled with OpenSSL support) is vulnerable to remote OO

CVE-2021-26529 CRITICAL POC
9.1 Feb 08

The mg_tls_init function in Cesanta Mongoose HTTPS server 7.0 and 6.7-6.18 (compiled with mbedTLS support) is vulnerable

CVE-2021-26528 CRITICAL POC
9.1 Feb 08

The mg_http_serve_file function in Cesanta Mongoose HTTP server 7.0 is vulnerable to remote OOB write attack via connect

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy