On 21 October 2026 the PHP security team released an emergency fix for two critical vulnerabilities, both rated 9.2 under CVSS 4.0. The fixed versions are PHP 8.5.12, 8.4.27, 8.3.36 and 8.2.35. Both flaws let an attacker run code on the server without authentication. If you run a website or application on PHP, update now: Amazon and Cloudflare already report exploitation attempts.

What happened

PHP is the programming language behind a large share of web applications, from content management systems and online shops to internal tools. This update therefore does not concern a single appliance at the network edge, but the runtime on your web servers.

According to the security advisory on php.net, these are two memory-handling flaws in the PHP core:

Per PHP, every installation that serves web requests is at risk: PHP-FPM, Apache with mod_php, php-cgi, FrankenPHP and LiteSpeed. PHP considers mod_php the highest-risk setup. A demonstrated exploit there shows that a single unauthenticated request can trigger the attack before any of your application code runs.

Exploitation status as of 22 October 2026

Since the fix shipped, the first reports of attacks have arrived. Amazon Threat Intelligence says its MadPot honeypots caught a first exploitation attempt on 17 October 2026, four days before the fix was released, with further attempts from several sources from 21 October. Amazon also notes it does not know whether those attempts would have succeeded on real systems. Cloudflare and the firm watchTowr both say, based on their own telemetry, that exploitation has started. Neither flaw is listed in the CISA Known Exploited Vulnerabilities catalogue as of 22 October 2026, and exploitation in the wild has not been confirmed by CERT-EU advisory 2026-018 either, which on 21 October only added that technical details are being discussed publicly and that initial proofs of concept have begun to circulate.

Reports also differ on the scale: some firms report attacks, others only scanning. Do not base decisions on that difference. The description of the flaws is public, and so is the fix, which can be read backwards to work out what was repaired, and per PHP updating is the only complete remedy.

Does this affect you?

According to CERT-EU, the affected versions are all PHP 8.5 before 8.5.12, PHP 8.4 before 8.4.27, PHP 8.3 before 8.3.36 and PHP 8.2 before 8.2.35. End-of-life branches, that is PHP 8.1 and older, are affected as well and no longer receive fixes from the PHP project. PHP 8.6.0 RC4 contains the fix too, but it is a test build and PHP says it does not belong in production.

You can check the version with php -v on the server or in your hosting control panel. With distribution packages, compare the vendor package number rather than the PHP version alone: distributions backport fixes into their own numbering, so a patched system may still report an older PHP version.

Assume this affects you if PHP runs anywhere in your organisation, even where you do not develop the application yourself. According to W3Techs figures from October 2026, PHP is used by 69.3 % of websites whose server-side language can be determined. That is a share of the detectable ones, not of every website on the internet. In practice this means WordPress, Drupal, Magento, Shopware, WooCommerce and in-house applications alike.

PHP is also embedded in finished products that do not look like PHP at all. CERT-EU therefore points to the list of affected software maintained by NCSC-NL. It helps you work out whether the fix also applies to applications and appliances you have from vendors. For some products the vendor is still assessing whether they are affected at all: as of 22 October that includes several Fortinet products listed in advisory FG-IR-26-186.

Equally important is who actually controls PHP in your organisation. The fix cannot be applied by changing the application, because the PHP binaries themselves change. On a self-managed server that is your own team, on managed hosting it is the provider, and with containers it is whoever builds the base image and triggers a new deployment.

What to do now

If you cannot apply the fix straight away

None of the measures below makes an installation safe, they only narrow specific attack paths. That holds both for PHP and for CERT-EU. Where the fix cannot be applied yet, consider isolating internet-facing applications from public networks until the update is applied and verified. In practice that means restricting access to known addresses or taking the application offline for a while.

For CVE-2026-109618, PHP recommends setting memory_limit=-1 in a way applications cannot override, for example through php_admin_value in the PHP-FPM pool or in the Apache configuration, and checking that no pool, directory or application setting puts a finite limit back. Next, lower post_max_size to 8M for applications that do not need file uploads and to 32M where uploads are required, and keep upload_max_filesize below that value. Limits on decoded request size, input field count and nesting depth can also be enforced at the web server or proxy. Use a container or cgroup memory limit only as an availability boundary, and never RLIMIT_AS or RLIMIT_DATA instead, because those trigger the vulnerable code path.

For CVE-2026-109619, PHP recommends setting session.upload_progress.enabled=0 and restarting every worker, applied in php.ini, an FPM pool or the server configuration, not through ini_set() or .user.ini. On PHP 8.5, also set fatal_error_backtraces=0 and restart the workers again. Both block only the confirmed attack paths, not every variant.

How to tell whether you have already been attacked

On 21 October 2026 the Czech national cyber security authority NUKIB published its own advisory on php2shell. It names unusual processes started by PHP services as a possible indicator of compromise, that is processes launched by PHP-FPM or Apache under the web server account. Review running processes and web server logs from 17 October 2026 onwards, the date of the first observed attempt, and watch for outbound connections from web servers that do not belong there. More detailed detection and mitigation material is maintained by NCSC-NL in the detection_mitigation part of its repository.

Not enough time to track this?

Most organisations do not have the people to keep track of what every application runs on and what is being fixed in it. We help with that in two ways: a security assessment shows what you have exposed to the internet and where you stand on vulnerabilities, and as your external security manager we keep track of priorities and remediation over time. The first consultation is free of charge, get in touch. If you are handling an incident right now, reach us on our incident response page.

Sources: php.net, security announcements and released PHP versions · php-src, advisory GHSA-w8hw-w9fx-j79w on CVE-2026-109618 · php-src, advisory GHSA-6wmf-4rv5-p3rp on CVE-2026-109619 · CERT-EU, advisory 2026-018 on critical vulnerabilities in PHP · NUKIB, advisory on critical vulnerabilities in PHP · NCSC-NL, list of affected third-party software and detection material · CISA, Known Exploited Vulnerabilities catalogue · W3Techs, PHP usage statistics · watchTowr, FAQ on CVE-2026-109618 and CVE-2026-109619 · Sansec, php2shell analysis and what to expect after the release · Amazon Threat Intelligence and Cloudflare, reports of exploitation attempts from 21 and 22 October 2026