Skip to main content

CVE-2025-3046: CWE-22 Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal') in run-llama run-llama/llama_index

High
VulnerabilityCVE-2025-3046cvecve-2025-3046cwe-22
Published: Mon Jul 07 2025 (07/07/2025, 09:54:50 UTC)
Source: CVE Database V5
Vendor/Project: run-llama
Product: run-llama/llama_index

Description

A vulnerability in the `ObsidianReader` class of the run-llama/llama_index repository, versions 0.12.23 to 0.12.28, allows for arbitrary file read through symbolic links. The `ObsidianReader` fails to resolve symlinks to their real paths and does not validate whether the resolved paths lie within the intended directory. This flaw enables attackers to place symlinks pointing to files outside the vault directory, which are then processed as valid Markdown files, potentially exposing sensitive information.

AI-Powered Analysis

AILast updated: 07/07/2025, 10:25:44 UTC

Technical Analysis

CVE-2025-3046 is a high-severity path traversal vulnerability (CWE-22) affecting the `ObsidianReader` class in the run-llama/llama_index repository, specifically versions 0.12.23 to 0.12.28. The vulnerability arises because the ObsidianReader fails to properly resolve symbolic links to their canonical paths and does not verify whether these resolved paths remain within the intended vault directory. Attackers can exploit this flaw by creating symbolic links inside the vault directory that point to arbitrary files elsewhere on the filesystem. When the ObsidianReader processes these symlinks as valid Markdown files, it inadvertently exposes the contents of files outside the vault, potentially including sensitive system or user data. The vulnerability requires no authentication or user interaction and can be exploited remotely if an attacker can place or influence symlinks within the vault directory. The CVSS 3.0 score of 7.5 reflects the network attack vector, low complexity, no privileges required, no user interaction, and a high impact on confidentiality, with no impact on integrity or availability. No known exploits are currently reported in the wild, but the vulnerability poses a significant risk to confidentiality due to arbitrary file read capabilities. The lack of patch links suggests that a fix may not yet be publicly available or is pending release.

Potential Impact

For European organizations using run-llama/llama_index versions 0.12.23 to 0.12.28, this vulnerability could lead to unauthorized disclosure of sensitive information stored on affected systems. This includes internal documents, configuration files, credentials, or personally identifiable information (PII) that may reside outside the vault directory but accessible via symlink exploitation. Such data breaches could violate GDPR and other data protection regulations, leading to legal penalties and reputational damage. The exposure of sensitive internal files could also facilitate further attacks, such as lateral movement or privilege escalation within the organization’s network. Since the vulnerability does not affect integrity or availability, the primary concern is confidentiality loss. European organizations in sectors with high data sensitivity—such as finance, healthcare, government, and critical infrastructure—are particularly at risk. Additionally, organizations using this library in cloud or containerized environments may face increased exposure if directory permissions are misconfigured, allowing attackers to plant malicious symlinks.

Mitigation Recommendations

1. Immediate mitigation involves upgrading to a fixed version of run-llama/llama_index once available. Until then, organizations should audit and restrict write permissions to the vault directory to trusted users only, preventing unauthorized creation of symbolic links. 2. Implement filesystem monitoring to detect creation of unexpected symlinks within the vault directory. 3. Employ application-level input validation to ensure that any file paths resolved by ObsidianReader are canonicalized and strictly confined within the vault directory boundaries before processing. 4. Use container or OS-level sandboxing to limit the file system scope accessible to the application, reducing the impact of potential exploitation. 5. Conduct regular security reviews and penetration testing focused on path traversal and symlink attacks in environments using this library. 6. If possible, configure the application to run with least privilege, restricting its access to only necessary directories and files. 7. Monitor security advisories from run-llama and related repositories for patches or updates addressing this vulnerability.

Need more detailed analysis?Get Pro

Technical Details

Data Version
5.1
Assigner Short Name
@huntr_ai
Date Reserved
2025-03-31T12:36:26.873Z
Cvss Version
3.0
State
PUBLISHED

Threat ID: 686b9cd16f40f0eb72e2e231

Added to database: 7/7/2025, 10:09:21 AM

Last enriched: 7/7/2025, 10:25:44 AM

Last updated: 8/3/2025, 12:37:28 AM

Views: 12

Actions

PRO

Updates to AI analysis are available only with a Pro account. Contact root@offseq.com for access.

Please log in to the Console to use AI analysis features.

Need enhanced features?

Contact root@offseq.com for Pro access with improved analysis and higher rate limits.

Latest Threats