phpunit/phpunit vulnerabilities

The PHP Unit Testing framework.

Registry
Composer
Latest
13.4.6
License
BSD-3-Clause

5 known advisories

The latest version, 13.4.6, is not affected by any of them. Projects on older versions may be.

Update to the latest version:composer require phpunit/phpunit:^13.4.6

Is your project on an affected phpunit/phpunit?

Private repo? Upload its lockfile instead, or connect GitHub to check every repo.

Look after several Laravel or PHP apps? Indie watches up to 15 repos, private ones too, for $5 a month. See Indie

Security advisories for phpunit/phpunit

  • MediumCVE-2026-119193GHSA-9vw2-f4vp-x7gf30 Oct 2026

    PHPUnit vulnerable to code execution by other local users via shared temporary directory in PHPT code coverage handling

    Affected
    >=13.4.0 <13.4.4
    Fixed in
    13.4.4
  • HighGHSA-mh6w-vxff-9wqp22 Apr 2026

    PHPUnit: Argument injection via newline in PHP INI values forwarded to child processes

    Affected
    >=12.5.21 <12.5.22 · >=13.1.5 <13.1.6
    Fixed in
    12.5.22, 13.1.6
  • HighCVE-2026-41570GHSA-qrr6-mg7r-m24318 Apr 2026

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

    Affected
    >=12.5.21 <12.5.22 · >=13.1.5 <13.1.6
    Fixed in
    12.5.22, 13.1.6
  • HighCVE-2026-24765GHSA-vvj3-c3rp-c85p27 Jan 2026

    PHPUnit Vulnerable to Unsafe Deserialization in PHPT Code Coverage Handling

    Affected
    <8.5.52 · >=9.0.0 <9.6.33 · >=10.0.0 <10.5.62 · >=11.0.0 <11.5.50 · >=12.0.0 <12.5.8
    Fixed in
    8.5.52, 9.6.33, 10.5.62, 11.5.50, 12.5.8
  • CriticalCVE-2017-9841GHSA-r7c9-c69m-rph826 Mar 2022

    Code Injection in PHPUnit

    Affected
    >=4.8.19 <4.8.28 · >=5.0.10 <5.6.3
    Fixed in
    4.8.28, 5.6.3

Is your phpunit/phpunit version vulnerable?

Which of your client projects still run an old phpunit/phpunit?

NPMscan reads the composer.lock in every GitHub repo you pick and checks each installed version against these advisories, including the packages your packages pull in. Each finding comes with the command that fixes it.

Other Composer packages

Advisory data from OSV.dev (opens OSV.dev in a new tab), refreshed daily. Package details from the Composer registry.