Skip to content
PHP released the fixed versions on 21 October at 14:00 UTC. Update PHP on every server you run.CERT-EU advisory
php2shell.xyz
For defenders

Detecting PHP2Shell

Updating PHP is the only complete fix. If a server can’t be updated right away, these are the signals to watch for until it is, and what each one means.

Updated

In web-request logs

  1. 01multipart/form-data to endpoints that take no upload

    Every known trigger is a multipart/form-data request. Look into any POST with that content type to a URL that has no reason to accept a file, such as a login, an API route or the front page.

  2. 02Oversized or malformed PHPSESSID cookies

    CVE-2026-109619 can be reached through PHP’s session upload-progress handling, which is on by default and works without a call to session_start(). Wiz describes a related bug that returns memory in the session cookie. Look for unusually long or non-standard PHPSESSID values.

  3. 03Bursts of HTTP 500s or memory errors

    The attack drives PHP through an out-of-memory or fatal-error path. Clusters of 500s, out-of-memory log lines or repeated worker crashes from one client are a lead.

On the host

  1. 01A web-server process spawning a shell

    CISA advises watching for PHP worker processes that launch shells or download tools. A php-fpm, php-cgi, httpd or apache2 process that spawns sh, bash, python, curl or wget is the clearest sign that the flaw was exploited.

  2. 02Workers restarting or crashing without cause

    The flaw corrupts a worker’s state, so investigate unexplained PHP-FPM or application-server worker restarts, segfaults or OPcache resets.

A rough process-tree check for unexpected child processes of the web server:

ps -eo ppid,pid,comm,args | grep -E "php-fpm|php-cgi|httpd|apache2" \
  | grep -E "sh|bash|python|curl|wget|nc "

If you find something

Treat it as a full compromise. This flaw allows remote code execution, so after a confirmed hit the whole server should be considered breached. Isolate the host and preserve the web-server and PHP-FPM logs before they rotate. Amazon’s MadPot network logged the earliest known exploitation attempt on 17 October, so review logs back to at least that date. Rebuild from a known-good state instead of cleaning the server in place. Then update to a fixed PHP version before anything goes back online.

Sources