# Critical n8n Sandbox Escape Allows Workflow Editors to Execute OS Commands

High-severity vulnerability enables authenticated users to run arbitrary commands on the host server.

- **Source:** [The Hacker News](https://brifing.si/source/f944ec2b-8180-47bc-94de-57085b5a6563)
- **Published:** 2026-07-27
- **Topic:** [Software & Engineering](https://brifing.si/c/engineering)
- **Original article:** <https://thehackernews.com/2026/07/n8n-sandbox-escape-lets-workflow.html>
- **On Brifing:** https://brifing.si/s/8d49eeea-61f7-4d88-a492-28fa96cb4c5e

## Vulnerability Essence

An expression sandbox escape in n8n's workflow editor allows authenticated users to execute operating-system commands on the server. The flaw affects versions 2.31.5 and 2.32.0-2.32.1, tracked as GHSA-gv7g-jm28-cr3m with a high-severity CVSS score of 8.7. Successful exploitation grants privileges equal to the n8n process.

## Discovery Process

Security Joes researchers identified the flaw while investigating potential bypasses for CVE-2026-27577 patched in February. They found uncontrolled ArrowFunctionExpression handling combined with Reflect.get() exploitation allowed access to Node.js globals. The PoC was successfully tested against version 2.30.4.

## Technical Breakdown

The vulnerability stems from two gaps: ArrowFunctionExpression being placed in a no-op branch in VariablePolyfill.ts, and insufficient filtering of Reflect.get() arguments. This let attackers load child_process module to execute host commands. Neither condition alone was sufficient for exploitation.

## Impact Scope

Successful exploitation could expose N8N_ENCRYPTION_KEY, decrypt stored credentials, and access connected databases/internal services. While no active exploitation was observed, the flaw poses critical risks to deployments storing privileged credentials. n8n Cloud's affected status remains unconfirmed.

## Remediation Steps

n8n patched the issue in versions 2.31.5 and 2.32.1 by adding dedicated ArrowFunctionExpression handlers and strengthening data context routing. Administrators must update immediately rather than relying on interim access controls. Suspicious workflow modifications should be investigated for malicious JavaScript.

## Industry Implications

This marks n8n's third sandbox escape since 2025, highlighting the security challenges in low-code automation platforms. The incident underscores the need for rigorous sandbox testing, especially when platforms handle sensitive credentials. Security teams should monitor for child processes spawned from n8n/Node.js.

## Sources covering this story

- https://thehackernews.com/2026/07/n8n-sandbox-escape-lets-workflow.html — 

---

_Summary written by Brifing from the original reporting. Copyright in the original article belongs to its publisher; read the full piece at the link above._
