Impact
MongoDB Compass uses the database name supplied by the server when it starts its embedded MongoDB shell. The server can supply a database name that contains shell code, and Compass does not escape that name. When a user with permissions to create databases on the target server opens the shell for that database, the injected code is executed by the shell within the Compass process. This allows an attacker to run arbitrary commands with the privileges of the Compass application.
Affected Systems
The vulnerability affects MongoDB Compass, specifically any installed version that allows a user to open the embedded shell from a database view before the fix released in version v1.49.12. Versions earlier than 1.49.12 are impacted; upgrades to 1.49.12 or later mitigate the issue.
Risk and Exploitability
The CVSS score of 7.3 indicates high severity. Although no EPSS score is published and the vulnerability is not listed in the CISA KEV catalog, exploitation requires a user who can create databases on the MongoDB server and who can launch Compass. An attacker with those conditions can run arbitrary shell commands and potentially take control of the host running Compass. For environments where users have those privileges, the risk is high and should be addressed promptly.
OpenCVE Enrichment