CVE-2026-109618: PHP out-of-memory handling corrupts request memory, remote code execution

Exploited in the wild Critical 9.2 EPSS 100.0% PHP

When PHP hits an out-of-memory error it aborts the request with longjmp(), which can leave request memory partly initialized; request cleanup then treats it as valid, which attackers can turn into remote code execution. An unauthenticated attacker can trigger the out-of-memory condition with crafted multipart POST requests, and with Apache mod_php this happens before any application code runs; PHP-FPM is also considered susceptible. Fixed in PHP 8.5.12, 8.4.27, 8.3.36 and 8.2.35; CISA added it to the Known Exploited Vulnerabilities catalog on 26 October 2026.

Also known as “php2shell”.

What do these terms mean? CVE · CVSS score · exploited (KEV) · EPSS · backported fix · all terms

What to do now

  1. Check whether you run PHP and which version (commands below).
  2. Install the fixed version for your system: see “Patch it” below.
  3. Restart every PHP worker so no process keeps running the old code: PHP-FPM (php8.x-fpm / php-fpm / php-fpm8x / php_fpm), Apache when mod_php is used (apache2 / httpd / apache24), and FrankenPHP or LiteSpeed (lsphp) where used. Containers must be rebuilt from a fixed image and recreated. No reboot is needed.
  4. If you cannot patch today, apply the temporary mitigation below and patch as soon as possible.
  5. Because this flaw is being exploited, also check the server for signs of compromise.

Affected and fixed versions

Affected:

Fixed in:

Am I affected?

php -v   # CLI binary; also check the binary actually serving web requests
dpkg -l 'php*' 'libapache2-mod-php*' | grep ^ii   # Debian/Ubuntu
rpm -qa 'php*' | sort   # RHEL/Alma/Rocky/SUSE
apk info -v | grep '^php8'   # Alpine
pkg info -x '^(php8|mod_php8)'   # FreeBSD
pkg audit -F   # FreeBSD: lists vulnerable packages from VuXML
apachectl -M 2>/dev/null | grep -i php   # is Apache mod_php loaded? (highest risk per php.net)
php -i | grep -E '^(memory_limit|session.upload_progress.enabled|fatal_error_backtraces) '

Patch it

Use the commands for your system. Distribution packages often keep an older version number with the fix backported, so compare with the fixed package versions in the table below, not only with the upstream version.

Debian
sudo apt update
sudo apt install --only-upgrade $(dpkg-query -W -f='${Package}\n' 'php8.*' 'libapache2-mod-php8.*' 2>/dev/null)
# expect php8.4 >= 8.4.27-1~deb13u1 (trixie) or php8.2 >= 8.2.35-1~deb12u1 (bookworm)
sudo systemctl try-restart 'php*-fpm.service' apache2.service
Ubuntu
sudo apt update
sudo apt install --only-upgrade $(dpkg-query -W -f='${Package}\n' 'php*' 'libapache2-mod-php*' 2>/dev/null)
# 20.04 and older: fixes are in Ubuntu Pro/ESM (sudo pro attach first)
sudo systemctl try-restart 'php*-fpm.service' apache2.service
RHEL, AlmaLinux, Rocky, Oracle
sudo dnf upgrade --refresh 'php*'
# RHEL 7 ELS: sudo yum update 'php*'
sudo systemctl try-restart php-fpm.service httpd.service
Fedora
sudo dnf upgrade --refresh php-fpm php-cli
SUSE / openSUSE
sudo zypper refresh
sudo zypper patch --category security
# openSUSE Tumbleweed: sudo zypper dup
sudo systemctl try-restart php-fpm.service apache2.service
Amazon Linux
sudo dnf upgrade --releasever=latest php8.4 php8.4-fpm (or the installed php8.x)
Arch Linux
sudo pacman -Syu
Alpine
sudo apk update
sudo apk upgrade
apk info -v | grep -E '^php8[2-5]-8'   # expect 8.2.35-r0 / 8.3.36-r0 / 8.4.27-r0 / 8.5.12-r0
sudo rc-service php-fpm84 restart   # use your suffix: php-fpm83, php-fpm85 ...
FreeBSD
sudo pkg update
sudo pkg upgrade
sudo pkg audit -F
sudo service php_fpm restart
sudo service apache24 restart   # if mod_php is used
Docker images
# official image: rebuild on a fixed tag (8.5.12, 8.4.27, 8.3.36, 8.2.35 or the moving 8.x tags)
docker pull php:8.4-fpm   # or your variant: -apache, -fpm-alpine, -cli ...
docker compose build --pull
docker compose up -d
docker compose exec <service> php -v
Built from source
V=8.4.27   # or 8.5.12 / 8.3.36 / 8.2.35
curl -LO https://www.php.net/distributions/php-$V.tar.xz
sha256sum php-$V.tar.xz   # compare with https://www.php.net/downloads.php
tar xf php-$V.tar.xz && cd php-$V
php -i | grep 'Configure Command'   # reuse your old configure options
./configure <same options>
make -j"$(nproc)"
sudo make install
# then restart php-fpm / Apache / FrankenPHP / LiteSpeed workers

