phpunit/phpunit · PHPUnit vulnerable to code execution by other local users via shared temporary directory in PHPT code coverage
Affects phpunit/phpunitSource GCVE Database
Not known to be exploited · CVSS 5.4 Medium : upgrade to 13.4.4 when convenient.
Data as of 31 Oct 2026, 02:05 UTC
Thin evidence
One scorer or none| CNA (GitHub_M) | CVSS 4.0 | 5.4 |
|---|
- Patch
- Available – fixed in 13.4.4
CVSS:4.0/AV:L/AC:L/AT:P/PR:L/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:NExploitation evidence
Disclosed: evidence found.
CVE published 29 Oct 2026
Detectable: no evidence on record.
No public nuclei template indexed
Weaponized: no evidence on record.
No public exploit code indexed in Metasploit or Exploit-DB
Exploited in the wildExploited: no evidence on record.
Not in CISA KEV and no source reports exploitation
Observed by OffSeq MirageSeen by Mirage: no evidence on record.
No attack traffic recorded by OffSeq Mirage sensors
A missing step is not evidence of safety. Sources: cve.org (opens in a new tab), the Metasploit, Exploit-DB and nuclei-templates index as of 30 Oct 2026.
What to do
Upgrade phpunit/phpunit to 13.4.4.
Affected software
| Product | Affected | Fixed in |
|---|---|---|
| Packagistphpunit/phpunit | Affected
| Fixed in
|
Check your own hosts for these packages with threat-finder (opens in a new tab), our free open-source scanner.
AI-suggested
Upgrade PHPUnit to version 13.4.4 or later, which fixes the issue by using unpredictable temporary directory names with permissions restricting access to the current user only. If upgrading is not immediately possible, avoid running PHPT tests with code coverage enabled on multi-user systems with shared temporary directories. Note that the vendor has provided an official fix in version 13.4.4.
Description
PHPUnit versions 13.4.0 through 13.4.3 have a vulnerability in their PHPT code coverage feature where temporary test files are written to a fixed directory under the system's temporary path (e.g., /tmp/phpunit-phpt). On multi-user systems with shared temporary directories, a local attacker can pre-create this directory and replace test files to execute arbitrary code with the privileges of the PHPUnit user. This attack is stealthy as the test passes and coverage reports appear normal. The issue is fixed in PHPUnit 13.4.4 by using unpredictable directory names with restricted permissions.
References
- github.com/sebastianbergmann/phpunit/security/advisories/GHSA-9vw2-f4vp-x7gf (opens in a new tab)
- nvd.nist.gov/vuln/detail/CVE-2026-119193 (opens in a new tab)
- github.com/sebastianbergmann/phpunit/commit/ae31c78a86e9d6c641497bacf47462d7bb7d7f34 (opens in a new tab)
- github.com/FriendsOfPHP/security-advisories/blob/master/phpunit/phpunit/CVE-2026-119193.yaml (opens in a new tab)
- github.com/sebastianbergmann/phpunit (opens in a new tab)
- github.com/sebastianbergmann/phpunit/releases/tag/13.4.4 (opens in a new tab)