Blog · Industry news

PHP Patches 7 Critical Flaws as PHP 8.6 Launches: Update Now

Share: https://www.ellixorlabs.com/blog/php-security-update-critical-flaws-php-8-6-released (copy URL for iMessage or social)

Published (display in IST)

Updated (IST)

The official PHP logo, blue lowercase php lettering inside a grey oval
Colin Viebrock / Wikimedia Commons (https://commons.wikimedia.org/wiki/File:PHP-logo.svg)

PHP has fixed seven critical flaws, including one in its default session storage, and launched PHP 8.6. Here is which version you need, how to check your site and what to do if you cannot patch yet.

PHP, the server language behind WordPress, Laravel and many custom business websites, released security updates on 19 November 2026 that fix seven critical flaws, several of which can let an attacker run code on a server. The fixed versions are PHP 8.5.13, 8.4.28, 8.3.37 and 8.2.36, according to the official php.net release announcements, and the PHP team says all users of those branches should upgrade. On the same day the project shipped PHP 8.6.0, a major new version that already includes the fixes. If your site runs on PHP, check its version today: one of the critical bugs, nicknamed phpAfterShell by the depthfirst researchers who found it, sits in PHP's default way of storing user sessions.

What are the critical PHP flaws?

The PHP 8.5.13 changelog lists fixes for 17 security advisories. Laravel Forge's advisory counts seven as critical, each scored 9.2 under CVSS 4.0, plus four rated high. Two stand out. The first, CVE-2026-126714, affects the file-based session handler, which is PHP's default. The official PHP advisory explains that if a session write is interrupted, the file can keep part of the new data and part of the old, and PHP may then rebuild attacker-controlled objects the next time the session opens. Turning that into code execution also needs a suitable weakness in the application's own code. The second, CVE-2026-129289, is request smuggling in PHP-FPM, the process manager commonly used to run PHP behind Nginx. Its advisory says an attacker without a login can slip a hidden request past the web server and run their own PHP code when FastCGI connections stay open between requests and the app opens the request body without reading all of it. The other critical bugs are memory errors in the timezone cache, session shutdown and error backtraces, and mostly need specific settings. When PHP pre-announced the release on 18 November it said the critical issues require non-default configuration or uncommon setups, but depthfirst and Forge both say at least some affect default setups, so treat the update as urgent.

Is my website affected, and what should I do today?

Any PHP 8.2, 8.3, 8.4 or 8.5 release older than the fixed versions is affected. WordPress recommends PHP 8.3 or newer, so a typical WordPress site is in scope, as are Laravel, Symfony and custom PHP apps. PHP 8.1 and older are end of life, and php.net's support table shows PHP 8.2 itself loses security fixes on 31 December 2026. To check, look for the PHP version in your hosting control panel or WordPress's Site Health screen, or run php -v on the server. Then upgrade to the fixed release for your branch, rebuild any container images and confirm production is really running it. Packages can lag: Forge reported that patched builds took several hours to reach the Ubuntu 22.04 and 24.04 mirror it uses, and some ARM builds were still missing when we checked on 20 November (IST). If you must wait, depthfirst advises setting session.upload_progress.enabled = 0 to close the easiest attack path, and Forge advises removing fastcgi_keep_conn on from Nginx site configs. Neither replaces the update. On shared or managed hosting, ask your provider which PHP version you are on. As with the NGINX HTTP/2 flaws and Apache bug we covered this month, the gap between a public fix and real attacks can be short.

What is new in PHP 8.6, and should I switch now?

PHP 8.6.0 is a feature release rather than a patch. The official PHP 8.6 release page highlights partial function application, which lets developers fill in some of a function's arguments now and the rest later; a Duration class for measuring elapsed time; a polling API for scalable input and output in event loop libraries such as ReactPHP and AMPHP; a clamp() function that keeps a value within a range; a SortDirection enum; and default values for readonly properties. Its changelog includes the same 17 security fixes, and php.net lists active support until 31 December 2028 and security fixes until 31 December 2030. For most businesses the sensible order is to patch today, then test 8.6 on a staging copy before going live, because the migration guide lists backward-incompatible changes that older code and plugins may trip over.

Frequently asked questions

Which PHP versions fix the November 2026 security flaws? PHP 8.5.13, 8.4.28, 8.3.37 and 8.2.36, released on 19 November 2026, fix the flaws, and the new PHP 8.6.0 includes the same fixes. Earlier releases on those branches, including the October 2026 updates, are still affected.

What is phpAfterShell? phpAfterShell is the name the security firm depthfirst gave to CVE-2026-126714, a critical flaw in PHP's default file-based session storage. An interrupted session write can leave a mixed file that PHP later unpacks, which in some applications can lead to remote code execution.

Should I upgrade to PHP 8.6 straight away? Not necessarily. First install the security release for the branch you already run, because it fixes the flaws with minimal change. Then test PHP 8.6 on a staging copy of your site, since it deprecates some older features, and switch once your code and plugins work.

If you are not sure which PHP version your website or app runs, or who is responsible for patching it, we can check and set up a safe update routine with you. Get in touch with our team or see how we build and maintain web applications.

FAQ

Which PHP versions fix the November 2026 security flaws?

PHP 8.5.13, 8.4.28, 8.3.37 and 8.2.36, released on 19 November 2026, fix the flaws, and the new PHP 8.6.0 includes the same fixes. Earlier releases on those branches, including the October 2026 updates, are still affected.

What is phpAfterShell?

phpAfterShell is the name the security firm depthfirst gave to CVE-2026-126714, a critical flaw in PHP's default file-based session storage. An interrupted session write can leave a mixed file that PHP later unpacks, which in some applications can lead to remote code execution.

Should I upgrade to PHP 8.6 straight away?

Not necessarily. First install the security release for the branch you already run, because it fixes the flaws with minimal change. Then test PHP 8.6 on a staging copy of your site, since it deprecates some older features, and switch once your code and plugins work.

Talk to Ellixor Labs about this topic.

Source: The PHP Group (php.net)