CVE-2024-28247 Pihole Authenticated Arbitrary File Read with root privileges

High 7.6 Published Updated

Authenticated attackers can read arbitrary server files as root by exploiting local file update logic in Pi-hole.

Exploited in the wild
Not known
Login needed
Any signed-in user
Attackable
Over the internet
Victim action needed
Not needed
Fix
None listed

What is CVE-2024-28247?

CVE-2024-28247 is a high-severity path traversal vulnerability in pi-hole, published on 27 Mar 2024. Any signed-in user can exploit it over the network, with no action from the victim.

Official description

The Pi-hole is a DNS sinkhole that protects your devices from unwanted content without installing any client-side software. A vulnerability has been discovered in Pihole that allows an authenticated user on the platform to read internal server files arbitrarily, and because the application runs from behind, reading files is done as a privileged user.If the URL that is in the list of "Adslists" begins with "file*" it is understood that it is updating from a local file, on the other hand if it does not begin with "file*" depending on the state of the response it does one thing or another. The problem resides in the update through local files. When updating from a file which contains non-domain lines, 5 of the non-domain lines are printed on the screen, so if you provide it with any file on the server which contains non-domain lines it will print them on the screen. This vulnerability is fixed by 5.18.

Weakness: CWE-269, CWE-200

Which versions are affected by CVE-2024-28247?

It affects 1 product.

Products include Pi-Hole Pi-Hole.

How do I fix CVE-2024-28247?

No fix has been published for CVE-2024-28247 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-28247 being exploited?

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

Public exploit code: 1 proofs of concept on GitHub.

Sources

Also known as GHSA-95g6-7q26-mp9x.

Is CVE-2024-28247 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free