PHP2Shell, part two: "you're behind Cloudflare" doesn't mean you're safe
· 4 min read
Last week we wrote about PHP2Shell, the serious flaw in the software that runs most business websites. Since then, a lot of small businesses have had a reassuring message from whoever hosts their site. It usually goes something like this: “Your site is behind Cloudflare, so you’re unaffected.”
We’re not going to name anyone. Most of these messages were written in a hurry, by people working hard on the day, and some of what they said was fair. But that one line is wrong, and the thinking behind it is how websites get broken into. So it’s worth taking apart.
What Cloudflare actually does
Cloudflare is good, and we use it ourselves. Think of it as a doorman standing in front of your website. Visitors come through Cloudflare first, and it turns away the ones it recognises as trouble.
With PHP2Shell, Cloudflare moved fast. Within hours it had taught its doorman what the known attacks look like, for every customer, free ones included. That bought a lot of websites valuable time, and it deserves credit.
But a doorman isn’t a lock. The weakness is still inside the building.
Why “unaffected” is the wrong word
“Protected while we fix it” would have been honest. “Unaffected” tells you there’s nothing left to do. Here’s why that isn’t true.
- The flaw is still there. A site behind Cloudflare is running exactly the same vulnerable software as one that isn’t. Cloudflare is filtering attacks, not fixing anything.
- The doorman only sees people who use the front door. If an attacker can find your server’s real address, they can go straight to it and Cloudflare never sees them. On shared hosting, where lots of sites sit on one server, that address is often easy to find.
- Having your domain “in Cloudflare” isn’t the same as being protected. Cloudflare can just handle your domain’s address book without standing in front of your site at all. Only some settings put the doorman on the door, and most business owners have no way of telling which they’ve got.
- Attackers change their disguise. Within days, Cloudflare said attackers were already tweaking their attacks to slip past the new rules, and that some setups weren’t covered at all.
- Cloudflare says so itself. Its own advice was to fix PHP even with its protection switched on. Its chief technology officer put it more bluntly on social media: “This is a STOPGAP only.”
If the company providing the protection calls it a stopgap, nobody else should be calling it a fix.
What a good update looks like
If you pay someone to look after your website, this is roughly what you should have heard from them in October:
“Cloudflare is blocking the known attacks while we patch. Your site is on PHP 8.3. We’ll have it patched by Friday. Because it was exposed for a few days before the fix, we’ll also check it for any signs of a break-in, and let you know what we find.”
It’s honest about what Cloudflare is doing. It tells you exactly where your site stands and when it’ll be fixed. And it deals with the uncomfortable question of whether anyone got in before the fix.
If what you got was a general “don’t worry, you’re covered”, it’s fair to reply and ask for those specifics. A good agency will have them to hand.
The bigger question: does your website need all this?
Here’s the part that doesn’t get said enough. Most small business websites are brochures. A few pages about what you do, some photos, a contact form. They change a handful of times a year.
Yet many of them run on WordPress, which means every single visit runs code on a server. That server, the PHP underneath it, WordPress itself and every plugin on top all need watching and updating, forever. Miss one and you’re exposed.
To be fair to WordPress, the core software is well looked after. The problem is everything around it. Last year, security firm Patchstack counted 11,334 new flaws in the WordPress world. 91% of them were in plugins. Almost half had no fix available when they became public, and the worst ones were being attacked on a large scale within about five hours.
No small business owner can keep up with that, and it’s a lot to ask of anyone looking after dozens of sites.
There’s a simpler option for a lot of sites: a static website. It looks exactly the same to your visitors, but it’s just ready-made pages sitting there to be read. Nothing runs when someone visits. No PHP, no plugins, no database. PHP2Shell couldn’t have touched it, because there was nothing for it to attack. Your contact form still works, handled by a small separate service. As a bonus, static sites are fast and cheap to host.
WordPress still makes sense for some businesses, like a busy online shop or a team publishing new content every week. If that’s you, it just needs proper, ongoing care from someone who’s actually doing it. But if your site is a brochure, it’s worth asking why it needs a server running code at all.
The short version
Cloudflare is a doorman, not a lock. It’s worth having, and it helped a lot of sites through a bad week. But the only fix for a flaw in your website’s software is fixing the software, or not running it in the first place.
So don’t settle for “you’re covered”. Ask what version your site is on, when it was patched, and whether anyone checked for a break-in. And if your site is really just a brochure, ask whether it needs WordPress at all.
If you’d like a straight answer on any of that, get in touch. We’ll look at your site and tell you plainly where it stands, even if the answer is that it’s fine. If it turns out a rebuild makes more sense, here’s how we secure and host websites.