Documented Incident · INC-2024-38459 · High severity

LangChain Experimental Package Exposing Python REPL Without Explicit Opt-In

CVE-2024-38459 highlighted insecure-by-default tool exposure in `langchain-experimental`, where the `PythonREPLTool` permitted arbitrary host Python execution without requiring an explicit developer opt-in flag. Applications instantiating experimental agent toolkits could expose full OS shell and filesystem capabilities to end-user prompts unintentionally. Prompt injection or direct user queries against the agent could execute arbitrary host scripts without sandboxing. Maintainers introduced mandatory explicit `allow_dangerous_code` opt-in gates and documentation warnings while advising strict container isolation.

Incident dossier metadata

Case ID
INC-2024-38459
Classification
Incident
Date
Severity
High
Sector
Software Development & AI Tooling
Attack vector
Tool/MCP Abuse
System type
Code-Interpreter & REPL-Equipped LLM Frameworks
CVE / reference
CVE-2024-38459
Reference URI
https://nvd.nist.gov/vuln/detail/CVE-2024-38459

Inspect INC-2024-38459 in Interactive Incidents & Cases Hub

Defensive takeaway

Default dangerous code-execution tools to disabled, require explicit opt-in flags, and execute interpreter tools strictly inside ephemeral network-disabled sandboxes.

Mapped AI security techniques

Mapped defensive controls

Source citation records