CVE-2026-33751

GHSA-w83q-mcmx-mh42 MEDIUM

n8n: LDAP injection enables auth bypass in workflows

Published March 25, 2026
CISO Take

If your organization uses n8n to build AI agent workflows that accept external user input and route it through LDAP authentication nodes, you are exposed to authentication bypass and unauthorized LDAP data retrieval. Exploitation requires a specific workflow configuration (LDAP node + user-controlled expressions), but this pattern is common in enterprise identity-integrated automation. Upgrade to n8n 1.123.27, 2.13.3, or 2.14.1 immediately; if you cannot patch, disable the LDAP node via NODES_EXCLUDE environment variable.

Affected Systems

Package Ecosystem Vulnerable Range Patched
n8n npm < 1.123.27 1.123.27

Do you use n8n? You're affected.

Severity & Risk

CVSS 3.1
4.8 / 10
EPSS
0.1%
chance of exploitation in 30 days
KEV Status
Not in KEV
Sophistication
Moderate

Recommended Action

  1. 1. PATCH: Upgrade to n8n 1.123.27 (v1 branch), 2.13.3, or 2.14.1 immediately. These versions fix the filter escape logic in the LDAP node. 2. DISABLE (if patching is not immediate): Set environment variable NODES_EXCLUDE=n8n-nodes-base.ldap to prevent LDAP node execution. 3. RESTRICT: Limit workflow creation/editing to fully trusted users — prevent untrusted users from introducing LDAP nodes with unvalidated expressions. 4. SANITIZE INPUT: Audit existing workflows using the LDAP node; ensure any external input passed via expressions is validated or allow-listed before interpolation into LDAP filters. 5. DETECT: Review n8n workflow logs for anomalous LDAP filter patterns containing metacharacters (*, (, ), \, NUL). Alert on LDAP queries returning unusually large result sets. 6. AUDIT: Inventory all n8n workflows using the LDAP node and map which accept external input via webhooks, forms, or HTTP triggers.

Classification

Compliance Impact

This CVE is relevant to:

EU AI Act
Article 15 - Accuracy, robustness and cybersecurity
ISO 42001
A.9.3 - Security of AI system inputs
NIST AI RMF
MANAGE 2.2 - Mechanisms are in place to recognize and respond to risks from AI system dependencies
OWASP LLM Top 10
LLM06 - Excessive Agency

Technical Details

NVD Description

n8n is an open source workflow automation platform. Prior to versions 1.123.27, 2.13.3, and 2.14.1, a flaw in the LDAP node's filter escape logic allowed LDAP metacharacters to pass through unescaped when user-controlled input was interpolated into LDAP search filters. In workflows where external user input is passed via expressions into the LDAP node's search parameters, an attacker could manipulate the constructed filter to retrieve unintended LDAP records or bypass authentication checks implemented in the workflow. Exploitation requires a specific workflow configuration. The LDAP node must be used with user-controlled input passed via expressions (e.g., from a form or webhook). The issue has been fixed in n8n versions 1.123.27, 2.13.3, and 2.14.1. Users should upgrade to one of these versions or later to remediate the vulnerability. 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 LDAP node by adding `n8n-nodes-base.ldap` to the `NODES_EXCLUDE` environment variable, and/or avoid passing unvalidated external user input into LDAP node search parameters via expressions. These workarounds do not fully remediate the risk and should only be used as short-term mitigation measures.

Exploitation Scenario

An adversary targets an organization using n8n to power an AI agent that authenticates users against Active Directory before granting access to sensitive workflows. The n8n instance exposes a webhook endpoint that accepts a username parameter, which is interpolated via an expression into an LDAP search filter: (&(objectClass=user)(sAMAccountName={{$json.username}})). The attacker submits username=*)(|(objectClass=* — injecting LDAP metacharacters that transform the filter into (&(objectClass=user)(sAMAccountName=*)(|(objectClass=*)) — effectively matching all LDAP objects and bypassing the intended user-specific lookup. Depending on workflow logic, this returns the first LDAP result (often an admin account), allowing authentication bypass. Alternatively, the attacker submits username=*)(memberOf=CN=Domain Admins,DC=corp,DC=local)(* to enumerate domain admin accounts, harvesting organizational structure without credentials.

CVSS Vector

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

Timeline

Published
March 25, 2026
Last Modified
March 27, 2026
First Seen
March 25, 2026