Memory Access Vulnerability in MongoDB Foreign Data Wrapper by EnterpriseDB
CVE-2026-62157
Key Information:
- Vendor
Enterprisedb
- Vendor
- CVE Published:
- 25 November 2026
What is CVE-2026-62157?
The mongo_fdw extension is susceptible to a memory access vulnerability arising from improper handling of _id values during conversion. The library utilizes libbson functions that read a fixed number of bytes without verifying the length of the input. This flaw affects bytea _id values and name-typed values such as $oid fields in JSON. Submitting shorter values can result in reading past the intended memory buffer, potentially crashing the PostgreSQL backend or inadvertently including adjacent memory in queries sent to MongoDB. The issue has been resolved in mongo_fdw version 5.6.0, which now enforces strict validation to ensure only legitimate 24-character hexadecimal ObjectIds and 12-byte bytea values are processed.
Affected Version(s)
MongoDB Foreign Data Wrapper (mongo_fdw) 0 < 5.6.0
