Vulnerabilities

CVE-2025-6209

High 7.5 CVSS 3.0

Description

A path traversal vulnerability exists in run-llama/llama_index versions 0.12.27 through 0.12.40, specifically within the `encode_image` function in `generic_utils.py`. This vulnerability allows an attacker to manipulate the `image_path` input to read arbitrary files on the server, including sensitive system files. The issue arises due to improper validation or sanitization of the file path, enabling path traversal sequences to access files outside the intended directory. The vulnerability is fixed in version 0.12.41.

Description as published by the source, in English.

Key facts

Published
2025-07-07
Last modified
2026-06-17
Assigned by
security@huntr.dev
CVSS vector
CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N
Scored by
security@huntr.dev
Probability of exploitation
0.5 % higher than 43 % of all known vulnerabilities
EPSS, next 30 days, model v2026.06.15
Fix available
Yes, see references

Affected products

Vendor Product Versions Status
llama-index-core (PyPI) ≥ 0.11.23, < 0.12.41 Affected
Llamaindex Llamaindex ≥ 0.12.27, < 0.12.41 Affected

Weakness type

  • CWE-29: Path Traversal: '\..\filename'

    The product uses external input to construct a pathname that should be within a restricted directory, but it does not properly neutralize '\..\filename' (leading backslash dot dot) sequences that can resolve to a locati…

References

Does this affect you?

A vulnerability matters only if you run the product, in an affected version, somewhere an attacker can reach.

Check your asset list Browse all vulnerabilities