Skip to content

CVE-2017-9841 in PHPUnit

PHPUnit 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.

CISA listing

Vendor
PHPUnit
Product
PHPUnit
CISA name
PHPUnit Command Injection Vulnerability
Listed by CISA
2022-02-15
Ransomware use
Not known to be used in ransomware campaigns
EPSS
100.0% as of 2026-11-18

What the probe looks like in your access log

Sample access log line. Demo data.

203.0.113.7 - - [19/Nov/2026:09:14:02 +0000] "GET /vendor/phpunit/phpunit/util/php/eval-stdin.php HTTP/1.1" 404 153

Search your log for the method and path

grep -Fi '"GET /vendor/phpunit/phpunit/util/php/eval-stdin.php' access.log

Sample access log line. Demo data.

203.0.113.7 - - [19/Nov/2026:09:14:02 +0000] "GET /vendor/phpunit/src/util/php/eval-stdin.php HTTP/1.1" 404 153

Search your log for the method and path

grep -Fi '"GET /vendor/phpunit/src/util/php/eval-stdin.php' access.log

Sample access log line. Demo data.

203.0.113.7 - - [19/Nov/2026:09:14:02 +0000] "GET /vendor/phpunit/util/php/eval-stdin.php HTTP/1.1" 404 153

Search your log for the method and path

grep -Fi '"GET /vendor/phpunit/util/php/eval-stdin.php' access.log

Patch the CVE. camada finds and blocks the clients probing for it, from the next review on. If you run PHPUnit, requests to this path can be normal, so check your version against the advisory.

Check your own log for these probes in your browser.