CVE-2026-103250: n8n: NoSQL injection in MongoDB Chat Memory node

HIGH
Published October 1, 2026
CISO Take

n8n's MongoDB Chat Memory node doesn't validate the sessionId parameter. An unauthenticated attacker can inject MongoDB query operators to read other users' conversation histories and to write or delete chat memory records. The CVSS is 8.1 (scope changed, high confidentiality impact), but the high attack complexity and the lack of a public exploit or Nuclei template keep near-term risk moderate. EPSS is 0.2%, which is the top 91% percentile, and the CVE is not in CISA KEV. Even so, the exposure is real for any internet-facing n8n workflow that passes a user-controlled value into sessionId. Upgrade to n8n 1.123.80, 2.39.6 or 2.40.1 depending on your branch. Until then, hardcode or sanitize sessionId and audit your MongoDB collections for tampered or missing chat memory.

Sources:NVDEPSSGitHub AdvisoryVulnCheckATLAS

What is the risk?

Rated high (CVSS 8.1) but not critical. The attack needs no authentication or user interaction and runs over the network. Its high complexity reflects that the attacker needs a workflow that exposes a user-controlled sessionId to the Chat Memory node. There is no known exploitation, no KEV listing, no public PoC and no scanner template. EPSS of 0.002 puts it in the top 91% percentile, so it deserves prioritized patching but not emergency response. The scope change means the impact goes beyond the vulnerable component to the data stored in MongoDB. Confidentiality impact is high, and integrity and availability impacts are low.

How does the attack unfold?

Initial Access
The attacker finds an n8n workflow exposed via a webhook or chat trigger that passes a user-controlled sessionId to the MongoDB Chat Memory node.
AML.T0049
Exploitation
The attacker sends a sessionId that contains MongoDB query operators, such as $ne or $regex, and bypasses the session filter in the NoSQL query.
AML.T0049
Collection
The query returns the conversation histories of other users, which expose prompts, responses and sensitive data.
AML.T0036
Impact
The attacker modifies or deletes memory records, which poisons the agent's context or destroys conversation data.
AML.T0080.000

What systems are affected?

PackageEcosystemVulnerable RangePatched
n8nnpm—No patch
210.5KOpenSSF 7.116 dependentsPushed 3d ago42% patched~19d to patchFull package profile →

Do you use n8n? You're affected.

How severe is it?

CVSS 3.1
8.1 / 10
EPSS
0.2%
chance of exploitation in 30 days
Higher than 10% of all CVEs
Exploitation Status
No known exploitation
Sophistication
Moderate

What is the attack surface?

AVACPRUISCIA
AVNetwork
ACHigh
PRNone
UINone
SChanged
CHigh
ILow
ALow

What should I do?

1 step
  1. 1) Upgrade n8n to 1.123.80, 2.39.6 or 2.40.1 or later, depending on your branch. 2) As a workaround, validate and cast sessionId to a plain string (for example, a UUID format check) before it reaches the memory node. Do not take it directly from user input. 3) Restrict access to public chat triggers and webhooks with authentication or network controls. 4) Use a MongoDB account with least privilege, scoped to the memory collection. 5) Detect abuse by checking n8n and MongoDB logs for sessionId values that contain operators or JSON objects ($ne, $gt, $regex, $where). 6) Review the memory collections for unexpected deletions or modifications. 7) Rotate any secrets that may have been exposed in chat histories.

What does CISA's SSVC say?

DecisionTrack
Exploitationnone
AutomatableNo
Technical Impactpartial

Source: CISA Vulnrichment (SSVC v2.0). Decision based on the CISA Coordinator decision tree.

How is it classified?

Which compliance frameworks are affected?

This CVE is relevant to:

EU AI Act
Art. 15-Accuracy, robustness and cybersecurity
ISO 42001
A.7.4-Quality of data for AI systems
NIST AI RMF
MANAGE 2.3-Respond to previously unknown risks
OWASP LLM Top 10
LLM02-Sensitive Information DisclosureLLM06-Excessive Agency

