For years the advice was “update when you get a chance”. In 2026 that advice stopped working. When WordPress fixed a critical core vulnerability on 22 September, attackers were testing sites for it before many site owners had read the release notes.

What happened

The flaw, tracked as CVE-2026-87902, is a path traversal bug in the way WordPress resolves page templates. In the right conditions it lets an attacker include files from the server and, from there, run their own code without logging in. Patchstack rates it 9.2 out of 10 (critical).

It affects every WordPress version from 4.7.0 to 7.1.1. The fix shipped in WordPress 7.1.2, with backports to 7.0.6, 6.9.9, 6.8.10 and older branches down to 4.7.37.

The timeline, hour by hour

Patchstack published what its sensors saw after the release:

CVE-2026-87902

From patch to attack in a single day

22 SepFix ships11:49 UTCFirst probe15:34 UTCFile-write try23 SepMass scanning
Times as reported by Patchstack for 22–23 September 2026.
  • 22 September: WordPress 7.1.2 is released with the fix.
  • 11:49 UTC, same day: the first probe is blocked, checking whether core files could be included.
  • 15:34 UTC, same day: the first attempt to write a file to a server.
  • 23 September: public scanning tools are circulating, and attack volume peaks around midday.

Reports from BleepingComputer and others describe malicious activity growing roughly tenfold as attackers moved from scanning to delivering payloads.

The attack itself followed a pattern: first a harmless check to see whether file inclusion worked, then a check for a PHP tool called pearcmd.php, then an attempt to use that tool to write PHP files into /tmp or /var/tmp.

Was my site at risk?

Exploiting this flaw needed several things at once, according to Patchstack:

  • The active theme has a top-level folder whose name starts with page-.
  • PHP has the register_argc_argv setting turned on.
  • The request points at a page that really exists.

So many sites weren’t exploitable even before patching. That doesn’t mean you can skip the update. Scanners test every site they find, and it only takes one match.

How to check your site

  1. Confirm your version. In WordPress, go to Dashboard → Updates. You want 7.1.2 or later, or the patched release for your branch.
  2. Look for unexpected PHP files in /tmp and /var/tmp if you have server access. Patchstack advises treating any you find as a sign the server was compromised.
  3. Search your access logs for pearcmd, +config-show, +config-create, or encoded dots like %2e%2e in requests.
  4. Run a malware scan. On cPanel hosting, Imunify360 scans files automatically; you can also run a scan from its dashboard.

If anything turns up, restore from a backup taken before 22 September, update, then change your passwords and keys.

Your plan for the next critical update

This won’t be the last flaw exploited within hours. A routine that runs without you is the only one that’s fast enough.

Let security releases install themselves

WordPress installs minor and security releases automatically by default. Check that nothing has turned this off: some plugins and wp-config.php settings do. In cPanel’s WordPress Toolkit, open your site and check the auto-update settings for core, plugins and themes.

Keep backups you can restore in minutes

Updates occasionally break things. In March 2026 WordPress shipped three releases in about 30 hours, after the first security patch broke some sites. A recent daily backup turns a bad update into a five-minute rollback instead of a crisis.

Test big updates on staging

Major releases and big plugin updates deserve a quick test on a staging copy first. Security releases usually don’t: apply those straight away and keep a backup ready.

Remove what you don’t use

Every inactive plugin and theme is code an attacker can target. If you haven’t used it in months, delete it rather than just deactivating it.

Check your logs after a critical patch

Ten minutes looking for the signs above, a day after a big security release, tells you whether you were targeted before you updated.

Checklist

Is your site ready for the next patch?

0 of 6 done

Tick what’s already in place. Nothing is saved or sent anywhere.

How LogicWeb helps

On our WordPress hosting and web hosting plans, every account includes:

  • WordPress Toolkit for updates, staging, cloning and security checks.
  • Daily JetBackup copies with seven days of retention, plus free restores from our support team.
  • Imunify360 scanning files and watching PHP activity.
  • CloudLinux isolation, so a compromised site on another account can’t reach yours.

If you’re not sure whether your site was touched, open a ticket and we’ll check the logs with you.

The bottom line

The gap between a security fix and the first attack used to be days or weeks. With CVE-2026-87902 it was hours. You don’t need to watch WordPress news around the clock to keep up. Turn on automatic security updates, keep daily backups you’ve actually tested, and take ten minutes to check your logs after a critical patch. Do those three things, and the next five-hour window won’t catch you out.

FAQ

What is CVE-2026-87902?

A critical path traversal vulnerability in WordPress core’s page template handling. In certain conditions it allows file inclusion and remote code execution without logging in. It affects WordPress 4.7.0 to 7.1.1.

Which WordPress versions fix CVE-2026-87902?

WordPress 7.1.2, 7.0.6, 6.9.9 and 6.8.10, with backported fixes for older branches down to 4.7.37.

Does WordPress update itself automatically?

By default, WordPress installs minor and security releases automatically. Major releases, plugins and themes need auto-updates turned on separately, and some sites have automatic updates disabled.

How fast should I install WordPress security updates?

The same day. In this case attackers began probing within hours of the fix being released.

Sources