CVE-2026-41570
PHPUnit: Argument injection via newline in PHP INI values forwarded to child processes
Also known as GHSA-qrr6-mg7r-m243
Mitigation
- Upgrade phpunit/phpunit to one of 12.5.22, 13.1.6 (or later in the same release line).
Who should check
- Projects that depend on Packagist package phpunit/phpunit (>= 12.5.21, < 12.5.22)
- Anyone running sebastianbergmann phpunit = 12.5.21; = 13.1.5
Vulnerability facts
- Affected
- phpunit/phpunit >= 12.5.21, < 12.5.22
- Fixed in
- 12.5.22, 13.1.6
- Exploited in the wild
- Not in CISA KEV
- Public exploit / PoC
- None known
- Remote exploitation
- Not remotely exploitable (local or adjacent access needed)
- CVSS
- 7.8 (v3.1, CNA)CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:HOpen in CVSS calculator
Show all 8 CVSS metrics
- Attack vector: Local
- Attack complexity: Low
- Privileges required: Low
- User interaction: None
- Scope: Unchanged
- Confidentiality impact: High
- Integrity impact: High
- Availability impact: High
- EPSS
- 0.28% chance of exploitation in 30 days (percentile 13, 2026-11-26)
- CWE
- CWE-93, CWE-88
- Modified
Description
PHPUnit is a testing framework for PHP. In versions 12.5.21 and 13.1.5, PHPUnit forwards PHP INI settings to child processes (used for isolated/PHPT test execution) as -d name=value command-line arguments without neutralizing INI metacharacters. Because PHP's INI parser interprets " as a string delimiter, ; as the start of a comment, and most importantly a newline as a directive separator, a value containing a newline is parsed by the child process as multiple INI directives. An attacker able to influence a single INI value can therefore inject arbitrary additional directives into the child's configuration, including auto_prepend_file, extension, disable_functions, open_basedir, and others. Setting auto_prepend_file to an attacker-controlled path yields remote code execution in the child process. This issue has been patched in versions 12.5.22 and 13.1.6.
Affected and fixed versions
| Package / product | Affected | Fixed | Source |
|---|---|---|---|
| Packagist phpunit/phpunit | >= 12.5.21, < 12.5.22 | 12.5.22, 13.1.6 | osv |
| sebastianbergmann phpunit | = 12.5.21; = 13.1.5 | — | cvelist |
Check your systems with an agent
Paste this into Claude Code, Cursor or another coding agent. It only reads; it changes nothing.
Check whether anything I run is affected by CVE-2026-41570. Work read-only: do not install, upgrade, delete or change anything. Details: https://flawdb.com/CVE-2026-41570.md Affected: phpunit/phpunit >= 12.5.21, < 12.5.22 Fixed in: 12.5.22, 13.1.6 Steps: 1. Search this machine and project for phpunit/phpunit (Packagist), sebastianbergmann phpunit: dependency manifests and lockfiles, installed packages, container images and running services. 2. For each match, note the installed version and whether it is inside the affected range. 3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
References
Vendor advisories
FAQ
Is CVE-2026-41570 being exploited?
There is no confirmed exploitation: CVE-2026-41570 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.28% chance of exploitation in the next 30 days (as of 2026-11-26).
How serious is CVE-2026-41570?
High: CVSS 7.8 (v3.1, scored by CNA). Not remotely exploitable (local or adjacent access needed).
Which versions are affected by CVE-2026-41570?
phpunit/phpunit >= 12.5.21, < 12.5.22.
Is there a fix for CVE-2026-41570?
Yes. Fixed in 12.5.22, 13.1.6. Upgrade phpunit/phpunit to one of 12.5.22, 13.1.6 (or later in the same release line).
How do I check if I'm affected by CVE-2026-41570?
Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.