GraphQL Tools: TLS Certificate Validation Disabled in Legacy GraphQL WebSocket ExecutorGHSA-6fw5-9hq8-w87g
HIGHFix: ardatan/graphql-tools#8426GHSA-6fw5-9hq8-w87g is a high-severity (CVSS 7.4) CWE-295 vulnerability in @graphql-tools/executor-legacy-ws. A fix is available for @graphql-tools/executor-legacy-ws — see the affected versions and patch details below.
Exploitation Status
No confirmed exploitation observed yet
- A successful exploit gives an attacker total control of the affected component, not partial access.
- CISA’s own triage has not observed active exploitation or public proof-of-concept code for this CVE as of its last assessment.
Exploitation and automatability from CISA’s SSVC triage for GHSA-6fw5-9hq8-w87g.
EPSS Exploitation Probability
Probability of exploitation in the next 30 days, from FIRST.org EPSS.
How urgent is this, really
GHSA-6fw5-9hq8-w87g by exploitation likelihood (EPSS) against impact (CVSS). Outside the shaded patch-first corner.
Where this sits among everything scored
Of 394,803 CVEs with a current EPSS score, this one falls in the < 10% band (highlighted). Counts from FIRST.org, log-scaled.
Real-World Exposure
@graphql-tools/executor-legacy-wsReal-time download stats are indexed for npm and PyPI packages. This vulnerability affects npm packages — download data is not available via public APIs for these ecosystems.
Description
Impact
buildWSLegacyExecutor() in @graphql-tools/executor-legacy-ws previously hardcoded rejectUnauthorized: false when creating WebSocket connections over WSS. This disabled TLS certificate validation, allowing a network-positioned attacker to perform a Man-in-the-Middle (MITM) attack against applications that use this executor with a wss:// endpoint. Credentials passed via connectionParams or headers could be intercepted, and subscription data could be tampered with.
Who is impacted: Applications using @graphql-tools/executor-legacy-ws (directly or via @graphql-tools/url-loader with SubscriptionProtocol.LEGACY_WS) to connect to a wss:// endpoint from Node.js while sending authentication material over the connection.
Browser WebSocket clients are unaffected by this option (browsers always validate certificates).
Patches
Upgrade to @graphql-tools/[email protected] or later (and @graphql-tools/[email protected] or later if you use the loader). TLS certificate validation is enabled by default. Callers that intentionally use self-signed certificates in trusted environments can opt out with rejectUnauthorized: false.
Workarounds
- Prefer the modern
graphql-ws/SubscriptionProtocol.WSpath where possible. - Until upgraded, avoid sending secrets over legacy WSS connections, or terminate TLS at a trusted proxy and use
ws://only on trusted networks. - Supply a custom
webSocketImplthat enforces certificate validation.
Affected Packages
| Ecosystem | Package | Vulnerable range | Fix |
|---|---|---|---|
| 📦npm | @graphql-tools/executor-legacy-ws | all versions | 1.1.35npm install @graphql-tools/executor-legacy-ws@1.1.35 |
Detection & mitigation playbook
Open-source dependencyDetect
Scan your dependency tree (package-lock.json, pnpm-lock.yaml, requirements.txt, go.sum, etc.) for @graphql-tools/executor-legacy-ws, including transitive dependencies — a direct dependency you never call can still pull in a vulnerable version.
Fix
Update @graphql-tools/executor-legacy-ws to 1.1.35 or later, then make sure no transitive (indirect) dependency still pins the vulnerable range — O3 confirms GHSA-6fw5-9hq8-w87g is resolved across your whole dependency graph.
Workarounds
If you can't upgrade right away: gate or disable the affected feature, validate untrusted input at the boundary, and avoid passing attacker-controlled data into the vulnerable path. O3's runtime protection blocks exploitation in production as an interim safeguard until the upgrade lands.
Frequently Asked Questions
Is GHSA-6fw5-9hq8-w87g in your dependencies?
Find it across npm, including transitive dependencies.