7.8

CVE-2026-24765: PHPUnit Vulnerable to Unsafe Deserialization in PHPT Code Coverage Handling

Analyzed
AliasesUBUNTU-CVE-2026-24765DEBIAN-CVE-2026-24765DLA-4470-1
Published 27-01-2026Last modified 06-02-2026

Vulnerability summary

CVE-2026-24765 is a high (CVSS 7.8) Deserialization of Untrusted Data vulnerability in debian debian_linux. EPSS estimates a 0.38% chance of exploitation in the next 30 days, higher than 34.6% of scored vulnerabilities.

Priority
Routine

Not severe (CVSS 7.8, local access); no exploitation reported by the 5 checked sources

Source freshness unavailable

How is this decided?
CVSS score
7.8/10
010
High · v3.1 (CVE.org)
EPSS score
0.38%
0%100%
Low · 0.00 pp in 30 days
KEVNot listedNot listed by any tracked catalog.
RansomwareNot flaggedNo ransomware use recorded.
Public exploits0No public exploits recorded

Timeline

  1. 27-01-2026
    PublishedVulnerability first disclosed.
  2. 06-02-2026
    Last modifiedVulnerability information updated.

Description

PHPUnit is a testing framework for PHP. A vulnerability has been discovered in versions prior to 12.5.8, 11.5.50, 10.5.62, 9.6.33, and 8.5.52 involving unsafe deserialization of code coverage data in PHPT test execution. The vulnerability exists in the `cleanupForCoverage()` method, which deserializes code coverage files without validation, potentially allowing remote code execution if malicious `.coverage` files are present prior to the execution of the PHPT test. The vulnerability occurs when a `.coverage` file, which should not exist before test execution, is deserialized without the `allowed_classes` parameter restriction. An attacker with local file write access can place a malicious serialized object with a `__wakeup()` method into the file system, leading to arbitrary code execution during test runs with code coverage instrumentation enabled. This vulnerability requires local file write access to the location where PHPUnit stores or expects code coverage files for PHPT tests. This can occur through CI/CD pipeline attacks, the local development environment, and/or compromised dependencies. Rather than just silently sanitizing the input via `['allowed_classes' => false]`, the maintainer has chosen to make the anomalous state explicit by treating pre-existing `.coverage` files for PHPT tests as an error condition. Starting in versions in versions 12.5.8, 11.5.50, 10.5.62, 9.6.33, when a `.coverage` file is detected for a PHPT test prior to execution, PHPUnit will emit a clear error message identifying the anomalous state. Organizations can reduce the effective risk of this vulnerability through proper CI/CD configuration, including ephemeral runners, code review enforcement, branch protection, artifact isolation, and access control.

CVSS metrics

4 scores · 4 sources · 1 version

EPSS trend

Probability

0.38%

Chance of exploitation in the next 30 days

Percentile

35%

Versus all other CVEs

30-day change

No change 0.00 pp

From 0.38% on 04-11-2026

04-11-202604-12-2026

Known exploited

Compare KEV catalogs
CISA KEV

Not in the CISA KEV catalog.

ENISA CNW

Not in the ENISA CNW catalog.

CIRCL

Not in the CIRCL catalog.

Public exploits

0 found

No public exploits indexed.

Weaknesses

CWE · root cause

Affected systems

Version check

Known conditions: local access, low-privilege account, no user interaction (CVSS vector). Other conditions: not stated in public data.

Debian2 products
  • phpunit< 9.6.7-1+deb12u1 | < 11.5.19-1+deb13u1 | < 12.5.8-1 | < 9.5.2-1+deb11u1
  • debian_linuxEOL11.0
Phpunit_project1 product
  • phpunit< 8.5.52 | ≥ 9.0.0, < 9.6.33 | ≥ 10.0.0, < 10.5.62 | ≥ 11.0.0, < 11.5.50 | ≥ 12.0.0, < 12.5.8
Sebastianbergmann1 product
  • phpunit< 8.5.52 | ≥ 9.0.0, < 9.6.33 | ≥ 10.0.0, < 10.5.62 | ≥ 11.0.0, < 11.5.50 | ≥ 12.0.0, < 12.5.8
Ubuntu1 product
  • phpunitAll versions (No fix recorded) | < 6.5.5-1ubuntu2+esm1 | < 8.5.2-1ubuntu1+esm1 | < 9.5.10-1ubuntu2+esm1 | < 9.6.17-1ubuntu0.1~esm1

4 vendors · 5 products

References

12 links
Show all 12 references