PHP session serializer mismatch can lead to RCE (CVE-2026-115560)
A session serializer mismatch in PHP can allow an attacker to inject unserializable data via session upload progress, potentially leading to remote code execution. Fixed in PHP 8.2.36, 8.3.37, 8.4.28 and 8.5.13.
Overview
CVE-2026-115560 affects PHP session handling. When session.upload_progress.enabled is on, attacker-controlled data from a multipart upload can be stored in a session key using the php_binary or php_serialize session serializer. If the same session is later read with the php serializer—because session.serialize_handler is changed at runtime or differs between applications sharing a session store—bytes inside the key can reach the unserializer. An attacker able to submit a multipart upload may inject objects, potentially leading to code execution if the reading application contains a suitable gadget chain, or to session corruption/denial of service.
Affected versions: PHP 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.
Sources: - https://nvd.nist.gov/vuln/detail/CVE-2026-115560 - https://github.com/php/php-src/security/advisories/GHSA-658j-r8rw-q6mx
What to do
1. Identify affected PHP installations and update to a fixed release: 8.2.36, 8.3.37, 8.4.28 or 8.5.13 as applicable. Verify the vendor advisory before changing production. 2. If you cannot patch immediately, review applications that share a session store or change session.serialize_handler at runtime; ensure serializers are consistent. 3. Where feasible, disable session.upload_progress.enabled unless upload progress tracking is required, and restrict/validate multipart upload endpoints. 4. Audit applications that unserialize session data or may contain PHP object injection gadget chains; monitor for suspicious session contents. 5. Continue to monitor the NVD entry and vendor advisory for updated details or exploitation indicators.