Description
The BSON encoder in the MongoDB PHP Driver converts a string length to a 32-bit value without validation. When an affected application encodes a string near 4 GiB, the allocation size can wrap while the copy operation uses the original length. The resulting heap buffer overflow can corrupt process memory or terminate the PHP process. Reaching this issue requires a non-default runtime configuration that permits multi-gigabyte values. No MongoDB server interaction is required.
Published: 2026-10-08
Score: 2 Low
EPSS: < 1% Very Low
KEV: No
Impact: Heap Buffer Overflow
Action: Assess Impact
AI Analysis

Impact

The BSON encoder in the MongoDB PHP Driver converts string lengths to a 32‑bit value without validation. When an application encodes a string near 4 GiB, the allocated buffer size can wrap while the copy still uses the original large length. This heap buffer overflow can corrupt process memory or terminate the PHP process. Reaching the issue requires a non‑default runtime configuration that permits multi‑gigabyte strings; no interaction with the MongoDB server is required.

Affected Systems

MongoDB PHP Driver is the affected product. All installations that include the unpatched BSON encoder are vulnerable, regardless of specific version. The flaw exists only within the driver; MongoDB server interaction is not needed.

Risk and Exploitability

The CVSS score of 2 indicates a low severity. EPSS is not available and the vulnerability is not listed in CISA’s KEV catalog. Exploitation requires a runtime configuration that allows strings close to the 4‑GiB boundary; the default configuration typically mitigates this scenario. If an attacker can supply large strings to a PHP application using the driver, they could trigger an overflow, potentially corrupting memory or causing a crash, but the flaw does not provide code execution or persistence. Therefore, the risk is low under typical configurations, though it could be higher in environments accepting large payloads without validation.

Generated by OpenCVE AI on October 9, 2026 at 14:10 UTC.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Upgrade the MongoDB PHP Driver to the latest version that contains the fix for the BSON encoding overflow.
  • Configure the PHP runtime or application server to disallow or reject strings that approach the 4 GiB boundary, for example by setting appropriate length limits in php.ini or within the application logic.
  • Implement validation checks in the application layer to ensure that any string passed to the driver is within a safe, small size before encoding.

Generated by OpenCVE AI on October 9, 2026 at 14:10 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories yet.

History

Tue, 13 Oct 2026 20:15:00 +0000

Type Values Removed Values Added
CPEs cpe:2.3:a:mongodb:php_driver:*:*:*:*:*:mongodb:*:*

Fri, 09 Oct 2026 12:15:00 +0000

Type Values Removed Values Added
Weaknesses CWE-787
References
Metrics threat_severity

None

threat_severity

Low


Thu, 08 Oct 2026 21:15:00 +0000

Type Values Removed Values Added
First Time appeared Mongodb
Mongodb php Driver
Vendors & Products Mongodb
Mongodb php Driver

Thu, 08 Oct 2026 20:30:00 +0000

Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'none', 'Technical Impact': 'partial'}, 'version': '2.0.3'}


Thu, 08 Oct 2026 19:30:00 +0000

Type Values Removed Values Added
Description The BSON encoder in the MongoDB PHP Driver converts a string length to a 32-bit value without validation. When an affected application encodes a string near 4 GiB, the allocation size can wrap while the copy operation uses the original length. The resulting heap buffer overflow can corrupt process memory or terminate the PHP process. Reaching this issue requires a non-default runtime configuration that permits multi-gigabyte values. No MongoDB server interaction is required.
Title Heap buffer overflow via 32-bit string-length truncation in MongoDB PHP Driver
Weaknesses CWE-681
References
Metrics cvssV3_1

{'score': 3.6, 'vector': 'CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:N/I:L/A:L'}

cvssV4_0

{'score': 2, 'vector': 'CVSS:4.0/AV:L/AC:L/AT:P/PR:L/UI:N/VC:N/VI:L/VA:L/SC:N/SI:N/SA:N'}


Subscriptions

Mongodb Php Driver
cve-icon MITRE

Status: PUBLISHED

Assigner: mongodb

Published:

Updated: 2026-10-08T19:51:42.949Z

Reserved: 2026-10-06T16:40:35.016Z

Link: CVE-2026-106432

cve-icon Vulnrichment

Updated: 2026-10-08T19:51:39.099Z

cve-icon NVD

Status : Analyzed

Published: 2026-10-08T20:17:30.647

Modified: 2026-10-13T20:09:23.800

Link: CVE-2026-106432

cve-icon Redhat

Severity : Low

Publid Date: 2026-10-08T19:02:25Z

Links: CVE-2026-106432 - Bugzilla

cve-icon OpenCVE Enrichment

Updated: 2026-10-09T14:15:09Z

Weaknesses
  • CWE-681

    Incorrect Conversion between Numeric Types

  • CWE-787

    Out-of-bounds Write