WordPress 7.0.2 Core security fix: what site owners need to do
WordPress released an urgent Core security update on July 17, 2026 after two vulnerabilities were disclosed. One involved SQL injection through WP_Query; the second involved REST API batch-route confusion and could be chained with the SQL injection flaw to reach remote code execution on affected versions.
What was fixed?
The July release addressed two separate WordPress Core issues:
Facilitated SQL injection in WP_Query
WordPress did not correctly sanitise the author__not_in parameter in certain WP_Query uses. Exploitation depends on a plugin or theme passing attacker-controlled input into that parameter, which is why the issue is described as “facilitated” rather than universally exploitable on every installation.
REST API batch-route confusion
A route-confusion issue in the REST API batch endpoint could be combined with the SQL injection weakness on affected WordPress 6.9 and 7.0 sites. The combined chain could allow an unauthenticated attacker to move from database access to remote code execution.
Which WordPress versions are affected?
| Branch | Affected versions | Required version | Scope |
|---|---|---|---|
| WordPress 6.8 | 6.8.0–6.8.5 | Update to 6.8.6 or newer | Affected by CVE-2026-60137 |
| WordPress 6.9 | 6.9.0–6.9.4 | Update to 6.9.5 or newer | Affected by both vulnerabilities |
| WordPress 7.0 | 7.0.0–7.0.1 | Update to 7.0.2 or newer | Affected by both vulnerabilities |
WordPress stated that versions before 6.8 are not affected by these two specific vulnerabilities. That does not mean an older branch is generally safe: only the latest WordPress release is fully maintained, and old installations can contain other unresolved security problems.
Why this incident matters
Most high-profile WordPress incidents involve a vulnerable plugin or theme. This case is different because the vulnerable code is in WordPress Core itself. A Core flaw can affect a much broader range of sites, including otherwise carefully maintained installations with reputable plugins.
The risk is also not limited to visibly damaged websites. Successful exploitation can begin with database access or credential exposure and later progress to malicious administrators, modified files, scheduled tasks, web shells, redirects, spam pages, or persistent backdoors.
How to update safely
- Confirm your current version. Check Dashboard → Updates or run
wp core versionthrough WP-CLI. - Create a verified backup. Back up both files and database before a manual update, especially on WooCommerce, membership, or custom sites.
- Install the security release. Update to the newest available WordPress version. At minimum, affected branches need 6.8.6, 6.9.5, or 7.0.2.
- Clear all cache layers. Purge page cache, object cache, CDN cache, reverse-proxy cache, and PHP OPcache where relevant.
- Test critical functionality. Verify login, checkout, payments, forms, scheduled actions, REST integrations, and custom code.
- Confirm the update actually persisted. Recheck the Core version and inspect hosting dashboards that may use immutable or managed WordPress filesystems.
Updating is necessary, but it may not be enough
Installing the patched version closes the known vulnerabilities. It does not automatically remove a compromise that occurred before the update. Because both CVEs were added to active-exploitation tracking, sites that remained exposed should receive at least a focused post-update review.
Post-update compromise checklist
Administrator accounts: look for unknown users, altered email addresses, unexpected application passwords, or recently elevated roles.
Core integrity: compare WordPress Core files against official checksums with wp core verify-checksums.
Modified PHP files: review recent changes in wp-content, must-use plugins, uploads, temporary folders, and the site root.
Database changes: inspect options, users, posts, scheduled events, injected JavaScript, and unexpected URLs or spam content.
Scheduled persistence: review WordPress cron, server cron, hosting tasks, and background queues for unfamiliar jobs.
Access logs: check REST API traffic, unusual POST requests, repeated requests to unknown files, and activity around the disclosure window.
Credentials: rotate WordPress, hosting, database, SFTP, SSH, API, and deployment credentials when compromise is suspected.
Neighbouring sites: inspect every website sharing the same hosting account; one compromised installation can reinfect another.
What not to do
- Do not assume the website is safe only because the homepage looks normal.
- Do not rely exclusively on one security-plugin scan.
- Do not delete suspicious files before preserving evidence and a backup.
- Do not reinstall Core and assume plugins, themes, uploads, database content, or server tasks are clean.
- Do not postpone the update while waiting for a maintenance window if the site is on an affected release.
Was every WordPress site automatically updated?
WordPress enabled forced security updates for affected installations, but background updates can fail because of filesystem permissions, disabled update constants, hosting restrictions, version-control deployments, disk-space problems, timeouts, or previous failed updates. The only reliable approach is to check the installed version directly.
Do you need a full malware cleanup?
A complete cleanup is appropriate when you find unknown administrators, modified files, suspicious scheduled tasks, unexplained redirects, spam pages, hosting warnings, unexpected database changes, or evidence that the site was exposed and actively targeted. A business-critical WooCommerce or membership site may justify deeper review even when there are no obvious symptoms.
Concerned that an affected site was compromised?
I can inspect the installation, remove malware and persistence, verify Core integrity, and document the likely entry point and recovery steps.