Skip to content
Cybersecurity

WordPress critical vulnerability CVE-2026-87902: update to 7.1.2 or later now

A vulnerability in WordPress core, present since version 4.7, lets attackers load PHP files outside the theme folder under certain conditions. There is only one fix: update.

Team Cloudita

2 min read

Illustrazione: WordPress, falla critica CVE-2026-87902: aggiorna subito alla 7.1.2 o superiore

On 22 September 2026 the WordPress team released security updates for a vulnerability in core, the heart of the platform itself, not a plugin. It is tracked as CVE-2026-87902 and has a CVSS score of 9.2 out of 10: critical.

It affects every version from 4.7.0 up to 7.1.1. Given how many websites run on WordPress, it is worth understanding exactly what it is about.

The technical problem

When WordPress picks which theme file to use to render a page, one step did not check for ../ sequences, the ones used to “climb” up a folder. An unauthenticated attacker could therefore make WordPress load PHP files that live outside the theme folder.

To reach actual code execution, two conditions are needed at the same time:

  • the active theme must have, in its main folder, a subfolder whose name starts with page-;
  • the server must have a PHP file that does something useful for the attacker when loaded that way, or the PHP setting register_argc_argv must be enabled.

So not every site can be fully exploited, but every non-updated site contains the flaw. And in security, “it probably doesn’t affect me” is not a strategy.

Fixed versions

WordPress published fixes for every branch still in use:

  • 7.1.x → 7.1.2
  • 7.0.x → 7.0.6
  • 6.9.x → 6.9.9
  • 6.8.x → 6.8.10
  • older branches back to 4.7, with the fix backported (4.7.37).

There is no alternative workaround: the only fix is to update. When the news came out, no active attacks had been reported, but experience tells us bots start trying within days.

How to check your website in two minutes

  1. Go to Dashboard → Updates and check the installed version.
  2. If it is lower than the versions above, take a backup and update.
  3. If minor automatic updates are on (they are by default), your site has probably already updated itself: check anyway.
  4. While you are there, update plugins and theme too: most real-world attacks go through them.

We did it at home too: cloudita.it runs WordPress 7.1.3, already fixed, and during the same check we updated every plugin that could be updated safely.

Why it happens (and why it is not a reason to leave WordPress)

Every widely used piece of software has vulnerabilities. What sets a serious platform apart is how fast they get fixed and how transparently they are communicated. The weak spot is almost always the website nobody updates: the one delivered years ago and then left alone.

If your website is in that situation, we can take it over with a security check and a maintenance plan. Let’s talk.

Sources

  1. The Hacker News: WordPress issues patch for critical flaw that can enable code execution

Let's talk

Got a website, a software project or a security question? A real person will get back to you.

Write to us

Keep reading

All articles

Music: "Tech Corporate Startup Promo With Bright Drive" by Alex Morgan, CC BY 4.0 licence. Satellite imagery Esri, Maxar.