How AI Helped Find Critical PHP Vulnerabilities — and How to Protect Your Website
PHP2Shell: Two critical remote code execution vulnerabilities in the PHP runtime, and a practical step-by-step guide to securing your website.
AI-assisted security research has helped uncover two critical vulnerabilities in PHP — the software that powers many websites and web applications.
Known together as PHP2Shell, the vulnerabilities are tracked as CVE-2026-109618 and CVE-2026-109619. They can allow unauthenticated remote code execution in affected environments — meaning an attacker may be able to run code on a server without first logging in. Security fixes became available on 21 October 2026.
For website owners, the priority is clear: patch the PHP runtime, ensure the updated software is running, and verify the result. Updating a website's content, themes, or plugins is not a substitute for fixing the underlying PHP vulnerability.
What Is PHP2Shell?
PHP2Shell is the name used for two critical vulnerabilities in the PHP runtime. Ubuntu's security guidance assigns both vulnerabilities a CVSS 4.0 score of 9.2, placing them in the critical severity category.
Because the flaws affect PHP itself, the risk is not limited to one content-management system or one poorly written application. Wiz Research demonstrated attack scenarios involving WordPress, Drupal, and Joomla, illustrating how vulnerabilities in a shared software component can affect different applications built on top of it.
The researchers also describe potential exposure of sensitive information held in PHP worker memory, including passwords, tokens, and API keys. These findings demonstrate what the vulnerabilities can enable; they do not establish that every affected website has been compromised.
How Did AI Help Researchers Discover the Problem?
According to Wiz Research, AI tools supported vulnerability discovery, exploit development, debugging, and patch validation. Its account describes researchers using AI to work through complex memory-safety problems and adapt testing to different applications and configurations.
This was not simply a case of an autonomous AI finding and resolving a security issue on its own. Human researchers investigated the findings, worked with the PHP security team and other organizations, and coordinated disclosure and remediation. The research involved collaboration among PHP, Wiz, Calif, and OpenAI.
Key Distinction
AI assisted the technical work, while people remained responsible for validating the results and coordinating the response.
Does This Mean "70% of the Internet" Was Hacked?
No. Wiz's headline refers to PHP's reported prevalence across websites, not a measured number of successful attacks. The proportion of websites using a technology is different from the number exposed in a particular configuration — and different again from the number actually compromised.
The responsible conclusion is that vulnerabilities in widely used infrastructure can create broad potential exposure. It would be inaccurate to turn that into a claim that most websites were hacked.
How to Protect Your Website: A Step-by-Step Guide
The following steps address PHP2Shell specifically. They do not guarantee that a website is free of every security problem or establish that it was not compromised before the update.
Identify All PHP Environments
Ask your hosting provider or technical administrator to identify every PHP deployment associated with your business.
Include:
Cloud-provider guidance recommends updating all affected PHP deployments, with internet-facing systems taking priority. Checking only the main website may leave other exposed services unaddressed.
Confirm Whether Your PHP Build Is Fixed
The following upstream PHP releases contain the PHP2Shell fixes:
| PHP Branch | First Fixed Upstream Release |
|---|---|
| PHP 8.5 | 8.5.12 |
| PHP 8.4 | 8.4.27 |
| PHP 8.3 | 8.3.36 |
| PHP 8.2 | 8.2.35 |
AWS and Google Cloud identify these as fixed releases. Use the appropriate fixed release or a later security-maintained release in the relevant branch.
However, version checking requires care. Operating-system vendors may backport a security fix into their own PHP packages without using the same upstream release number. Ubuntu, for example, lists distribution-specific fixed package versions in its security notice. Your administrator should check the complete installed package version against the relevant vendor advisory.
Arrange the Security Update
If your website uses managed hosting, ask the hosting provider to confirm whether it has applied the fixes. Do not assume that an update has happened automatically.
If you manage your own server, follow the security instructions from your operating-system or platform vendor.
For containerized applications, update the PHP runtime in the container image, rebuild it, and redeploy the application. Updating the host operating system alone does not update the PHP software inside an existing container image.
As an operational precaution, confirm that you have a recent, restorable backup and check application compatibility before changing PHP branches. Keep this preparation proportionate to the urgency rather than delaying a critical security update for a broader redesign or migration.
Restart or Replace Affected Processes
Installing the update is not necessarily the final step. Existing PHP processes may continue running the old software until they are restarted or replaced.
Depending on the environment, your administrator may need to restart PHP-FPM, Apache, or other long-running PHP workers. The relevant service must then be checked to confirm that it is using the patched build.
For managed hosting, request confirmation that the provider has both installed the fix and restarted the affected services.
Verify the Runtime Serving the Live Website
The version used by the live website matters. A command-line PHP installation may not be the same runtime that handles web requests. The University of Toronto's advisory recommends verifying the version reported by the running service after restarting it.
For a practical remediation record, document:
| Item | Evidence to Record |
|---|---|
| Website or application | Domain, service name, or environment |
| Active PHP build | Complete runtime or package version |
| Fix confirmation | Applicable vendor security advisory |
| Deployment completion | Date and time of update and restart |
| Verification | Person or provider who checked the running service |
| Outstanding actions | Any remaining exposure or investigation |
Also test important website functions after the change:
Functional testing helps identify disruption caused by the update; it does not, by itself, prove that the security fix is active.
Use Temporary Protections Where Necessary
If immediate patching is not possible, contact your hosting or security provider about temporary controls. AWS, Microsoft Azure, and Cloudflare have published PHP2Shell mitigation guidance. Their guidance distinguishes firewall-based protection from complete remediation through updating PHP.
Depending on your environment, temporary measures may include:
Cloudflare notes that restricting unnecessary uploads and limiting upload sizes may reduce exposure, but these measures do not replace the PHP update. Use platform-specific guidance rather than copying unverified server settings from forums or social media.
Check for Signs of Earlier Compromise
Patching addresses the vulnerability. It does not prove that an attacker did not exploit it beforehand.
The University of Toronto's advisory recommends treating internet-facing systems that remained unpatched from 20 October onward as potentially compromised until checked. This is a precautionary recommendation, not confirmation that every such system was attacked.
Ask your administrator or security specialist to assess relevant logs and investigate suspicious activity. If compromise is suspected, preserve evidence and follow an incident-response process rather than assuming that installing the update has resolved the whole incident.
A Message You Can Send to Your Hosting Provider
Subject: Please confirm PHP2Shell remediation for our website
Please confirm whether our website and associated hosting environments are affected by PHP2Shell, CVE-2026-109618 and CVE-2026-109619.
Please provide:
Please confirm when remediation was completed and identify any action still required from us.
When Can You Mark the Remediation as Complete?
Look for evidence that every affected deployment is running a vendor-confirmed fixed build, the relevant processes have been restarted or replaced, and the active runtime has been verified. Temporary firewall protection should not be recorded as equivalent to patching. Any investigation into possible earlier compromise should also be tracked separately.
PHP2Shell illustrates how AI can contribute to security research, but the practical response still depends on disciplined operational work: identify affected systems, apply trusted updates, verify deployment, and investigate where necessary.
Source Basis
This article draws on the original Wiz Research disclosure, Ubuntu security guidance, and remediation advisories from AWS, Google Cloud, Microsoft Azure, Cloudflare, and the University of Toronto. The citations throughout identify the sources supporting the relevant claims.
Disclaimer
This article provides general information, not an assessment of a particular website. Follow the current guidance from your hosting provider, software vendor, or qualified security professional for your own environment.
At Engaged Echo, we help organisations audit their infrastructure, apply security updates, and verify their systems are protected.
Whether you need help identifying affected PHP environments, coordinating with your hosting provider, or verifying that your live website is running a patched build, our team can guide you through every step.
Request Security Audit