# PHPUnit has Argument injection via newline in PHP INI values that are forwarded to child processes

Advisory record · `GHSA-qrr6-mg7r-m243`

- **Identifiers:** `GHSA-qrr6-mg7r-m243` · `CVE-2026-41570` · `PKSA-5jz8-6tcw-pbk4`
- **State:** Confirmed
- **Severity:** CVSS 7.8 High
- **Critical:** No
- **Weakness (CWE):** [CWE-88](https://cwe.mitre.org/data/definitions/88.html) · [CWE-93](https://cwe.mitre.org/data/definitions/93.html)
- **Tags:** [Command injection](https://agentprime.io/advisories/tag/command-injection.md) · [Other injection](https://agentprime.io/advisories/tag/injection.md)
- **Published:** 18 Apr 2026
- **Updated:** 12 May 2026
- **Reviewed by a person:** No

Published by the GitHub Advisory Database at 18 Apr 2026, 00:59 UTC. agentprime has not analysed this yet, so whether it affects any app is not known.

## Affected packages

- `phpunit/phpunit` (Packagist): affected `>=12.5.21, <12.5.22 || >=13.1.5, <13.1.6`; fixed in `12.5.22`, `13.1.6`

## Machine-written summary

Summary written by Claude Haiku from the source advisory. Not reviewed by a person.

> PHPUnit versions 12.5.21 before 12.5.22 and 13.1.5 before 13.1.6 forward INI values to child processes without neutralizing newlines, so a value with an embedded newline can inject extra INI directives such as auto_prepend_file. An attacker must be able to control an INI value PHPUnit reads, such as in phpunit.xml, the host php.ini, or the PHP environment, which in practice means a crafted pull request in CI; the impact could be remote code execution in the child process. Upgrade to phpunit/phpunit 12.5.22 or 13.1.6.

Written 3 Nov 2026.

## Not analysed yet

We haven’t published our analysis of this Advisory yet. Once a person has reviewed it, this page will say what’s vulnerable, what has to be true for your app to be affected, and how to check.

## Severity and exploitation

- 7.8 High, CVSS 3.1: `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`, from CNA (GitHub_M)

- **CISA KEV:** Not listed.
- **EPSS:** 0.0019, the 8th percentile, on 14 Nov 2026: FIRST’s estimate of the chance of exploitation in the next 30 days.

## Timeline

- 31 Oct 2026, 14:25 UTC: First seen by agentprime
- 31 Oct 2026, 14:25 UTC: [Confirmed by OSV](https://osv.dev/vulnerability/GHSA-qrr6-mg7r-m243)

## Sources

- [GitHub Advisory Database: GHSA-qrr6-mg7r-m243](https://github.com/advisories/GHSA-qrr6-mg7r-m243)
- [OSV: GHSA-qrr6-mg7r-m243](https://osv.dev/vulnerability/GHSA-qrr6-mg7r-m243)
- <https://github.com/sebastianbergmann/phpunit/security/advisories/GHSA-qrr6-mg7r-m243>
- <https://nvd.nist.gov/vuln/detail/CVE-2026-41570>
- <https://github.com/sebastianbergmann/phpunit/pull/6592>
- <https://github.com/FriendsOfPHP/security-advisories/blob/master/phpunit/phpunit/CVE-2026-41570.yaml>
- <https://github.com/sebastianbergmann/phpunit>

Facts on this page come from the GitHub Advisory Database (CC-BY 4.0), OSV and the other sources listed, as published. We don’t reproduce full advisory descriptions, which can contain exploit code.

## Check whether this affects you

A Match means an installed version is in the affected range above. Most don’t affect the app; agentprime hasn’t analysed this one yet.

- With the agentprime MCP server (<https://api.agentprime.io/mcp>), ask your agent to check the project: `check_lockfile` sends a lockfile, `check_packages` a list of installed packages, and both return the Matches and the upgrades that clear them. `get_advisory` returns this record. Setup: <https://agentprime.io/mcp.md>
- In a browser: <https://agentprime.io/check/> reads your lockfile in the browser, never uploading it.
- Whether it touches your code, with file and line: the Claude Code plugin, <https://agentprime.io/plugin.md>
- As JSON: <https://api.agentprime.io/v1/advisories/GHSA-qrr6-mg7r-m243>, or `POST https://api.agentprime.io/v1/match` with your packages (<https://agentprime.io/api.md>)

---

The web page: <https://agentprime.io/advisories/GHSA-qrr6-mg7r-m243/>. Everything for agents: <https://agentprime.io/llms.txt>.
