{"id":11223,"date":"2026-11-20T17:30:29","date_gmt":"2026-11-20T17:30:29","guid":{"rendered":"https:\/\/www.hostinger.com\/blog\/?p=11223"},"modified":"2026-11-20T17:32:14","modified_gmt":"2026-11-20T17:32:14","slug":"tackling-wp2shell-vulnerability","status":"publish","type":"post","link":"https:\/\/www.hostinger.com\/blog\/tackling-wp2shell-vulnerability\/","title":{"rendered":"How we protected WordPress sites from WP2Shell before it went public"},"content":{"rendered":"<p class=\"wp-block-paragraph\">WP2Shell was a critical vulnerability chain that could let an unauthenticated attacker take over a WordPress website. By the time its details went public in July 2026, every shared server in our infrastructure was already protected.<\/p><p class=\"wp-block-paragraph\">That didn&rsquo;t happen by chance. Getting there required close coordination with the WordPress core security team and several rounds of testing. The hardest part was writing firewall rules that blocked attacks without breaking legitimate WordPress functionality. The simplest fix, blocking the vulnerable endpoint entirely, would have broken the block editor for every site.&nbsp;<\/p><p class=\"wp-block-paragraph\">Our Head of WordPress, <a data-click-id=\"hgr-post-content-link-marco-chiesi\" href=\"https:\/\/www.linkedin.com\/in\/marcochiesi\/\" target=\"_blank\" rel=\"noopener\">Marco Chiesi<\/a>, takes us behind the scenes of how we prepared and deployed protection against WP2Shell.<\/p><p class=\"wp-block-paragraph\"><div id=\"ez-toc-container\" class=\"ez-toc-v2_0_75 counter-hierarchy ez-toc-counter ez-toc-grey ez-toc-container-direction\">\n<div class=\"ez-toc-title-container\">\n<span class=\"ez-toc-title-toggle\"><\/span><\/div>\n<nav><ul class='ez-toc-list ez-toc-list-level-1 ' ><li class='ez-toc-page-1 ez-toc-heading-level-2'><a data-click-id=\"hgr-post-content-link-what-is-the-wp2shell-vulnerability-chain\" class=\"ez-toc-link ez-toc-heading-1\" href=\"https:\/\/www.hostinger.com\/blog\/tackling-wp2shell-vulnerability\/#What_is_the_WP2Shell_vulnerability_chain\">What is the WP2Shell vulnerability chain?<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a data-click-id=\"hgr-post-content-link-every-patch-is-a-race-against-attackers\" class=\"ez-toc-link ez-toc-heading-2\" href=\"https:\/\/www.hostinger.com\/blog\/tackling-wp2shell-vulnerability\/#Every_patch_is_a_race_against_attackers\">Every patch is a race against attackers&nbsp;<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a data-click-id=\"hgr-post-content-link-the-layered-protection-that-keeps-wordpress-sites-safe\" class=\"ez-toc-link ez-toc-heading-3\" href=\"https:\/\/www.hostinger.com\/blog\/tackling-wp2shell-vulnerability\/#The_layered_protection_that_keeps_WordPress_sites_safe\">The layered protection that keeps WordPress sites safe&nbsp;<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a data-click-id=\"hgr-post-content-link-how-we-got-ahead-of-the-wp2shell-public-disclosure\" class=\"ez-toc-link ez-toc-heading-4\" href=\"https:\/\/www.hostinger.com\/blog\/tackling-wp2shell-vulnerability\/#How_we_got_ahead_of_the_WP2Shell_public_disclosure\">How we got ahead of the WP2Shell public disclosure<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a data-click-id=\"hgr-post-content-link-how-we-built-and-tested-the-firewall-rules\" class=\"ez-toc-link ez-toc-heading-5\" href=\"https:\/\/www.hostinger.com\/blog\/tackling-wp2shell-vulnerability\/#How_we_built_and_tested_the_firewall_rules\">How we built and tested the firewall rules<\/a><ul class='ez-toc-list-level-3' ><li class='ez-toc-heading-level-3'><a data-click-id=\"hgr-post-content-link-four-firewall-rule-versions-in-about-22-hours\" class=\"ez-toc-link ez-toc-heading-6\" href=\"https:\/\/www.hostinger.com\/blog\/tackling-wp2shell-vulnerability\/#Four_firewall_rule_versions_in_about_22_hours\">Four firewall rule versions in about 22 hours<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a data-click-id=\"hgr-post-content-link-a-problem-specific-to-our-stack\" class=\"ez-toc-link ez-toc-heading-7\" href=\"https:\/\/www.hostinger.com\/blog\/tackling-wp2shell-vulnerability\/#A_problem_specific_to_our_stack\">A problem specific to our stack<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a data-click-id=\"hgr-post-content-link-testing-before-every-rollout\" class=\"ez-toc-link ez-toc-heading-8\" href=\"https:\/\/www.hostinger.com\/blog\/tackling-wp2shell-vulnerability\/#Testing_before_every_rollout\">Testing before every rollout<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a data-click-id=\"hgr-post-content-link-the-false-positive-we-didnt-see-coming\" class=\"ez-toc-link ez-toc-heading-9\" href=\"https:\/\/www.hostinger.com\/blog\/tackling-wp2shell-vulnerability\/#The_false_positive_we_didnt_see_coming\">The false positive we didn&rsquo;t see coming<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a data-click-id=\"hgr-post-content-link-decisions-beyond-the-rules\" class=\"ez-toc-link ez-toc-heading-10\" href=\"https:\/\/www.hostinger.com\/blog\/tackling-wp2shell-vulnerability\/#Decisions_beyond_the_rules\">Decisions beyond the rules<\/a><\/li><\/ul><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a data-click-id=\"hgr-post-content-link-after-the-wp2shell-vulnerability-chain-became-public\" class=\"ez-toc-link ez-toc-heading-11\" href=\"https:\/\/www.hostinger.com\/blog\/tackling-wp2shell-vulnerability\/#After_the_WP2Shell_vulnerability_chain_became_public\">After the WP2Shell vulnerability chain became public<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a data-click-id=\"hgr-post-content-link-keeping-wordpress-sites-secure-is-an-ongoing-shared-effort\" class=\"ez-toc-link ez-toc-heading-12\" href=\"https:\/\/www.hostinger.com\/blog\/tackling-wp2shell-vulnerability\/#Keeping_WordPress_sites_secure_is_an_ongoing_shared_effort\">Keeping WordPress sites secure is an ongoing, shared effort<\/a><\/li><\/ul><\/nav><\/div>\n<\/p><h2 class=\"wp-block-heading h-t-title-2\" id=\"h-what-is-the-wp2shell-vulnerability-chain\"><span class=\"ez-toc-section\" id=\"What_is_the_WP2Shell_vulnerability_chain\"><\/span>What is the WP2Shell vulnerability chain?<span class=\"ez-toc-section-end\"><\/span><\/h2><p class=\"wp-block-paragraph\">WP2Shell chained two flaws in WordPress core:<\/p><ul class=\"wp-block-list\">\n<li>A batch-route confusion flaw in the REST API (CVE-2026-63030).<\/li>\n\n\n\n<li>An SQL injection flaw in WP_Query (CVE-2026-60137).<\/li>\n<\/ul><p class=\"wp-block-paragraph\">Together, they allowed attackers to create an administrator account, log in, and upload a malicious plugin. Neither flaw required a vulnerable plugin or special configuration to exploit. Even a default WordPress installation was exposed, with no existing account or login required.<\/p><p class=\"wp-block-paragraph\">The severity scores show why looking at individual flaws doesn&rsquo;t tell the whole story.&nbsp;<\/p><figure class=\"wp-block-table\"><table class=\"has-fixed-layout\"><tbody><tr><td><strong>Flaw<\/strong><\/td><td><strong>CVSS (WordPress)<\/strong><\/td><td><strong>CISA&rsquo;s assessment<\/strong><\/td><\/tr><tr><td>REST API batch-route confusion<\/td><td><a data-click-id=\"hgr-post-content-link-9-8-critical\" href=\"https:\/\/nvd.nist.gov\/vuln\/detail\/cve-2026-63030\" target=\"_blank\" rel=\"noopener\">9.8 (Critical)<\/a><\/td><td><a data-click-id=\"hgr-post-content-link-used-in-real-attacks\" href=\"https:\/\/www.cisa.gov\/known-exploited-vulnerabilities-catalog?field_cve=CVE-2026-63030\" target=\"_blank\" rel=\"noopener\">Used in real attacks<\/a><\/td><\/tr><tr><td>SQL injection<\/td><td><a data-click-id=\"hgr-post-content-link-5-9-medium\" href=\"https:\/\/nvd.nist.gov\/vuln\/detail\/cve-2026-60137\" target=\"_blank\" rel=\"noopener\">5.9 (Medium)<\/a><\/td><td><a data-click-id=\"hgr-post-content-link-used-in-real-attacks-2\" href=\"https:\/\/www.cisa.gov\/known-exploited-vulnerabilities-catalog?field_cve=CVE-2026-60137\" target=\"_blank\" rel=\"noopener\">Used in real attacks<\/a> &ndash; if combined with the REST API flaw, could give attackers full control<\/td><\/tr><\/tbody><\/table><\/figure><p class=\"wp-block-paragraph\">CVSS measures the severity of individual vulnerabilities on a scale of 0 to 10, but it doesn&rsquo;t capture how flaws combine. For WordPress sites, factors such as authentication requirements, the number of affected installations, and active exploitation matter just as much.<\/p><p class=\"wp-block-paragraph\">Sites running WordPress 6.9 or 7.0 were exposed to the full chain, while sites running WordPress 6.8 were affected by only one of the two flaws. Versions before 6.8 weren&rsquo;t affected.<\/p><h2 class=\"wp-block-heading h-t-title-2\" id=\"h-every-patch-is-a-race-against-attackers\"><span class=\"ez-toc-section\" id=\"Every_patch_is_a_race_against_attackers\"><\/span>Every patch is a race against attackers&nbsp;<span class=\"ez-toc-section-end\"><\/span><\/h2><p class=\"wp-block-paragraph\">WordPress enables automatic updates by default, helping websites receive critical security fixes without manual intervention. However, a global rollout still takes hours, and some websites don&rsquo;t receive automatic updates at all.<\/p><p class=\"wp-block-paragraph\">At the same time, publishing a security patch can reveal how to exploit the vulnerability it fixes. By comparing the updated code with its previous version, attackers can identify what changed, pinpoint the vulnerability, and develop exploits targeting websites that haven&rsquo;t updated yet.<\/p><p class=\"wp-block-paragraph\">The time-to-exploit window also keeps shrinking year by year, as <a data-click-id=\"hgr-post-content-link-mandiants-research\" href=\"https:\/\/cloud.google.com\/blog\/topics\/threat-intelligence\/time-to-exploit-trends-2023?hl=en\" target=\"_blank\" rel=\"noopener\">Mandiant&rsquo;s research<\/a> shows:<\/p><ul class=\"wp-block-list\">\n<li><strong>2018&ndash;2019:<\/strong> 63 days<\/li>\n\n\n\n<li><strong>2020&ndash;early 2021:<\/strong> 44 days<\/li>\n\n\n\n<li><strong>2021&ndash;2022:<\/strong> 32 days<\/li>\n\n\n\n<li><strong>2023:<\/strong> 5 days<\/li>\n\n\n\n<li><strong>2025:<\/strong> around &minus;7 days, meaning exploits often appeared before patches were even released (<a data-click-id=\"hgr-post-content-link-m-trends-2026\" href=\"https:\/\/cloud.google.com\/blog\/topics\/threat-intelligence\/m-trends-2026?hl=en\" target=\"_blank\" rel=\"noopener\">M-Trends 2026<\/a>)<\/li>\n<\/ul><div class=\"wp-block-image\">\n<figure data-wp-context='{\"imageId\":\"6b009674587fc\"}' data-wp-interactive=\"core\/image\" data-wp-key=\"6b009674587fc\" class=\"aligncenter size-large wp-lightbox-container\"><img decoding=\"async\" width=\"1024\" height=\"576\" data-wp-class--hide=\"state.isContentHidden\" data-wp-class--show=\"state.isContentVisible\" data-wp-init=\"callbacks.setButtonStyles\" data-wp-on--click=\"actions.showLightbox\" data-wp-on--load=\"callbacks.setButtonStyles\" data-wp-on--pointerdown=\"actions.preloadImage\" data-wp-on--pointerenter=\"actions.preloadImageWithDelay\" data-wp-on--pointerleave=\"actions.cancelPreload\" data-wp-on-window--resize=\"callbacks.setButtonStyles\" src=\"https:\/\/www.hostinger.com\/blog\/wp-content\/uploads\/sites\/4\/2026\/11\/diagram-of-the-time-to-exploit-software-1024x576.png\" alt=\"Bar chart of the average time to exploit software vulnerabilities, falling from 63 days in 2018&ndash;2019 to 44 days in 2020&ndash;early 2021, 32 days in 2021&ndash;2022, 5 days in 2023, and &minus;7 days in 2025, meaning exploits often arrived before the patch.\" class=\"wp-image-11226\" srcset=\"https:\/\/www.hostinger.com\/blog\/wp-content\/uploads\/sites\/4\/2026\/11\/diagram-of-the-time-to-exploit-software-1024x576.png 1024w, https:\/\/www.hostinger.com\/blog\/wp-content\/uploads\/sites\/4\/2026\/11\/diagram-of-the-time-to-exploit-software-1536x864.png 1536w, https:\/\/www.hostinger.com\/blog\/wp-content\/uploads\/sites\/4\/2026\/11\/diagram-of-the-time-to-exploit-software-300x169.png 300w, https:\/\/www.hostinger.com\/blog\/wp-content\/uploads\/sites\/4\/2026\/11\/diagram-of-the-time-to-exploit-software-768x432.png 768w, https:\/\/www.hostinger.com\/blog\/wp-content\/uploads\/sites\/4\/2026\/11\/diagram-of-the-time-to-exploit-software.png 1973w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><button class=\"lightbox-trigger\" type=\"button\" aria-haspopup=\"dialog\" data-wp-bind--aria-label=\"state.thisImage.triggerButtonAriaLabel\" data-wp-init=\"callbacks.initTriggerButton\" data-wp-on--click=\"actions.showLightbox\" data-wp-style--right=\"state.thisImage.buttonRight\" data-wp-style--top=\"state.thisImage.buttonTop\">\n\t\t\t<svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"12\" height=\"12\" fill=\"none\" viewbox=\"0 0 12 12\">\n\t\t\t\t<path fill=\"#fff\" d=\"M2 0a2 2 0 0 0-2 2v2h1.5V2a.5.5 0 0 1 .5-.5h2V0H2Zm2 10.5H2a.5.5 0 0 1-.5-.5V8H0v2a2 2 0 0 0 2 2h2v-1.5ZM8 12v-1.5h2a.5.5 0 0 0 .5-.5V8H12v2a2 2 0 0 1-2 2H8Zm2-12a2 2 0 0 1 2 2v2h-1.5V2a.5.5 0 0 0-.5-.5H8V0h2Z\"><\/path>\n\t\t\t<\/svg>\n\t\t<\/button><\/figure>\n<\/div><p class=\"wp-block-paragraph\">The researcher who discovered the WP2Shell vulnerability chain, Adam Kues of Searchlight Cyber, used an AI model to <a data-click-id=\"hgr-post-content-link-identify-the-chain-in-about-10-hours\" href=\"https:\/\/www.slcyber.io\/research\/exploit-brokers-pay-500000-for-a-wordpress-rce-i-found-one-with-gpt5-6\" target=\"_blank\" rel=\"noopener\">identify the chain in about 10 hours<\/a>, incurring only about $25 in compute costs.<\/p><p class=\"wp-block-paragraph\">&ldquo;[Finding a vulnerability like this] is within reach of practically everyone,&rdquo; Marco says. &ldquo;Today, with AI, the timelines have accelerated enormously.&rdquo;<\/p><h2 class=\"wp-block-heading h-t-title-2\" id=\"h-the-layered-protection-that-keeps-wordpress-sites-safe\"><span class=\"ez-toc-section\" id=\"The_layered_protection_that_keeps_WordPress_sites_safe\"><\/span>The layered protection that keeps WordPress sites safe&nbsp;<span class=\"ez-toc-section-end\"><\/span><\/h2><p class=\"wp-block-paragraph\">WordPress websites can still be protected at several layers. Marco compares it to an apartment building:<\/p><ul class=\"wp-block-list\">\n<li>A CDN firewall is the bouncer at the end of the street, stopping attacks before they reach the server.<\/li>\n\n\n\n<li>A hosting provider&rsquo;s firewall is the doorman in the lobby, checking every request that arrives.&nbsp;<\/li>\n\n\n\n<li>The security update is the locksmith who fixes the broken lock for good.<\/li>\n<\/ul><div class=\"wp-block-image\">\n<figure data-wp-context='{\"imageId\":\"6b0096745bcef\"}' data-wp-interactive=\"core\/image\" data-wp-key=\"6b0096745bcef\" class=\"aligncenter size-large wp-lightbox-container\"><img decoding=\"async\" width=\"1024\" height=\"576\" data-wp-class--hide=\"state.isContentHidden\" data-wp-class--show=\"state.isContentVisible\" data-wp-init=\"callbacks.setButtonStyles\" data-wp-on--click=\"actions.showLightbox\" data-wp-on--load=\"callbacks.setButtonStyles\" data-wp-on--pointerdown=\"actions.preloadImage\" data-wp-on--pointerenter=\"actions.preloadImageWithDelay\" data-wp-on--pointerleave=\"actions.cancelPreload\" data-wp-on-window--resize=\"callbacks.setButtonStyles\" src=\"https:\/\/www.hostinger.com\/blog\/wp-content\/uploads\/sites\/4\/2026\/11\/wordpress-sites-protection-layers-1024x576.png\" alt=\"Diagram of three protection layers between an attack request and a WordPress site: a network firewall (the bouncer), server-level protection (the doorman), and the software update (the locksmith), which fixes the flaw for good.\" class=\"wp-image-11227\" srcset=\"https:\/\/www.hostinger.com\/blog\/wp-content\/uploads\/sites\/4\/2026\/11\/wordpress-sites-protection-layers-1024x576.png 1024w, https:\/\/www.hostinger.com\/blog\/wp-content\/uploads\/sites\/4\/2026\/11\/wordpress-sites-protection-layers-300x169.png 300w, https:\/\/www.hostinger.com\/blog\/wp-content\/uploads\/sites\/4\/2026\/11\/wordpress-sites-protection-layers-768x432.png 768w, https:\/\/www.hostinger.com\/blog\/wp-content\/uploads\/sites\/4\/2026\/11\/wordpress-sites-protection-layers-1536x864.png 1536w, https:\/\/www.hostinger.com\/blog\/wp-content\/uploads\/sites\/4\/2026\/11\/wordpress-sites-protection-layers.png 1973w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><button class=\"lightbox-trigger\" type=\"button\" aria-haspopup=\"dialog\" data-wp-bind--aria-label=\"state.thisImage.triggerButtonAriaLabel\" data-wp-init=\"callbacks.initTriggerButton\" data-wp-on--click=\"actions.showLightbox\" data-wp-style--right=\"state.thisImage.buttonRight\" data-wp-style--top=\"state.thisImage.buttonTop\">\n\t\t\t<svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"12\" height=\"12\" fill=\"none\" viewbox=\"0 0 12 12\">\n\t\t\t\t<path fill=\"#fff\" d=\"M2 0a2 2 0 0 0-2 2v2h1.5V2a.5.5 0 0 1 .5-.5h2V0H2Zm2 10.5H2a.5.5 0 0 1-.5-.5V8H0v2a2 2 0 0 0 2 2h2v-1.5ZM8 12v-1.5h2a.5.5 0 0 0 .5-.5V8H12v2a2 2 0 0 1-2 2H8Zm2-12a2 2 0 0 1 2 2v2h-1.5V2a.5.5 0 0 0-.5-.5H8V0h2Z\"><\/path>\n\t\t\t<\/svg>\n\t\t<\/button><\/figure>\n<\/div><p class=\"wp-block-paragraph\">The locksmith is the only permanent fix, but until it arrives, the doorman keeps the site safe. That&rsquo;s our role as a hosting provider. Every request to a website on our shared hosting passes through our servers first, so we can inspect it and block attacks before they reach WordPress.<\/p><p class=\"wp-block-paragraph\">And because one firewall rule covers our entire shared hosting infrastructure, we can protect every website on it at once, without customers needing to do anything. For more, see <a data-click-id=\"hgr-post-content-link-how-we-keep-our-customers-websites-safe\" href=\"https:\/\/www.hostinger.com\/blog\/hostinger-security\/\">how we keep our customers&rsquo; websites safe<\/a>.<\/p><p class=\"wp-block-paragraph\">With WP2Shell, we deployed firewall rules while the details were still confidential, so websites were already protected when the patch was released.<\/p><h2 class=\"wp-block-heading h-t-title-2\" id=\"h-how-we-got-ahead-of-the-wp2shell-public-disclosure\"><span class=\"ez-toc-section\" id=\"How_we_got_ahead_of_the_WP2Shell_public_disclosure\"><\/span>How we got ahead of the WP2Shell public disclosure<span class=\"ez-toc-section-end\"><\/span><\/h2><p class=\"wp-block-paragraph\">Protecting websites before a vulnerability goes public requires coordination that mostly happens behind the scenes. It depends on confidentiality and trust.&nbsp;<\/p><p class=\"wp-block-paragraph\">The WordPress core security team shares only what a few companies need to prepare defenses, and keeps the group small on purpose: the more people who know about a vulnerability before the fix, the higher the risk of a leak. WP2Shell was no exception.<\/p><div class=\"wp-block-image\">\n<figure data-wp-context='{\"imageId\":\"6b0096746142f\"}' data-wp-interactive=\"core\/image\" data-wp-key=\"6b0096746142f\" class=\"aligncenter size-large wp-lightbox-container\"><img decoding=\"async\" width=\"1024\" height=\"576\" data-wp-class--hide=\"state.isContentHidden\" data-wp-class--show=\"state.isContentVisible\" data-wp-init=\"callbacks.setButtonStyles\" data-wp-on--click=\"actions.showLightbox\" data-wp-on--load=\"callbacks.setButtonStyles\" data-wp-on--pointerdown=\"actions.preloadImage\" data-wp-on--pointerenter=\"actions.preloadImageWithDelay\" data-wp-on--pointerleave=\"actions.cancelPreload\" data-wp-on-window--resize=\"callbacks.setButtonStyles\" src=\"https:\/\/www.hostinger.com\/blog\/wp-content\/uploads\/sites\/4\/2026\/11\/network-behind-security-release-1024x576.png\" alt=\"Diagram of the network behind a WordPress security release: security researchers report flaws to the WordPress core security team, which fixes them and coordinates with hosting providers, CDNs and firewalls, and security companies.\" class=\"wp-image-11228\" srcset=\"https:\/\/www.hostinger.com\/blog\/wp-content\/uploads\/sites\/4\/2026\/11\/network-behind-security-release-1024x576.png 1024w, https:\/\/www.hostinger.com\/blog\/wp-content\/uploads\/sites\/4\/2026\/11\/network-behind-security-release-300x169.png 300w, https:\/\/www.hostinger.com\/blog\/wp-content\/uploads\/sites\/4\/2026\/11\/network-behind-security-release-768x432.png 768w, https:\/\/www.hostinger.com\/blog\/wp-content\/uploads\/sites\/4\/2026\/11\/network-behind-security-release-1536x864.png 1536w, https:\/\/www.hostinger.com\/blog\/wp-content\/uploads\/sites\/4\/2026\/11\/network-behind-security-release.png 1973w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><button class=\"lightbox-trigger\" type=\"button\" aria-haspopup=\"dialog\" data-wp-bind--aria-label=\"state.thisImage.triggerButtonAriaLabel\" data-wp-init=\"callbacks.initTriggerButton\" data-wp-on--click=\"actions.showLightbox\" data-wp-style--right=\"state.thisImage.buttonRight\" data-wp-style--top=\"state.thisImage.buttonTop\">\n\t\t\t<svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"12\" height=\"12\" fill=\"none\" viewbox=\"0 0 12 12\">\n\t\t\t\t<path fill=\"#fff\" d=\"M2 0a2 2 0 0 0-2 2v2h1.5V2a.5.5 0 0 1 .5-.5h2V0H2Zm2 10.5H2a.5.5 0 0 1-.5-.5V8H0v2a2 2 0 0 0 2 2h2v-1.5ZM8 12v-1.5h2a.5.5 0 0 0 .5-.5V8H12v2a2 2 0 0 1-2 2H8Zm2-12a2 2 0 0 1 2 2v2h-1.5V2a.5.5 0 0 0-.5-.5H8V0h2Z\"><\/path>\n\t\t\t<\/svg>\n\t\t<\/button><\/figure>\n<\/div><p class=\"wp-block-paragraph\">The collaboration culminated in <a data-click-id=\"hgr-post-content-link-wordpress-7-0-2\" href=\"https:\/\/wordpress.org\/news\/2026\/07\/wordpress-7-0-2-release\/\" target=\"_blank\" rel=\"noopener\">WordPress 7.0.2<\/a>, the security release that addressed WP2Shell on July 17, 2026. Hostinger was among seven companies acknowledged in the release announcement, alongside Altis, Automattic, Bluehost, Cloudflare, GoDaddy, and WP Engine.&nbsp;<\/p><p class=\"wp-block-paragraph\">Getting into that small group isn&rsquo;t something a company can buy. &ldquo;It&rsquo;s a matter of trust,&rdquo; Marco explains, &ldquo;and of relationships with members of the community, built over years of contributing and going to WordCamps.&rdquo;<\/p><p class=\"wp-block-paragraph\">Once we received the confidential notice, our team moved quickly to deploy effective protection across the shared hosting infrastructure. Here&rsquo;s how the response unfolded:<\/p><figure class=\"wp-block-table\"><table class=\"has-fixed-layout\"><tbody><tr><td><strong>Timeline<\/strong>&nbsp;<\/td><td><strong>What happened<\/strong><\/td><\/tr><tr><td>Thursday, July 16 &ndash; Evening<\/td><td>The WordPress core security team shared the initial vulnerability information and the first firewall rule. Our team immediately started preparing protection.<\/td><\/tr><tr><td>Overnight into Friday<\/td><td>We tested the first rule on a single server, then began rolling it out. Working with the WordPress core security team, we refined the rules through several versions.<\/td><\/tr><tr><td>Friday, July 17 &ndash; Early afternoon<\/td><td>Protection was in place across every shared server, hours before public disclosure.<\/td><\/tr><tr><td>Friday, July 17 &ndash; Evening<\/td><td>While attending Hostinger&rsquo;s Cowboy Extravaganza summer party in Lithuania, a handful of our team members continued coordinating with the WordPress core security team &ndash; in cowboy hats and boots.<\/td><\/tr><tr><td>Friday, July 17 &ndash; 18:45 UTC<\/td><td>WordPress released version 7.0.2 and publicly disclosed the vulnerability details. Automatic updates began rolling out to affected websites.<\/td><\/tr><tr><td>Saturday, July 18<\/td><td>We followed up on websites that hadn&rsquo;t been reached by the automatic update process.<\/td><\/tr><\/tbody><\/table><\/figure><h2 class=\"wp-block-heading h-t-title-2\" id=\"h-how-we-built-and-tested-the-firewall-rules\"><span class=\"ez-toc-section\" id=\"How_we_built_and_tested_the_firewall_rules\"><\/span>How we built and tested the firewall rules<span class=\"ez-toc-section-end\"><\/span><\/h2><p class=\"wp-block-paragraph\">Every rule risks blocking legitimate requests, and the WP2Shell rules took several rounds to get right.<\/p><h3 class=\"wp-block-heading h-t-title-3\"><span class=\"ez-toc-section\" id=\"Four_firewall_rule_versions_in_about_22_hours\"><\/span>Four firewall rule versions in about 22 hours<span class=\"ez-toc-section-end\"><\/span><\/h3><p class=\"wp-block-paragraph\">Between July 16 and 17, the firewall rules went through four versions. The first version, from the WordPress core security team, blocked malformed requests to the REST API batch endpoint, but only when accessed via the standard method.&nbsp;<\/p><p class=\"wp-block-paragraph\">Testing by hosts and researchers soon turned up other ways, and each new version closed more of them.<\/p><p class=\"wp-block-paragraph\">The second widened the rule&rsquo;s coverage, the third split it into two rules with much stricter validation of the request path, and the fourth, shared just before the release, added protection against nested batch requests.<\/p><h3 class=\"wp-block-heading h-t-title-3\"><span class=\"ez-toc-section\" id=\"A_problem_specific_to_our_stack\"><\/span>A problem specific to our stack<span class=\"ez-toc-section-end\"><\/span><\/h3><p class=\"wp-block-paragraph\">The exploit could be sent as a JSON request body, which our web application firewall (WAF) didn&rsquo;t inspect at the time. Enabling that inspection surfaced a bug in a third-party component, which we reported to the vendor.&nbsp;<\/p><p class=\"wp-block-paragraph\">So we wrote our own rules that inspect the raw request body directly. When the final rule set arrived, one of its rules would have undone that workaround, so we kept our version and adopted the rest.<\/p><p class=\"wp-block-paragraph\">Not every part of our infrastructure could run the same rules. Where a firewall couldn&rsquo;t apply the precise rules, we used broader measures instead: blocking the entire batch endpoint at the CDN level in front of our own WordPress sites, or disabling the vulnerable routes with a small code snippet.<\/p><h3 class=\"wp-block-heading h-t-title-3\"><span class=\"ez-toc-section\" id=\"Testing_before_every_rollout\"><\/span>Testing before every rollout<span class=\"ez-toc-section-end\"><\/span><\/h3><p class=\"wp-block-paragraph\">Each version was first deployed to one production server, then to three servers across different data centers. The team watched the logs for about an hour before scaling up.&nbsp;<\/p><p class=\"wp-block-paragraph\">Test scripts shared by other hosts and community contributors sent both attack payloads, which had to be blocked, and normal requests, which had to pass.&nbsp;<\/p><p class=\"wp-block-paragraph\">After the JSON workaround, for example, the suite reported 30 blocked attacks, 10 legitimate requests allowed, and 0 failures. From there, we rolled out data center by data center.<\/p><p class=\"wp-block-paragraph\">Three things justified moving quickly: the scope was narrow (a single REST endpoint), normal requests in the test suites kept passing, and the alternative was exposing millions of sites to unauthenticated remote code execution.&nbsp;<\/p><p class=\"wp-block-paragraph\">The WordPress core security team also held the release until hosts confirmed their firewall coverage, so the rules had to be live first.<\/p><h3 class=\"wp-block-heading h-t-title-3\"><span class=\"ez-toc-section\" id=\"The_false_positive_we_didnt_see_coming\"><\/span>The false positive we didn&rsquo;t see coming<span class=\"ez-toc-section-end\"><\/span><\/h3><p class=\"wp-block-paragraph\">One rule went too far. To support our JSON workaround, we added a nested-batch rule of our own, not part of the WordPress team&rsquo;s set. It turned out to block legitimate requests from WordPress&rsquo;s block-based Widget Editor, which saves widgets through the same batch endpoint.&nbsp;<\/p><p class=\"wp-block-paragraph\">We had assumed the endpoint was rarely used in normal browsing, and we were partly wrong.<\/p><p class=\"wp-block-paragraph\">Customers reported that saving widgets failed, and the tickets reached engineering about three weeks after the incident. Support unblocked affected sites with per-site exceptions while the team fixed the rule. We kept the rules active everywhere else, because many sites were still running vulnerable versions.<\/p><h3 class=\"wp-block-heading h-t-title-3\"><span class=\"ez-toc-section\" id=\"Decisions_beyond_the_rules\"><\/span>Decisions beyond the rules<span class=\"ez-toc-section-end\"><\/span><\/h3><p class=\"wp-block-paragraph\">Two other choices shaped the response. We didn&rsquo;t notify customers before the details were public, since an early warning could have tipped off attackers. WordPress.org chose to force updates for affected versions, accepting the risk that if an update broke something, it would break everywhere at once.<\/p><h2 class=\"wp-block-heading h-t-title-2\" id=\"h-after-the-wp2shell-vulnerability-chain-became-public\"><span class=\"ez-toc-section\" id=\"After_the_WP2Shell_vulnerability_chain_became_public\"><\/span>After the WP2Shell vulnerability chain became public<span class=\"ez-toc-section-end\"><\/span><\/h2><p class=\"wp-block-paragraph\">WordPress published the vulnerability details at 18:45 UTC on July 17. Attackers moved fast. <a data-click-id=\"hgr-post-content-link-patchstack-recorded-the-first-attack-attempts\" href=\"https:\/\/patchstack.com\/articles\/ninety-minutes-watching-attackers-weaponize-the-wordpress-core-rce\/\" target=\"_blank\" rel=\"noopener\">Patchstack recorded the first attack attempts<\/a> about 90 minutes after WordPress released 7.0.2. By July 19, VulnCheck had verified <a data-click-id=\"hgr-post-content-link-more-than-two-dozen-proof-of-concept-exploits\" href=\"https:\/\/www.vulncheck.com\/blog\/wp2shell\" target=\"_blank\" rel=\"noopener\">more than two dozen proof-of-concept exploits<\/a>. On July 21, CISA added both vulnerabilities to its <a data-click-id=\"hgr-post-content-link-list-of-actively-exploited-vulnerabilities\" href=\"https:\/\/www.cisa.gov\/news-events\/alerts\/2026\/07\/21\/cisa-adds-four-known-exploited-vulnerabilities-catalog\" target=\"_blank\" rel=\"noopener\">list of actively exploited vulnerabilities<\/a>, and a fully working end-to-end exploit was published the next day.<\/p><p class=\"wp-block-paragraph\">Security vendors counted the attacks they blocked:<\/p><ul class=\"wp-block-list\">\n<li>Monarx recorded <a data-click-id=\"hgr-post-content-link-over-2-million-blocked-requests\" href=\"https:\/\/www.monarx.com\/press-news\/same-story-different-layer-wp2shell-and-the-wordpress-core-rce-chain\" target=\"_blank\" rel=\"noopener\">over 2 million blocked requests<\/a> over the disclosure weekend.<\/li>\n\n\n\n<li>Imunify360 reported <a data-click-id=\"hgr-post-content-link-more-than-29-million-blocked-attempts\" href=\"http:\/\/blog.imunify360.com\/wordpress-core-rce-wp2shell-our-weekend-waf-response\" target=\"_blank\" rel=\"noopener\">more than 29 million blocked attempts<\/a>, peaking at over 9 million in a single day.<\/li>\n\n\n\n<li>CrowdSec counted <a data-click-id=\"hgr-post-content-link-more-than-62000-attacking-ip-addresses\" href=\"https:\/\/www.crowdsec.net\/vulntracking-report\/cve-2026-63030-wordpress-wp2shell-active-exploitation\" target=\"_blank\" rel=\"noopener\">more than 62,000 attacking IP addresses<\/a> in a rolling 15-day window five weeks after disclosure.<\/li>\n<\/ul><div class=\"wp-block-image\">\n<figure data-wp-context='{\"imageId\":\"6b0096746d687\"}' data-wp-interactive=\"core\/image\" data-wp-key=\"6b0096746d687\" class=\"aligncenter size-large wp-lightbox-container\"><img decoding=\"async\" width=\"1024\" height=\"576\" data-wp-class--hide=\"state.isContentHidden\" data-wp-class--show=\"state.isContentVisible\" data-wp-init=\"callbacks.setButtonStyles\" data-wp-on--click=\"actions.showLightbox\" data-wp-on--load=\"callbacks.setButtonStyles\" data-wp-on--pointerdown=\"actions.preloadImage\" data-wp-on--pointerenter=\"actions.preloadImageWithDelay\" data-wp-on--pointerleave=\"actions.cancelPreload\" data-wp-on-window--resize=\"callbacks.setButtonStyles\" src=\"https:\/\/www.hostinger.com\/blog\/wp-content\/uploads\/sites\/4\/2026\/11\/wp2shell-attack-after-disclosure-1-1024x576.png\" alt=\"Timeline of WP2Shell attacks after disclosure: first attempts within 90 minutes on July 17, 24+ proof-of-concept exploits by July 19, CISA&rsquo;s active exploitation listing on July 21, and a public exploit on July 22. Monarx blocked 2M+ requests, Imunify360 29M+ attempts, and CrowdSec counted 62K attacking IPs.\" class=\"wp-image-11230\" srcset=\"https:\/\/www.hostinger.com\/blog\/wp-content\/uploads\/sites\/4\/2026\/11\/wp2shell-attack-after-disclosure-1-1024x576.png 1024w, https:\/\/www.hostinger.com\/blog\/wp-content\/uploads\/sites\/4\/2026\/11\/wp2shell-attack-after-disclosure-1-300x169.png 300w, https:\/\/www.hostinger.com\/blog\/wp-content\/uploads\/sites\/4\/2026\/11\/wp2shell-attack-after-disclosure-1-768x432.png 768w, https:\/\/www.hostinger.com\/blog\/wp-content\/uploads\/sites\/4\/2026\/11\/wp2shell-attack-after-disclosure-1-1536x864.png 1536w, https:\/\/www.hostinger.com\/blog\/wp-content\/uploads\/sites\/4\/2026\/11\/wp2shell-attack-after-disclosure-1.png 1973w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><button class=\"lightbox-trigger\" type=\"button\" aria-haspopup=\"dialog\" data-wp-bind--aria-label=\"state.thisImage.triggerButtonAriaLabel\" data-wp-init=\"callbacks.initTriggerButton\" data-wp-on--click=\"actions.showLightbox\" data-wp-style--right=\"state.thisImage.buttonRight\" data-wp-style--top=\"state.thisImage.buttonTop\">\n\t\t\t<svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"12\" height=\"12\" fill=\"none\" viewbox=\"0 0 12 12\">\n\t\t\t\t<path fill=\"#fff\" d=\"M2 0a2 2 0 0 0-2 2v2h1.5V2a.5.5 0 0 1 .5-.5h2V0H2Zm2 10.5H2a.5.5 0 0 1-.5-.5V8H0v2a2 2 0 0 0 2 2h2v-1.5ZM8 12v-1.5h2a.5.5 0 0 0 .5-.5V8H12v2a2 2 0 0 1-2 2H8Zm2-12a2 2 0 0 1 2 2v2h-1.5V2a.5.5 0 0 0-.5-.5H8V0h2Z\"><\/path>\n\t\t\t<\/svg>\n\t\t<\/button><\/figure>\n<\/div><p class=\"wp-block-paragraph\">For most Hostinger customers, though, nothing changed. Our firewall rules had been in place for hours before the first attacks arrived. As Marco puts it: &ldquo;Most of our customers, like those of most other hosts, didn&rsquo;t even notice anything, because everything had already been secured ahead of time.&rdquo;<\/p><p class=\"wp-block-paragraph\">Protection didn&rsquo;t end with the firewall deployment. In the following days, our team monitored the situation, diagnosed websites that hadn&rsquo;t updated automatically, and helped bring them up to date.&nbsp;<\/p><p class=\"wp-block-paragraph\">We sent targeted notifications to customers whose WordPress versions weren&rsquo;t automatically updated, briefed our Customer Success team, and updated our AI support assistant. This way, we made sure customers received clear, accurate answers when they asked for information about this vulnerability.<\/p><p class=\"wp-block-paragraph\">Between August and October 2026, the same coordination happened five more times as WordPress released more security patches &ndash; 7.0.3, 7.0.4, 7.1.1, 7.1.2, and 7.1.3. Each time, the WordPress core security team shared protective rules in advance, hosting providers deployed them, and the public patch followed.<\/p><h2 class=\"wp-block-heading h-t-title-2\" id=\"h-keeping-wordpress-sites-secure-is-an-ongoing-shared-effort\"><span class=\"ez-toc-section\" id=\"Keeping_WordPress_sites_secure_is_an_ongoing_shared_effort\"><\/span>Keeping WordPress sites secure is an ongoing, shared effort<span class=\"ez-toc-section-end\"><\/span><\/h2><p class=\"wp-block-paragraph\">For us, effective infrastructure security takes preparation, sound engineering judgment, and relationships built long before an incident happens.<\/p><p class=\"wp-block-paragraph\">But hosting providers aren&rsquo;t the only ones with a role to play in keeping WordPress sites secure. Website owners can reduce their exposure by keeping <strong>automatic updates<\/strong> enabled, using <strong>additional firewall protection<\/strong> where needed, and <strong>watching for signs of compromise<\/strong>, such as unexpected administrator accounts or unfamiliar plugins.&nbsp;<\/p><p class=\"wp-block-paragraph\">Whoever discovers vulnerabilities should report them privately: WordPress core issues through the <a data-click-id=\"hgr-post-content-link-wordpress-hackerone-program\" href=\"https:\/\/hackerone.com\/wordpress\" target=\"_blank\" rel=\"noopener\">WordPress HackerOne program<\/a>, and plugin issues to the plugin&rsquo;s developer or the WordPress.org Plugins team.&nbsp;<\/p><p class=\"wp-block-paragraph\">Publishing vulnerability details before a fix is available hands attackers a head start on every site running the affected software. <a data-click-id=\"hgr-post-content-link-php2shell\" href=\"https:\/\/www.hostinger.com\/blog\/what-is-php2shell\/\">PHP2Shell<\/a>, a pair of critical PHP vulnerabilities disclosed in October 2026, showed what that looks like. The CVE identifiers leaked on a public forum a day before the scheduled release, forcing the PHP team to rush out patches while proof-of-concept exploits were already circulating.<\/p><p class=\"wp-block-paragraph\">Marco says, &ldquo;When security works, it doesn&rsquo;t make the news.&rdquo; There was no headline for the more than 4.5 million WordPress websites we host that weren&rsquo;t hacked, and that&rsquo;s exactly the standard we hold ourselves to.<\/p><p class=\"wp-block-paragraph\">The rules took hours to deploy. The trust that made early preparation possible took years to build. We&rsquo;ll keep investing in both, so future WordPress security releases can go out just as quietly.<\/p><p>\n\n\n<div class=\"protip\">\n                    <h4 class=\"title\"><\/h4>\n                    <p>This article is based on Marco Chiesi's talk, \"WP2Shell e gli eroi invisibili di WordPress\" (WP2Shell and the invisible heroes of WordPress) at <a data-click-id=\"hgr-post-content-link-wordcamp-pisa-2026\" href=\"https:\/\/pisa.wordcamp.org\/2026\/session\/wp2shell-e-gli-eroi-invisibili-di-wordpress\/\" target=\"_blank\" rel=\"noopener\">WordCamp Pisa 2026<\/a>.<\/p>\n                <\/div>\n<\/p>\n","protected":false},"excerpt":{"rendered":"<p>WP2Shell was a critical vulnerability chain that could let an unauthenticated attacker take over a WordPress website. By the time its details went public in July 2026, every share\u2026<\/p>\n","protected":false},"author":257,"featured_media":11225,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_content_updated_date":"","footnotes":""},"categories":[82,2365],"tags":[],"hashtags":[],"class_list":["post-11223","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-engineering","category-wordpress"],"hreflangs":[],"_links":{"self":[{"href":"https:\/\/www.hostinger.com\/blog\/wp-json\/wp\/v2\/posts\/11223","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.hostinger.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.hostinger.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.hostinger.com\/blog\/wp-json\/wp\/v2\/users\/257"}],"replies":[{"embeddable":true,"href":"https:\/\/www.hostinger.com\/blog\/wp-json\/wp\/v2\/comments?post=11223"}],"version-history":[{"count":2,"href":"https:\/\/www.hostinger.com\/blog\/wp-json\/wp\/v2\/posts\/11223\/revisions"}],"predecessor-version":[{"id":11231,"href":"https:\/\/www.hostinger.com\/blog\/wp-json\/wp\/v2\/posts\/11223\/revisions\/11231"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.hostinger.com\/blog\/wp-json\/wp\/v2\/media\/11225"}],"wp:attachment":[{"href":"https:\/\/www.hostinger.com\/blog\/wp-json\/wp\/v2\/media?parent=11223"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.hostinger.com\/blog\/wp-json\/wp\/v2\/categories?post=11223"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.hostinger.com\/blog\/wp-json\/wp\/v2\/tags?post=11223"},{"taxonomy":"hashtags","embeddable":true,"href":"https:\/\/www.hostinger.com\/blog\/wp-json\/wp\/v2\/hashtags?post=11223"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}