A newly identified vulnerability named phpAfterShell is exposing servers to unauthenticated remote code execution, even those recently patched for PHP2Shell vulnerabilities. Discovered by Depthfirst researchers on November 19, the flaw, known as CVE-2026-126714, has been given a critical CVSS score of 9.2. It is found in PHP’s default file-based session handler. When upload progress is enabled, PHP can inadvertently create session files with mixed data if a session update is interrupted, leading applications to accept these corrupted files as valid. This issue allows PHP to deserialize objects from corrupted session data, enabling the execution of remote code. Although the October updates addressed some PHP2Shell issues, they did not cover the scenario where interrupted writes create vulnerable session files. Depthfirst demonstrated that attackers could exploit this by combining the flaw with a memory corruption bug in a PHP class. While code execution would occur with PHP worker permissions, it could still expose sensitive data like credentials and application files. The flaw does not affect applications that use Redis or a database for session storage instead of PHP’s file handler. Fixed versions of PHP have been released, including 8.2.36, 8.3.37, 8.4.28, and 8.5.13, but these updates are separate from the October PHP2Shell patches. Organizations using PHP versions 8.0 and 8.1, which are no longer supported, should upgrade. As a temporary measure, setting session.upload_progress.enabled to 0 in the php.ini file and restarting PHP workers can mitigate risk, although this does not fix the session handler. After updating, confirm that the correct version is serving web requests, and for containerized applications, rebuild and redeploy the image. Additionally, check distribution advisories for their patched PHP packages.
phpAfterShell Exploit Evades PHP2Shell Fixes for Remote Code Execution
phpAfterShell attack (CVE-2026-126714) bypasses PHP2Shell fixes allowing unauthenticated remote code execution via session storage.
Executive Summary
The phpAfterShell vulnerability allows remote code execution on PHP servers by bypassing recent PHP2Shell patches. This flaw, identified by Depthfirst, highlights the need for organizations to upgrade to the latest PHP versions and review their session storage configurations.
Actionable insights
PremiumWhat Premium adds to this story
- 5 concrete actions your team can take on this story
- The same on every Monday and Friday story
- Every Monday and Friday edition by email, on top of Wednesday
€2 a month. New to Premium? The first 7 days are free, no card needed.
Unlock with PremiumOriginal source
cybersecuritynews.com

