跪拜 Guibai
← All articles
Frontend

AI Found PHP's Most Severe Vulnerabilities in a Decade in Two Days

By 公众号_计算机魔术师 ·
Read original on juejin.cn ↗ Google Translate ↗ Alt translation

Production PHP servers are exposed to unauthenticated remote code execution and cross-request credential theft, and the affected version range is so wide that roughly 60% of public-facing PHP servers are already unsupported. The two-day AI-assisted discovery also compresses the window defenders have to react: a vulnerability class that used to surface over months can now be weaponized before a patch is ready.

Summary

Two critical memory safety bugs in PHP core now have working exploit chains, and the discovery was done in two days by a Wiz Research researcher steering two AI models. CVE-2026-109618 and CVE-2026-109619 both score 9.2 on CVSS v4.0, require no authentication, and allow remote code execution. The root cause sits in PHP's custom zalloc heap allocator and its request lifecycle: OOM interruptions and fatal-error paths leave internal structures uninitialized, and subsequent requests can read leftover memory, including other sessions' tokens, API keys, and TLS private keys.

Traditional discovery for this class of bug has often taken months, and 40% of 47 critical PHP vulnerabilities disclosed between 2015 and 2020 went unnoticed for over a year. The AI-assisted workflow split the work: Gemini 4 Argon traced how external data reaches memory allocation code, GPT-5.6 Sol modeled behavior and generated PoC candidates, and a human researcher verified. Three iterations produced reproducible attack chains for both CVEs.

Because PHP still powers about 70% of active websites and PHP2Shell claims compatibility with every version from 5.4.0 onward, roughly 60% of public-facing PHP servers are already unsupported. Cloudflare shipped emergency WAF rules, Elastic and Corelight published Suricata/Zeek detections, and the PHP Foundation moved up a patch that took about two months to prepare.

Takeaways
— CVE-2026-109618 and CVE-2026-109619 are critical (CVSS v4.0 9.2) PHP core memory safety flaws that allow unauthenticated remote code execution.
— CVE-2026-109618 is triggered when an OOM interrupt during large file uploads leaves request data structures partially initialized; CVE-2026-109619 abuses leftover global state on fatal error paths.
— Sansec's analysis showed that even without session_start(), a malicious request can read other sessions' tokens, API keys, and TLS private keys from the same PHP process.
— Wiz's PHP2Shell PoC is claimed to work against PHP 5.4.0 and later; around 60% of public-facing PHP servers run versions that are no longer supported.
— The vulnerabilities stem from PHP's zalloc heap allocator reusing memory blocks across requests without zeroing references, a use-after-free pattern amplified by FPM concurrency.
— In the Wiz investigation, Gemini 4 Argon traced source-level call chains and GPT-5.6 Sol inferred behavior and generated PoC code; after three iterations, reproducible exploit chains existed for both vulnerabilities.
— Traditional discovery is slower: CVE-2018-12889 took months to find, average severe-vulnerability fixes took 3-6 weeks, and 40% of 47 critical PHP vulnerabilities from 2015-2020 took over a year to surface.
— Before the official patch, Cloudflare deployed WAF rules, Elastic and Corelight shipped Suricata/Zeek detections, and Sansec estimated mass exploitation within 15 minutes of the patch going live.
— Temporary mitigations include checking `php -v`, setting `session.upload_progress.enabled=Off`, and treating mod_php as higher risk than PHP-FPM because all Apache requests share one process.
Conclusions

AI compressed the information-gathering phase of vulnerability research from weeks to hours, but the entry point still came from a human prompt and the output needed human validation; the speedup is real, but it is not autonomy.

The same two-day discovery timeline is a warning for operators, not only a research milestone: once a serious flaw can be found and weaponized that fast, the long tail of unsupported PHP versions becomes a much larger liability.

The vulnerabilities are a product of PHP's backward-compatibility debt; memory reuse and preserved 'living fossil' session behavior made the bug class hard to find with traditional fuzzing, and the patch addresses the symptom while governance and compatibility debt remain.

A wrong prompt can send the model off on irrelevant problems, which keeps the human researcher in the loop as the one who frames the problem; AI narrows the search space, it does not define it.

The funding model for PHP core security is now the bottleneck: the PHP Foundation has a limited team, money flows from the WordPress/Drupal/Magento ecosystem are opaque, and a two-month patch cycle is too slow once AI cuts discovery time to days.

Concepts & terms
zalloc
PHP's custom heap allocator. It reuses memory blocks across the request lifecycle; if a block is freed without clearing references, later requests can read stale data.
Use-after-free (UAF)
A memory safety flaw in which a program uses memory after it has been freed, allowing an attacker to influence control flow or read remnants of other requests.
session.upload_progress
A PHP feature that records file upload progress into session data. It also serves as a controllable entry point for triggering the memory reallocation and uninitialized-state paths behind these CVEs.
PHP-FPM and mod_php
Two ways PHP runs with Apache. mod_php executes all requests in the same process, so leaked memory is visible across requests; PHP-FPM uses FastCGI and separate workers, reducing cross-request exposure.
Source: juejin.cn ↗ Google Translate ↗ Backup ↗