Skip to main content

n8n CVE-2026-59257

| EUVDEUVD-2026-42269 MEDIUM
SQL Injection (CWE-89)
2026-07-08 disclosure@vulncheck.com GHSA-2qp2-6frj-p9pq GHSA-hwmj-qg4v-cvg9
5.3
CVSS 4.0 · Vendor: vulncheck
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Identify n8n instance with public Webhook endpoint
  2. Delivery
    Send crafted HTTP request with SQL injection payload
  3. Exploit
    n8n evaluates {{ ... }} expression and interpolates payload into raw SQL
  4. Execution
    MySQL v1 node executes injected SQL with configured credential privileges
  5. Impact
    Exfiltrate or modify connected database contents

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization Parameterized queries, prepared statements
MITRE ATT&CK

2 techniques across 2 tactics: Initial Access, Persistence

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Exploitation requires all three of the following conditions simultaneously: (1) the target workflow must use the legacy MySQL v1 node's executeQuery operation specifically - the MySQL v2 node is not affected; (2) the SQL query in that node must incorporate one or more {{ ... }} expression values that are populated from workflow trigger input (e.g., request body fields from a Webhook node); and (3) the workflow trigger must be externally reachable by the attacker, most commonly a Webhook node exposed to the internet or an untrusted network. Exploitation is further limited by the AT:P metric, confirming these configuration prerequisites must be in place at the target. The PR:L metric in the provided CVSS 4.0 vector suggests some form of access may be required, such as a Webhook authentication token, though n8n supports unauthenticated Webhooks - teams relying on unauthenticated endpoints face a higher practical risk. The MySQL v2 node, static SQL queries without expressions, and workflows not connected to external triggers are all outside the vulnerable attack surface.

Impact

The CVSS 4.0 score of 5.3 reflects a notable risk profile: AV:N and AC:L confirm network reachability and low complexity, but AT:P captures the essential prerequisite - the target workflow must explicitly use the MySQL v1 node with expression-interpolated values and be reachable via an external trigger. The PR:L metric in the provided vector suggests some level of privilege (such as a valid webhook token or n8n user session) may be required; however, n8n Webhook nodes can be configured without authentication, which would reduce the effective barrier. The subsequent-system impact is SC:H and SI:H, indicating that the MySQL database connected to the workflow faces full confidentiality and integrity compromise with the configured credentials' privileges. No EPSS score was provided in the input data, and there is no KEV listing nor identified public proof-of-concept, suggesting exploitation has not been widely observed. Despite the moderate overall score, the downstream database impact is severe and real-world risk is elevated for organizations running n8n with public-facing, authentication-free Webhook endpoints connected to MySQL v1 workflows.

Exploit ScenarioDerived

An attacker identifies an n8n instance with a publicly accessible Webhook endpoint connected to a workflow that uses the MySQL v1 node's executeQuery operation with expression-sourced input. The attacker sends a crafted HTTP POST request to the Webhook URL with a SQL injection payload embedded in the expected request body field; n8n evaluates the {{ ... }} expression and substitutes the malicious payload directly into the SQL string, causing the MySQL server to execute attacker-supplied SQL with the configured credentials' privileges. The attacker can then exfiltrate all accessible database tables, modify or delete records, or - depending on credential privileges - execute stacked queries to further compromise the database server.

This Month Plan within 30 days. Why: MEDIUM severity (CVSS 4.0-6.9).
Patch available 0.3% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Jul 08, 2026

SQL injection in n8n's legacy MySQL v1 node (executeQuery operation) exposes the connected MySQL database to arbitrary query execution when workflow expressions interpolate attacker-controlled input without parameterization. Versions before 1.123.61 (1.x branch), 2.27.4 (2.x branch), and 2.28.1 (2.28.x branch) are affected when workflows combine the MySQL v1 node with externally-reachable triggers such as a Webhook node. No public exploit or CISA KEV listing is identified at time of analysis; however, deployments exposing such workflows to untrusted networks face high-severity database confidentiality and integrity risk.

RemediationAI

Upgrade n8n to version 1.123.61 or later (1.x branch), 2.27.4 or later (2.x branch), or 2.28.1 or later (2.28.x branch) as confirmed by the vendor advisory at https://github.com/n8n-io/n8n/security/advisories/GHSA-hwmj-qg4v-cvg9. As a direct workaround, migrate all executeQuery operations from the MySQL v1 node to the MySQL v2 node, which uses parameterized queries and is not affected; this is the safest and most operationally sustainable remediation short of patching. If immediate patching or migration is not feasible, restrict access to Webhook trigger endpoints by enabling n8n's built-in webhook authentication or placing a reverse proxy with authentication in front of the instance, eliminating the external attacker-controlled input path; note this adds operational overhead for legitimate callers. As a last resort, disable or suspend any workflows that combine an externally-facing Webhook node with a MySQL v1 executeQuery node until the patch can be applied.

Affected VersionsENISA

n8n 0 <2.28.1
n8n 0 <2.27.4
n8n 0 <1.123.61

Affected Packages

npm n8n fix: 1.123.61, 2.27.4, 2.28.1

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in npm

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

