Incident report
LlamaIndex RunGptLLM Command Injection via Unvalidated Model Arguments
CVE-2024-4181 affected the `RunGptLLM` wrapper integration in LlamaIndex (`<= 0.9.47`), where model arguments were passed unsafely into system execution contexts. Untrusted configuration or prompt-derived arguments could inject shell metacharacters, triggering arbitrary OS command execution on hosts running the connector. The flaw illustrated how third-party model adapters often skip basic command neutralization when shelling out to local binaries. Maintainers patched argument handling and advised auditing connector wrappers for `subprocess` shells.
Incident record
- Reported
- Severity
- High
- Vector
- Tool/MCP Abuse
- Affected system type
- LLM Wrapper & Local Execution Integrations
- Reference
CVE-2024-4181- Reference URI
https://nvd.nist.gov/vuln/detail/CVE-2024-4181
Defensive lesson
Audit third-party LLM model adapters for shell=True invocations and validate model parameters strictly before invoking subprocesses.
Referenced techniques
- Supply Chain Compromise: Software AML.T0010.001
- Command and Scripting Interpreter AML.T0050
- AI Agent Tool Invocation AML.T0053