Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessSupply BSON document with binary field
-
DeliveryApplication invokes BSON-to-JSON with length cap
-
ExploitTruncation triggers encoding overrun
-
ExecutionDriver writes bytes past heap buffer end
-
ImpactAdjacent heap memory corrupted
Vulnerability Assessment
| Weakness |
CWE
ASVS 5.0
V15 - Secure Coding and Architecture Bounds checking, write limits
MITRE ATT&CK
2 techniques across 2 tactics: Execution, Privilege Escalation The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up. |
| Exploitation Conditions | Two specific conditions must both be met: (1) the application links against an affected version of the MongoDB C Driver and calls a BSON-to-JSON conversion function with a caller-configured maximum output length (truncation limit) - applications that call the conversion without a length cap are not vulnerable; (2) the attacker controls the content of the BSON document being converted and can include a binary-type field. Exploitation is therefore limited to applications that explicitly configure output truncation AND process untrusted BSON documents containing binary fields - a non-default pattern not present in every libmongoc consumer. Authentication on the application side is not required (PR:N), but the attacker must have a channel to supply document content to the affected conversion path. |
| Impact | The CVSS 4.0 vector (AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:L/VA:N) scores 6.3, reflecting a genuine but bounded risk. The network attack vector and no-privilege requirement are concerning, but the AT:P prerequisite (caller must configure a length-limiting truncation) substantially narrows the exploitable population - applications that call the BSON-to-JSON conversion without a custom length cap are not affected. The impact is scored VI:L/VA:N by the vendor (MongoDB CNA), meaning only a small, low-integrity heap corruption; no confidentiality exposure and no confirmed availability impact. In practice, a CWE-787 write in a heap-allocated C buffer can theoretically be leveraged for allocator metadata corruption or, in rare layouts, control-flow hijack, but the vendor characterisation of 'a small number of bytes' and VI:L suggests the write is too constrained for reliable exploitation beyond data corruption. No EPSS score was provided; no KEV listing; no public exploit code exists at time of analysis. Real-world priority is moderate for applications that expose BSON-to-JSON conversion with truncation to untrusted input (e.g., REST APIs serving MongoDB data), and low-to-negligible for applications that do not configure a length limit. |
| Exploit ScenarioDerived | An attacker submits a MongoDB document containing a binary BSON field to an application - such as a REST API or ingestion service - that uses the MongoDB C Driver to convert incoming documents to JSON with a configured output-length cap. When the driver's BSON-to-JSON helper truncates the output at the caller-specified limit during binary field encoding, it writes a small number of bytes past the heap buffer boundary, potentially corrupting adjacent heap contents. No public exploit code exists, and reliable exploitation beyond a bounded heap corruption would depend heavily on the target process's allocator layout. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Sep 03, 2026
Heap buffer out-of-bounds write in the MongoDB C Driver's BSON-to-JSON conversion helpers allows an unauthenticated party who supplies document content to corrupt a small number of bytes past the end of a heap-allocated buffer. The overflow is triggered specifically when a binary BSON field is being encoded and the caller has configured a maximum output length that causes the conversion to be cut short. Impact is limited to a low-integrity write of a few bytes adjacent to the buffer - no confidentiality loss and no confirmed availability impact - but heap corruption in native C applications can have unpredictable downstream effects depending on allocator layout. No public exploit code and no CISA KEV listing exist at time of analysis.
RemediationAI
No vendor-released patch version is confirmed in the available input data; the upstream fix is tracked in JIRA issue CDRIVER-6410 (https://jira.mongodb.org/browse/CDRIVER-6410) - monitor that ticket and the mongodb/mongo-c-driver GitHub releases page for a patched build. As a compensating control, audit all call sites that pass a caller-configured maximum-length argument to the BSON-to-JSON conversion helpers (e.g., bson_as_json_with_opts or equivalent) and, where feasible, remove the truncation limit or increase the buffer to eliminate the short-write condition; note that this may change output size behaviour for downstream consumers. Additionally, restrict which document sources are permitted to supply binary BSON fields to the conversion path, using input validation at the application boundary to reject or sanitise binary payloads before serialisation.
Affected VersionsENISA
Affected Packages
Source: OSV (Open Source Vulnerabilities)
Affects your stack
Affects 1 package in euvd
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
The MongoDB C Driver (libmongoc) provides BSON-to-JSON serialisation helpers used by applications written in C/C++ when converting BSON wire-format documents to human-readable or JSON representations. CWE-787 (Out-of-Bounds Write) identifies the root cause: the conversion routine does not correctly account for the remaining buffer space when a binary sub-type field triggers an encoding path that can emit more bytes than the caller-supplied length limit permits, causing the write pointer to advance past the heap allocation boundary. The CVSS 4.0 Attack-Type metric AT:P confirms that a specific application-side prerequisite - setting a caller-configured truncation limit on the conversion - must be in place for the bug to be reachable. The JIRa tracker CDRIVER-6410 (cna@mongodb.com) is the primary upstream reference; no CVE-scoped vendor advisory with affected version ranges was provided in the input.
Know when MongoDB gets its next vulnerability
- Watch products and get an email when something new is published
- Check this CVE against your own stack and servers
- Exploit and PoC references, threat intelligence from 22 sources
No credit card · 7-day full trial
Severity by source
CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:L/VA:N/SC:N/SI:N/SA:N
AC:H reflects the required caller-configured truncation prerequisite; only low integrity impact matches vendor VI:L; no confidentiality or availability impact.
Primary rating from Vendor (mongodb).
CVSS VectorVendor: mongodb
Lifecycle Timeline
1DescriptionCVE.org
A memory-handling error in the BSON-to-JSON conversion helpers of the MongoDB C Driver can write a small number of bytes past the end of a heap buffer when a binary field is encoded and the output is cut short at a caller-configured length limit. A party who supplies the document content, with no privileges on the application that links the driver, may cause a small amount of data outside the intended buffer to be altered.
Threat Intelligence Overview
How this decision was reached
The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
A buffer overflow occurs when a program writes more data to a memory buffer than it was allocated to hold, causing the excess data to spill into adjacent memory regions.
Memory corruption occurs when a program writes data beyond the boundaries of allocated memory regions or accesses memory in unintended ways, violating the integrity of the process's address space.
MongoDB before 2.0.9 and 2.2.x before 2.2.4 does not properly validate requests to the nativeHelper function in SpiderMo
Use-after-free in MongoDB Server's replication component can terminate replica set members unexpectedly and, under certa
The find prototype in scripting/engine_v8.h in MongoDB 2.4.0 through 2.4.4 allows remote authenticated users to cause a
The MongoDB bson JavaScript module (also known as js-bson) versions 0.5.0 to 1.0.x before 1.0.5 is vulnerable to a Regul
Remote code execution in Chartbrew versions prior to 4.8.1 allows authenticated attackers with high privileges to execut
After user deletion in MongoDB Server the improper invalidation of authorization sessions allows an authenticated user's
The default configuration for MongoDB before 2.3.2 does not validate objects, which allows remote authenticated users to
Unauthenticated MongoDB filter erasure in Budibase Server 3.39.18 through 3.44.0 lets a remote attacker read, modify, or
Authenticated command injection in Dokploy before 0.31.1 lets any user who can update a MySQL, PostgreSQL, MariaDB, Mong
SimStudio below 0.5.74 has a missing authorization on MongoDB tool endpoints that allows attackers to execute arbitrary
MongoDB Server may access non-initialized region of memory leading to unexpected behaviour when zero arguments are calle
MongoDB Compass may be susceptible to code injection due to insufficient sandbox protection settings with the usage of e
Same weakness CWE-787 – Out-of-bounds Write
View allSame technique Buffer Overflow
View allVendor StatusVendor
SUSE
Severity: Moderate| Product | Status |
|---|---|
| openSUSE Tumbleweed | Fixed |
EUVD-2026-70508
GHSA-9xr7-hhfx-wh4c
NVD
CVE.org
EPSS
Vulnrichment
VulDB
Exploit-DB