CVE-2026-126714: PHP session files overwritten in part can lead to remote code execution

Data Security

CVE-2026-126714 affects PHP applications that store sessions in files, which is the PHP default. A session write that is cut short can leave a file that PHP later reads back as injected objects. It was published on November 19, 2026, and Opensolr has been protected against it since that same day.

01 · At a glance

Identifier
CVE-2026-126714
Severity
9.2 Critical (CVSS v4.0)
Published
November 19, 2026
Affected
PHP 8.2 before 8.2.36, 8.3 before 8.3.37, 8.4 before 8.4.28, 8.5 before 8.5.13
Fixed in
PHP 8.2.36, 8.3.37, 8.4.28 and 8.5.13
Opensolr
Protected since November 19, 2026
Last reviewed
November 20, 2026

02 · What it is

The files session handler writes updated session data into the existing session file without emptying it first. If the write is interrupted, the file holds the start of the new session followed by the tail of the old one.

When PHP reads that file again, bytes that were part of an ordinary string can be unserialized as objects. An attacker who can influence session data, for example through session upload progress, and interrupt a write at the right point can inject objects. If the application contains a usable gadget chain, that becomes code execution. Without one, the result is a corrupted session.

03 · Who is affected

  • The server runs an affected PHP version.
  • The application uses native PHP sessions.
  • session.save_handler is files. That is the default.

Applications that keep sessions in a database, in Redis or in Memcached through their own handler do not use the vulnerable code path.

04 · How to fix it

Upgrade to PHP 8.2.36, 8.3.37, 8.4.28 and 8.5.13, depending on your branch, and restart PHP-FPM or the web server.

php -v
sudo apt update && sudo apt install --only-upgrade 'php8.*'
sudo systemctl restart php8.4-fpm

05 · How to mitigate until you can upgrade

Move sessions off the files handler. With the Memcached or Redis extension installed, two lines in php.ini are enough. Existing sessions end, so visitors sign in again once.

session.save_handler = memcached
session.save_path = "127.0.0.1:11211"
session.save_handler = redis
session.save_path = "tcp://127.0.0.1:6379"

If the application does not use upload progress, switching it off removes the easiest way to place data in a session:

session.upload_progress.enabled = Off

06 · How to check a server

php-fpm8.4 -i | grep -E '^session.save_handler|^session.save_path|^session.upload_progress.enabled'
ls /var/lib/php/sessions | head

A pool or a virtual host can override the handler, so check the values the application actually runs with.

07 · Opensolr and this vulnerability

Status on November 20, 2026. Opensolr is protected against CVE-2026-126714. The condition it needs was closed on the platform on November 19, 2026, the day the advisory was published. Nothing is required from you: your Opensolr Index, your account and your data are not exposed to it.

  • Opensolr watches newly published vulnerabilities for every component of the platform, around the clock.
  • Each advisory is assessed against the platform as soon as it is published.
  • The fix is applied, or the vulnerable condition is closed, and the result is verified before the case is closed.

More on how Opensolr protects your data: Opensolr Trust Center and all security pages. Questions about a vulnerability that is not listed: contact Opensolr.

Official advisory: PHP security advisory GHSA-fm2m-fjf5-v3cp · NVD entry.