CVE-2026-142596
Mongoose: sanitizeProjection can be bypassed to include fields deselected with `select: false`
AI summary AI generated
An attacker can bypass Mongoose sanitizeProjection using crafted projections to return fields marked select: false, such as password hashes and API keys, from MongoDB queries.
Mitigation
- Upgrade mongoose to 9.12.2 or later.
Who should check
- Anyone running Automattic mongoose >= 8.5.0, < 8.24.10; >= 9.0.0, < 9.12.2
Vulnerability facts
- Affected
- Automattic mongoose >= 8.5.0, < 8.24.10; >= 9.0.0, < 9.12.2
- Fixed in
- Automattic mongoose 8.24.10, Automattic mongoose 9.12.2
- Exploited in the wild
- Not in CISA KEV
- Public exploit / PoC
- None known
- Remote exploitation
- Remote, no login needed
- CVSS
- 7.5 (v3.1, CNA)CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:NOpen in CVSS calculator
Show all 8 CVSS metrics
- Attack vector: Network
- Attack complexity: Low
- Privileges required: None
- User interaction: None
- Scope: Unchanged
- Confidentiality impact: High
- Integrity impact: None
- Availability impact: None
- CWE
- CWE-200
- Modified
Description
Mongoose is a MongoDB object modeling tool designed to work in an asynchronous environment. From 8.5.0 until 8.24.10 and 9.12.2, Mongoose's sanitizeProjection can be bypassed by +path selections, object or array aggregation expressions, nested and parent projections, positional projections, $meta, discriminator-specific exclusions, an own __proto__ key, and projection-cast error paths. Applications that pass attacker-controlled data to select(), find(filter, projection), or the projection option while relying on sanitizeProjection can return fields marked select: false, including password hashes, reset tokens, API keys, and nested secrets. Nested exclusion objects, $elemMatch combined with an exclusion or a cast error, and discriminator filters can also cause ordinary queries that do not enable sanitizeProjection to omit the select: false exclusions that Mongoose normally adds. This issue is fixed in versions 8.24.10 and 9.12.2.
Affected and fixed versions
| Package / product | Affected | Fixed | Source |
|---|---|---|---|
| Automattic mongoose | >= 8.5.0, < 8.24.10; >= 9.0.0, < 9.12.2 | — | cvelist |
Versions mentioned in the description AI generated
Extracted by AI; each line quotes the description word for word. Source data above takes precedence.
- Affected: mongoose From 8.5.0 until 8.24.10 and 9.12.2
From 8.5.0 until 8.24.10 and 9.12.2
- Fixed: mongoose 8.24.10
This issue is fixed in versions 8.24.10 and 9.12.2.
- Fixed: mongoose 9.12.2
This issue is fixed in versions 8.24.10 and 9.12.2.
Check your systems with an agent
Paste this into Claude Code, Cursor or another coding agent. It only reads; it changes nothing.
Check whether anything I run is affected by CVE-2026-142596. Work read-only: do not install, upgrade, delete or change anything. Details: https://flawdb.com/CVE-2026-142596.md Affected: Automattic mongoose >= 8.5.0, < 8.24.10; >= 9.0.0, < 9.12.2 Fixed in: Automattic mongoose 8.24.10, Automattic mongoose 9.12.2 Steps: 1. Search this machine and project for Automattic mongoose: dependency manifests and lockfiles, installed packages, container images and running services. 2. For each match, note the installed version and whether it is inside the affected range. 3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
Technologies
References
Patches
FAQ
Is CVE-2026-142596 being exploited?
There is no confirmed exploitation: CVE-2026-142596 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known.
How serious is CVE-2026-142596?
High: CVSS 7.5 (v3.1, scored by CNA). Remote, no login needed.
Which versions are affected by CVE-2026-142596?
Automattic mongoose >= 8.5.0, < 8.24.10; >= 9.0.0, < 9.12.2.
Is there a fix for CVE-2026-142596?
Yes. Fixed in Automattic mongoose 8.24.10, Automattic mongoose 9.12.2. Upgrade mongoose to 9.12.2 or later.
How do I check if I'm affected by CVE-2026-142596?
Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.
More automattic vulnerabilities
See all| Severity | Identifier / vulnerability | Technology | Signals | Age |
|---|---|---|---|---|
| LOW | CVE-2026-142608 Mongoose: Plain objects with a forged _bsontype bypass ObjectId and String casting, leaking and replaying data from other command | MongoDB+1 | ||
| MEDIUM 6.5 | CVE-2026-142595 Mongoose: `sanitizeFilter` bypass via MongoDB internal top-level query operators such as `$_internalSchemaXor` | MongoDB+1 | ||
| MEDIUM 4.3 | CVE-2026-128998 WordPress WP Job Manager plugin <= 2.4.10 - Content Injection vulnerability | WordPress plugins and themes | EPSS 16% | |
| MEDIUM 6.5 | CVE-2026-125801 WordPress WooCommerce plugin 11.0.0-11.2.2 - Race Condition vulnerability | WooCommerce | EPSS 12% |