Vulnerability · Published Jan 2, 2024 · Assigned by redhat
CVE-2023-47039Perl: perl for windows binary hijacking vulnerability
High 7.8
In plain English
A high-severity heap buffer overflow in perl. There are no confirmed reports of exploitation so far. The chance it is exploited in the next 30 days is estimated at 0.4% (higher than 36% of all known vulnerabilities).
Official description
A vulnerability was found in Perl. This security issue occurs while Perl for Windows relies on the system path environment variable to find the shell (`cmd.exe`). When running an executable that uses the Windows Perl interpreter, Perl attempts to find and execute `cmd.exe` within the operating system. However, due to path search order issues, Perl initially looks for cmd.exe in the current working directory. This flaw allows an attacker with limited privileges to place`cmd.exe` in locations with weak permissions, such as `C:\ProgramData`. By doing so, arbitrary code can be executed when an administrator attempts to use this executable from these compromised locations.
Affected packages & fixed versions
| Ecosystem | Package | Fixed in | Advisory |
|---|---|---|---|
| Ubuntu:22.04:LTS | perl | no fix listed | UBUNTU-CVE-2023-47039 |
Affected products (as reported)
| Vendor | Product | Versions |
|---|---|---|
| perl | 0 – before 5.34.35.36.0 – before 5.36.35.38.0 – before 5.38.2 | |
| Red Hat | Red Hat Enterprise Linux 6 | see references |
| Red Hat | Red Hat Enterprise Linux 7 | see references |
| Red Hat | Red Hat Enterprise Linux 8 | see references |
| Red Hat | Red Hat Enterprise Linux 8 | see references |
| Red Hat | Red Hat Enterprise Linux 8 | see references |
| Red Hat | Red Hat Enterprise Linux 9 | see references |
Weakness: CWE-122 · Vector: CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
References
- https://access.redhat.com/security/cve/CVE-2023-47039 vdb-entry, x_refsource_REDHAT
- https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1056746
- RHBZ#2249525 issue-tracking, x_refsource_REDHAT
- https://security.netapp.com/advisory/ntap-20240208-0005/ x_transferred
- https://perldoc.perl.org/perl5382delta#CVE-2023-47039-Perl-for-Windows-binary-hijacking-vulnerability x_transferred