Partially overwritten session files can lead to remote code execution

Summary

CVECVE-2026-126714
StatePUBLISHED
Assignerphp
Source PriorityCVE Program / NVD first with legacy fallback
Published2026-11-19 15:17:26 UTC
Updated2026-11-19 18:18:04 UTC
DescriptionPartially overwritten session files can lead to remote code execution. The files session save handler, which is the default, writes updated session data into the existing session file without first clearing it. If a write is interrupted, the file can contain the beginning of the new session followed by the end of the old one, and bytes of an ordinary string can later be unserialized as objects. An attacker who can influence the session data, for example through session upload progress, and interrupt a write at a suitable point may inject objects, which can lead to code execution when the application contains a suitable gadget chain. Session data can also be corrupted. This issue affects PHP versions 8.2.* before 8.2.36, 8.3.* before 8.3.37, 8.4.* before 8.4.28 and 8.5.* before 8.5.13.

Risk And Classification

Primary CVSS: v4.0 9.2 CRITICAL from [email protected]

CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X

Problem Types: CWE-367 | CWE-662 | CWE-367 CWE-367 Time-of-check Time-of-use (TOCTOU) Race Condition | CWE-662 CWE-662 Improper Synchronization


VersionSourceTypeScoreSeverityVector
4.0[email protected]Secondary9.2CRITICALCVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N/E:X/C...
4.0CNACVSS9.2CRITICALCVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N

CVSS v4.0 Breakdown

Attack Vector
Network
Attack Complexity
Low
Attack Requirements
Present
Privileges Required
None
User Interaction
None
Confidentiality
High
Integrity
High
Availability
High
Sub Conf.
None
Sub Integrity
None
Sub Availability
None

CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X

Vendor Declared Affected Products

SourceVendorProductVersionPlatforms
CNA PHP Group PHP affected 8.2.0 8.2.36 semver Not specified
CNA PHP Group PHP affected 8.3.0 8.3.37 semver Not specified
CNA PHP Group PHP affected 8.4.0 8.4.28 semver Not specified
CNA PHP Group PHP affected 8.5.0 8.5.13 semver Not specified

References

ReferenceSourceLinkTags
github.com/php/php-src/security/advisories/GHSA-fm2m-fjf5-v3cp [email protected] github.com
depthfirst.com/phpAfterShell af854a3a-2127-422b-91ae-364da2661108 depthfirst.com
github.com/semgrep/detection-scripts/pull/14 af854a3a-2127-422b-91ae-364da2661108 github.com
bugzilla.suse.com/show_bug.cgi af854a3a-2127-422b-91ae-364da2661108 bugzilla.suse.com
ubuntu.com/security/CVE-2026-126714 af854a3a-2127-422b-91ae-364da2661108 ubuntu.com
CVE Program record CVE.ORG www.cve.org canonical
NVD vulnerability detail NVD nvd.nist.gov canonical, analysis

Vendor Comments And Credit

Discovery Credit

CNA: Leo Lin (en)

CNA: Asahi (en)

CNA: Ilija Tovilo (en)

CNA: Arnaud Le Blanc (en)

© CVE.report 2026

Use of this information constitutes acceptance for use in an AS IS condition. There are NO warranties, implied or otherwise, with regard to this information or its use. Any use of this information is at the user's risk. It is the responsibility of user to evaluate the accuracy, completeness or usefulness of any information, opinion, advice or other content. EACH USER WILL BE SOLELY RESPONSIBLE FOR ANY consequences of his or her direct or indirect use of this web site. ALL WARRANTIES OF ANY KIND ARE EXPRESSLY DISCLAIMED. This site will NOT BE LIABLE FOR ANY DIRECT, INDIRECT or any other kind of loss.

CVE, CWE, and OVAL are registred trademarks of The MITRE Corporation and the authoritative source of CVE content is MITRE's CVE web site. This site includes MITRE data granted under the following license.

Free CVE JSON API cve.report/api

CVE.report and Source URL Uptime Status status.cve.report