mongodb: Reject "." and NUL bytes in database and collection namesGHSA-65fr-j4p9-vc33
HIGHFix: mongodb/mongo-php-library#1967GHSA-65fr-j4p9-vc33 is a high-severity (CVSS 8.1) CWE-943 vulnerability in mongodb/mongodb. A fix is available for mongodb/mongodb — see the affected versions and patch details below.
EPSS Exploitation Probability
Probability of exploitation in the next 30 days, from FIRST.org EPSS.
How urgent is this, really
GHSA-65fr-j4p9-vc33 by exploitation likelihood (EPSS) against impact (CVSS). Outside the shaded patch-first corner.
Where this sits among everything scored
Of 385,738 CVEs with a current EPSS score, this one falls in the < 10% band (highlighted). Counts from FIRST.org, log-scaled.
Real-World Exposure
mongodb/mongodb🐘mongodb/mongodbReal-time download stats are indexed for npm and PyPI packages. This vulnerability affects Packagist packages — download data is not available via public APIs for these ecosystems.
Description
The MongoDB client library for PHP does not sufficiently sanitize special elements in application-supplied namespace identifiers before using them to construct the target namespace for database operations. An application that incorporates untrusted text into these identifiers may have operations silently directed at a different storage location than the one the application intended.
Affected Packages
| Ecosystem | Package | Vulnerable range | Fix |
|---|---|---|---|
| 🐘Packagist | mongodb/mongodb | all versions | 1.21.4composer require mongodb/mongodb:^1.21.4 |
| 🐘Packagist | mongodb/mongodb | ≥ 2.0.0&&< 2.4.1 | 2.4.1composer require mongodb/mongodb:^2.4.1 |
Affected Products
php drivermongodbphp librarymongodbDetection & mitigation playbook
Open-source dependencyDetect
Scan your dependency tree (package-lock.json, pnpm-lock.yaml, requirements.txt, go.sum, etc.) for mongodb/mongodb, including transitive dependencies — a direct dependency you never call can still pull in a vulnerable version.
Fix
Update mongodb/mongodb to 1.21.4 or later, then make sure no transitive (indirect) dependency still pins the vulnerable range — O3 confirms GHSA-65fr-j4p9-vc33 is resolved across your whole dependency graph.
Workarounds
If you can't upgrade right away: gate or disable the affected feature, validate untrusted input at the boundary, and avoid passing attacker-controlled data into the vulnerable path. O3's runtime protection blocks exploitation in production as an interim safeguard until the upgrade lands.
Frequently Asked Questions
Is GHSA-65fr-j4p9-vc33 in your dependencies?
Find it across Packagist, including transitive dependencies.