CVE-2023-7216 Cpio: extraction allows symlinks which enables remote command execution
A path traversal flaw in Cpio allows attackers to write files to arbitrary directories via symlinks, potentially leading to remote code execution.
- 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-2023-7216?
CVE-2023-7216 is a medium-severity path traversal vulnerability in Redhat Enterprise Linux, published on 5 Feb 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
A path traversal vulnerability was found in the CPIO utility. This issue could allow a remote unauthenticated attacker to trick a user into opening a specially crafted archive. During the extraction process, the archiver could follow symlinks outside of the intended directory, which allows files to be written in arbitrary directories through symlinks.
Which versions are affected by CVE-2023-7216?
It affects 2 products.
Products include Gnu Cpio, Redhat Enterprise Linux.
How do I fix CVE-2023-7216?
No fix has been published for CVE-2023-7216 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-2023-7216 being exploited?
It is not confirmed as exploited in the wild, but public exploit code for CVE-2023-7216 exists.
Other vulnerabilities in Redhat Enterprise Linux
Sources
Also known as GHSA-v9vx-4mxw-76j2, UBUNTU-CVE-2023-7216.