Advisory

PYSEC-2026-397

Also known as: CVE-2024-3098, GHSA-wvpx-g427-q9wc

Summary

llama-index-core Prompt Injection vulnerability leading to Arbitrary Code Execution

Details

A vulnerability was identified in the exec_utils class of the llama_index package, specifically within the safe_eval function, allowing for prompt injection leading to arbitrary code execution. This issue arises due to insufficient validation of input, which can be exploited to bypass method restrictions and execute unauthorized code. The vulnerability is a bypass of the previously addressed CVE-2023-39662, demonstrated through a proof of concept that creates a file on the system by exploiting the flaw.

Severity

Critical Basis: CVSS v3 score 9.8, vector CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H

Dates

Published
2026-06-29 11:50 UTC
Modified
2026-07-01 20:22 UTC

Affected packages and fixes

llama-index-core

PyPI · All systems

Affected

  • introduced 0, fixed 0.10.24 (ecosystem)

Fixed versions

0.10.24

Fix

  • Fixed version 0.10.24
    pip install --upgrade llama-index-core==0.10.24

Fix commands are the export's own generic commands. Ojuju never runs them. Check them against your setup first.

Check your own computer: guard packages check

View this record on OSV.dev

Source

Source: PyPA Advisory Database · CC BY 4.0

Sources & licences