Bug 2563002 (CVE-2026-118581)

Summary: CVE-2026-118581 org.mongodb/bson: MongoDB Java Driver: Unintended command modification via improper BSON document length validation
Product: [Other] Security Response Reporter: OSIDB Bzimport <bzimport>
Component: vulnerabilityAssignee: Product Security DevOps Team <prodsec-dev>
Status: NEW --- QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: unspecifiedCC: ant, ccranfor, cescoffi, fmongiar, gmalinko, gsmet, janstey, jmartisk, jnethert, jpechane, manderse, olubyans, ozzy, pdelbell, pjindal, rguimara, rhel-process-autobot, rstepani, sbiarozk, varjain, watson-tool-maintainers
Target Milestone: ---Keywords: Security
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: ---
Doc Text:
A flaw was found in the MongoDB Java Driver. The BSON (Binary JSON) encoding component fails to verify that an externally supplied raw document's declared length matches its actual byte range before copying it into an outgoing database command. A remote attacker can exploit this flaw by submitting crafted input through an application that wraps the raw document into database operations, causing trailing data to be interpreted as additional command fields. This issue allows attackers to alter database commands and potentially read or modify data under the application's credentials.
Story Points: ---
Clone Of: Environment:
Last Closed: Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description OSIDB Bzimport 2026-10-28 17:18:09 UTC
A BSON encoding component of the MongoDB Java Driver does not verify that an externally supplied raw document's self-declared length agrees with the extent of the byte range it is given before that range is copied into an outgoing database command. An application that wraps untrusted raw bytes in such a document and uses it as part of a command can therefore emit a structurally inconsistent message, causing the database to interpret attacker-supplied trailing content as additional fields of the surrounding command. No authentication to the driver or database is required beyond the ability to influence those bytes through the victim application, and no user interaction is needed. The result is unintended modification of the command actually executed, which can alter the data read or written under the application's credentials.