
The Polyfill Attack, and the Code Your Site Borrows
- Post author:Lodgik Team
- Post published:
Last week, more than 100,000 websites started sending some of their visitors to scam pages. None of those sites had been broken into. No passwords were stolen. So what happened?
A small script with a new owner
For years, many websites loaded a small helper script from a service called polyfill.io. It made newer website features work in older browsers. It was free and widely trusted, and themes and plugins added it without their users ever knowing.
In February 2024, the polyfill.io domain was sold to a new owner. In late June, security researchers at Sansec reported that the script had been changed to redirect some mobile visitors to malicious sites.
Every site still loading that script was affected at once. BleepingComputer has the full story. Cloudflare and Fastly set up safe copies, and Google began warning advertisers whose pages carried the script.
Why this one is different
We talk a lot about keeping WordPress and plugins updated. This attack wasn't about that. A fully updated site could still be affected.
The problem was trust. When your site loads a file from someone else's server, you're trusting whoever controls that server, today and in the future. If it changes hands, your site changes with it.
Most sites load more outside code than their owners realise: fonts, analytics, chat widgets, video players, and helper scripts added by themes and plugins.
How to check your site
- Search your theme and plugin files for "polyfill.io" and remove it if you find it
- List the outside services your site loads files from
- For each one, ask whether you still need it
- Remove plugins and themes you no longer use. They can still load code
This is Lodgik Hosting
This is the kind of thing a security audit is for. On our Plus plan and above, we review your plugins and setup and tell you what we'd change. We'd rather find the borrowed code before someone else does.
Want us to take a look at your site? Reach out.
Categories: Security
Tags: security, plugins, themes