CVE-2023-47039

Perl: perl for windows binary hijacking vulnerability

Published Jan 2, 2024 CVSS 3.1 · 7.8 High EPSS < 1% KEV · Not listed
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.

Analysis

No analysis available yet

Remediation

No remediation available yet

Tracking

Sign in to view the affected projects.

Advisories

Source ID Title
EUVD EUVD EUVD-2023-51194 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.
Weaknesses

Sources

Status
PUBLISHED
Assigner
redhat
Published
Updated
Nov 20, 2025, 5:57 PM
Reserved
Oct 30, 2023, 1:58 PM
Status
Modified
Published
Jan 2, 2024, 6:15 AM
Modified
Jun 17, 2026, 6:32 AM
Severity
Moderate
Public date
Nov 25, 2023, 12:00 AM