CVE-2026-42334 json
Mongoose: Improper Sanitization of $nor in sanitizeFilter May Allow NoSQL Injection
published 2026-05-05 6 mo ago modified 2026-10-26 13 d ago also BIT-mongoose-2026-42334 , EUVD-2026-30349 , GHSA-wpg9-53fq-2r8h
- cvss
- 7.5
- version 3.1, CNA
- cisa kev
- Not listed
- not in CISA's catalog
- epss
- 0.3%
- EPSS 0.3% chance of exploitation in 30 days, percentile 19%
- public exploits
- 0
- none known
Summary
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.
Patch / fix
- npm mongoose 6.13.9, 7.8.9, 8.22.1, 9.1.6
- bitnami mongoose 6.13.9, 7.8.9, 8.22.1, 9.1.6
- mongoosejs mongoose 6.13.9, 7.8.9, 8.22.1, 9.1.6
Vendor advisories
What the vendors themselves say about their products: affected, fixed or not affected, and what to do.
red hat product security vex CVE-2026-42334 updated cvss 7.5
mongoose: Mongoose: Information disclosure via sanitizeFilter bypass using $nor operator
-
Red Hat All currently supported Red Hat productsnot affected: vulnerable code not present
Red Hat CSAF VEX © Red Hat, Inc., from https://security.access.redhat.com/data/csaf/v2/vex/; changed: reduced to product statuses and remediations. CC BY 4.0 · csaf
CISA SSVC
- Exploitation
- none
- Automatable
- yes
- Technical impact
- partial
- Assessed
- 5 mo ago
Exploit prediction
0.27% chance of exploitation in the next 30 days, higher than 19% of all scored CVEs (FIRST EPSS, 2026-11-08).
CVSS scores
| assigned by | version | score | vector |
|---|---|---|---|
| CNA | 3.1 | 7.5 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N |
| GitHub | 3.1 | 7.5 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N |
| OSV | 3.1 | 7.5 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N |
Affected packages
| ecosystem | package | affected | fixed in |
|---|---|---|---|
| npm | mongoose | <6.13.9 >=7.0.0, <7.8.9 >=8.0.0, <8.22.1 >=9.0.0, <9.1.6 |
6.13.9 7.8.9 8.22.1 9.1.6 |
| bitnami | mongoose | <6.13.9 >=7.0.0, <7.8.9 >=8.0.0, <8.22.1 >=9.0.0, <9.1.6 |
6.13.9 7.8.9 8.22.1 9.1.6 |
Affected products
- Automattic mongoose
Classification
- Weakness
-
- CWE-74 Improper Neutralization of Special Elements in Output Used by a Downstream Component
References
-
github.com
/Automattic/mongoose/security/advisories/GHSA-wpg9-53fq-2r8h
web, mitigation, vendor-advisory, advisory
-
nvd.nist.gov
/vuln/detail/CVE-2026-42334
advisory, web
-
github.com
/Automattic/mongoose
package
-
mongoosejs.com
/docs/api/mongoose.html#Mongoose.prototype.sanitizeFilter()
web
-
thecodebarbarian.com
/whats-new-in-mongoose-6-sanitizefilter.html
web
Sources
- CVE List CVE-2026-42334
- GitHub Advisory GHSA-wpg9-53fq-2r8h
- NVD CVE-2026-42334
- OSV BIT-mongoose-2026-42334
Fencer Vulns keeps one entry per vulnerability: the CVE id wins, then GHSA, and records that alias each other are merged, except that two CVEs always keep separate entries. The same data is available as JSON.
CPEs and fixed versions use Anchore's correction of NVD's data: Added CPE configurations because not yet analyzed by NVD.