ADVISORIES

Ubuntu CVE Tracker

UBUNTU-CVE-2026-129538

Details

PHP-CGI out-of-bounds read and write during PATH_INFO correction. The PHP CGI binary (php-cgi), in CGI and FastCGI mode with cgi.fix_pathinfo enabled (the default), can perform an out-of-bounds read and write when the path removed from SCRIPT_FILENAME or PATH_TRANSLATED is longer than the supplied PATH_INFO, or when PATH_INFO is empty. This requires a web server mapping that passes such inconsistent values, or a FastCGI listener reachable by untrusted clients. An unauthenticated remote attacker can crash the process, may obtain process memory if the application exposes PATH_INFO or PATH_TRANSLATED, and may corrupt memory. PHP-FPM and the Apache module are not affected. This issue affects PHP versions before 8.2.36, 8.3.* before 8.3.37, 8.4.* before 8.4.28 and 8.5.* before 8.5.13. This affects php-cgi in both CGI and FastCGI mode when cgi.fix_pathinfo=1, the default. PHP-FPM and PHP running as an Apache module are not affected.

Affected packages

EcosystemPackageAffected versions
Ubuntu:Pro:14.04:LTSphp5
All versions before 5.5.9+dfsg-1ubuntu4.29+esm19 (fixed in 5.5.9+dfsg-1ubuntu4.29+esm19)
Ubuntu:Pro:16.04:LTSphp7.0
All versions before 7.0.33-0ubuntu0.16.04.16+esm23 (fixed in 7.0.33-0ubuntu0.16.04.16+esm23)
Ubuntu:Pro:18.04:LTSphp7.2
All versions before 7.2.24-0ubuntu0.18.04.17+esm15 (fixed in 7.2.24-0ubuntu0.18.04.17+esm15)
Ubuntu:Pro:20.04:LTSphp7.4
All versions before 7.4.3-4ubuntu2.29+esm6 (fixed in 7.4.3-4ubuntu2.29+esm6)
Ubuntu:22.04:LTSphp8.1
All versions before 8.1.2-1ubuntu2.29 (fixed in 8.1.2-1ubuntu2.29)
Ubuntu:24.04:LTSphp8.3
All versions before 8.3.6-0ubuntu0.24.04.14 (fixed in 8.3.6-0ubuntu0.24.04.14)
Ubuntu:26.10php8.5
All versions before 8.5.9-0ubuntu2.2 (fixed in 8.5.9-0ubuntu2.2)
Ubuntu:26.04:LTSphp8.5
All versions before 8.5.4-0ubuntu1.6 (fixed in 8.5.4-0ubuntu1.6)

References