Langflow unauthenticated code execution used to dump server environment variables
Attackers ran code on Langflow servers and dumped their environment secrets.
Are you affected?
The free scanner that answers this opens soon. Until then, the steps below work by hand.
What happened
Langflow flaw let attackers dump server secrets. CVE-2025-3248 lets a remote, unauthenticated attacker run arbitrary code through the /api/v1/validate/code endpoint of Langflow before 1.3.0. Horizon3.ai, which reported it on 2025-02-22, showed that the env command returns the Langflow superuser's username and password when authentication is enabled. CISA added the flaw to its Known Exploited Vulnerabilities catalog on 2025-05-05. Trend Micro reports a campaign that exploited it to install the Flodrix botnet, and lists printenv among the payloads attackers sent, noting that the environment can reveal API keys, cloud credentials and database connection strings.
- Exposure starts
- Not known yet (no source gives the first in-the-wild exploitation)
- Exposure ends
- Not known yet (exposure ends when each server is upgraded and its secrets rotated)
- Confidence
- low
- Scope
- every environment variable and credential readable by an internet-reachable Langflow server older than 1.3.0, including the Langflow superuser password and the API keys its flows use
What to do, in this order
- Upgrade Langflow to 1.3.0 or later and restrict public access to its endpoints
Trend Micro and Horizon3.ai give 1.3.0 as the fix; rotating on a still-exposed server hands the new secrets to the next attacker.
- Change the Langflow superuser password
Horizon3.ai showed the env command returns the superuser username and password when authentication is enabled.
anything else stored there
- Rotate every API key, cloud credential and database connection string in the Langflow server's environment
Advisory inference. Trend Micro saw attackers send printenv and says it can reveal these secrets; no source confirms which were taken or tells users to rotate them.
anything else stored there
Notes
- Langflow 1.3.0 was released on 2025-03-31 (Horizon3.ai). OSV lists the PyPI advisories PYSEC-2025-36 and GHSA-rvqx-wpfh-mfx7 for the langflow package.
- Trend Micro also recommends restricting public access to Langflow endpoints and monitoring for Flodrix indicators.
How to tell if you’re affected
- Python package langflow below 1.3.0
- Requests to /api/v1/validate/code from unknown sources
- Downloader scripts named docker or deez, the binary e1x.x86_64 or /tmp/e1x, and a hidden .system_idle file
- Connections to 80.66.75.121 (port 25565), 45.61.137.226, 206.71.149.179 or 188.166.68.21
Sources
- NVD CVE-2025-3248
- GitHub advisory GHSA-rvqx-wpfh-mfx7: Langflow unauthenticated RCE
- Horizon3.ai: Unsafe at any speed, abusing Python exec for unauth RCE in Langflow AI
- Trend Micro: Langflow vulnerability exploited to deliver the Flodrix botnet
Rotating the keys
Pro, $49 a year when it opens, plans the rotation of each affected key for this incident, in this order. Automatic rotation is in testing and included.
By hand, free: the steps above.