General update steps for every system are on the Linux and Unix & BSD pages; after updating, see which services to restart.

Fix status in Linux distributions

ReleasePackageStatusFixed version / advisory
Debian 12php8.2fixed8.2.35-1~deb12u1
Debian 13php8.4fixed8.4.27-1~deb13u1
Debian testingphp8.4fixed8.4.27-1
Ubuntu 18.04 (ESM)php7.2fixed7.2.24-0ubuntu0.18.04.17+esm14
Ubuntu 20.04 (ESM)php7.4fixed7.4.3-4ubuntu2.29+esm5
Ubuntu 22.04php8.1fixed8.1.2-1ubuntu2.28
Ubuntu 24.04php8.3fixed8.3.6-0ubuntu0.24.04.13
Ubuntu 26.04php8.5fixed8.5.4-0ubuntu1.5
Ubuntu 26.10php8.5fixed8.5.9-0ubuntu2.1
Red Hat Enterprise Linux 9php:8.2-9080020261020145734.9fixedRHSA-2026:87072
Red Hat Enterprise Linux 9php:8.3-9080020261020115403.9fixedRHSA-2026:87079
Red Hat Enterprise Linux 9php-0:8.0.30-8.el9_8.1fixedRHSA-2026:87151
Red Hat Enterprise Linux 9php:8.4/phpaffected
Red Hat Enterprise Linux 8php:8.2-8100020261020140951.f7998665fixedRHSA-2026:87073
Red Hat Enterprise Linux 8php:7.4-8100020261021081045.f7998665fixedRHSA-2026:87080
Red Hat Enterprise Linux 6phpout of support scope
Red Hat Enterprise Linux 10php-0:8.3.36-1.el10_2fixedRHSA-2026:87070
Red Hat Enterprise Linux 10php8.4-0:8.4.27-1.el10_2fixedRHSA-2026:87071
Debian 13 (trixie)php8.4fixed8.4.27-1~deb13u1 (DSA-6574-1)
Debian 12 (bookworm, LTS)php8.2fixed8.2.35-1~deb12u1 (DLA-4848-1)
Debian forky/sidphp8.4fixed8.4.27-1
Ubuntu 26.10 (stonking)php8.5fixed8.5.9-0ubuntu2.1 (USN-8948-1)
Ubuntu 26.04 LTS (resolute)php8.5fixed8.5.4-0ubuntu1.5 (USN-8948-1)
Ubuntu 24.04 LTS (noble)php8.3fixed8.3.6-0ubuntu0.24.04.13 (USN-8948-1)
Ubuntu 22.04 LTS (jammy)php8.1fixed8.1.2-1ubuntu2.28 (USN-8948-1)
Ubuntu 20.04 (focal, Ubuntu Pro/ESM)php7.4fixed7.4.3-4ubuntu2.29+esm5 (USN-8948-2)
Ubuntu 18.04 (bionic, Ubuntu Pro/ESM)php7.2fixed7.2.24-0ubuntu0.18.04.17+esm14 (USN-8948-2)
Ubuntu 16.04 (xenial, Ubuntu Pro/ESM)php7.0fixed7.0.33-0ubuntu0.16.04.16+esm22 (USN-8948-2)
Ubuntu 14.04 (trusty, Ubuntu Pro/ESM)php5fixed5.5.9+dfsg-1ubuntu4.29+esm18 (USN-8948-2)
RHEL 10phpfixed8.3.36-1.el10_2 (RHSA-2026:87070)
RHEL 10php8.4fixed8.4.27-1.el10_2 (RHSA-2026:87071)
RHEL 9php (8.0, default)fixed8.0.30-8.el9_8.1 (RHSA-2026:87151)
RHEL 9php:8.2 modulefixedphp:8.2-9080020261020145734.9 (RHSA-2026:87072)
RHEL 9php:8.3 modulefixedphp:8.3-9080020261020115403.9 (RHSA-2026:87079)
RHEL 8php:8.2 modulefixedphp:8.2-8100020261020140951.f7998665 (RHSA-2026:87073)
RHEL 8php:7.4 modulefixedphp:7.4-8100020261021081045.f7998665 (RHSA-2026:87080)
SUSE Linux Enterprise 16.1php8fixed8.5.12-160100.1.1
SUSE Linux Enterprise 16.0 / openSUSE Leap 16.0php8fixed8.4.27-160000.1.1 (SUSE-SLES-16.0-1955)
SLES 15 SP7 (Web and Scripting module)php8fixed8.3.36-150700.3.24.1 (SUSE-SU-2026:4844-1)
SLES 15 SP6-LTSSphp8fixed8.2.35-150600.3.39.1 (SUSE-SU-2026:4843-1)
SLES 15 SP4/SP5-LTSSphp8fixed8.0.30-150400.4.80.1 (SUSE-SU-2026:4852-1)
openSUSE Tumbleweedphp8fixed8.5.12-1.1
Alpine 3.23, 3.24, edgephp83 / php84 / php85fixed8.3.36-r0 / 8.4.27-r0 / 8.5.12-r0
Alpine 3.22php82 / php83 / php84fixed8.2.35-r0 / 8.3.36-r0 / 8.4.27-r0
FreeBSD ports/pkgphp82 / php83 / php84 / php85fixed8.2.35 / 8.3.36 / 8.4.27 / 8.5.12 (VuXML d8e16d08-cd2f-11f1-8135-8447094a420f)
Docker official image (php)phpfixedtags 8.5.12-*, 8.4.27-*, 8.3.36-*, 8.2.35-*
Sury repo (packages.sury.org, Debian 12/13) / ondrej PPA (Ubuntu)php8.2 / php8.3 / php8.4 / php8.5fixed8.2.35-1+... / 8.3.36-1+... / 8.4.27-1+... / 8.5.12-1+...
Remi repo (EL9)php (module php:remi-8.x) / php8x-phpfixed8.2.35-1 / 8.3.36-1 / 8.4.27-1 / 8.5.12-1

