CVE-2026-49444: n8n: Python sandbox escape
Impact An authenticated user with permission to create or modify workflows containing a Python Code Node could escape the sandbox and achieve arbitrary code execution on the task runner container.
This issue only affects instances where the Python Task Runner is enabled.
Patches The issue has been fixed in n8n versions 1.123.48, 2.21.8, and 2.22.4. Users should upgrade to one of these versions or later to remediate the vulnerability.
Workarounds If upgrading is not immediately possible, administrators should consider the following temporary mitigations: - Limit workflow creation and editing permissions to fully trusted users only. - Disable the Python Code node by adding n8n-nodes-base.code to the NODESEXCLUDE environment variable, or disable the Python Task Runner entirely.
These workarounds do not fully remediate the risk and should only be used as short-term mitigation measures.
Other sources
n8n is an open source workflow automation platform. Prior to 1.123.48, 2.21.8, and 2.22.4, an authenticated user with permission to create or modify workflows containing a Python Code Node could escape the sandbox and achieve arbitrary code execution on the task runner container. This vulnerability is fixed in 1.123.48, 2.21.8, and 2.22.4.
— MITRE
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade
npm/n8nto a version that resolves this vulnerability.Fixed in 2.21.8 - Upgrade
Upgrade
npm/n8nto a version that resolves this vulnerability.Fixed in 2.22.4 - Upgrade
Upgrade
npm/n8nto a version that resolves this vulnerability.Fixed in 1.123.48 - Upgrade
Upgrade
n8nto a version that resolves this vulnerability.Fixed in 1.123.48 - Upgrade
Upgrade
n8nto a version that resolves this vulnerability.Fixed in 2.21.8 - Upgrade
Upgrade
n8nto a version that resolves this vulnerability.Fixed in 2.22.4 - Configuration
Temporarily disable the Python Code node by adding `n8n-nodes-base.code` to the `NODES_EXCLUDE` environment variable (short-term mitigation only).
n8n (environment configuration) NODES_EXCLUDE = n8n-nodes-base.code - Configuration
Temporarily mitigate by disabling the Python Task Runner entirely (short-term mitigation only).
n8n (Python Task Runner) Python Task Runner = disabled - Configuration
Limit workflow creation and editing permissions to fully trusted users only (short-term mitigation only).
n8n (authorization) workflow creation/editing permissions = fully trusted users only - Compensating control
Ensure instances are only protected for the case where the Python Task Runner is enabled, since the vulnerability only affects instances with the Python Task Runner enabled.
Event History
Frequently Asked Questions
What is the severity of CVE-2026-49444?
CVE-2026-49444 has a high severity rating of 8.5.
How do I fix CVE-2026-49444?
To mitigate CVE-2026-49444, ensure the Python Task Runner is disabled if it's not required for your workflows.
What impact does CVE-2026-49444 have?
CVE-2026-49444 allows authenticated users with specific permissions to execute arbitrary code due to sandbox escape.
Who is affected by CVE-2026-49444?
Instances of npm/n8n where the Python Task Runner is enabled are affected by CVE-2026-49444.
What type of vulnerability is CVE-2026-49444?
CVE-2026-49444 is an Input Validation vulnerability.