Skip to content
DoS Disclosed report Beginner CVE-2025-6208

llama-index-core vulnerable to Uncontrolled Resource Consumption

The SimpleDirectoryReader component in llama_index.core applied the user-specified file limit only after loading all files in a directory into memory. An attacker could cause memory exhaustion and degraded performance by pointing it at a directory with many files.

run-llama/llama_index

Originally disclosed on huntr

The SimpleDirectoryReader component in llama_index.core version 0.12.23 suffers from uncontrolled memory consumption due to a resource management flaw. The vulnerability arises because the user-specified file limit (num_files_limit) is applied after all files in a directory are loaded into memory. This can lead to memory exhaustion and degraded performance, particularly in environments with limited resources. The issue is resolved in version 0.12.41.

From the GitHub Advisory Database (GHSA-488g-hw5f-x29p, CC BY 4.0).

The original report as published on the GitHub Advisory Database. Images and videos are our own copies; raw HTML is shown as text. View it on GitHub Advisory Database.

Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.

How it worked

Impact

This could lead to memory exhaustion and degraded performance, particularly in environments with limited resources.

What the attacker needed

Ability to control the directory path; directory contains many files

The fix

The issue was fixed in version 0.12.41.

Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.

Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.

A program that reads files from a folder was supposed to stop after a certain number, but it actually read every file first and only then applied the limit. If a folder had a huge number of files, the program could run out of memory and slow down or crash.

What is DoS?

A request that exhausts resources or crashes a component. Many programs forbid testing it; reports usually show it from code, not by attacking.

More from run-llama/llama_index

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Denial of service

The lesson behind this report.

A request that exhausts resources or crashes a component. Many programs forbid testing it; reports usually show it from code, not by attacking.