CVE-2026-7700High· 8.8▾ TwilightLangflow: Prompt injection in Langflow Smart Transform can lead to code execution
▾ Twilight zone — High severity, or a signal on a lesser flaw
impact 48.4 · likelihood 0.1 · exploitation 0
Need a working PoC? Pro members can cast a request and our team develops one — it lands right here.
Disclosure to exploitation, from the record and what we observed since indexing it.
Disclosed via GHSA
0.4%
Langflow versions 1.3.0 through 1.10.2 contain a code-injection vulnerability in the Smart Transform (LambdaFilterComponent) component.
Smart Transform places flow-author instructions and a preview of its input data into a prompt asking an LLM to generate a Python lambda. It then extracts a one-line lambda from the model response, applies only syntactic format checks, evaluates it with Python's full builtins, and invokes the resulting function inside the Langflow process.
A malicious flow author can exploit this directly through the Instructions field. In deployments where an exposed flow passes attacker-controlled content into Smart Transform, an attacker may also exploit it indirectly through prompt injection, subject to the configured model following the injected instruction.
Vulnerable Code Location: src/lfx/src/lfx/components/llm_operations/lambda_filter.py (line 242 in v1.10.2)
def _validate_lambda(self, lambda_text: str) -> bool:
"""Validate the provided lambda function text."""
return lambda_text.strip().startswith("lambda") and ":" in lambda_text
# ...
return eval(lambda_text) # noqa: S307
For example, an attacker can attempt to make the model return:
lambda x: __import__("os").system("id")
This expression satisfies the vulnerable format checks. eval() creates the lambda with access to Python's default builtins, and the subsequent fn(data) invocation (in _execute_lambda) executes the command.
Successful exploitation allows code execution with the privileges of the Langflow service process. This can expose or modify credentials, files, application data, and network resources accessible to that process, and may affect other tenants in shared deployments.
https://github.com/user-attachments/assets/13c48fe1-7225-4e0d-9687-2d2df1e87f0e
The reported path was addressed by validating the generated code's AST and evaluating it with a restricted builtins mapping.
The mainline fix is in PR #13530 (1641b28f) and shipped in Langflow 1.11.0. The 1.10.3 backport is in PR #14071 (94859df3). Users should upgrade to Langflow 1.10.3 or later.
Until an upgrade is possible:
langflow >= 1.3.0, < 1.10.3Upgrade to a patched release:
langflow 1.10.3Connected by shared product, vendor, weakness, or advisory.
GHSA-hhxr-7j22-694rLow· 6.3Duplicate Advisory: Prompt injection in Langflow Smart Transform can lead to code execution
CVE-2026-105741High· 7.1Langflow is a tool for building and deploying AI-powered agents and workflows
CVE-2026-51886High· 8.8langflow-ai langflow v1.9.3 is affected by: Code Injection
CVE-2026-48519Critical· 9.6Langflow: Unauthenticated RCE in Shareable Playgrounds
CVE-2026-105697Critical· 9.9Langflow is a tool for building and deploying AI-powered agents and workflows
CVE-2026-101861Medium· 4.1Langflow 1.0.16 before 1.12.0 and 0.0.94 before 1.12.0 contain an unsafe eval() vulnerability in schema.py that allows authenticated attackers to achieve code execution by placing a Python object with a malicious __repr__ method into com…