/Vulnerability Library

Langflow OSS <=1.12.2 - Unauthenticated RCE via Import Code Execution

CVE-2026-93674
Verified

Description

Langflow OSS 1.0.0 through 1.12.2 is vulnerable to unauthenticated remote code execution via the POST /api/v1/validate/code endpoint, which calls importlib.import_module() on user-supplied import statements, executing module top-level code instead of merely validating syntax. Combined with the default LANGFLOW_AUTO_LOGIN=true configuration (which issues a superuser JWT from GET /api/v1/auto_login with no credentials) and the custom_component exec() sink (POST /api/v1/custom_component, which can plant arbitrary Python modules into site-packages), a remote unauthenticated attacker achieves arbitrary OS command execution. Fixed in 1.12.3 by replacing importlib.import_module() with importlib.util.find_spec() (commit 461506ac2f).

Severity

Critical

CVSS Score

9.8

Exploit Probability

14%

Affected Product

langflow

Published Date

October 9, 2026

Template Author

dhiyaneshdk

CVE-2026-93674.yaml
9.8Score

CVSS Metrics

CVSS Vector:
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
CVE ID:
cve-2026-93674
CWE ID:
cwe-94

References

https://www.pruva.dev/reproductions/REPRO-2026-00381https://github.com/langflow-ai/langflowhttps://github.com/langflow-ai/langflow/commit/461506ac2f38f70a994b5140572b876448c11e4c

Remediation Steps

Upgrade to Langflow OSS 1.12.3 or later. As a temporary mitigation, set LANGFLOW_AUTO_LOGIN=false with strong superuser credentials and restrict network access to the Langflow instance.