n8n Merge node SQL injection lets authenticated users read files and run code
What this means
An authenticated user who can create or change workflows can read any file on the n8n server and run arbitrary code on it. This can expose secrets, configuration files, and other sensitive data, and allow complete takeover of the n8n instance.
SecurityElites Manager Brief: the decision in one minute
n8n users with workflow editing permission can read server files and run code using the Merge node. You must upgrade to version 1.123.27, 2.13.3, or 2.14.1 or later immediately, or restrict editing permissions and disable the Merge node.
| SecurityElites Fix-First Score | 51 of 100 Our own ranking of what to fix first. Real attacks count most, then the chance of attack, then severity. |
|---|---|
| SecurityElites fix window | Within 7 days Critical severity. This is our suggestion from common practice; your own policy comes first. |
| Who should own the fix | Platform or infrastructure team responsible for n8n deployments. |
| Likely effort | About 15 minutes per n8n instance: check the current version, upgrade to the patched version, and restart. Complexity increases if you have many instances or custom configurations. |
Questions to ask your team or supplier
- Who in your organization can currently create or edit n8n workflows, and are all of them fully trusted?
- Do any of your existing workflows use the Merge node with Combine by SQL mode, and if so, what do they access?
Message you can forward to the owning team
Security notice: n8n Merge node SQL injection lets authenticated users read files and run code (CVE-2026-33660)
Severity: Critical
SecurityElites Fix-First Score: 51 of 100
SecurityElites fix window: Within 7 days
Action: upgrade to n8n 2.14.1 or later.
What we need from you: confirm whether we run this software, who owns it, and the date it will be fixed.
Full guide: https://securityelites.com/ai-vulnerabilities/cve-2026-33660-n8n-merge-node-sql-injection-lets-authenticated-users-read/
Source: SecurityElites AI Vulnerabilities Database, record SE-AIV-01722What is at stake in your AI setup
- API keys and credentials for external AI services that workflows connect to could be read from configuration files or memory.
- Prompts and instructions stored in workflow definitions or n8n database could be extracted.
- Chat history and user inputs from AI-powered workflows could be accessed.
- Training or fine-tuning data used by n8n integrations could be read from the host file system.
Who is exposed
- Teams running n8n 1.0 through 1.123.26 in any environment.
- Teams running n8n 2.0.0-rc.0 through 2.13.2 in any environment.
- Teams running n8n 2.14.0 in any environment.
- Any user with permission to create or edit workflows on an affected n8n instance.
Upgrades you need
| Software | Affected versions | Move to |
|---|---|---|
| n8n npm | 2.14.0 up to, but not including, 2.14.1; 2.0.0-rc.0 up to, but not including, 2.13.3; Every version before 1.123.27 | 2.14.1 or later |
Each maintained branch has its own fixed version. Stay on your branch if you cannot jump to the newest: n8n 1.123.27, 2.13.3, 2.14.1.
Am I affected?
Enter the version you run. Nothing you type is stored.
SecurityElites Developer Brief: the technical picture
| Is it being attacked | No known attacks and no public attack code when CISA last reviewed it |
|---|---|
| Where the attacker must be | Anywhere that can reach it over a network, including the internet if it is exposed |
| Account needed | An ordinary user account |
| Does a person have to do something | No. It works without anyone clicking or opening anything |
| How hard it is to do | Easy. It works reliably once the attacker can reach it |
| Risk of: data being read | High |
| Risk of: data or settings being changed | High |
| Risk of: the service being taken down | High |
| Can attackers automate it at scale | Yes, according to CISA |
| How much control an attacker gains | Total control of the affected software, according to CISA |
Read from the official severity rating: CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H
Kind of coding mistake
- CWE-89: database queries can be injected
- CWE-94: code can be injected
If you cannot upgrade today
- Restrict workflow creation and editing permissions to only fully trusted users until you can upgrade.
- Disable the Merge node by adding `n8n-nodes-base.merge` to the `NODES_EXCLUDE` environment variable and restart n8n. This blocks all use of the Merge node and prevents exploitation.
- These are temporary measures only and do not eliminate the vulnerability. Upgrade as soon as possible.
Signs it may already have been used against you
- Review audit logs for workflows created or edited by authenticated users, especially those with Merge nodes using SQL mode.
- Search server logs for SQL queries executed by the Merge node or AlaSQL that reference file I/O operations (e.g., LOAD DATA, INTO OUTFILE, or file system access patterns).
- Check process logs for unexpected child processes or shell commands spawned by the n8n service, which could indicate code execution.
- Look for access to sensitive files on the n8n host (such as /etc/passwd, .env files, or SSH keys) in file access logs if available.
Log searches to start from
Merge node SQL execution (adapt field names to your logs)Splunk
index=main source=n8n merge OR "Combine by SQL" OR AlaSQL | stats count by user, workflow_nameChild process spawned by n8n service (adapt process and parent fields to your logs)Elastic
process.parent.name:n8n AND process.name:* | aggregate _count by process.name, process.command_lineWritten with AI as a starting point. Review them and change the index and field names to match your own logs before you rely on the result.
SecurityElites Fix Guide: step by step
- Find all n8n instances in your environmentSearch your infrastructure for running n8n services. Check container registries, deployment tools, and configuration management systems to locate every n8n installation you operate.
- Check the current version of each n8n instanceLog in to the n8n web interface or query the instance. Look for the version number in the settings or about page, or use the API to retrieve the version. Document each version you find.
- Identify which instances need the upgradeCompare your current versions against the fixed versions: 1.123.27 or later, 2.13.3 or later, or 2.14.1 or later. Any version below these thresholds is vulnerable and must be patched.
- Review workflow editing permissions before upgradingList all users and service accounts that have permission to create or modify workflows. Note which of these are trusted and which may pose a risk. This helps you decide on additional controls after the upgrade.
- Upgrade to a patched versionFollow your n8n deployment method to upgrade. For npm installations, run the upgrade command for your package manager to reach 1.123.27, 2.13.3, or 2.14.1 or later. For container deployments, pull the patched image version and redeploy. For cloud-hosted n8n, check that your instance has been auto-updated.
- Restart the n8n service after upgradeStop the n8n process and start it again, or reload the container. Verify that the service comes up and is accessible to users.
- Confirm the patched version is now runningCheck the version number in the n8n interface or via the API again. Verify that it matches or exceeds the fixed version for your release line.
- Review access to workflows created during the vulnerable periodAudit which workflows were created or modified while the instance was vulnerable. Check whether any of them use the Merge node with Combine by SQL mode, and review who accessed them. If the Merge node was used, treat the server as potentially compromised and investigate for signs of unauthorized access.
How to confirm it is fixed: Log in to the n8n interface or query the API to confirm the installed version is 1.123.27 or later, 2.13.3 or later, or 2.14.1 or later.
SecurityElites Quick Fixes: copy and paste
Upgrade n8n with npmupgrade
npm install n8n@2.14.1
npm ls n8nCheck n8n version via npmfor this issue
npm list n8nDisable Merge node as temporary mitigation (set environment variable)for this issue
export NODES_EXCLUDE=n8n-nodes-base.mergePass values as parameters (Python)general hardening
cur.execute("SELECT * FROM items WHERE id = %s", (item_id,))Test in a non-production environment first. General hardening examples use placeholder names and ports; change them to match your setup.
Let your AI coding assistant do the upgrade
Paste this into the coding assistant you already use, inside the project. It checks first and asks before it changes anything.
Instruction for your coding assistant
You are helping me fix a security vulnerability (CVE-2026-33660) in this project.\n\n1. Search the whole repository, including lock files, container files and CI configuration, for these packages and list every place they are pinned or installed:\n - n8n (npm): must be 2.14.1 or later
2. Tell me which version we use now and whether it is affected. Stop and ask me before changing anything.
3. After I agree, raise each one to the safe version, update the lock files, and keep every other dependency as it is.
4. Run the tests and tell me what failed.
5. Give me a short summary of the files you changed that I can put in the pull request.SecurityElites Incident Drill: could your team handle this?
Four questions to ask in your next team meeting. If any has no clear answer, that is the gap to close.
Ticket for your backlog
Paste into Jira, GitHub Issues or any tracker that reads Markdown.
Ready-made ticket
## n8n Merge node SQL injection lets authenticated users read files and run code (CVE-2026-33660)
**Severity:** Critical | **SE Fix-First Score:** 51/100 | **Fix window:** Within 7 days
**Record:** SE-AIV-01722 https://securityelites.com/ai-vulnerabilities/cve-2026-33660-n8n-merge-node-sql-injection-lets-authenticated-users-read/
### Why this matters
An authenticated user who can create or change workflows can read any file on the n8n server and run arbitrary code on it. This can expose secrets, configuration files, and other sensitive data, and allow complete takeover of the n8n instance.
### What to do
1. Find all n8n instances in your environment
2. Check the current version of each n8n instance
3. Identify which instances need the upgrade
4. Review workflow editing permissions before upgrading
5. Upgrade to a patched version
6. Restart the n8n service after upgrade
7. Confirm the patched version is now running
8. Review access to workflows created during the vulnerable period
Full steps: https://securityelites.com/ai-vulnerabilities/cve-2026-33660-n8n-merge-node-sql-injection-lets-authenticated-users-read/
### Done when
- [ ] n8n is at 2.14.1 or later everywhere it is installed
- [ ] Lock files, container images and CI configuration are updated
- [ ] Log in to the n8n interface or query the API to confirm the installed version is 1.123.27 or later, 2.13.3 or later, or 2.14.1 or later.
- [ ] Logs were checked for signs of earlier use
SecurityElites Fix Tracker
Record who owns this fix, the date it is due and when it is done, and see everything still open in one list. Free with a SecurityElites account.
Related vulnerabilities
In the same software
- n8n legacy expression engine allows code execution via JSON.stringify override High · CVE-2026-86083
- n8n OpenAI node bypasses domain restrictions on model search High · CVE-2026-86082
- n8n Git node can freeze the instance with a crafted path High · CVE-2026-86081
- n8n OAuth registration accepts unlimited field sizes, filling the database High · CVE-2026-86075
- n8n expression compiler can run arbitrary code through class field names High · CVE-2026-86076
- n8n Edit Fields node can crash the whole instance with a bad field name High · CVE-2026-72749
The same kind of mistake in other AI tools
- n8n Source Control can inject SQL through malicious Data Table files High · CVE-2026-44792
- Flowise GraphCypherQAChain forwards user input directly to Neo4j without filtering High · CVE-2026-41274
- n8n Data Table Get node allows SQL injection in authenticated workflows High · CVE-2026-33713
- n8n Merge node allows authenticated users to run code and write files Critical · CVE-2026-27497
- Flowise can run harmful database commands when importing chatflow files High · CVE-2025-71332
Change history
- 25 Mar 2026: Made public
- 2 Dec 2026: Published
Official record
## Impact An authenticated user with permission to create or modify workflows could use the Merge node's "Combine by SQL" mode to read local files on the n8n host and achieve remote code execution. The AlaSQL sandbox did not sufficiently restrict certain SQL statements, allowing an attacker to access sensitive files on the server or even compromise the intance.## Patches The issue has been fixed in n8n versions 2.14.1, 2.13.3, and 1.123.27. 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 Merge node by adding `n8n-nodes-base.merge` to the `NODES_EXCLUDE` environment variable.These workarounds do not fully remediate the risk and should only be used as short-term mitigation measures.
Weakness type: CWE-89, CWE-94
Use this record in your own tools
Get this record as JSON
curl https://securityelites.com/wp-json/se-aivd/v1/vulns/CVE-2026-33660For scanners and pipelines: OSV format · CycloneDX format · API guide · Email alerts · Fix tracker
The plain-language sections were written with AI from the official record, and the upgrade versions come directly from the official data. Last updated 2 Dec 2026. Read the vendor advisory before changing a production system.