{"answers":{"affected":"9 open source packages ship an affected version, including mongoose. It affects 1 product.","exploited":"There is no known exploitation of CVE-2026-42334 in the wild and no public exploit code.","fix":"Upgrade mongoose to a fixed version for your release line: 6.13.9, 7.8.9, 8.22.1 or 9.1.6.","what":"CVE-2026-42334 is a high-severity SQL injection vulnerability in Automattic mongoose, published on 14 May 2026. An attacker can exploit it over the internet without logging in, with no action from the victim."},"fix_prompt":"Check this codebase for CVE-2026-42334 and fix it if it is affected.\n\nWhat it is: CVE-2026-42334 is a high-severity SQL injection vulnerability in Automattic mongoose, published on 14 May 2026. An attacker can exploit it over the internet without logging in, with no action from the victim.\nExploitation: There is no known exploitation of CVE-2026-42334 in the wild and no public exploit code.\n\nAffected packages and fixed versions:\n- mongoose (Bitnami): affected all versions; fixed in 6.13.9, 7.8.9, 8.22.1, 9.1.6\n- mongoose (npm): affected all versions; fixed in 6.13.9\n- mongoose (npm): affected all versions; fixed in 6.13.9\n- mongoose (npm): affected from 7.0.0; fixed in 7.8.9\n- mongoose (npm): affected from 7.0.0; fixed in 7.8.9\n- mongoose (npm): affected from 8.0.0; fixed in 8.22.1\n- mongoose (npm): affected from 8.0.0; fixed in 8.22.1\n- mongoose (npm): affected from 9.0.0; fixed in 9.1.6\n- mongoose (npm): affected from 9.0.0; fixed in 9.1.6\n\nTask:\n1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.\n2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.\n3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.\n4. Run the tests and summarise what changed and why.\n5. If nothing in the project is affected, say so and change nothing.\n\nReference: https://insights.sbomify.com/CVE-2026-42334/ (Markdown: https://insights.sbomify.com/CVE-2026-42334/index.md)","id":"CVE-2026-42334","markdown":"https://insights.sbomify.com/CVE-2026-42334/index.md","name":"CVE-2026-42334","record":{"aliases":["BIT-mongoose-2026-42334","CLSA-2026-1783558972","GHSA-wpg9-53fq-2r8h","ROOT-APP-NPM-CVE-2026-42334"],"analysis":{"component_type":"library","fix_type":"upgrade","impacts":["data_read","data_modify"],"network_reachable":"yes","non_default_config":true,"product_category":"MongoDB ODM library","requires_auth":"none","summary":"Attackers can bypass query sanitization via the $nor operator to inject malicious NoSQL queries, potentially reading or modifying data.","user_interaction":"not_required","vuln_class":"sql_injection"},"analysis_generated_by":"qwen3.8-flash-next","assigner":"GitHub_M","cpe":[{"product":"mongoose","vendor":"mongoosejs"}],"cvss":{"score":7.5,"severity":"high","source":"cna","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N","version":"3.1"},"cwes":[{"id":"CWE-74","name":"Improper Neutralization of Special Elements in Output Used by a Downstream Component"}],"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.","ecosystems":["Bitnami","npm"],"exploits":{"exploitdb":0,"first_seen":null,"github_poc":0,"max_poc_stars":null,"metasploit":0,"nuclei":0,"refs":[],"tier":"none_known"},"has_fix":true,"headline":"Mongoose: Improper Sanitization of $nor in sanitizeFilter May Allow NoSQL Injection","id":"CVE-2026-42334","indexable":true,"kev":null,"kind":"cve","links":{"ecosystem":"Bitnami","product":null,"products":[],"type":"sql_injection","year":"2026"},"n_packages":9,"n_references":1,"next":{"headline":"MaxKB: SSRF Bypass in MaxKB OSS URL Fetch due to URL Parsing Discrepancy","id":"CVE-2026-42335"},"packages":[{"ecosystem":"Bitnami","fixed":["6.13.9","7.8.9","8.22.1","9.1.6"],"introduced":["0","7.0.0","8.0.0","9.0.0"],"last_affected":[],"package":"mongoose","purl":"pkg:bitnami/mongoose","source":"BIT-mongoose-2026-42334"},{"ecosystem":"npm","fixed":["6.13.9"],"introduced":["0"],"last_affected":[],"package":"mongoose","purl":null,"source":"GHSA-wpg9-53fq-2r8h"},{"ecosystem":"npm","fixed":["6.13.9"],"introduced":["0"],"last_affected":[],"package":"mongoose","purl":"pkg:npm/mongoose","source":"GHSA-wpg9-53fq-2r8h"},{"ecosystem":"npm","fixed":["7.8.9"],"introduced":["7.0.0"],"last_affected":[],"package":"mongoose","purl":null,"source":"GHSA-wpg9-53fq-2r8h"},{"ecosystem":"npm","fixed":["7.8.9"],"introduced":["7.0.0"],"last_affected":[],"package":"mongoose","purl":"pkg:npm/mongoose","source":"GHSA-wpg9-53fq-2r8h"},{"ecosystem":"npm","fixed":["8.22.1"],"introduced":["8.0.0"],"last_affected":[],"package":"mongoose","purl":null,"source":"GHSA-wpg9-53fq-2r8h"},{"ecosystem":"npm","fixed":["8.22.1"],"introduced":["8.0.0"],"last_affected":[],"package":"mongoose","purl":"pkg:npm/mongoose","source":"GHSA-wpg9-53fq-2r8h"},{"ecosystem":"npm","fixed":["9.1.6"],"introduced":["9.0.0"],"last_affected":[],"package":"mongoose","purl":null,"source":"GHSA-wpg9-53fq-2r8h"},{"ecosystem":"npm","fixed":["9.1.6"],"introduced":["9.0.0"],"last_affected":[],"package":"mongoose","purl":"pkg:npm/mongoose","source":"GHSA-wpg9-53fq-2r8h"}],"prev":{"headline":"quarkus-openapi-generator has overly broad path-parameter matching that sends authentication headers to unintended operations","id":"CVE-2026-42333"},"products":["mongoose"],"published":"2026-05-14","related":[{"cvss_score":10,"headline":"Prototype Pollution in automattic/mongoose","id":"CVE-2023-3696","kev_date_added":null,"published":"2023-07-17"},{"cvss_score":9.1,"headline":"Mongoose search injection vulnerability","id":"CVE-2024-53900","kev_date_added":null,"published":"2024-12-02"},{"cvss_score":9.1,"headline":"Improper Input Validation in Automattic Mongoose","id":"CVE-2019-17426","kev_date_added":null,"published":"2019-10-10"},{"cvss_score":9,"headline":"Mongoose search injection vulnerability","id":"CVE-2025-23061","kev_date_added":null,"published":"2025-01-15"},{"cvss_score":7,"headline":"Prototype Pollution in automattic/mongoose","id":"CVE-2022-2564","kev_date_added":null,"published":"2022-07-28"}],"sources":[{"class":"attribution","licence":"Apache-2.0","name":"Bitnami","prefix":"BIT"},{"class":"attribution","licence":"CVE Terms of Use (MITRE)","name":"CVE List","prefix":"CVE"},{"class":"attribution","licence":"CC BY 4.0","name":"GitHub Advisory Database","prefix":"GHSA"},{"class":"attribution","licence":"US public information, NVD API terms","name":"NVD"},{"class":"attribution","licence":"CWE Terms of Use","name":"CWE (MITRE)"},{"class":"attribution","licence":"FIRST CVSS licence","name":"CVSS (FIRST)"}],"ssvc":{"automatable":"yes","exploitation":"none","technical_impact":"partial"},"state":"PUBLISHED","updated":"2026-05-14","vendors":["Automattic"]},"summary":"Attackers can bypass query sanitization via the $nor operator to inject malicious NoSQL queries, potentially reading or modifying data.","url":"https://insights.sbomify.com/CVE-2026-42334/"}