Skip to content

CVE-2024-11958 SQL Injection in run-llama/llama_index

CriticalCVSS 9.8 EPSS 1.4%
Published
Updated
Exploit status
No public exploit known
CISA SSVC
Proof of concept public · automatable: yes · technical impact: total

Description

A SQL injection vulnerability exists in the duckdb_retriever component of the run-llama/llama_index repository, specifically in the latest version. The vulnerability arises from the construction of SQL queries without using prepared statements, allowing an attacker to inject arbitrary SQL code. This can lead to remote code execution (RCE) by installing the shellfs extension and executing malicious commands.

Upgrade path

3 packages: 3 fixed.

PackageAffectedFixed inStatus
llamaindex < 0.4.0 0.4.0 Fixed
pypi llama-index-retrievers-duckdb-retriever(PyPI) < 0.4.0; = 0.1.4; = 0.2.0; = 0.3.0 0.4.0 Fixed
run-llama/llama_index < 0.4.0 0.4.0 Fixed

Affected products

ProductAffected versionsFixed in
pypi llama-index-retrievers-duckdb-retriever(PyPI) < 0.4.0 0.4.0
pypi llama-index-retrievers-duckdb-retriever(PyPI) = 0.1.4 No fix listed
pypi llama-index-retrievers-duckdb-retriever(PyPI) = 0.2.0 No fix listed
pypi llama-index-retrievers-duckdb-retriever(PyPI) = 0.3.0 No fix listed
run-llama/llama_index < 0.4.0 0.4.0
llamaindex < 0.4.0 0.4.0

References