CVE-2024-30254 Directory traversal allowing overwriting arbitrary files
An attacker can overwrite arbitrary files by tricking a victim into running the MesonLSP language server on a crafted project or with specific flags.
- Exploited in the wild
- Not known
- Login needed
- Not needed
- Attackable
- Local or same network only
- Victim action needed
- A user has to click or open something
- Fix
- None listed
What is CVE-2024-30254?
CVE-2024-30254 is a medium-severity path traversal vulnerability in JCWasmx86 mesonlsp, published on 4 Apr 2024. It can only be exploited from the same machine or local network, and only if a user opens a file or follows a link.
Official description
MesonLSP is an unofficial, unendorsed language server for meson written in C++. A vulnerability in versions prior to 4.1.4 allows overwriting arbitrary files if the attacker can make the victim either run the language server within a specific crafted project or `mesonlsp --full`. Version 4.1.4 contains a patch for this issue. As a workaround, avoid running `mesonlsp --full` and set the language server option `others.neverDownloadAutomatically` to `true`.
Weakness: CWE-22
Which versions are affected by CVE-2024-30254?
How do I fix CVE-2024-30254?
No fix has been published for CVE-2024-30254 yet. Limit exposure of the affected software until one is available.
Upgrade, and resolve every user-supplied path against an allowed base folder before opening it. More about Path traversal.
Is CVE-2024-30254 being exploited?
It is not confirmed as exploited in the wild, but public exploit code for CVE-2024-30254 exists.
Sources
Also known as GHSA-48c5-35fh-846h.