ZeroHour
Security Affairspublished ()ingested @securityaffairs

Ni8mare flaw gives unauthenticated control of n8n instances

Vulnerabilities mentionedAll →

CVEVulnerabilityCVSSEPSSFlagsAffectedExposurePublished
CVE-2025-68613
Authenticated RCE in n8n Workflow Automation Expression Evaluation

n8n, an open source workflow automation platform, contains a critical remote code execution vulnerability (CVE-2025-68613, CWE-913) in its workflow expression evaluation system, affecting versions starting at 0.211.0 and prior to 1.120.4, 1.121.1, and 1.122.0. The flaw is triggered when expressions supplied by authenticated users during workflow configuration are evaluated in an execution context that is not sufficiently isolated from the underlying runtime, allowing the attacker to execute arbitrary code with the privileges of the n8n process. Successful exploitation can result in full compromise of the affected instance, including unauthorized access to sensitive data, modification of workflows, and execution of system-level operations. Any self-hosted or cloud n8n deployment running an affected version is exposed, with public scans indicating roughly 24,700 instances remain exposed on the internet. The flaw was added to CISA's Known Exploited Vulnerabilities catalog on 2026-03-11, EPSS places the 30-day exploitation probability at 99.1% (100th percentile), and Akamai has documented a ZeroBot malware campaign targeting n8n instances.

Do: Upgrade immediately to n8n 1.120.4, 1.121.1, or 1.122.0 (or later), as the flaw is in CISA KEV and actively exploited by the ZeroBot malware campaign documented by Akamai. If immediate upgrade is not possible, restrict workflow creation and editing permissions to fully trusted users and run n8n in a hardened environment with restricted OS privileges and network access, keeping in mind these mitigations do not fully eliminate the risk. Review instances for signs of compromise, including unexpected workflow changes and suspicious process activity, and apply BOD 22-01 requirements if the product is used in federal cloud services.

8.899% KEV PoC
  • n8n 0.211.0 and later, prior to 1.120.4, 1.121.1, and 1.122.0 (fixed in 1.120.4, 1.121.1, and 1.122.0)
large≈24,700 internet-exposed n8n instances (public internet scan counts cited in exploit reporting)
CVE-2026-21858
Unauthenticated RCE in n8n Workflow Automation (Ni8mare)

n8n versions 1.65.0 through below 1.121.0 contain an input-validation flaw (CWE-20) in the handling of certain form-based workflows, allowing an unauthenticated remote attacker to reach the underlying server through form endpoints. By triggering a vulnerable form workflow, the attacker can access files on the host and expose sensitive information stored there; the Cyera research team (which named the bug "Ni8mare") and the CVSS 10.0 score with high integrity impact indicate this yields unauthenticated remote code execution and potential full takeover. Any self-hosted n8n instance running an affected version that exposes form-based workflows over the network is at risk, with blast radius amplified by n8n's typical access to credentials, secrets, and connected internal systems. The issue is fixed in version 1.121.0; the flaw is not yet in CISA's KEV, but a public proof-of-concept is available and EPSS assigns a 78.4% probability of exploitation within 30 days, so defenders should treat exploitation as likely and imminent.

Do: Upgrade n8n to version 1.121.0 or later immediately. If you cannot upgrade right away, check whether any workflows use form triggers and remove those form endpoints from untrusted network exposure — place them behind authentication, a reverse proxy, or an IP allowlist. Review instance logs for unexpected requests to form/webhook paths and unusual file access, given the high EPSS score and public proof-of-concept.

10.078% PoC ×2
  • n8n >= 1.65.0 and < 1.121.0 (fixed in 1.121.0)
large≈50,000–100,000 internet-exposed n8n servers (self-hosted automation platform, affected range spans roughly a year of releases)
Full article597 words · extracted from securityaffairs.com · click to collapse

A critical n8n flaw (CVE-2026-21858, CVSS 10.0), dubbed Ni8mare, allows unauthenticated attackers to fully take over vulnerable instances.

Researchers uncovered a maximum severity n8n vulnerability, tracked as CVE-2026-21858 (CVSS score of 10.0). The flaw, dubbed Ni8mare by Cyera researchers who discovered the vulnerability, lets unauthenticated attackers fully compromise affected instances.

n8n is a workflow automation platform designed for technical teams that combines the flexibility of custom code with the speed and simplicity of no-code tools. It supports more than 400 integrations, includes native AI features, and uses a fair-code license, allowing organizations to build powerful automations while retaining full control over their data and deployment environments.

The flaw in n8n workflows can let unauthenticated attackers access server files, exposing sensitive data and potentially leading to further system compromise.

“A vulnerability in n8n allows an attacker to access files on the underlying server through execution of certain form-based workflows. A vulnerable workflow could grant access to an unauthenticated remote attacker. This could result in exposure of sensitive information stored on the system and may enable further compromise depending on deployment configuration and workflow usage.” reads the advisory.

The vulnerability affects all versions of n8n prior to and including 1.65.0, and it was fixed in n8n version 1.121.0 in November 2025.

The issue stems from how n8n Webhooks handle uploaded data. Webhooks start workflows and parse incoming requests based on the Content-Type header. If the request is multipart/form-data, n8n uses a file upload parser (Formidable) that safely stores uploaded files in temporary locations and populates req.body.files. For other content types, a regular parser is used, which directly fills req.body with user-supplied data.

The vulnerability arises because some file-handling workflows do not verify the Content-Type before processing files. In the Form Webhook node, a file-handling function is called without checking that the request is actually multipart/form-data. This allows an attacker to send a request with a different Content-Type (e.g., JSON) and manually define req.body.files.

By doing this, the attacker can control file paths used by the workflow and trick n8n into copying any local system file instead of a legitimate upload. These files can then be processed by downstream nodes and exposed, for example through a chat or knowledge-base workflow.

In practice, this enables arbitrary file read attacks, such as retrieving /etc/passwd, potentially exposing sensitive system data and enabling further compromise.

The vulnerability enables escalation from arbitrary file read to full RCE in n8n. n8n stores auth sessions in an n8n-auth cookie, built from user data (ID, partial password hash) and signed with a local secret key. With arbitrary file read, an attacker can extract the local SQLite database (containing user records) and the config file holding the signing secret. Using these, they can forge a valid admin session cookie and bypass authentication. Once logged in as admin, the attacker can create a workflow using the “Execute Command” node, achieving remote code execution on the n8n instance.

“The blast radius of a compromised n8n is massive.” concludes the report. “A compromised n8n instance doesn’t just mean losing one system –  it means handing attackers the keys to everything. API credentials, OAuth tokens, database connections, cloud storage – all centralized in one place. n8n becomes a single point of failure and a goldmine for threat actors.”

In December, researchers warned that another critical vulnerability, tracked as CVE-2025-68613 (CVSS score of 9.9), in the n8n workflow automation platform could allow attackers to achieve arbitrary code execution under certain circumstances.

Follow me on Twitter: @securityaffairs and Facebook and Mastodon

Pierluigi Paganini

(SecurityAffairs – hacking, CVE-2026-21858)



Text extracted automatically; images, tables and formatting may be missing. Original: https://securityaffairs.com/186648/security/ni8mare-flaw-gives-unauthenticated-control-of-n8n-instances.html