CVE-2025-1691Mongodb Mongosh
Medium 6.5 No auth needed
Follow: this CVE · Mongodb · Mongodb Mongosh We alert you by email or Slack (account required).
- Priority
- 54
- CVSS 3.1
- 6.5
- EPSS
- 0.7% probability of exploitation in 30 days · percentile 49
- Auth required
- No
- Published
- Feb 27, 2025
- Updated
- Jun 17, 2026
- Category
- Application · Cross-platform
- Weakness (CWE)
- CWE-74
- SSVC (CISA)
- Exploitation: none · Automatable: no · Technical impact: total
- Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:H/A:N
What happens
The MongoDB Shell may be susceptible to control character injection where an attacker with control of the mongosh autocomplete feature, can use the autocompletion feature to input and run obfuscated malicious text. This requires user interaction in the form of the user using ‘tab’ to autocomplete text that is a prefix of the attacker’s prepared autocompletion. This issue affects mongosh versions prior to 2.3.9.
The vulnerability is exploitable only when mongosh is connected to a cluster that is partially or fully controlled by an attacker.
What to do
- Apply the vendor's security update for Mongosh.
- It can be exploited without authentication: if you cannot patch now, restrict Internet access to the affected service.
Affected packages
| Ecosystem | Package | Affected versions | Fixed in | How to upgrade |
|---|---|---|---|---|
| npm | mongosh |
< 2.3.9 |
2.3.9 |
npm install mongosh@2.3.9 |
Per OSV / GitHub Advisories (GHSA-43g5-2wr2-q7vj). Check the version in your lockfile before upgrading.
Affected products (CPE)
| Vendor | Product | Versions |
|---|---|---|
| mongodb | mongosh | < 2.3.9 |
Official sources
References
Links published by the sources. Open them with care.
- jira.mongodb.org Issue Tracking Vendor Advisory