Vulnerability  ·  2026-06-20

Langflow Path Traversal to Unauthenticated RCE — Active Exploitation Against 7,000+ Instances

VulnerabilityHigh impactGlobalCVE-2026-5027
Langflow's file-upload handler accepted filenames like '../../app.py' and wrote files to arbitrary locations. This allowed unauthenticated attackers to write Python files into the application directory and execute them. A fix was available in February 2026, but many instances remained unpatched. By June 2026, active exploitation was confirmed across thousands of instances.
Langflow instances hold API keys for OpenAI, Anthropic, and other LLM providers, plus database credentials and customer data. RCE on a Langflow instance gives attackers access to the entire RAG/agent pipeline, including vector databases, model credentials, and customer-facing agents.
The file-upload endpoint fails to sanitize the 'filename' parameter in multipart form data. An attacker can use path traversal sequences (../) to write arbitrary files to locations outside the intended upload directory, including Python files in the application directory. By uploading a .py file with malicious code and then accessing it via the HTTP server, the attacker achieves RCE.
Langflow 1.8.4 and earlier; the POST /api/v2/files file-upload endpoint
Upgrade Langflow to a version after 1.8.4. Implement strict input validation and restrict file write locations. Apply WAF rules to block path traversal payloads.
Sources
CSO Online: Langflow RCE Under Active AttackBleeping Computer: Langflow Path Traversal VulnerabilityVentureBeat: 7,000 Langflow Servers Under Attack
See this in the live feed Explore related AI security and governance findings — updated every morning.
Open the feed →