The short version
- The flaw. WordPress fixed a critical unauthenticated path traversal bug in its core software, tracked as CVE-2026-87902 and rated 9.2 under the CVSS severity system. Every version from 4.7.0 through 7.1.1 is affected, and fixes were backported down to 4.7.37.
- The exploitation. Patchstack saw the first malicious requests at 17:44 UTC on 22 September, under five hours after the patch shipped. Initial traffic looked like reconnaissance; by 23 September it had risen tenfold and included attempts to write PHP files to disk.
- Conditions for code execution. Running attacker-chosen code also needs a theme with a top-level folder whose name begins with page-, a readable local PHP file, and, in the technique observed, PHP's register_argc_argv setting enabled. Not every affected site reaches that worst case.
- What to do. Site owners should update to 7.1.2, or the corresponding release for their branch, review logs for malicious activity, and add the three IP addresses Patchstack published to a blocklist.
Timeline
| Date | Event |
|---|---|
| July | Robert Ressl reports the flaw privately through WordPress's HackerOne programme. |
| 17 September | WordPress ships a security release, 7.1.1, that does not fix this flaw. |
| 22 September | WordPress releases 7.1.2 with the fix, backported to older supported branches. |
| 22 September, 17:44 UTC | Patchstack records the first malicious requests targeting the flaw. |
| 23 September | Attack traffic rises tenfold and begins writing files to disk, according to Patchstack. |
How the flaw works
WordPress builds the template file name for a page partly from the web address. On affected versions it did not run that value through the ../ traversal check that neighbouring code already used, so an unauthenticated attacker could make a site include a readable local PHP file from outside the active theme directories.
The file name is built as page-{value}.php, so an attack also needs the active theme to have a top-level folder whose name starts with page-, and a target file that ends in .php and can be read by the web server account. The WordPress advisory gives pearcmd.php as the example when PHP's register_argc_argv setting is active.
WordPress credited Robert Ressl with finding the flaw; he disclosed it privately in July and published a write-up, a proof-of-concept and a test lab when the fix shipped. His demonstration ran code with web-server privileges and was tested against WordPress 7.0.2 in isolated local labs, not against live sites.
Exploitation within hours
Patchstack says the first malicious requests came at 17:44 UTC on 22 September from a small group of IP addresses and hit multiple sites under its protection. The earliest traffic tried to include ordinary WordPress core files, which the firm reads as an attempt to identify vulnerable hosts.
A day later the volume had grown tenfold and included a stage that writes files to disk. Patchstack says one variant switches pearcmd from config-show to config-create so the tool writes a file with attacker-supplied content. Some payloads only left a marker confirming a host was exploitable; others wrote a tag that runs a shell command when the file is accessed.
The files were delivered to /tmp and /var/tmp under names including wp-pear-rce-flag.php, poc87902.php, luci_<random>.php and zeta_<random>.php. Patchstack says the probes used double-encoded traversal sequences in the 'pagename' parameter alongside a valid 'page_id', and published the source addresses 169.58.48.193, 169.58.48.195 and 2001:df1:e8c0::106b.
Who is exposed
All versions from 4.7.0 to 7.1.1 carry the flaw, including 7.1.1 from 17 September, so a site patched days earlier still needs this release. WordPress backported the fix to every branch it still supports, down to 4.7.37; releases before 4.6 will not receive one. Sites with automatic background updates will install it themselves.
The WordPress advisory says the official PHP Docker image is affected, as is a default cPanel configuration running a PHP version before 8.5. WordPress offers no separate workaround, so updating is the fix. The article published on 22 September said there were then no reports of the flaw being used in attacks and no entry in CISA's Known Exploited Vulnerabilities catalogue; Patchstack's first observed requests were logged at 17:44 UTC that same day.
What is not known yet
- Who is behind the exploitation, and whether the activity comes from one group or several.
- How many sites were probed, and how many were successfully compromised.
- Whether any attacker progressed beyond writing marker or shell-tag files to full code execution on a live site.
- Whether any site was exploited before the patch was released on 22 September.
- What the attackers intend to do with any access they obtained.
What to do
If you run WordPress
- Update to 7.1.2, or the corresponding release for your branch listed in WordPress's release notes.
- Search web-server logs for requests from 169.58.48.193, 169.58.48.195 and 2001:df1:e8c0::106b and for double-encoded traversal sequences in the 'pagename' parameter, then block those addresses.
- Check /tmp and /var/tmp for files named wp-pear-rce-flag.php, poc87902.php, luci_<random>.php or zeta_<random>.php and treat any you find as a sign of compromise.
If you cannot update immediately
- Turn off register_argc_argv for web requests.
- Remove unused PEAR components from the server.
- Treat both measures as reducing exposure only: neither repairs the underlying flaw.
For everyone else
- Assume that a published patch for internet-facing software will be probed within hours, and watch logs closely in the days after a disclosure.
Update log
- First published.
Sources
New incident reports by email
One email a week with the reports published since the last one.