Information disclosure in MongoDB C# Driver
Key facts
- Attack vector
- Network
- Privileges required
- High
- User interaction
- None
- Attack complexity
- Low
- Impact type
- Information disclosure
- Confidentiality · integrity · availability
- High · None · None
- Fix status
- Fixed
Attack profile from CVSS 3.1 · NVD. Fix status from CNA and GitHub. Impact type from CWE-200.
Summary
Specific versions of the MongoDB C# Driver may erroneously publish events containing authentication-related data to a command listener configured by an application. The published events may contain security-sensitive data when commands such as "saslStart", "saslContinue", "isMaster", "createUser", and "updateUser" are executed. Without due care, an application may inadvertently expose this authenticated-related information, e.g., by writing it to a log file. This issue only arises if an application enables the command listener feature (this is not enabled by default). This issue affects the MongoDB C# Driver v2.12 versions prior to and including 2.12.1.
Why it matters now
SSVC decision points
CISA ADP · SSVC 2.0.3
- Exploitation
- None
- Automatable
- No
- Technical impact
- Partial
The decision (Track, Attend, Act) also depends on your mission and well-being impact; see CISA's SSVC guide.
Affected products
| Vendor | Product | Affected versions | Fixed in | Status | Source |
|---|---|---|---|---|---|
| MongoDB | MongoDB C# Driver | 2.12 – 2.12.1 | — | No fix listed | CNA |
| — | mongodb.driver (NuGet) | 2.11.0 to before 2.12.2 | 2.12.2 | Patch available | GHSA-p9rv-qgqw-jx2w |
- MongoDB C# Driver VendorMongoDB Affected 2.12 – 2.12.1 Fixed in — No fix listed CNA
- mongodb.driver (NuGet) Vendor— Affected 2.11.0 to before 2.12.2 Fixed in 2.12.2 Patch available GHSA-p9rv-qgqw-jx2w
Remediation
- Fix · GHSA-p9rv-qgqw-jx2w mongodb.driver (NuGet) Fixed in 2.12.2 Advisory →
Timeline
- 2026-10-02 Threatist record created from CVE-2021-20331
- 2026-10-03 Alias added: GHSA-p9rv-qgqw-jx2w
- 2026-11-04 EPSS moved to the 50th–90th percentile
References
More MongoDB C# Driver vulnerabilities
- TI-2026-56248 NoSQL injection via unquoted constant GroupBy keys in LINQ pipeline translation CVSS 4.0MEDIUM 6.9
- TI-2022-23899 Deserializing compromised object with MongoDB .NET/C# Driver may cause remote code execution CVSS 3.1HIGH 7.2
- TI-2026-60051 Regular expression injection via unescaped characters in LINQ query translation in MongoDB C# Driver CVSS 4.0HIGH 7.1
- TI-2026-56250 Connection-option injection via unescaped settings in the canonical MongoDB URL builder CVSS 4.0HIGH 7.1
- TI-2026-56251 KMS master key exposure via unredacted credential serialization in driver settings string CVSS 4.0MEDIUM 6.8
- TI-2026-60050 GridFS data disclosure and deletion via query-operator injection in file IDs in the MongoDB C# Driver CVSS 4.0MEDIUM 6.1
Sources
- CVE-2021-20331 · CVE Program
- CVE-2021-20331 · NVD
- FIRST EPSS
- GHSA-p9rv-qgqw-jx2w · GitHub Advisory Database · CC BY 4.0
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences