A PrestaShop back-office user who can change Debug mode settings can make a store execute PHP on a later request. CERT/CC describes an authenticated code-injection flaw in the Performance configuration: cookie settings entered through the admin interface end up in a PHP file that PrestaShop loads during startup. Stores with staff or integrations granted that configuration permission need to check both the installed version and who holds the permission.
The newly assigned CVE-2026-124916 record lists PrestaShop 1.5.0.0 through versions below 9.2.1 as affected. CERT/CC says the affected-release range remains to be confirmed and names 9.2.1 as the fix. For a store running an earlier version, prioritize the upgrade; use the access and file checks below even if its specific release has yet to be tested.
Cookie settings enter executable PHP
The Debug mode form accepts debug_cookie_name and debug_cookie_value. PrestaShop inserts those user-controlled values into a PHP expression without enough escaping for source code, then writes a define() statement to config/defines.inc.php or config/defines_custom.inc.php. A crafted value can end the intended string and introduce PHP statements. On the next request that initializes the application, the modified file loads and the injected statements run as the PHP process.
This path depends on two conditions: a back-office account allowed to edit Debug mode and a configuration file writable by the PHP process. A public visitor cannot reach this path through an ordinary storefront request. CERT/CC puts the privilege boundary plainly: “Root or operating-system administrator privileges are not required.” The code runs with the PHP process’s rights, which may include access to application secrets, customer data and the store database. Operating-system command execution depends on the PHP configuration and available functions.
The store’s CSRF protection guards against someone sending an unauthorized configuration request through another user’s session. It does not stop a person controlling an account with Debug mode permission from submitting a crafted value. Those two cases need different controls: keep CSRF protection enabled, and restrict the accounts that can change Performance settings.
Inspect the files and permissions
Start with the account list for the back-office Performance configuration. Remove Debug mode editing rights from roles that do not need them, and limit access to the back office to trusted administrators. Then compare config/defines.inc.php and config/defines_custom.inc.php with your approved deployment or known-good version. Focus on changes near debug_cookie_name and debug_cookie_value, and investigate unexpected PHP statements or file writes against change records. A normal-looking cookie setting on the form is a poor substitute for looking at the PHP file that executes.
Where the deployment allows it, prevent the PHP process from writing those two configuration files. CERT/CC warns that this restriction can also prevent legitimate configuration changes, so test it against the store’s maintenance workflow before making it permanent. Preserve the file diff and relevant back-office change history if you find code you cannot account for; removing the input alone would leave modified PHP in place.
Upgrade and verify the store
Upgrade PrestaShop to 9.2.1 or later. After deployment, read the installed application version on each store, check that Debug mode editing is confined to the intended administrators, and compare both named PHP configuration files with the approved release and authorized local changes. The expected result is a fixed installed version and only reviewed PHP statements in those files. If either file contains an unexplained statement, investigate the store under the PHP process’s permissions, including access to secrets and customer data, before restoring from clean files.