From the Debian security tracker, Ubuntu CVE tracker and Red Hat Security Data API, refreshed every few hours.

If you cannot patch yet

Look for signs of exploitation

CISA required action: Apply mitigations in accordance with vendor instructions, ensuring compliance with CISA’s BOD 26-04 Prioritizing Security Updates Based on Risk (see URL in Notes) guidance and CISA’s “Forensics Triage Requirements” (see URL in Notes). Follow applicable BOD 26-04 guidance for cloud services or discontinue use of the product if mitigations are unavailable. Stakeholders are responsible for evaluating each asset's internet exposure and ensuring adherence to BOD 26-04 patching guidelines.

This vulnerability affects an open-source component, third-party library, protocol, or proprietary implementation that could be used by different products. For more information, please see: https://www.php.net/ ; https://www.cisa.gov/news-events/alerts/2026/10/21/critical-vulnerabilities-php-require-immediate-patching ; BOD 26-04: https://www.cisa.gov/news-events/directives/bod-26-04-prioritizing-security-updates-based-risk ; Forensics Triage Requirements: https://www.cisa.gov/news-events/directives/bod-26-04-implementation-guidance-prioritizing-security-updates-based-risk ; https://nvd.nist.

Related vulnerabilities

Sources

Page generated automatically from official sources on 2026-11-03 17:06 UTC and reviewed by an editor. Always confirm with your vendor's advisory.