KeygraphLabs · CVE MCP

CVE-2017-9841 · mitre

CVE-2017-9841

Util/PHP/eval-stdin.php in PHPUnit before 4.8.28 and 5.x before 5.6.3 allows remote attackers to execute arbitrary PHP code via HTTP POST data beginning with a "<?php " substring, as demonstrated by an attack on a site with an exposed /vendor folder, i.e., external access to the /vendor/phpunit/phpunit/src/Util/PHP/eval-stdin.php URI.

Published 2017-06-27, last changed 2026-06-17. Weakness: CWE-94.

CVSS
9.8
critical, from NVD
EPSS
100.0%
percentile 100.0%, chance of exploitation in 30 days
Exploitation
In CISA KEV
exploited in the wild, added 2022-02-15

CISA KEV

PHPUnit Command Injection Vulnerability. Added 2022-02-15, federal due date 2022-08-15, ransomware use: Unknown.

Public exploits

SourceKindReference
exploit-dbproof-of-conceptEDB-50702
nucleiscan-templateCVE-2017-9841

How to fix

Upgrade to a fixed version: phpunit/phpunit 4.8.28, 5.6.3 (Packagist) (each is the fix for its own release line). For the version that clears every advisory for your installed version, ask an agent for get_remediation.

Where the flaw is in the code

Fixed in sebastianbergmann/phpunit by 284a69fb88, pull request #1956. Functions changed by the fix: runJob. Confidence: verified (a record names this commit as the fix, and it changed these functions).

Timeline

2017-06-27Published
2022-02-15Added to CISA KEV: exploited in the wild
2022-03-26Package advisory GHSA-r7c9-c69m-rph8
2022-08-15CISA KEV due date for US federal agencies
2026-06-17Record last changed
2026-11-30EPSS when our history starts: 100.0%
2026-11-30Code-level analysis added

Affected packages

AdvisoryPackageFixed in
GHSA-r7c9-c69m-rph8phpunit/phpunit (Packagist)4.8.28
GHSA-r7c9-c69m-rph8phpunit/phpunit (Packagist)5.6.3

Also known as: GHSA-r7c9-c69m-rph8

Related

CVEPublishedCVSSSummary
CVE-2026-1191932026-10-295.4PHPUnit vulnerable to code execution by other local users via shared temporary directory in PHPT code coverage handling
CVE-2026-415702026-05-087.8PHPUnit: Argument injection via newline in PHP INI values forwarded to child processes
CVE-2026-247652026-01-277.8PHPUnit Vulnerable to Unsafe Deserialization in PHPT Code Coverage Handling
CVE-2026-518322026-10-297.8same weakness (CWE-94) from the same CNA (mitre)
CVE-2026-518312026-10-297.8same weakness (CWE-94) from the same CNA (mitre)
CVE-2026-1070502026-10-299.8same weakness (CWE-94) from the same CNA (mitre)
CVE-2026-788452026-10-279.8same weakness (CWE-94) from the same CNA (mitre)
CVE-2026-1070912026-10-267.8same weakness (CWE-94) from the same CNA (mitre)

Add it to your agent

One command for Claude Code; setup for Claude Desktop, Cursor and others. No signup or key.

claude mcp add --transport http keygraph-cve https://cve-mcp.keygraph.io/mcp

Then ask for triage_cve CVE-2017-9841, or call /api/v1/vulnerabilities/CVE-2017-9841. To prove whether it is exploitable in your running app, run Shannon, Keygraph's open-source AI pentester.

NVD · CVE.org