CybersecurityMalware & Ransomware
Hundreds of websites deliver malware cocktail using Optimizely infrastructure
A security researcher discovered that malicious code was injected into customer JavaScript snippets delivered through Optimizely's legitimate content delivery network.

Key takeaways
- Hundreds of websites are distributing malware using Optimizely's legitimate infrastructure.
- The malware performs crypto wallet address swapping and card skimming.
- Specific exploit kits, DarkSword and Coruna, target various versions of iOS.
- Website administrators should check security advisories from ReportURI and Cynet for indicators of compromise.
In this article
How the attack was delivered
A security researcher reported that hundreds of websites were distributing a sophisticated malware cocktail to users. This malicious code was delivered using Optimizely's existing infrastructure, which provides JavaScript snippets to various customers. The attack did not involve cache poisoning, which is a common method of compromising content delivery networks. Instead, attackers managed to inject their own code into the JavaScript snippets used by affected customers and served them from cdn.optimizely.com.
This tainted code was delivered alongside Optimizely's legitimate scripts, meaning the malicious payload ran on every page served by the affected websites. The scripts, named track.js, were active across all four components of the attack simultaneously. Optimizely representatives did not respond to requests for comment regarding the breach.
Types of malware delivered
The malicious scripts were designed to perform several harmful actions depending on the user's device and activity. One function involved crypto wallet address swapping. The script searches for wallet addresses belonging to nine different cryptocurrencies and replaces them with those controlled by the attackers. This has already led to the theft of funds from some individuals whose devices ran the code.
Another component of the attack focused on card skimming. The script monitors HTTP requests for payment details, such as card numbers, expiry dates, and CVVs. If all three pieces of information are present, the script sends them to a specific malicious server. However, payment information entered into hosted payment iframes, such as those used by Stripe and Adyen, remained unaffected.
Threat to iOS users

The malware also included exploit kits targeting Apple devices. Specifically, the DarkSword and Coruna exploit kits were delivered through files named boot.js from various domains. These files deliver a hidden iframe containing an exploit chain tailored to the specific version of iOS being used by the victim.
Coruna is capable of infecting iOS versions 13 through 17. DarkSword is designed to infect iOS versions 18.x. A separate chain was also observed for iOS 26 fingerprints, although its function was not clear. Researchers had previously noted potential attempts by hackers linked to the Kremlin to distribute DarkSword via compromised web analytics services.
Scope and response to the threat
The security researcher identified 178 websites distributing the malicious scripts, and this list includes several well-known companies. It is currently unknown if this list is complete. The method by which the attackers gained access to so many unrelated customer projects remains unclear, with possibilities including a compromised Optimizely system or a compromised credential with cross-customer access.
Website administrators who wish to check for signs of compromise should consult the reports published by ReportURI and the security firm Cynet. While indicators are available for end users, the technical skill required to verify infection is likely beyond the reach of most people.
Sources
Spotted a mistake? See our corrections policy. Read how News by OnDevice works in our editorial policy.



