Todos los artículos

Two unauthenticated RCEs fixed in PHP, update now

On 21 October 2026 the PHP team fixed two critical vulnerabilities. Both can lead to remote code execution without logging in. The flaws sit in PHP's core, so it makes no difference whether you run Laravel, WordPress or hand-written code. Every installation that serves web requests is affected. According to Amazon, exploitation attempts began four days before the patches.

That includes PHP-FPM, Apache mod_php, php-cgi, FrankenPHP and LiteSpeed.

The two flaws

CVE-2026-109618 (GHSA-w8hw-w9fx-j79w). The code that handles out-of-memory conditions can interrupt PHP while internal request data is only half initialized. During request cleanup, that incomplete data is treated as valid.

CVE-2026-109619 (GHSA-6wmf-4rv5-p3rp). Internal state owned by a request survives after the memory behind it has been freed. The next request handled by the same worker can use that stale state before normal initialization resets it.

The PHP team names mod_php as the riskiest setup. There, a demonstrated exploit lets a single unauthenticated request trigger the attack before any application code runs.

Exploitation has started

According to Amazon Threat Intelligence, the first exploitation attempts began on 17 October, four days before the patches. AWS's chief information security officer CJ Moses says the flaws are now broadly exploited and reminds defenders that the disclosure date is not the earliest date of exploitation. Cloudflare, watchTowr, Hadrian and Patchstack also saw failed attempts before disclosure. Dataminr writes that as of 22 October it only sees scanning, fingerprinting and non-working exploits, with no known compromises.

The PHP team had to move up its planned release date because details leaked. The UK's NCSC asked organizations to update their PHP servers immediately or take them offline until they can. This is not a good week to say "I'll look at it later".

Which version to move to

  • PHP 8.5 is fixed in 8.5.12
  • PHP 8.4 is fixed in 8.4.27
  • PHP 8.3 is fixed in 8.3.36
  • PHP 8.2 is fixed in 8.2.35

PHP 8.1 and older no longer receive updates from the project. Because of the severity, the team still published minimal source backports for 7.4, 8.0 and 8.1. If you build from source you can use those. If you use distribution packages, ask your vendor about their backport. Linux distributions received the patches in advance, so your package repository may already have them.

If you cannot update right now

The PHP team is explicit about this. The measures below only narrow specific attack paths and do not make an installation safe.

For CVE-2026-109618 the goal is to stop an attacker from controlling the memory limit failure. Set memory_limit to -1 and lock it on the server side so the application cannot undo it. Also shrink the request body limit. The advisory suggests post_max_size = 8M for apps without uploads and 32M when uploads are needed, with upload_max_filesize kept below it. If you can, add limits at the web server or proxy for field count, multipart part count, header count and nesting depth.

; php-fpm pool
php_admin_value[memory_limit] = -1
php_admin_value[post_max_size] = 8M
php_admin_value[upload_max_filesize] = 4M

memory_limit = -1 is dangerous on its own because a runaway script can eat the machine's memory. Pair it with a container or cgroup limit, ideally with a policy that kills only the affected worker. Do not use RLIMIT_AS or RLIMIT_DATA. They can cause the very allocation failure the bug depends on.

For CVE-2026-109619 set session.upload_progress.enabled=0 and restart every worker. Do it somewhere that applies before request parsing, such as php.ini, the FPM pool or the server configuration. ini_set() and .user.ini do not work. On PHP 8.5 also set fatal_error_backtraces=0, which closes one confirmed path. Fix fatal errors and timeouts that an attacker can reach in your own code, paying special attention to callbacks and to upload and import handling. Hiding errors with error_reporting, display_errors or @ changes nothing.

The 23 October follow-up

Two days later the team published an informational notice about a third, less likely path (CVE-2026-115560). They want session.upload_progress.enabled=0 to stay in place until the next regular release. The conditions are unusual. session.serialize_handler must be set to php_binary or php_serialize in the configuration, the application must switch it to php with ini_set() before session_start(), and upload progress must still be enabled. If you already applied the setting above, you need nothing more. The full advisory will come with the next release.

How to check the patch is really in

A version number alone may not be enough. Distribution packages carry the fix under their own numbering, and a Docker tag can point at an old image.

php -v
php-fpm8.3 -v
docker run --rm php:8.3-fpm php -v

For Docker, check that the tag has reached the new release and that the image on your server was actually re-pulled. For distribution packages, a query like apt changelog php8.3-fpm | grep -i CVE-2026-109618 that shows the CVE number means the fix is in. Then restart the workers, because old processes keep running the old code.

Sources

Related posts

Written by sheduxdev.

Two unauthenticated RCEs fixed in PHP, update now | TurkishPvP LLC