n8n: SSH MitM enables malicious workflow injection
n8n instances with Source Control configured over SSH are vulnerable to man-in-the-middle attacks that can silently inject malicious content into AI automation workflows. The patch is available in 2.5.0—upgrade immediately; if not feasible, disable Source Control or enforce trusted network paths to the git server. The critical risk here is not data theft: it is an attacker reshaping AI agent behavior at the workflow layer, invisible to end users.
Affected Systems
| Package | Ecosystem | Vulnerable Range | Patched |
|---|---|---|---|
| n8n | npm | < 2.5.0 | 2.5.0 |
Do you use n8n? You're affected.
Severity & Risk
Recommended Action
- 1) Upgrade n8n to version 2.5.0 or later—this is the only full remediation. 2) If upgrade is blocked, disable the Source Control feature entirely via settings. 3) As a network control, route n8n-to-git-server traffic exclusively over a private VPC or VPN where MitM is not feasible. 4) Audit workflow git history for unexpected commits or structural changes to HTTP, code, or LLM nodes. 5) Enable SSH known_hosts enforcement across all automation tooling and validate this is not silently disabled in other CI/CD components. 6) Review n8n logs for unexpected git sync activity or authentication anomalies.
Classification
Compliance Impact
This CVE is relevant to:
Technical Details
NVD Description
n8n is an open source workflow automation platform. Prior to version 2.5.0, when the Source Control feature is configured to use SSH, the SSH command used for git operations explicitly disabled host key verification. A network attacker positioned between the n8n instance and the remote Git server could intercept the connection and present a fraudulent host key, potentially injecting malicious content into workflows or intercepting repository data. This issue only affects instances where the Source Control feature has been explicitly enabled and configured to use SSH (non-default). The issue has been fixed in n8n version 2.5.0. Users should upgrade to this version or later to remediate the vulnerability. If upgrading is not immediately possible, administrators should consider the following temporary mitigations: Disable the Source Control feature if it is not actively required, and/or restrict network access to ensure the n8n instance communicates with the Git server only over trusted, controlled network paths. These workarounds do not fully remediate the risk and should only be used as short-term mitigation measures.
Exploitation Scenario
An attacker with network positioning on the path between the n8n instance and its remote git server—achievable via ARP poisoning on the same subnet, a compromised cloud routing layer, or BGP manipulation—intercepts the SSH handshake when n8n pulls workflow updates. Because StrictHostKeyChecking is disabled, n8n silently accepts the attacker's fraudulent host key. The attacker serves a modified repository containing production workflows with injected malicious steps: an added HTTP Request node that forwards all LLM completions to an external endpoint, a modified AI Agent node with a rewritten system prompt introducing a persistent indirect prompt injection, or a Code node that exfiltrates environment variables including API keys for downstream AI services. These poisoned workflows deploy transparently and execute on every subsequent trigger, potentially for weeks before discovery.
CVSS Vector
CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:N References
- github.com/advisories/GHSA-43v7-fp2v-68f6
- github.com/n8n-io/n8n/security/advisories/GHSA-43v7-fp2v-68f6
- nvd.nist.gov/vuln/detail/CVE-2026-33724
- github.com/n8n-io/n8n/security/advisories/GHSA-43v7-fp2v-68f6 Vendor Mitigation
- github.com/n8n-io/n8n/security/advisories/GHSA-43v7-fp2v-68f6 Vendor Mitigation
AI Threat Alert