Deserialization of Untrusted Data in PHPUnit - CVE-2026-24765
Published: April 17, 2026
Vulnerability details
The vulnerability allows a local user to execute arbitrary code.
The vulnerability exists due to deserialization of untrusted data in the cleanupForCoverage() method of the PHPT test runner when processing a pre-existing .coverage file during PHPT test execution with code coverage instrumentation enabled. A local user can place a malicious serialized object in a .coverage file to execute arbitrary code.
The issue is triggered only if a .coverage file is present before test execution.
Affected software
Moodle
Fedora
phpunit11
phpunit12
How to mitigate CVE-2026-24765
Moodle - update to 4.5.11
phpunit11 - addressed in versions 11.5.50-1.fc42, 11.5.50-1.fc43
phpunit12 - addressed in versions 12.5.8-1.fc42, 12.5.8-1.fc43