theadminstack / scan
CVE-2026-109618·CVE-2026-109619·CVSS v4 9.2·Unauthenticated RCE

PHP2Shell exposure check

Find out whether your PHP servers are exposed to the PHP2Shell flaws, and what to do about it. Run a local check for a definitive answer, or check a URL for a first signal.

Fixed upstream in
8.5.12 · 8.4.27 · 8.3.36 · 8.2.35
PHP 8.1 and older
No upstream fix
Exploitation
Reported in the wild
Vendor data updated
22 Oct 2026
Patching is the only fix, and php -v can mislead you.
Ubuntu, Debian and Red Hat backport the fix without changing the PHP version number. Ubuntu 24.04 stays on 8.3.6 whether it is patched or not. The package version decides, which is why the local checks read it.

Check your exposure

Three ways in. Local checks are definitive; the URL check only reads what a server says about itself.

Collect evidence on the server

Read-only scripts. They change nothing and send nothing anywhere: you copy the output yourself.

Finds CLI, PHP-FPM, LiteSpeed lsphp, cPanel EA-PHP, Remi and Plesk builds plus Apache mod_php, reads each one's package version, and works out which ones are actually in use: running processes, Apache workers with PHP loaded, cron and PATH. Run it with sudo so it can see other users' processes. Review it first.

bash
curl -fsSLO https://scan.theadminstack.com/php2shell/scripts/php2shell-check.sh
less php2shell-check.sh          # review it
sudo bash php2shell-check.sh

Paste the output

Script output works best, but you can also paste php -v, php -i, phpinfo(), rpm -q php, dpkg -l 'php*' or curl -I headers. Include /etc/os-release if you have it.

Analysed in your browser. Nothing is uploaded.

Can't patch tonight? Interim mitigations

These reduce exposure while you schedule the update. None of them replaces it, and each has a cost. The strongest option is blocking multipart/form-data, because PHP parses those bodies before your application code runs.

Generate a config snippet

Comma-separated, exact path prefixes. Every exception you add stays exposed, so keep them behind authentication and an IP allow-list.
nginx
Trade-off

What each option buys you

  • Block multipart/form-data at the edge or web server. This is the most effective interim control. It breaks file uploads and any form that posts multipart, including some checkout and contact forms.
  • Set session.upload_progress.enabled = Off. This closes the upload-progress path behind the CVE-2026-109618 memory disclosure. Advisories call it partial: it does not stop the other trigger paths.
  • Cap request size in the web server (client_max_body_size, LimitRequestBody). The trigger relies on memory exhaustion, so smaller bodies raise the bar. Chunked requests without a Content-Length are reported to bypass post_max_size, so set the limit in the web server, not only in PHP.
  • Turn off fatal_error_backtraces on PHP 8.5. Exploitation of CVE-2026-109619 was confirmed with it enabled.
  • Accept GET and HEAD only, or take PHP offline, for sites that can tolerate it. Application maintenance modes don't help: the bug triggers before the application runs.
  • Avoid memory_limit = -1, despite some advisories suggesting it. It removes a trigger but lets a single request exhaust server memory.

Were you hit? Compromise-hunting checklist

Attacks were reported before the fix shipped on 21 Oct 2026. If a server was exposed from 20 Oct onwards, work through this list even after patching. Adjust paths to your stack.

Fixed versions and vendor status

The data behind every verdict. Statuses the vendor has not published show as unconfirmed, and the tool treats them as exposed. Last updated 22 Oct 2026. Raw JSON.

Upstream fixed versions
BranchFixed inStatus
Distribution packages
DistributionPackageFixed packageStatusReference

How verdicts work

  • Upstream-versioned builds (php.net source, Windows, official Docker images, Ondřej Surý, Remi) are compared on the PHP version against 8.5.12, 8.4.27, 8.3.36 or 8.2.35. PHP 8.1 and older have no upstream fix.
  • Distro builds (Ubuntu, Debian, RHEL and its rebuilds) are compared on the package version, using Debian or RPM ordering. On AlmaLinux, Rocky and Oracle Linux, the version and leading release number are compared against Red Hat's fix.
  • Unconfirmed means the vendor has not published a fixed package for that release yet. It is never shown as safe.
  • URL checks only see a version banner, if there is one, so their verdicts are always marked indicative.

Sources