← All advisories
CVE-2024-3271criticalCode execution2024-04-16

CVE-2024-3271: llama-index-core Command Injection vulnerability

A command injection vulnerability exists in the run-llama/llama_index repository, specifically within the safe_eval function. Attackers can bypass the intended security mechanism, which checks for the presence of underscores in code generated by LLM, to execute arbitrary code.

01.

What it is

A command injection vulnerability exists in the run-llama/llama_index repository, specifically within the safe_eval function. Attackers can bypass the intended security mechanism, which checks for the presence of underscores in code generated by LLM, to execute arbitrary code. This is achieved by crafting input that does not contain an underscore but still results in the execution of OS commands. The vulnerability allows for remote code execution (RCE) on the server hosting the application.

02.

How to check

  1. Affected: llama-index-core (pip) < 0.10.24.
  2. Compare your installed version with the range above (command below).
03.

How to fix

  1. Upgrade llama-index-core to 0.10.24 or later.
pip show llama-index-core | grep Version
04.

Sources

More advisories for this tool
The weekly email

One email a week. Only what changed.

New advisories, CVEs and fixes for Lovable, Bolt, v0, Replit, Base44 and Cursor apps. No roundups of things you already read.