IBM Langflow OSS Remote Code Execution via Unsanitized User Input
First seen Jul 31, 2026 · Updated Jul 31, 2026 · CVSS 9.9
IBM Langflow OSS versions 1.0.0 through 1.10.0 contain a critical vulnerability allowing a remote, likely unauthenticated attacker to inject and execute arbitrary code due to improper handling of user-supplied input. Given the near-maximum CVSS score of 9.9, this represents a severe risk to any environment running affected Langflow instances, potentially exposing the underlying host, connected agent pipelines, and any credentials or tools accessible to the Langflow server.
Technical Analysis
Langflow is a visual builder for LLM/agent workflows that allows users to define custom components, often via embedded Python code blocks, flow configuration fields, or component parameters. The vulnerability stems from improper control of user input code, suggesting that input meant to configure a flow, node, or component is instead evaluated or executed without adequate sanitization, likely via patterns similar to eval(), exec(), pickle deserialization, or dynamic import of attacker-controlled code strings. Because Langflow orchestrates agent tool calls, chains, and connected credentials/API keys, code execution at this layer grants an attacker control over the full agent pipeline, including any downstream tools, MCP servers, or external APIs the flow is authorized to invoke. This crosses the boundary from a single malformed input field into full host compromise, enabling lateral movement to any secrets, environment variables, or connected agent infrastructure reachable from the Langflow server process.
Affected Systems
IBM Langflow OSS
Detection Signatures
- Monitor Langflow server logs for anomalous POST requests to flow/component configuration or code-execution endpoints containing unexpected Python syntax, base64-encoded payloads, or shell metacharacters.
- Alert on unexpected child processes spawned by the Langflow server process (e.g., /bin/sh, python -c, curl, wget invocations).
- Inspect flow definitions and custom component code fields for unauthorized modifications or injected imports (os, subprocess, socket, pickle).
- Watch for outbound network connections from the Langflow host to unfamiliar external IPs immediately following flow execution requests.
- Review access logs for unauthenticated or unusual-origin API calls to Langflow's flow-run or code-validation endpoints.
Remediation Steps
- 1
Patch Langflow immediately
Upgrade to a fixed Langflow release beyond 1.10.0 as soon as IBM publishes a patched version; track the official advisory for CVE-2026-12946.
- 2
Restrict network exposure
Do not expose Langflow instances directly to the public internet; place behind authentication, VPN, or a reverse proxy with strict access controls.
- 3
Sandbox execution environment
Run Langflow in an isolated container or VM with minimal privileges, no access to production secrets, and restricted outbound network access to limit blast radius of any code execution.
- 4
Disable or restrict custom code components
If feasible, disable user-defined Python code execution features or enforce strict allowlisting/sandboxing (e.g., restricted execution environments, seccomp, gVisor) for any component that evaluates user input as code.
- 5
Audit and rotate credentials
If the instance was exposed prior to patching, rotate all API keys, tokens, and credentials accessible to the Langflow server and audit logs for signs of exploitation.
- 6
Enable strict input validation
Apply strict schema validation and sanitization on all flow/component configuration fields to prevent injection of executable code or serialized objects.
CVE / Advisory IDs
Industries Most Exposed
Respond to this threat
Pro subscribers get a full AI-generated incident-response playbook for this threat — detection, containment, eradication, and recovery steps — plus an unlimited AI Threat Advisor for questions about your environment.