search menu icon-carat-right cmu-wordmark

CERT Coordination Center

PrestaShop Performance Debug Configuration Contains a PHP Code Injection Vulnerability

Vulnerability Note VU#385711

Original Release Date: 2026-11-09 | Last Revised: 2026-11-09

Overview

PrestaShop's back-office Performance > Debug mode functionality contains a PHP code injection vulnerability. An authenticated attacker with permission to modify debug-mode configuration can submit crafted cookie configuration values that are written into an executable PHP configuration file. Successful exploitation could allow arbitrary code execution with the privileges of the PHP process.

Description

PrestaShop is an open-source e-commerce platform for creating and managing online stores. Its back-office Performance configuration includes a Debug mode for developers, which is enabled based on a specified cookie name and value.

PrestaShop's debug-mode configuration code inserts the user-controlled values debug_cookie_name and debug_cookie_value into a PHP expression without adequately escaping or sanitizing them for use in PHP source code. The application writes this expression into the PHP define() statement in config/defines.inc.php or config/defines_custom.inc.php. A crafted value can terminate the intended string and introduce attacker-controlled PHP statements. The modified configuration file is loaded during application initialization, causing the injected code to execute on a subsequent request.

Exploitation requires an authenticated back-office account with permission to modify debug mode settings and a configuration file writable by the PHP process. Root or operating-system administrator privileges are not required. Cross-site request forgery (CSRF) protection helps prevent unauthorized requests made through another user's session, but does not prevent exploitation by an attacker controlling an account with the required permissions. Injected code executes with the privileges of the PHP process. Affected release versions remain to be confirmed.

Impact

An authenticated attacker with the required configuration permissions could execute arbitrary PHP code in the security context of the PHP process. This could allow access to application secrets and customer data, modification or deletion of application files and database contents, and disruption of store operations. Operating-system command execution depends on the PHP configuration and available functions. The vulnerability does not independently grant root privileges.

Solution

PrestaShop version 9.2.1 addresses this vulnerability. Administrators should upgrade affected installations to version 9.2.1 or later.
If an immediate upgrade is not possible, allow only trusted administrators to modify Performance and Debug mode settings, and restrict network access to the back office. Where operationally feasible, prevent the PHP process from writing to config/defines.inc.php and config/defines_custom.inc.php. This may also prevent legitimate configuration changes.

Acknowledgements

Thanks to Deflask13 for reporting this vulnerability. This document was written by Michael Bragg.

Vendor Information

385711
 

PrestaShop Unknown

Notified:  2026-09-09 Updated: 2026-11-09

CVE-2026-124916 Unknown

Vendor Statement

We have not received a statement from the vendor.


Other Information

CVE IDs: CVE-2026-124916
API URL: VINCE JSON | CSAF
Date Public: 2026-11-09
Date First Published: 2026-11-09
Date Last Updated: 2026-11-09 14:53 UTC
Document Revision: 1

Sponsored by CISA.