CVE-2026-33309: Langflow Arbitrary File Write Vulnerability Leading to RCE
Summary
CVE-2026-33309: Langflow has an Arbitrary File Write (RCE) via v2 API. Affects langflow versions >= 1.2.0, < 1.9.0. Fixed in 1.9.0. How to fix ↓
Check if this vulnerability affects your application
Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.
No signup required · Results in about 60 seconds
Background
Langflow is an open-source framework designed for building and managing machine learning workflows. It provides a user-friendly interface for users to upload files, manage data, and execute various tasks related to machine learning. However, a critical vulnerability has been identified in its file upload mechanism, which could allow unauthorized file access and execution on the host system.
Vulnerability Detail
The vulnerability arises from a failure in the architectural design of the LocalStorageService within Langflow. Specifically, the API endpoint for file uploads does not adequately sanitize the filename extracted from the multipart Content-Disposition header. This oversight allows authenticated users to perform directory traversal attacks, enabling them to write files outside the intended storage directory. The lack of containment checks in the storage layer further exacerbates the issue, leading to potential Remote Code Execution (RCE) as attackers can overwrite critical system files.
How To Fix
Latest published version: 1.14.0.dev2 as of 22 Oct 2026
pip install --upgrade "langflow==1.14.0.dev2"
Upgrading to it may include breaking changes; the version below is the minimum fixed release for this vulnerability.
If you need the minimum change
1.9.0
This is the first release that contains the fix.
pip install --upgrade "langflow==1.9.0"
Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →
Workaround
As a temporary workaround, developers can add a containment check in the LocalStorageService to prevent unauthorized file writes. Here’s an example of how to implement this check:
from pathlib import Path
def save_file(folder_path, file_name):
base_dir = Path('/app/data/.cache/langflow')
file_path = base_dir / file_name
if not file_path.resolve().is_relative_to(base_dir):
raise ValueError("Invalid file path")
# Proceed with saving the file
Conclusion
The CVE-2026-33309 vulnerability in Langflow poses a significant risk due to its potential for arbitrary file writes and Remote Code Execution. It is crucial for users to update to the latest version and implement recommended fixes to safeguard their systems.
See every vulnerability recorded for langflow →
FAQ
CVE-2026-33309 is a critical vulnerability in Langflow that allows authenticated users to perform arbitrary file writes, potentially leading to Remote Code Execution.
You can use Vulert's playground at Vulert Scanner to check if your application is affected by this vulnerability without needing to sign up.
The CVSS score for this vulnerability is 9.9, indicating a critical level of severity.
You can update Langflow to version 1.9.0 or later using pip: pip install --upgrade langflow.
An attacker could overwrite critical system files, inject malicious components, or gain full control over the host server through Remote Code Execution.
References
Related vulnerabilities
Recent vulnerabilities recorded for langflow.