# CVE-2024-6971: Path Traversal in parisneo/lollms-webui

> Attackers can exploit path traversal to vectorize SQLite files in arbitrary directories, potentially causing crashes or unauthorized data access.

- **Severity:** Low 3.4 (`CVSS:3.0/AV:L/AC:L/PR:H/UI:N/S:U/C:N/I:L/A:L`)
- **Exploited in the wild:** Not known
- **Login needed:** An administrator
- **Attackable:** Local or same network only
- **Victim action needed:** Not needed
- **Fix available:** No
- **Published:** 11 Oct 2024
- **Updated:** 11 Oct 2024
- **Also known as:** GHSA-7pgr-32fx-c6x9, PYSEC-2026-1585

## What is CVE-2024-6971?

CVE-2024-6971 is a low-severity path traversal vulnerability in parisneo/lollms, published on 11 Oct 2024. It can only be exploited from the same machine or local network, with no action from the victim.

### Official description

A path traversal vulnerability exists in the parisneo/lollms-webui repository, specifically in the `lollms_file_system.py` file. The functions `add_rag_database`, `toggle_mount_rag_database`, and `vectorize_folder` do not implement security measures such as `sanitize_path_from_endpoint` or `sanitize_path`. This allows an attacker to perform vectorize operations on `.sqlite` files in any directory on the victim's computer, potentially installing multiple packages and causing a crash.

Weakness: CWE-22 (Improper Limitation of a Pathname to a Restricted Directory)

## Which versions are affected by CVE-2024-6971?

3 open source packages ship an affected version, including lollms. It affects 1 product.


| Package | Ecosystem | Affected | Fixed in |
| --- | --- | --- | --- |
| `lollms` | PyPI | All versions to 9.5.1 | None |
| `lollms` | PyPI | All versions to 9.5.1 | None |
| `lollms` | PyPI | All versions to 9.5.1 | None |

Products: Lollms Lollms-Webui.

## How do I fix CVE-2024-6971?

No fix has been published for CVE-2024-6971 yet. Limit exposure of the affected software until one is available.

## Is CVE-2024-6971 being exploited?

It is not confirmed as exploited in the wild, but public exploit code for CVE-2024-6971 exists.

## Other vulnerabilities in parisneo/lollms

- [CVE-2024-4267](https://insights.sbomify.com/CVE-2024-4267/): Remote Code Execution in parisneo/lollms-webui (high 8.4)
- [CVE-2024-1646](https://insights.sbomify.com/CVE-2024-1646/): Authentication Bypass in parisneo/lollms-webui (high 8.2)
- [CVE-2024-1601](https://insights.sbomify.com/CVE-2024-1601/): SQL Injection in parisneo/lollms-webui (high 7.5)
- [CVE-2024-5125](https://insights.sbomify.com/CVE-2024-5125/): XSS and Open Redirect via SVG File Upload in parisneo/lollms-webui (high 7.3)
- [CVE-2024-1569](https://insights.sbomify.com/CVE-2024-1569/): Uncontrolled Resource Consumption in parisneo/lollms-webui (medium 5.3)

## Fix prompt for AI coding agents

```text
Check this codebase for CVE-2024-6971 and fix it if it is affected.

What it is: CVE-2024-6971 is a low-severity path traversal vulnerability in parisneo/lollms, published on 11 Oct 2024. It can only be exploited from the same machine or local network, with no action from the victim.
Exploitation: It is not confirmed as exploited in the wild, but public exploit code for CVE-2024-6971 exists.

Affected packages and fixed versions:
- lollms (PyPI): affected all versions up to 9.5.1; no fix listed
- lollms (PyPI): affected all versions up to 9.5.1; no fix listed
- lollms (PyPI): affected all versions up to 9.5.1; no fix listed

Task:
1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.
2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.
3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.
4. Run the tests and summarise what changed and why.
5. If nothing in the project is affected, say so and change nothing.

Reference: https://insights.sbomify.com/CVE-2024-6971/ (Markdown: https://insights.sbomify.com/CVE-2024-6971/index.md)
```

## Sources

- CVE record: https://www.cve.org/CVERecord?id=CVE-2024-6971
- NVD: https://nvd.nist.gov/vuln/detail/CVE-2024-6971
- OSV: https://osv.dev/vulnerability/CVE-2024-6971

---
From sbomify Insights: https://insights.sbomify.com/CVE-2024-6971/
Summaries are generated and may contain mistakes; the official description above is the record.
