llama-index-core Prompt Injection vulnerability leading to Arbitrary Code Execution
CVE-2024-3098 · GHSA-wvpx-g427-q9wc · PYSEC-2026-397 · published 10 Apr 2024
How serious is it
- Severity: critical, CVSS score 9.8 out of 10.
- No exploit prediction (EPSS) score yet.
- Not on the CISA list of exploited vulnerabilities.
- No public exploit in Exploit-DB.
Is your app affected by CVE-2024-3098?
Paste this prompt into Claude Code, Cursor or any AI coding tool: it runs a free Shippable scan of your project and fixes what it finds. Built with Lovable, Bolt or v0? Scan your live app. Or upload your package file.
Who is affected
llama-index-core(PyPI) < 0.10.24
How to check
- Run
pip show llama-index-corein your project to see the installed version, including copies pulled in by other packages. - Or paste your lockfile into the checker: it lists every package with a known vulnerability, this one included.
- Or run
npx shippable-dev scan localhost:3000in your project folder. It reads your lockfile and flags this vulnerability along with every other known one.
How to fix
Copies a prompt for Claude Code, Cursor or Codex: it checks your lockfiles for this and upgrades it.
- Upgrade
llama-index-coreto 0.10.24 or later, commit the lockfile and redeploy. - If a vulnerable version was live, check your logs and rotate the secrets that server could read.
The advisory
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.
Check your whole app
Dependencies are only half of it. Free and read-only: before you push, run npx shippable-dev scan localhost:3000 in your project folder, no account needed. For your live app, you prove it's yours with a one-line tag first.
References
- nvd.nist.gov/vuln/detail/CVE-2024-3098
- github.com/run-llama/llama_index/commit/5fbcb5a8b9f20f81b791c7fc8849e352613ab475
- huntr.com/bounties/1bce0d61-ad03-4b22-bc32-8f99f92974e7
- github.com/run-llama/llama_index/commit/2c92e88838a5f481d50840240b1dd3180066c6f5
- github.com/pypa/advisory-database/tree/main/vulns/llama-index-core/PYSEC-2026-397.yaml
- pypi.org/project/llama-index-core
- github.com/advisories/GHSA-wvpx-g427-q9wc
- github.com/run-llama/llama_index
Merged from GitHub Advisory Database, OSV. Last updated 28 Oct 2026. All vulnerabilities · RSS · JSON