Skip to content

n8n-mcp's IPv4-mapped IPv6 addresses bypass SSRF protection in validateUrlSync(), enabling full SSRF for SDK embedders

High severity GitHub Reviewed Published Apr 22, 2026 in czlonkowski/n8n-mcp • Updated Apr 30, 2026

Package

n8n-mcp (npm)

Affected versions

>= 2.47.4, < 2.47.14

Patched versions

2.47.14

Description

Impact

In the SDK embedder path (N8NDocumentationMCPServer constructor, getN8nApiClient(), and validateInstanceContext()), the synchronous URL validator in SSRFProtection.validateUrlSync() had no IPv6 checks. IPv4-mapped IPv6 addresses such as http://[::ffff:169.254.169.254] bypassed the cloud-metadata, localhost, and private-IP range checks. An attacker able to supply an n8nApiUrl value could cause the server to issue HTTP requests to cloud metadata endpoints (AWS IMDS, GCP, Azure, Alibaba, Oracle), RFC1918 private networks, or localhost services. Response bodies are returned to the caller (non-blind SSRF), and the n8nApiKey is forwarded in the x-n8n-api-key header to the attacker-controlled target.

The first-party HTTP server deployment was not primarily affected — it has a second async validator (validateWebhookUrl) that catches IPv6 addresses.

Impact category: CWE-918 (Server-Side Request Forgery).

Affected

Deployments embedding n8n-mcp as an SDK using N8NDocumentationMCPServer or N8NMCPEngine with user-supplied InstanceContext on versions v2.47.4 through v2.47.13.

Patched

v2.47.14 and later.

  • npm: npx n8n-mcp@latest (or pin to >= 2.47.14)
  • Docker: docker pull ghcr.io/czlonkowski/n8n-mcp:latest

Workarounds

If developers cannot upgrade immediately:

  • Validate URLs before passing to the SDK — reject any n8nApiUrl whose hostname is an IP literal (bracketed IPv6 or dotted IPv4) before calling N8NDocumentationMCPServer / getN8nApiClient(). Accept only URLs with DNS-resolvable hostnames.
  • Restrict egress at the network layer — block outbound traffic from the n8n-mcp process to RFC1918 ranges (10.0.0.0/8, 172.16.0.0/12, 192.168.0.0/16), link-local 169.254.0.0/16, and cloud metadata endpoints. Defense-in-depth against this class of issue and recommended even after upgrading.
  • Do not accept user-controlled n8nApiUrl values — if the project's integration derives the URL from internal configuration only, this vulnerability is not reachable.

Upgrading to v2.47.14 is still strongly recommended.

Credit

Reported by @manthanghasadiya.

References

@czlonkowski czlonkowski published to czlonkowski/n8n-mcp Apr 22, 2026
Published to the GitHub Advisory Database Apr 30, 2026
Reviewed Apr 30, 2026
Last updated Apr 30, 2026

Severity

High

CVSS overall score

This score calculates overall vulnerability severity from 0 to 10 and is based on the Common Vulnerability Scoring System (CVSS).
/ 10

CVSS v3 base metrics

Attack vector
Network
Attack complexity
Low
Privileges required
Low
User interaction
None
Scope
Changed
Confidentiality
High
Integrity
Low
Availability
None

CVSS v3 base metrics

Attack vector: More severe the more the remote (logically and physically) an attacker can be in order to exploit the vulnerability.
Attack complexity: More severe for the least complex attacks.
Privileges required: More severe if no privileges are required.
User interaction: More severe when no user interaction is required.
Scope: More severe when a scope change occurs, e.g. one vulnerable component impacts resources in components beyond its security scope.
Confidentiality: More severe when loss of data confidentiality is highest, measuring the level of data access available to an unauthorized user.
Integrity: More severe when loss of data integrity is the highest, measuring the consequence of data modification possible by an unauthorized user.
Availability: More severe when the loss of impacted component availability is highest.
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:L/A:N

EPSS score

Weaknesses

Server-Side Request Forgery (SSRF)

The web server receives a URL or similar request from an upstream component and retrieves the contents of this URL, but it does not sufficiently ensure that the request is being sent to the expected destination. Learn more on MITRE.

CVE ID

CVE-2026-42449

GHSA ID

GHSA-56c3-vfp2-5qqj

Source code

Credits

Loading Checking history
See something to contribute? Suggest improvements for this vulnerability.