n8n is an open-source workflow automation platform allowing users to chain triggers (e.g., Webhook nodes) with backend integrations (e.g., MySQL nodes) via a visual editor. The vulnerable component is the legacy MySQL v1 node's executeQuery operation, which uses n8n's {{ ... }} template expression syntax to substitute runtime values directly into a raw SQL string before execution - a classic string-concatenation anti-pattern that bypasses any form of query parameterization. CWE-89 (Improper Neutralization of Special Elements in an SQL Command) precisely identifies the root cause: user-controlled data flows into an SQL interpreter without sanitization or binding. The MySQL v2 node, which uses prepared statements with parameterized queries, is explicitly not affected. The CVSS 4.0 vector's AT:P (Attack Requirements: Present) metric confirms that exploitation requires a specific, non-default workflow configuration to be in place.

Know when N8n gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (vulncheck) PRIMARY 5.3 MEDIUM
CVSS:4.0/AV:N/AC:L/AT:P/PR:L/UI:N/VC:N/VI:N/VA:N/SC:H/SI:H/SA:N
vuln.today AI 8.9 HIGH

AC:H reflects the required workflow configuration prerequisites (AT:P equivalent); scope change to MySQL database drives SC:H/SI:H; PR:N because externally-reachable Webhook requires no attacker credentials.

3.1 AV:N/AC:H/PR:N/UI:N/S:C/C:H/I:H/A:L
4.0 AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:N/VA:N/SC:H/SI:H/SA:L

Primary rating from Vendor (vulncheck).

CVSS VectorVendor: vulncheck

Attack Vector
Network
Attack Complexity
Low
Attack Requirements
Present
Privileges Required
Low
User Interaction
None
Vulnerable system: Confidentiality
None
Vulnerable system: Integrity
None
Vulnerable system: Availability
None
Subsequent system: Confidentiality
High
Subsequent system: Integrity
High
Subsequent system: Availability
None

Lifecycle Timeline

1
Patch available
Jul 08, 2026 - 15:01 EUVD

DescriptionCVE.org

n8n before 1.123.61, 2.x before 2.27.4, and 2.28.x before 2.28.1 contains a SQL injection vulnerability in the legacy MySQL v1 node's executeQuery operation. The operation substitutes evaluated {{ ... }} expression values directly into the raw SQL string without parameterization. When a workflow uses this operation with expression-sourced values and is connected to an externally-reachable trigger (such as a Webhook node), attacker-controlled input reaching those expressions results in SQL injection, allowing execution of arbitrary SQL with the configured MySQL credentials' privileges. The MySQL v2 node, which uses parameterized queries, is not affected.

Threat Intelligence Overview

EPSS Score
0.3%
Top 77% exploitable
Prevalence
Medium
popular self-hosted open-source workflow automation platform, developer-focused
Threat Intel
1
1 source
Data Quality
6 sources
Confidence: High
EUVD NVD CVE.org EPSS Vulnrichment GHSA GitHub VulDB

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity MEDIUM
CISA KEV No
Public POC No
EPSS 0.3%
Patch available Yes
Active threat No
Deciding rule
MEDIUM severity (CVSS 4.0-6.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Scheduled
Exploitation
None
System Exposure· derived
Open
Automatable
No
Human Impact· derived
Medium
Technical Impact
Total

Priority Score

26
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +26
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

SQL injection exploits the way applications construct database queries by mixing user input directly into SQL statements.

More in N8n

View all
CVE-2025-68613 HIGH POC
8.8 Dec 19

Remote code execution in n8n's workflow expression evaluation system allows an authenticated user with workflow creation

CVE-2026-21877 CRITICAL POC
9.9 Jan 08

n8n workflow automation (through 1.121.2) allows authenticated users to execute arbitrary code via the n8n service, with

CVE-2026-21858 CRITICAL POC
10.0 Jan 08

n8n workflow automation (1.65.0 to 1.121.0) allows unauthenticated file access through form-based workflows. A critical

CVE-2026-1470 CRITICAL POC
9.9 Jan 27

n8n has a fifth critical RCE vulnerability (CVSS 9.9) in the Expression evaluator, enabling code execution through craft

CVE-2025-65964 CRITICAL POC
9.4 Dec 09

Authenticated users who can create or modify an n8n workflow can achieve remote code execution on the n8n host by abusin

CVE-2026-33696 CRITICAL POC
9.4 Mar 25

A prototype pollution vulnerability in the XML and GSuiteAdmin nodes of n8n workflow automation platform allows authenti

CVE-2026-33660 CRITICAL POC
9.4 Mar 25

An authenticated user with workflow creation or modification privileges in n8n workflow automation platform can exploit

CVE-2025-55526 CRITICAL POC
9.1 Aug 26

n8n-workflows Main Commit ee25413 allows attackers to execute a directory traversal via the download_workflow function w

CVE-2026-27493 CRITICAL POC
9.0 Feb 25

Second-order expression injection in n8n workflow automation before 2.10.1/2.9.3/1.123.22. Crafted workflow data trigger

CVE-2025-56265 HIGH POC
8.8 Sep 08

An arbitrary file upload vulnerability in the Chat Trigger component of N8N v1.95.3, v1.100.1, and v1.101.1 allows attac

CVE-2026-33665 HIGH POC
8.8 Mar 25

Authenticated n8n users can hijack administrator accounts when LDAP authentication is enabled by manipulating their LDAP

CVE-2023-27563 HIGH POC
8.8 May 10

The n8n package 0.218.0 for Node.js allows Escalation of Privileges. Rated high severity (CVSS 8.8), this vulnerability

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy