On November 19, 2026, the PHP development team released security updates addressing several vulnerabilities, including a critical remote code execution vulnerability identified as CVE-2026-126714.
The vulnerability affects PHP's default file-based session storage mechanism and may allow remote attackers to execute arbitrary code with the privileges of the PHP worker process.
Security Vulnerability
| Parameter | Description |
|---|---|
| CVE Identifier | CVE-2026-126714 |
| Security Advisory | GHSA-fm2m-fjf5-v3cp |
| Affected Software | PHP |
| Affected Component | Session extension (ext-session) |
| Vulnerability Type | Race condition and unsafe deserialization |
| CVSS 4.0 Score | 9.2 (Critical) |
| Attack Vector | Network |
| Attack Complexity | Low |
| Attack Requirements | Present |
| Privileges Required | None |
| User Interaction Required | No |
| Security Impact | Remote Code Execution (RCE) |
An interrupted session update may leave residual data from a previous session alongside newly written content.
Under certain conditions, PHP may interpret the corrupted session contents as serialized objects. Applications containing suitable deserialization gadget chains may consequently be exposed to arbitrary code execution.
Successful exploitation requires control over session content, an interrupted write, and vulnerable application behavior.
Affected and Fixed Versions
| PHP Branch | Affected Versions | Fixed Version |
|---|---|---|
| PHP 8.2 | Before 8.2.36 | 8.2.36 |
| PHP 8.3 | Before 8.3.37 | 8.3.37 |
| PHP 8.4 | Before 8.4.28 | 8.4.28 |
| PHP 8.5 | Before 8.5.13 | 8.5.13 |
According to the PHP development team, the affected implementation dates back to PHP 4.1.0.
Users running unsupported PHP versions should migrate to a supported release or obtain security updates from their operating system vendor.
Linux distributions may provide backported security fixes without changing the upstream PHP version number.
Security Impact
Successful exploitation may result in:
- Remote code execution with PHP worker privileges.
- Unauthorized access to application data.
- Compromise of websites and web applications.
- Unauthorized modification of application files.
- Disclosure of sensitive configuration data.
- Session corruption and service disruption.
Publicly accessible PHP applications using file-based sessions should be reviewed and updated promptly.
Checking Your PHP Configuration
Check your currently installed PHP version:
php -v
Check the configured session storage handler:
php -i | grep session.save_handler
The default configuration is:
session.save_handler = files
Check whether session upload progress is enabled:
php -i | grep session.upload_progress.enabled
The default configuration is:
session.upload_progress.enabled = On
PHP CLI and PHP-FPM may use different configuration files. Verify the effective configuration of the PHP-FPM pools serving your websites.
Update Recommendations
We strongly recommend that customers running PHP on their virtual or dedicated servers install the latest available security updates.
apt update
apt upgrade -y
dnf upgrade --refresh -y
After installing the updates, restart the corresponding PHP-FPM service if it has not already been restarted by the package manager.
For example, on Debian or Ubuntu with PHP 8.5:
systemctl restart php8.5-fpm
On systems using the standard PHP-FPM service:
systemctl restart php-fpm
Verify the installed PHP version:
php -v
Temporary Mitigation
If an immediate update is not possible, disabling session upload progress may reduce exposure.
Add the following directive to the appropriate PHP configuration file:
session.upload_progress.enabled = Off
Alternatively, enforce this setting in the PHP-FPM pool configuration:
php_admin_flag[session.upload_progress.enabled] = off
Restart PHP-FPM to apply the configuration changes.
Additional mitigation measures include:
- Limiting the amount of untrusted data stored in PHP sessions.
- Reviewing application deserialization behavior.
- Using an alternative session storage backend that supports atomic record replacement.
Alternative session storage implementations are not affected by this specific file-write vulnerability.
Disabling session upload progress does not completely eliminate the vulnerability. Applications that independently store attacker-controlled data in sessions may remain exposed.
Installing the appropriate PHP security update remains the recommended solution.
Regularly installing security updates is essential for maintaining a secure, reliable, and stable hosting environment.