Frequently Asked Questions

What is CVE-2026-103250?

n8n's MongoDB Chat Memory node doesn't validate the sessionId parameter. An unauthenticated attacker can inject MongoDB query operators to read other users' conversation histories and to write or delete chat memory records. The CVSS is 8.1 (scope changed, high confidentiality impact), but the high attack complexity and the lack of a public exploit or Nuclei template keep near-term risk moderate. EPSS is 0.2%, which is the top 91% percentile, and the CVE is not in CISA KEV. Even so, the exposure is real for any internet-facing n8n workflow that passes a user-controlled value into sessionId. Upgrade to n8n 1.123.80, 2.39.6 or 2.40.1 depending on your branch. Until then, hardcode or sanitize sessionId and audit your MongoDB collections for tampered or missing chat memory.

Is CVE-2026-103250 actively exploited?

No confirmed active exploitation of CVE-2026-103250 has been reported, but organizations should still patch proactively.

How to fix CVE-2026-103250?

1) Upgrade n8n to 1.123.80, 2.39.6 or 2.40.1 or later, depending on your branch. 2) As a workaround, validate and cast sessionId to a plain string (for example, a UUID format check) before it reaches the memory node. Do not take it directly from user input. 3) Restrict access to public chat triggers and webhooks with authentication or network controls. 4) Use a MongoDB account with least privilege, scoped to the memory collection. 5) Detect abuse by checking n8n and MongoDB logs for sessionId values that contain operators or JSON objects ($ne, $gt, $regex, $where). 6) Review the memory collections for unexpected deletions or modifications. 7) Rotate any secrets that may have been exposed in chat histories.

What systems are affected by CVE-2026-103250?

This vulnerability affects the following AI/ML architecture patterns: Agent frameworks, Workflow automation, Conversational chatbots with persistent memory, LLM memory stores (MongoDB).

What is the CVSS score for CVE-2026-103250?

CVE-2026-103250 has a CVSS v3.1 base score of 8.1 (HIGH). The EPSS exploitation probability is 0.20%.

What is the AI security impact?

Affected AI Architectures

Agent frameworksWorkflow automationConversational chatbots with persistent memoryLLM memory stores (MongoDB)

MITRE ATLAS Techniques

AML.T0036Data from Information Repositories
AML.T0049Exploit Public-Facing Application
AML.T0080.000Memory
AML.T0092Manipulate User LLM Chat History
AML.T0101Data Destruction via AI Agent Tool Invocation

Compliance Controls Affected

EU AI Act: Art. 15
ISO 42001: A.7.4
NIST AI RMF: MANAGE 2.3
OWASP LLM Top 10: LLM02, LLM06

What are the technical details?

Original Advisory

n8n versions before 1.123.80, from 2.0.0 before 2.39.6, and from 2.40.0 before 2.40.1 contain a NoSQL injection vulnerability in the MongoDB Chat Memory node that fails to validate the sessionId parameter. Unauthenticated attackers can supply MongoDB query operators in the sessionId field to access conversation histories from other users and perform unauthorized write and delete operations.

Exploitation Scenario

A company runs a public support chatbot built on n8n, and the webhook passes the client-supplied sessionId to the MongoDB Chat Memory node. The attacker sends a request in which sessionId is a JSON object such as {"$ne":"x"} instead of a string. The query then matches the memory records of many sessions, and the agent returns or processes other customers' histories. The attacker repeats the technique to read sensitive data, then overwrites or deletes the records. This poisons the agent's future context or erases the audit trail of conversations.

Weaknesses (CWE)

CWE-943 — Improper Neutralization of Special Elements in Data Query Logic: The product generates a query intended to access or manipulate data in a data store such as a database, but it does not neutralize or incorrectly neutralizes special elements that can modify the intended logic of the query.

Source: MITRE CWE corpus.

CVSS Vector

CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:C/C:H/I:L/A:L

Timeline

Published
October 1, 2026
Last Modified
October 6, 2026
First Seen
October 1, 2026

Related Vulnerabilities