CVE-2025-23061
Mongoosejs Mongoose vulnerability
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.
High priority: this vulnerability is rated critical and can be attacked over the network without a login.
Affected products
Mongoose. The exact versions are in the references.
What to do now
- Check your exposureFind out whether Mongoosejs Mongoose runs anywhere in your environment, including systems of suppliers.
- UpdateInstall the version in which the vendor fixed the vulnerability. The references lead to the advisory.
- Limit access until thenIf you cannot update at once, take the system off the internet or restrict who can reach it.
References
- github.com/Automattic/mongoose/commit/64a9f9706f2428c49e0cfb8e223065acc645f7bc · Patch
- github.com/Automattic/mongoose/blob/master/CHANGELOG.md
- github.com/Automattic/mongoose/releases/tag/8.9.5
- www.npmjs.com/package/mongoose?activeTab=versions
- nvd.nist.gov/vuln/detail/CVE-2025-23061
- github.com/Automattic/mongoose/compare/6.13.5...6.13.6
- github.com/Automattic/mongoose/compare/7.8.3...7.8.4
- github.com/Automattic/mongoose/compare/8.9.4...8.9.5
- nvd.nist.gov/vuln/detail/CVE-2025-23061
- cve.org/CVERecord?id=CVE-2025-23061
Data: CVE list and the NVD. This product uses data from the NVD API but is not endorsed or certified by the NVD.