Check a site
Check a website Service status Outages Blog
Theme
All tools
Check a websiteBrowse all tools
A panel for PHP 8.6.0 on 19 November showing partial function application, clamp, Duration and Io Poll as new, 18 CVEs to patch, and the fixed releases 8.5.13, 8.4.28, 8.3.37 and 8.2.36

Server & Security News

PHP 8.6 is out, and every supported PHP version gets security fixes: an analysis

Posted Jimel S.8 min read

PHP 8.6.0 arrived on 19 November with partial function application, clamp(), a Duration class and a new polling API. The same day, PHP 8.5.13, 8.4.28, 8.3.37 and 8.2.36 fixed security bugs the PHP team rated up to critical. Here’s what matters, and what to do first.

Illustration: UtiBox

Two releases in one day

On Thursday, 19 November 2026, the PHP project published two different kinds of release:

  • PHP 8.6.0, the new yearly feature release. In PHP’s words, it “marks a major update to the PHP language.”
  • Security releases for every supported branch: 8.5.13, 8.4.28, 8.3.37 and 8.2.36. Each announcement says simply: “This is a security release.”

We wrote about the schedule when 8.6 was still due, in PHP 8.6 is due on 19 November, and PHP 8.2 reaches end of life on 31 December. This is the follow-up, now that the code is out.

Part 1: the security fixes

How serious is it?

PHP warned in advance. Its notice of 18 November said the releases would “address security vulnerabilities affecting all supported PHP versions. The highest severity is CRITICAL.” It added an important limit: “The issues rated CRITICAL require either non-default configuration or uncommon setups.”

So this is urgent, but it isn’t a reason to panic. A default PHP install isn’t necessarily exposed to the worst bugs. You can’t easily prove which setup you have, though, so patching is the safe answer.

This is also the second security round in four weeks. On 21 October, PHP 8.5.12, 8.4.27, 8.3.36 and 8.2.35 fixed two critical remote-code-execution bugs, which we covered in Patch PHP now: the “php2shell” flaws are under active attack. If you skipped that round, today’s releases include those fixes too.

What was fixed

PHP 8.5.13’s ChangeLog lists 18 CVEs. PHP 8.6.0 ships with the same fixes. Grouped by area:

AreaWhat was fixed (from PHP’s ChangeLog)Why it matters
Sessions (3)Partially overwritten session files and a session serializer mismatch, each of which “can lead to remote code execution”; a use-after-free after an interrupted session shutdownAlmost every PHP site with logins uses sessions
PHP-FPM (3)Request smuggling “through an unread HTTP request body”; an epoll use-after-free that “can lead to local privilege escalation”; XSS on the FPM status pageFPM is how most Nginx and modern Apache setups run PHP
Core (2)Use-after-free bugs in error backtraces, one of which “can lead to remote code execution”Affects 8.5 and 8.6
Date (1)A timezone cache use-after-free that “can lead to remote code execution”
CGI (1)Out-of-bounds read and write while correcting PATH_INFOOnly for PHP run as CGI
SOAP (2)Information disclosure through malformed array dimensions; a use-after-free with DTD entity referencesSites that accept SOAP requests
Phar (1)Signature bypass “via algorithm downgrade”Code that trusts signed .phar archives
DOM (1)A double free during XML serialization
Standard (2)Mixed-case HTTPS:// and FTPS:// URLs “can expose data in plaintext”; denial of service through folded HTTP response headersAny PHP code that fetches URLs
URI (2)Bundled uriparser updated to 1.0.3; incorrect URI serialization for oversized inputThe URI extension is new in 8.5

Two are worth spelling out:

  • The HTTPS one is subtle. Per the ChangeLog, a URL written with unusual capitals, such as HTTPS://, could end up sent without encryption. If your code builds URLs from user input or config files, this is a real-world risk, not just a theoretical one.
  • The FPM status page XSS only matters if you’ve switched on pm.status_path and can reach it from a browser. If you have, it’s a good moment to put it behind a login or an IP allowlist.

Which version fixes it for you

You runInstallNotes
PHP 8.58.5.13All 18 fixes
PHP 8.48.4.2814 fixes. The two Core bugs and the two URI fixes don’t apply to 8.4’s code
PHP 8.38.3.37Security-only branch. Check its ChangeLog entry for the list
PHP 8.28.2.36Security-only, and end of life on 31 December 2026. Plan your move off 8.2 now
PHP 8.68.6.0Already includes them

On shared hosting and Linux packages: your host or distribution may ship the fix under its own version number (a backport). Check its security notice rather than relying on php -v alone. On cPanel and Plesk, look for updated “ea-php” or Plesk PHP packages.

How to check and patch

  1. Find every PHP version you run. The command line and the web server can use different ones: compare php -v with a phpinfo() page, then delete that page.
  2. Update from a trusted source, then restart PHP-FPM (systemctl restart php8.4-fpm or similar). A new package doesn’t help until the running processes are replaced.
  3. Check the site still works. Our HTTP status checker and website health report show whether pages still answer normally.

