CVE-2026-126837
Published:November 12, 2026
Updated:November 23, 2026
A validation flaw in the DNS SRV host discovery of the MongoDB Node.js driver may cause the driver to connect to a host outside the expected domain. For a mongodb+srv:// connection string, the driver checks each host name in the DNS SRV response against the domain of the connection string. The driver then builds the connection address from the original name, in which certain characters end the host name early. An unauthenticated party who can forge or change the DNS SRV response may redirect the connection to a host of their choice. TLS does not prevent this, because the driver verifies the server certificate against the redirected host name. This may result in unintended disclosure of application data and authentication credentials, and in altered query results. Applications that use mongodb:// connection strings are not affected.
Affected Packages
https://github.com/mongodb/node-mongodb-native.git (GITHUB):
Affected version(s) =v.2.2.34 <v7.8.0 || =v2.2.36 <v7.8.0 || >=v3.0.0-rc0 <v7.8.0 || >=v4.0.0-beta.0 <v7.8.0 || >=v5.0.0-alpha.0 <v7.8.0 || >=v6.0.0 <v7.8.0 || >=v7.0.0 <v7.8.0Fix Suggestion:
Update to version v7.8.0mongodb (NPM):
Affected version(s) >=4.0.0-beta.0 <7.8.0 || >=5.0.0-alpha.0 <7.8.0 || >=7.0.0 <7.8.0 || >=3.0.0-rc0 <7.8.0 || >=2.2.34 <7.8.0 || >=6.0.0-alpha.0 <7.8.0Fix Suggestion:
Update to version 7.8.0Related Resources (1)
Do you need more information?
Contact UsCVSS v4
Base Score:
9.1
Attack Vector
NETWORK
Attack Complexity
LOW
Attack Requirements
PRESENT
Privileges Required
NONE
User Interaction
NONE
Vulnerable System Confidentiality
HIGH
Vulnerable System Integrity
HIGH
Vulnerable System Availability
NONE
Subsequent System Confidentiality
NONE
Subsequent System Integrity
NONE
Subsequent System Availability
NONE
CVSS v3
Base Score:
7.4
Attack Vector
NETWORK
Attack Complexity
HIGH
Privileges Required
NONE
User Interaction
NONE
Scope
UNCHANGED
Confidentiality
HIGH
Integrity
HIGH
Availability
NONE
Weakness Type (CWE)
Incorrect Behavior Order: Validate Before Canonicalize
EPSS
Base Score:
0.24