NewApp Monitoring is liveSign up free
AgentbeamBeta
AI agent vulnerability · Langflow

CVE-2024-48061: Langflow vulnerable to remote code execution

mediumCVSS 4.0 6.9 · 3.1 9.8GHSA-5p5r-57fx-pmfr

Langflow 1.0.18 and earlier runs code-capable components directly on the host with no sandbox, so anyone who can build or run a flow can execute code on the Langflow server. The advisory data lists no patched version. Treat any exposed Langflow instance as able to give an attacker a shell.

Published Nov 5, 2024 · Updated Nov 6, 2024 · Analysis Nov 1, 2026

What an attacker can do

Langflow components can carry Python code, and the server runs that code on the local machine instead of in a sandbox. Anyone who can create or edit a flow, or send code to the endpoints that run it, gets code execution as the Langflow process user.

The researcher's gist, by Aftersnow and HRP, gives only this high-level description and no endpoint or proof of concept. The linked GitHub issue 696 is an older report about the api/v1/validate/code endpoint. It says the endpoint calls exec on function definitions, so an eval placed in a default parameter runs during validation. In that thread the maintainer said sandboxing was out of reach for the project, and the stale bot closed the issue in September 2023 with no fix. That issue is a related reference, not proof of this CVE's exact path.

The CVSS 3.1 vector (9.8) shows network access with no privileges or interaction. The CVSS 4.0 score of 6.9 is lower. A Langflow server often holds API keys for model providers and vector databases, so a compromise exposes those secrets and any network the host can reach.

Who is affected

langflow on pip, version 1.0.18 and earlier. Any instance reachable by users you do not fully trust is at risk, especially one with authentication off. Check the version:

pip show langflow

For containers, check the image tag.

langflow

Ecosystem
PyPI
Affected
<= 1.0.18
Fixed in
No patched version yet
Check
pip show langflow

How to fix it

The package data lists no patched version, and the sources read name none. Check the Langflow releases and security advisories for a current fixed release before upgrading. Until then, do not expose Langflow to the internet or to untrusted users. Put it behind authentication and a private network, run it as an unprivileged user in a container with no access to production secrets, and keep API keys out of its environment where you can.

How to tell if you were hit

Look at the Langflow host for child processes started by the Langflow Python process, such as shells, curl or package installers. Review request logs for calls to the code validation and flow run endpoints from unexpected clients, and for flows or components with code you did not write. Check for new files, cron entries and outbound connections from the Langflow user. If an AI agent can drive Langflow, Beam records the agent's shell commands and MCP tool calls.

Original advisory

From the GitHub Advisory Database (CC BY 4.0).

langflow <=1.0.18 is vulnerable to Remote Code Execution (RCE) as any component provided the code functionality and the components run on the local machine rather than in a sandbox.

Questions

Is there a patched Langflow version for CVE-2024-48061?

None is listed in the advisory data. The affected range is 1.0.18 and earlier. Check Langflow's releases for the current state before relying on any version.

Why does the CVSS 4.0 score differ from the 3.1 score?

The 3.1 vector gives 9.8 with high impact on the vulnerable system. The 4.0 vector scores 6.9 and puts the impact on subsequent systems. Both show network access with no privileges.

Is it exploited in the wild?

None of the sources read say so, and it is not in the CISA KEV catalog.

References

How this page is made: the data panel comes from the GitHub Advisory Database, CISA’s KEV catalog, the NVD and FIRST EPSS, and updates twice a day. The analysis is written by an AI model from the sources listed above and checked by automated rules before it is published. Check versions against the vendor's advisory before you act. Methodology

More Langflow vulnerabilities

All Langflow entries