Unauthenticated code execution via request-body evaluation
Published Jun 27, 2017 · Updated Oct 21, 2025
Code injection in PHPUnit's eval-stdin.php allows remote attackers to execute arbitrary PHP code via crafted HTTP POST data. In PHPUnit 4.8.19 through 4.8.27 and 5.0.10 through 5.6.2, the script reads php://input and passes the request body directly to eval, executing content beginning with a PHP opening tag. Exploitation requires HTTP access to the script, usually through an exposed vendor directory, and executes code with the PHP process's permissions.
Summary
What happened
Code injection in PHPUnit's eval-stdin.php allows remote attackers to execute arbitrary PHP code via crafted HTTP POST data. In PHPUnit 4.8.19 through 4.8.27 and 5.0.10 through 5.6.2, the script reads php://input and passes the request body directly to eval, executing content beginning with a PHP opening tag. Exploitation requires HTTP access to the script, usually through an exposed vendor directory, and executes code with the PHP process's permissions.
The record
- CVE
- CVE-2017-9841
- Published
- Jun 27, 2017
- Updated
- Oct 21, 2025
- Vendor
- Sebastian Bergmann
- Product
- PHPUnit
- Classifications
- CWE-94, T1190
- Attack vector
- network
- Privileges
- unauthenticated
Timeline
How it unfolded
- Jun 27, 2017CVE publishedPublication date reported by the CVE source.
- Oct 21, 2025Record updatedLatest update available in the CVE record.
Exploitability
Present is not the same as exploitable
Compare your product and version with the public record. A matching version still requires validation against your environment.
Is a vulnerable build present?
Compare these published version ranges with your installed build and any vendor patches.
- Affected versionversion=n/a
What conditions does exploitation require?
What is affected?
Published CVSS scores
CVSS describes severity. EPSS estimates exploitation probability.
Attacks
What attackers are doing with it
Daily unique IPs observed by Shadowserver honeypots for known exploited vulnerabilities (KEVs). Missing observations do not establish an absence of attacks.
Activity data is delayed. The latest report is Sep 28, 2026.
View daily counts
| Reporting day | Unique IPs |
|---|---|
| Sep 22, 2026 | 208 |
| Sep 23, 2026 | 178 |
| Sep 24, 2026 | 180 |
| Sep 25, 2026 | 169 |
| Sep 26, 2026 | 178 |
| Sep 27, 2026 | 198 |
| Sep 28, 2026 | 201 |
Weakness, pattern, technique
Public exploit references
- Maintainer HTTP POST reproductionproof of concept · demonstrated
- Nuclei CVE-2017-9841 execution probeproof of concept · unverified
- phpunit-bruteproof of concept · unverified
Labels summarize the accepted research assessment. They do not indicate a test against your environment.
Reported exploitation
- Androxgh0st-associated exploitationreported exploitation
- CISA Known Exploited Vulnerabilities listingknown exploited catalog
Technologies
Your stack
See the directory against your own environment.
Your stack
Check the software in your environment
Get started to see how Hinoki identifies affected software and validates exploitability in your environment.
Contact us