
The SonicWall Capture Labs threat research team became aware of a Critical Remote Code Execution (RCE) Vulnerability in n8n, a flexible AI workflow automation platform, assessed its impact, and developed mitigation measures. N8N is frequently used to automate repetitive operational tasks and to integrate security tools and SaaS platforms. In simple words, using n8n users build workflows composed of nodes, with each node representing an action such as making an API request, processing data, or sending an email.
The authenticated RCE vulnerability, identified as CVE-2025-68613, has been discovered in n8n AI workflow automation, affecting versions starting with 0.211.0 and prior to 1.120.4, 1.121.1, and 1.122.0 in its server-side expression evaluation engine. These flaws enable remote attackers to exploit the built-in node(s) feature to achieve code execution on the local host. With ease and a high exploitability rate, authenticated threat actors can exploit the vulnerability to achieve code execution via node abuse on the host. Though being an authenticated vulnerability, CVE-2025-68613 received a CVSS score of 9.9 (Critical) due to its low attack complexity, high impact, and the fact that it affects core application functionality. Exploitation requires authentication, but no elevated privileges beyond those required for workflow creation or editing. Targeting AI-powered workflow automation platforms introduces a new attack vector, which may create additional opportunities for threat actors, leading to data breaches and the distribution of malicious code. Hence, all organizations that use n8n AI workflow instances are strongly encouraged to update their instances to the latest patched version as a matter of urgency.
At the heart of vulnerability lies the core issue: the expression evaluation engine. n8n is frequently used to automate repetitive operational tasks and to integrate security tools and SaaS platforms. The n8n AI workflow platforms can be deployed in a variety of configurations, such as:
While understanding the architecture of n8n, it is built on Node.js, using JavaScript for platform internals and user workflow logic. The primary architecture is built on,
Technically, an n8n workflow is a directed graph of nodes as shown in Figure 1. According to the user's needs, they can select a node and formulate a workflow. A simple workflow can be triggered by a scheduled event, an HTTP request, a slack node, or a basic function node. As mentioned earlier, the Expression Evaluation System accepts function expressions that execute in a context that is not properly sandboxed, breaking the boundary between “server-code” and an “expression”.
The core security flaw is an expression injection vulnerability that enables authenticated attackers to execute arbitrary JavaScript code with the privileges of the n8n process. Exploitation begins when an attacker gains authenticated access to an n8n instance with permission to create or edit workflows. This access level is commonly granted to developers, DevOps engineers, automation owners, and integration partners. In many environments, these permissions are shared broadly to support collaboration, increasing exposure in the event of credential compromise or insider misuse.
N8n Expression RCE Attack Flow involves below sequence:
In practice, an attacker with low-privilege permissions limited to workflow creation or editing could:
Successful exploitation of CVE-2025-12480 allows remote, authenticated attackers to achieve Remote Code Execution (RCE) in vulnerable N8n AI workflow instances. As demonstrated in Figure 3, an attacker with access to a vulnerable N8n platform initiates the exploit chain by creating or editing a node to start the workflow. Here, the “Set” node is used as a use-case scenario. Furthermore, the Field value is given a malicious expression input, a name, and then the command is executed. The result shows clear RCE. This ease of access with low-level privileges allows remote actors to create new nodes or upload malicious content to existing ones. The patched system will reject such requests, which introduces additional safeguards to restrict expression evaluation.

Given that adversary can circumvent access controls allowing them to create a new workflow with ease, users are strongly advised to upgrade their instances to the latest patched version as outlined in the official vendor advisory. If an immediate upgrade is not possible, consider implementing the following temporary workarounds:
Share This Article

An Article By
An Article By
Dhiren Vaghela
Dhiren Vaghela
Dhiren Vaghela has over a decade of experience in the IPS domain, with a strong focus on defensive security. His expertise lies in identifying, analyzing and mitigating vulnerabilities. Dhiren is well-versed in content-based signature writing, scanner-based alert generation and technical blog writing. By leveraging emerging technologies, he has developed numerous IPS signatures across various protocols. Known for his exceptional signature writing skills and collaborative team spirit, Dhiren is a valuable asset in the field of cybersecurity.