mediumCVSS 5NVD status: Analyzed

CVE-2026-56777

n8n before 2.25.7 and 2.26.x before 2.26.2 contains an abstract syntax tree (AST) security validator bypass in the Python Code node.

Componentn8n
Severitymedium (CVSS 5)
CVSS vectorCVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:L/I:N/A:N
Published (NVD)2026-06-30
Last modified2026-07-02
Affected versions
n8n < 2.25.7
n8n >= 2.26.0, < 2.26.2
Fixed in2.25.7, 2.26.2
WeaknessCWE-184
CISA KEVnot listed

NVD description

n8n before 2.25.7 and 2.26.x before 2.26.2 contains an abstract syntax tree (AST) security validator bypass in the Python Code node. An authenticated user with permission to create or modify workflows containing a Python Code node can bypass the validator and access the task executor module namespace. The issue only affects self-hosted instances where the Python Task Runner is enabled; where N8N_BLOCK_RUNNER_ENV_ACCESS is configured to allow it, this can disclose environment variables accessible to the task runner process.

Does CVE-2026-56777 hit the version you run?Paste your docker-compose.yml, requirements.txt or package.json. The scanner checks your pinned versions against this CVE and every other one we track for n8n.
Check my stack

What to do

  • Upgrade n8n to 2.25.7 or later (or the patched release of your branch: 2.26.2).
  • Do not expose the component's API or UI to the internet without authentication in front of it.

Sources

Read more

Other n8n CVEs

All n8n CVEs