CVE-2026-62157
NVD
Vulnerability Summary
mongo_fdw converts _id values to 12-byte MongoDB ObjectIds with libbson functions that read a fixed number of bytes without checking the input length: 12 bytes for a bytea _id, and 24 characters for name-typed values and $oid fields in JSON. A shorter value causes a read past the end of the input, which can crash the PostgreSQL backend or include adjacent memory in the query sent to MongoDB. Any user who can supply an _id value or predicate on a foreign table can trigger it. The issue is fixed in mongo_fdw 5.6.0. From mongo_fdw 5.6.0, mongo_fdw accepts only valid 24-character hexadecimal ObjectIds and 12-byte bytea values.
CVSS v4.0 Base Metrics — Score 5.3 (MEDIUM)
CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:L/VI:N/VA:L/SC:N/SI:N/SA:NAttack VectorNetwork
Attack ComplexityLow
Attack RequirementsNone
Privileges RequiredLow
User InteractionNone
Confidentiality (Vulnerable System)Low
Integrity (Vulnerable System)None
Availability (Vulnerable System)Low
Confidentiality (Subsequent System)None
Integrity (Subsequent System)None
Availability (Subsequent System)None
Affected & Patched Versions
- EnterpriseDB MongoDB Foreign Data Wrapper (mongo_fdw) < 5.6.0
- EnterpriseDB MongoDB Foreign Data Wrapper (mongo_fdw) 5.6.0
What to do
Fix it during your normal patch cycle. No exploitation is confirmed yet.
- Check whether you run EnterpriseDB MongoDB Foreign Data Wrapper (mongo_fdw) and which version.
- Update to a patched version listed above, then confirm the new version.
Timeline
- Nov 25, 2026Published
- Nov 25, 2026Record last modified
Score, severity and exploitation changes are tracked from the day Watchtower started logging them.
Get notified about new EnterpriseDB MongoDB Foreign Data Wrapper (mongo_fdw) CVEsYou are reading CVE-2026-62157. Get an email when KEV listings, exploits or new CVEs match your stack.
Set up CVE alertsExternal References
Data last checked: Nov 30, 2026 06:16 UTC