PHP maintainers have released PHP 8.5.13, a security update that closes a newly documented critical remote-code-execution path in the 8.5 branch. The project’s release archive also lists security releases for PHP 8.4.28, 8.3.37 and 8.2.36. The change matters to operators because the flaw can be reached through a web request without an account when particular runtime settings and application behavior line up.

The 8.5 advisory describes a conditional RCE

PHP’s 8.5.13 changelog lists two critical advisories tied to use-after-free errors in fatal-error backtraces. The more direct remote-code-execution report, GHSA-8mjj-2r7p-4hg2, says PHP can read freed memory while gathering arguments for a method handled by __call() or __callStatic(). Under the described conditions, a crafted request can cause a fatal error as the application enters such a method; successful exploitation can then run code with the PHP worker’s privileges.

The advisory limits its affected range to PHP 8.5.0 through versions before 8.5.13. It says the demonstrated path requires fatal-error backtraces to be enabled and exception arguments not to be ignored. Those settings matter: PHP’s production configuration sets zend.exception_ignore_args=1, which the advisory says prevents this particular path. That is not a reason to skip the update. Administrators may have different effective settings in FPM pools, virtual hosts or application overrides, and checking only a command-line PHP configuration does not establish what a web worker uses.

A second critical advisory, GHSA-2fjv-p558-g82m, documents another way a fatal-error backtrace can be recreated during worker shutdown and then reused by a later request. The advisory identifies configuration combinations involving path-specific INI overrides and says the reported entry points can corrupt memory or crash a worker; remote code execution through those specific cases has not been demonstrated. That distinction is important: “critical” is the project’s severity rating, not evidence that every PHP 8.5 server is exploitable in the same way.

Use the matching branch update

The PHP archive labels 8.4.28, 8.3.37 and 8.2.36 security releases as well, and encourages users of each branch to upgrade. The two advisories above, however, specify PHP 8.5 as their affected range. They should not be casually generalized to the older branches. Operators should install the current patch for the branch they actually run and read the corresponding vendor notice; Linux distributions and hosting providers may ship backported packages whose package numbers do not mirror upstream.

For 8.5 deployments that cannot be patched immediately, the first advisory gives temporary configuration mitigations: set zend.exception_ignore_args=1 in the configuration used by the affected workers; it also says disabling fatal_error_backtraces blocks the described path. The second advisory recommends disabling fatal-error backtraces as a temporary measure. These controls reduce specific attack paths, but the maintainers identify upgrading to 8.5.13 as the fix. Apply configuration centrally, account for pool- or path-level overrides, and restart workers so the running processes use the changed settings.

TINA’s view

This is a patch-day story with a useful caveat: a critical rating does not mean blanket exposure, but conditional exposure is still hard to rule out from a version string alone. The most actionable fact is that the confirmed remote-code-execution advisory is limited to 8.5 and depends on a combination of web-worker settings, a reachable magic-method call and a fatal error. That narrows the set of vulnerable setups without making it wise to wait. The patch is available; checking several layers of PHP configuration across a fleet can take longer than deploying it.

The evidence that would change this assessment is a maintainer or independent researcher demonstrating that the reported path is reachable under standard production defaults, or publishing a reliable inventory of the affected application patterns. For now, teams should confirm the running branch, move to its current security release, and check effective worker configuration—especially on PHP 8.5. The next signal to watch is whether PHP or major distribution vendors publish additional branch-specific advisory details for today’s other security updates.