CVE-2024-4315 LFI Vulnerability due to Lack of Path Sanitization in parisneo/lollms
Attackers can exploit insufficient path sanitization to read or delete arbitrary files on Windows systems via directory traversal.
- Exploited in the wild
- Not known
- Login needed
- Not needed
- Attackable
- Over the internet
- Victim action needed
- Not needed
- Fix
- Available
What is CVE-2024-4315?
CVE-2024-4315 is a critical path traversal vulnerability in parisneo/lollms, published on 12 Jun 2024. An attacker can exploit it over the internet without logging in, with no action from the victim.
Official description
parisneo/lollms version 9.5 is vulnerable to Local File Inclusion (LFI) attacks due to insufficient path sanitization. The `sanitize_path_from_endpoint` function fails to properly sanitize Windows-style paths (backward slash `\`), allowing attackers to perform directory traversal attacks on Windows systems. This vulnerability can be exploited through various routes, including `personalities` and `/del_preset`, to read or delete any file on the Windows filesystem, compromising the system's availability.
Weakness: CWE-22
Which versions are affected by CVE-2024-4315?
3 open source packages ship an affected version, including lollms.
| Package | Affected | Fixed in |
|---|---|---|
lollms PyPI | All versions | 9.5.0 |
lollms PyPI | All versions | 9.5.0 |
lollms PyPI | All versions | 9.5.0 |
How do I fix CVE-2024-4315?
Upgrade lollms to 9.5.0 or later.
Upgrade, and resolve every user-supplied path against an allowed base folder before opening it. More about Path traversal.
Is CVE-2024-4315 being exploited?
It is not confirmed as exploited in the wild, but public exploit code for CVE-2024-4315 exists.
Sources
Also known as GHSA-vqwr-q6cc-c242, PYSEC-2026-403.