{"id":"CVE-2025-23061","aliases":["BIT-mongoose-2025-23061","CLSA-2026-1774916722","CLSA-2026-1777250310","EUVD-2025-0106","GHSA-vg7j-7cwx-8wgw","ROOT-APP-NPM-CVE-2025-23061"],"status":"published","title":"Mongoose search injection vulnerability","description":"Mongoose before 8.9.5 can improperly use a nested $where filter with a populate() match, leading to search injection. NOTE: this issue exists because of an incomplete fix for CVE-2024-53900.","severity":{"version":"3.1","score":9,"vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:C/C:H/I:H/A:H","level":"critical","assessor":"cna","from":"cve"},"epss":{"day":"2026-11-12","score":0.07236,"percentile":0.94415,"model":"v2026.06.15"},"facts":{"in_kev":false,"known_exploited":false,"public_exploit":true,"fix_available":true},"cwes":["CWE-94"],"published":"2025-01-15T00:00:00Z","modified":"2026-10-28T02:31:14Z","exploits":[{"source":"nuclei","id":"CVE-2025-23061","title":"Mongoose - NoSQL Injection","type":"detection template","url":"https://github.com/projectdiscovery/nuclei-templates/blob/main/http/cves/2025/CVE-2025-23061.yaml"},{"source":"pocgithub","id":"amikanev/CVE-2025-23061-LAB","title":"amikanev/CVE-2025-23061-LAB","date":"2026-04-06","url":"https://github.com/amikanev/CVE-2025-23061-LAB"},{"source":"pocgithub","id":"open-flaw/CVE-2025-23061","title":"open-flaw/CVE-2025-23061","date":"2025-12-11","url":"https://github.com/open-flaw/CVE-2025-23061"}],"fixes":[{"ecosystem":"npm","package":"mongoose","fixed_in":["8.9.5","7.8.4","6.13.6"],"sources":["ghsa","osv"]},{"ecosystem":"Bitnami","package":"mongoose","fixed_in":["6.13.6","7.8.4","8.9.5"],"sources":["osv"]},{"ecosystem":"TuxCare:npm","package":"mongoose","fixed_in":["5.13.23-tuxcare.1","6.12.2-tuxcare.2"],"sources":["osv"]},{"ecosystem":"Root:npm","package":"mongoose","fixed_in":["5.13.23-aikido.1","6.9.1-aikido.2","6.9.1-aikido.3","6.9.1-aikido.4"],"sources":["osv"]},{"ecosystem":"Root:npm","package":"@rootio/mongoose","fixed_in":["5.13.23-root.io.1","6.9.1-root.io.2","6.9.1-root.io.3","6.9.1-root.io.4"],"sources":["osv"]}],"affected":[{"source":"ghsa","ecosystem":"npm","package":"mongoose","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"8.0.0-rc0"},{"fixed":"8.9.5"}]}]},{"source":"ghsa","ecosystem":"npm","package":"mongoose","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"7.0.0-rc0"},{"fixed":"7.8.4"}]}]},{"source":"ghsa","ecosystem":"npm","package":"mongoose","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"6.13.6"}]}]},{"source":"osv","ecosystem":"Bitnami","package":"mongoose","ranges":[{"type":"SEMVER","events":[{"introduced":"6.0.0"},{"fixed":"6.13.6"},{"introduced":"7.0.0"},{"fixed":"7.8.4"},{"introduced":"8.0.0"},{"fixed":"8.9.5"}]}]},{"source":"osv","ecosystem":"TuxCare:npm","package":"mongoose","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"5.13.23-tuxcare.0"},{"fixed":"5.13.23-tuxcare.1"}]}],"versions":["5.13.23"]},{"source":"osv","ecosystem":"TuxCare:npm","package":"mongoose","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"6.12.2-tuxcare.0"},{"fixed":"6.12.2-tuxcare.2"}]}],"versions":["6.12.2","6.12.2-tuxcare.1"]},{"source":"osv","ecosystem":"npm","package":"mongoose","ranges":[{"type":"SEMVER","events":[{"introduced":"8.0.0-rc0"},{"fixed":"8.9.5"}]}]},{"source":"osv","ecosystem":"npm","package":"mongoose","ranges":[{"type":"SEMVER","events":[{"introduced":"7.0.0-rc0"},{"fixed":"7.8.4"}]}]},{"source":"osv","ecosystem":"npm","package":"mongoose","ranges":[{"type":"SEMVER","events":[{"introduced":"0"},{"fixed":"6.13.6"}]}]},{"source":"osv","ecosystem":"Root:npm","package":"mongoose","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"5.13.23-aikido.1"},{"fixed":"6.9.1-aikido.2"},{"fixed":"6.9.1-aikido.3"},{"fixed":"6.9.1-aikido.4"}]}]},{"source":"osv","ecosystem":"Root:npm","package":"@rootio/mongoose","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"5.13.23-root.io.1"},{"fixed":"6.9.1-root.io.2"},{"fixed":"6.9.1-root.io.3"},{"fixed":"6.9.1-root.io.4"}]}]}],"products":[{"vendor":"automattic","product":"mongoose"},{"vendor":"mongoosejs","product":"mongoose"}],"references":[{"url":"https://www.npmjs.com/package/mongoose?activeTab=versions","tags":["Product","web"]},{"url":"https://github.com/Automattic/mongoose/blob/master/CHANGELOG.md","tags":["Release Notes","article","web"]},{"url":"https://github.com/Automattic/mongoose/releases/tag/8.9.5","tags":["Release Notes","article","web"]},{"url":"https://github.com/Automattic/mongoose/commit/64a9f9706f2428c49e0cfb8e223065acc645f7bc","tags":["Patch","fix","web"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2025-23061","tags":["web","advisory"]},{"url":"https://github.com/Automattic/mongoose/compare/6.13.5...6.13.6","tags":["web"]},{"url":"https://github.com/Automattic/mongoose/compare/7.8.3...7.8.4","tags":["web"]},{"url":"https://github.com/Automattic/mongoose/compare/8.9.4...8.9.5","tags":["web"]},{"url":"https://github.com/Automattic/mongoose/releases/tag/6.13.6","tags":["web"]},{"url":"https://github.com/Automattic/mongoose/releases/tag/7.8.4","tags":["web"]},{"url":"https://github.com/advisories/GHSA-m7xq-9374-9rvx","tags":["advisory"]},{"url":"https://github.com/advisories/GHSA-vg7j-7cwx-8wgw"},{"url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/23xxx/CVE-2025-23061.json","tags":["advisory"]},{"url":"https://github.com/Automattic/mongoose","tags":["package"]}],"sources":{"cve":[{"id":"CVE-2025-23061","description":"Mongoose before 8.9.5 can improperly use a nested $where filter with a populate() match, leading to search injection. NOTE: this issue exists because of an incomplete fix for CVE-2024-53900.","status":"published","published":"2025-01-15T00:00:00Z","modified":"2025-01-15T15:11:21.314Z","cvss":[{"version":"3.1","score":9,"vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:C/C:H/I:H/A:H","level":"critical","assessor":"cna"}],"cwes":["CWE-94"],"updated_at":"2026-11-02T14:32:33.410838Z"}],"euvd":[{"id":"EUVD-2025-0106","description":"Mongoose before 8.9.5 can improperly use a nested $where filter with a populate() match, leading to search injection. NOTE: this issue exists because of an incomplete fix for CVE-2024-53900.","status":"published","published":"2025-01-15T00:00:00Z","modified":"2025-01-15T15:11:21Z","cvss":[{"version":"3.1","score":9,"vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:C/C:H/I:H/A:H","level":"critical"}],"updated_at":"2026-11-03T00:04:19.010388Z"}],"ghsa":[{"id":"GHSA-vg7j-7cwx-8wgw","title":"Mongoose search injection vulnerability","description":"Mongoose versions prior to 8.9.5, 7.8.4, and 6.13.6 are vulnerable to improper use of the `$where` operator. This vulnerability arises from the ability of the `$where` clause to execute arbitrary JavaScript code in MongoDB queries, potentially leading to code injection attacks and unauthorized access or manipulation of database data.\n\nNOTE: this issue exists because of an incomplete fix for CVE-2024-53900.","status":"published","published":"2025-01-15T06:30:49Z","modified":"2025-01-17T18:02:41Z","cvss":[{"version":"3.1","score":9,"vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:C/C:H/I:H/A:H","level":"critical"}],"cwes":["CWE-94"],"updated_at":"2026-11-02T14:38:27.067633Z"}],"nvd":[{"id":"CVE-2025-23061","description":"Mongoose before 8.9.5 can improperly use a nested $where filter with a populate() match, leading to search injection. NOTE: this issue exists because of an incomplete fix for CVE-2024-53900.","status":"published","published":"2025-01-15T05:15:10.517Z","modified":"2026-06-17T08:51:48Z","cvss":[{"version":"3.1","score":9,"vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:C/C:H/I:H/A:H","level":"critical","assessor":"secondary"},{"version":"3.1","score":9.8,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","level":"critical","assessor":"primary"}],"cwes":["CWE-94"],"updated_at":"2026-11-02T14:10:48.713733Z"}],"osv":[{"id":"CVE-2025-23061","description":"Mongoose before 8.9.5 can improperly use a nested $where filter with a populate() match, leading to search injection. NOTE: this issue exists because of an incomplete fix for CVE-2024-53900.","status":"published","published":"2025-01-15T00:00:00Z","modified":"2026-10-28T02:31:14.595683727Z","cvss":[{"version":"3.1","score":9,"vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:C/C:H/I:H/A:H","level":"critical"}],"cwes":["CWE-94"],"updated_at":"2026-11-02T15:44:47.009967Z"},{"id":"GHSA-vg7j-7cwx-8wgw","title":"Mongoose search injection vulnerability","description":"Mongoose versions prior to 8.9.5, 7.8.4, and 6.13.6 are vulnerable to improper use of the `$where` operator. This vulnerability arises from the ability of the `$where` clause to execute arbitrary JavaScript code in MongoDB queries, potentially leading to code injection attacks and unauthorized access or manipulation of database data.\n\nNOTE: this issue exists because of an incomplete fix for CVE-2024-53900.","status":"published","published":"2025-01-15T06:30:49Z","modified":"2025-10-03T15:40:22Z","cvss":[{"version":"3.1","score":9,"vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:C/C:H/I:H/A:H","level":"critical"}],"cwes":["CWE-94"],"updated_at":"2026-11-02T15:46:57.348035Z"},{"id":"BIT-mongoose-2025-23061","description":"Mongoose before 8.9.5 can improperly use a nested $where filter with a populate() match, leading to search injection. NOTE: this issue exists because of an incomplete fix for CVE-2024-53900.","status":"published","published":"2025-09-25T08:46:40.232Z","modified":"2026-09-10T16:01:43.392734452Z","updated_at":"2026-11-02T15:28:33.469426Z"},{"id":"CLSA-2026-1774916722","title":"TuxCare security update for mongoose (1 CVE)","description":"TuxCare rebuilt mongoose to address 1 CVE. Fixed in 5.13.23-tuxcare.1.","status":"published","published":"2026-08-04T14:52:17Z","modified":"2026-10-15T09:47:49.016066773Z","updated_at":"2026-11-02T15:43:43.621843Z"},{"id":"CLSA-2026-1777250310","title":"TuxCare security update for mongoose (1 CVE)","description":"TuxCare rebuilt mongoose to address 1 CVE. Fixed in 6.12.2-tuxcare.2.","status":"published","published":"2026-08-04T14:52:28Z","modified":"2026-10-15T09:45:49.582119384Z","updated_at":"2026-11-02T15:43:44.384419Z"},{"id":"ROOT-APP-NPM-CVE-2025-23061","title":"CVE-2025-23061 in mongoose - Patched by Root","description":"Root has patched CVE-2025-23061 in the mongoose package for Root:npm. Multiple fixed versions available.","status":"published","published":"2026-09-01T06:57:58Z","modified":"2026-09-01T09:15:06.90824781Z","updated_at":"2026-11-02T15:53:27.362922Z"}]}}