UtiBox can’t see which PHP version your server runs or whether it’s patched. Many sites hide the X-Powered-By header (they should), and backports make version numbers unreliable anyway. Only a check on the server tells you for sure.

Part 2: what’s new in PHP 8.6

PHP 8.6 is a big release for a “.x”. Here are the changes most developers will notice, using the PHP project’s own examples.

Partial function application

The headline feature. You can now call a function with some arguments filled in and a ? for the rest. You get back a closure that waits for the missing values:

$versions = ['8.4', '8.5', '8.6', '8.7', '9.0'];

$supportsPfa = array_filter(
    $versions,
    version_compare(?, '8.6', '>='),
);

Before 8.6 that was fn($v) => version_compare($v, '8.6', '>='). It looks like a small saving. In code that passes callbacks around all day (collections, pipelines, event handlers), it adds up. PHP also says array_map() with these callbacks is now compiled into a plain loop, so the shorter version can be faster too.

clamp()

A tiny function that every project has written itself at least once:

clamp(110, 0, 100); // 100
clamp(-10, 0, 100); // 0

It works with any comparable value, not just numbers. Expect to see a lot of custom max(min(...)) helpers deleted.

Time\Duration

A class for lengths of time (timeouts, retry delays, benchmark timings) with nanosecond precision, kept separate from dates and time zones. That separation matters. Mixing “how long” with “what time” is a classic source of bugs around clock changes. Durations can be added, multiplied and compared, so min() and clamp() work on them directly.

Io\Poll

A modern way to watch many network connections at once. It uses the best mechanism each operating system offers (epoll, kqueue, event ports or WSAPoll), and it removes the limits of stream_select(). Most developers won’t use it directly, but async libraries like ReactPHP and AMPHP are its intended users, and PHP calls it a “common foundation” for them.

Smaller things you’ll still notice

  • Readonly properties can have defaults. public readonly string $parser = SlugParser::class; now works.
  • A SortDirection enum (Ascending, Descending) gives libraries a shared, type-safe way to say “sort order”.
  • Stream errors can throw. Set a stream context’s error mode to throw a StreamException with structured StreamError objects, instead of warnings you have to catch with @ and error_get_last().
  • mysqli::quote_string() escapes and quotes in one step, like PDO::quote(). Prepared statements are still the better tool.
  • JSON errors now say where in the input the problem is.
  • Sodium gains post-quantum key exchange (X-Wing and ML-KEM-768), and TLS streams get session resumption and TLS 1.3 0-RTT.

Part 3: what could break when you upgrade to 8.6

Most of the changes are deprecations: warnings now, removal in a later major version. A few are real behaviour changes. The ones most likely to affect existing sites:

  • Safer session defaults. session.use_strict_mode and session.cookie_httponly are now on, and session.cookie_samesite defaults to Lax. That’s good for security. It can break cross-site flows that relied on the session cookie, such as some payment-provider returns or embedded iframes. Test checkout and single-sign-on flows first.
  • Custom session handlers that don’t implement both create_sid() and validateId() are deprecated.
  • trim() now strips form feeds (\f) by default.
  • fclose(), file_put_contents() and copy() return false when flushing or closing fails, instead of silently succeeding. Code that never checked their return values may now see errors it was quietly missing. That’s arguably a fix.
  • More ValueErrors for out-of-range values, invalid flags and strings containing NUL bytes, where PHP used to truncate or ignore them.
  • Deprecated: return inside finally; returning a value from __construct(); mb_ereg() and the other mbstring regex functions (use PCRE with the u flag); the is_double(), is_long(), is_integer() and doubleval() aliases; spl_object_hash(); strcoll(); and let and is as names of classes or functions.

A sensible upgrade plan

  1. Patch your current branch today. That’s the security part, and it doesn’t change behaviour.
  2. Run your test suite on 8.6 with deprecation notices visible (error_reporting=E_ALL), and fix what it shows.
  3. Wait for your stack. Check that your framework, CMS, plugins and hosting panel support 8.6. Major releases usually need a few weeks for that.
  4. If you’re on 8.2, don’t wait for 8.6. 8.2’s security support ends on 31 December. Move to 8.4 or 8.5 now, then to 8.6 when your stack is ready.

Sources

Related

More from Server & Security News

Most read

Latest

Most read

  1. 01November Patch Tuesday lands on the 10th: what October’s record release tells us19
  2. 02Introducing UtiBox: the Web’s Utility Box2
  3. 03Ivanti Connect Secure zero-days gave attackers root on VPN gateways1
  4. 04“Black October”: attackers raid secrets at cloud and AI developer platforms1

Embed this post

Paste this code into your page. It shows the post as a card that links back here. In WordPress you can also paste the post’s address on a line of its own.

Cookies on UtiBox

UtiBox is free because of ads. Google and its partners use cookies to show, limit and measure ads, Google Analytics, Ahrefs Web Analytics and Microsoft Clarity show us how the site is used, and we use a few essential cookies to run the site.