CVE-2026-42334 Details
Description
Mongoose is a MongoDB object modeling tool designed to work in an asynchronous environment. Prior to 6.13.9, 7.8.9, 8.22.1, and 9.1.6, a vulnerability allows bypassing Mongoose’s sanitizeFilter query sanitization mechanism via the $nor operator. When sanitizeFilter is enabled, Mongoose wraps query operators in $eq to neutralize them. However, prior to the fix, $nor was not included in the set of logical operators that are recursively sanitized. Because $nor accepts an array (like $and and $or), and arrays do not trigger hasDollarKeys(), malicious operators such as $ne, $gt, or $regex could be injected inside a $nor clause without being sanitized. This vulnerability is fixed in 6.13.9, 7.8.9, 8.22.1, and 9.1.6.
A vulnerability in Mongoose, a MongoDB object modeling tool, allows for bypassing the query sanitization mechanism of the sanitizeFilter feature via the $nor operator. This issue is present in Mongoose versions prior to 6.13.9, 7.8.9, 8.22.1, and 9.1.6. When sanitizeFilter is enabled, Mongoose neutralizes query operators by wrapping them in $eq. However, the $nor operator was not properly sanitized, allowing malicious operators like $ne, $gt, or $regex to be injected into a $nor clause without detection. This vulnerability could lead to authentication bypass, unauthorized data access, or data exfiltration.
Users can upgrade to Mongoose versions 6.13.9, 7.8.9, 8.22.1, or 9.1.6 to address this vulnerability. Alternatively, for those unable to upgrade, $nor keys can be removed, an additional schema validation library can be used, or middleware can be written to strip $nor from query filters.
Metrics
CVSS 4.0 Severity and Vector Strings:
No CVSS 4.0 data is available for this CVE.
CVSS 3.x Severity and Vector Strings:
No data available for CVSS Version 2.0 on this CVE.
CISA-ADP
Assessed May 14, 2026References to Advisories, Solutions, and Tools
By selecting these links, you will be leaving this site. These are references gathered from the official CVE record and are not endorsed by Volerion.
| URL | Source(s) | Tag(s) |
|---|---|---|
| https://github.com/Automattic/mongoose/security/advisories/GHSA-wpg9-53fq-2r8h | [email protected] | MitigationVendor Advisory |
Weakness Enumeration
| CWE-ID | CWE Name | Source |
|---|---|---|
| CWE-74 | Improper Neutralization of Special Elements in Output Used by a Downstream Component ('Injection') | [email protected] |
Affected Products
| Product | Versions |
|---|---|
| mongoosejs mongoose | < 6.13.9 >= 7.0.0, < 7.8.9 >= 8.0.0, < 8.22.1 >= 9.0.0, < 9.1.6 |
CPE
Remediation
| |
Change History
4 change records found show changes
| Date | Action | Recorded By |
|---|---|---|
| Jun 17, 2026 | CVE Modified | [email protected] |
| Jun 17, 2026 | CVE Modified | CISA-ADP |
| May 15, 2026 | Initial Analysis | [email protected] |
| May 14, 2026 | New CVE Received | [email protected] |