Supply chain attack: one Optimizely snippet, 178 organisations, and what CSP actually stopped

On 16 November 2026 attacker code rode inside the trusted Optimizely Web snippet onto the sites of 178 organisations. How it worked, why a trusted domain and SRI didn't help, what Content Security Policy stopped on 24 of 159 sites, and what owners and visitors should do.

On 16 November 2026, visitors of 178 organisations were served malicious JavaScript, among them Zoom, the BBC, CNN, Salesforce, GitLab, IKEA, HSBC, Equifax, Air France-KLM and Ledger. None of those sites had to be broken into. The code arrived inside a file every one of them loaded on purpose: their Optimizely Web snippet, served from Optimizely’s own CDN. The incident was documented the same day by Scott Helme of Report URI in World’s Largest Brands Infected With Malware Via Optimizely. All numbers in this post come from that report unless a different source is linked.

This is a textbook supply chain attack in the sense MDN uses the term: someone gains control of what a third party delivers, and every site that trusts the third party delivers it too. The interesting part is what it tells us about three things people believe protect them: a trusted domain, Subresource Integrity (SRI), and Content Security Policy (CSP).

Nothing here was scanned, crawled or tested by me. It is written from the report, Optimizely’s own statements and documentation, and the CSP and SRI standards.

How the snippet works, and where the code went

Optimizely Web is an A/B testing tool. A customer adds one script tag to the <head> of their pages, pointing at https://cdn.optimizely.com/js/<project id>.js. That file contains Optimizely’s client code, the customer’s experiments, and an optional field called Project JavaScript: custom code the customer types into their Optimizely dashboard, which the report describes as code that “runs on every page”.

The attacker wrote their own code into the Project JavaScript of many unrelated customers’ projects. Everything else in each snippet was untouched. The file still came from cdn.optimizely.com, with Optimizely’s certificate. The report is explicit that this “was not a CDN cache-poisoning attack”: the CDN “served exactly what it was given”. Customers who serve the snippet from their own domain were affected too, because the content comes from the same project. So were Optimizely’s own www.optimizely.com and login.optimizely.com snippets.

How the attacker got write access was unknown at the time of the report, and the report said it had no response from Optimizely at publication. Since then Optimizely has spoken twice:

  • To BleepingComputer on 16 November: “an unauthorized party exploited a vulnerability in the Experimentation account signup flow … They used it to add malicious JavaScript to some customer projects.” The company said it blocked the vulnerable path, deployed a fix, removed the injected code, ended active sessions, revoked tokens, reset access for affected user accounts, and notified all affected customers.
  • On its status page, posted 17 November 2026 at 01:02 UTC (status “Monitoring”, component “Web Experimentation (Snippet Delivery)”): the vulnerability is fixed, the injected code removed, affected accounts secured, and “additional protections” are in place.

Optimizely has not published technical details of the flaw so far.

The day, as published

16 November 2026, UTC (to scale)00:0006:0012:0018:0024:00payload builds 08:10 to 17:57 (26 in the day)04:21 first injection08:10 first build13:43 card skimmer17:57 last build21:52 1 of 188 left26 payload builds during the day; most snippets cleaned ~20:40–21:10
The day as published by Report URI (times UTC). The attacker's wallets had received about $7,040 by 19:25 UTC. Source: Report URI timeline, 16 Nov 2026.

The last clean capture of the BBC’s snippet was at 02:21 UTC; the first injection was seen at 04:21. The payload was rebuilt 26 times that day: the attacker “added features, and added wallets but never removed any”. Report URI’s sweep between 19:24 and 19:59 found 186 of 1,611 snippets infected; after a mass clean-up around 20:40 to 21:10, only 1 of the 188 infected snippets still carried the code at 21:52.

What the payload did

Every visitor got the same script, with every feature active at once:

Part What it did Who was exposed
Crypto address swapping Found valid wallet addresses (checksums validated) in page text, form fields, links, the clipboard and outgoing requests, and replaced them with the attacker’s Anyone copying or pasting an address while an affected tab was open
Card skimming (added 13:43 UTC) Watched form submissions and POST requests for card number, expiry and CVV Cards typed into a site’s own form fields. Hosted payment iframes (Stripe, Adyen and similar) were out of its reach
Cookie and screenshot theft Sent the page URL, document.cookie and a rendered screenshot of the page Cookies not marked HttpOnly
iOS exploit chains Loaded exploit kits in a hidden iframe, chosen by iOS version Unpatched iPhones and iPads; on iOS 18.6 or earlier the page reloaded every 60 seconds, a visible symptom

By 19:25 UTC the attacker’s wallets had received about $7,040, all within roughly nine hours. How many cards or cookies got out cannot be seen from the outside.

Myth 1: a trusted domain means trusted code

The padlock in the address bar proves which server sent a file. It says nothing about what is in it. The W3C Subresource Integrity specification says it directly about TLS and HSTS: “These mechanisms, however, authenticate only the server, not the content. An attacker (or administrator) with access to the server can manipulate content with impunity.”

A third-party <script> tag runs with your page’s full power. It can read and rewrite the DOM, watch every form, hook copy and paste, read non-HttpOnly cookies and make requests. Every site in this incident trusted the right domain. What changed was the code behind it.

Myth 2: Subresource Integrity would have fixed it

SRI pins a script to an exact hash: <script src="..." integrity="sha384-..." crossorigin="anonymous">. If a single byte differs, the browser refuses to run it. It would have caught this change.

The problem is that this file is supposed to change. Optimizely’s documentation says that after you add the snippet, “the snippet updates automatically”. Every experiment you edit produces a new file. Pin a hash and your own next experiment breaks the page. SRI is a great fit for a versioned library (lib-3.7.1.js never changes); it does not fit a live vendor snippet whose whole job is to change.

Myth 3: a Content Security Policy fixes it

CSP is a response header that tells the browser where scripts may come from (script-src), where the page may send data (connect-src), which frames it may load, and whether eval() is allowed. Report URI crawled 256 hosts of the affected organisations and checked each policy against what this payload needed. The four outcomes add up to 159 organisations:

No CSP at allNo CSP at all: 68 of 15968 (43%)CSP allowed everythingpayload + data theftCSP allowed everything: 50 of 15950 (31%)connect-src blocked theftaddress swap still ranconnect-src blocked theft: 17 of 15917 (11%)Payload blockedrestrictive script-srcPayload blocked: 24 of 15924 (15%)
What the affected sites' own Content Security Policy did against this payload, as evaluated by Report URI (256 hosts crawled; the four rows add up to 159 organisations, percentages are our arithmetic on them). Source: Scott Helme, Report URI, "World's Largest Brands Infected With Malware Via Optimizely", 16 Nov 2026.
Outcome Organisations Share of 159
No CSP at all 68 43%
CSP allowed the payload and the data theft 50 31%
Payload ran, connect-src blocked the data theft (address swapping still worked) 17 11%
Payload blocked 24 15%

So CSP did help, but only where it was strict. Three details explain the split:

  1. Allow-listing the vendor did nothing. The bad code came from cdn.optimizely.com itself. What separated the 24 was a restrictive script-src that listed only the hosts each site needed, so the attacker’s own server was refused.
  2. 'strict-dynamic' let it through. With 'strict-dynamic', the trust given to a script with a nonce or hash “is passed on to scripts that the original script loads”, and host allow-lists are ignored. The trusted snippet inserted the attacker’s script, so it was trusted too. The CSP Level 3 draft notes that 'strict-dynamic' “should be avoided when possible”.
  3. 'unsafe-eval' ran the inline copy. One version of the injected code carried the whole payload inline and ran it through eval when the download was blocked. At HSBC, the report says, the CSP blocked the download and the data theft, “but the inline copy still ran”. MDN is blunt: “developers should avoid unsafe-eval”.

The twist: both settings appear in Optimizely’s own CSP guide. Its recommended script-src uses a nonce plus 'strict-dynamic', it says some features such as audiences with custom JavaScript conditions need 'unsafe-eval', and its “Example of a complete CSP policy” contains both.

What CSP cannot do

On the 17 “partial” sites, connect-src stopped the card, cookie and screenshot theft, because those need a request to the attacker’s server (connect-src covers fetch, XHR, WebSocket and sendBeacon). It did not stop the address swapping, which happens entirely inside the page. CSP controls what loads and where data may go. It cannot control what an allowed script does to your DOM once it runs.

What to do if you run a site

From the report’s own checklist, plus the standards:

  • Look inside your vendor configuration, not just your repo. For Optimizely, open every project’s Project JavaScript and every experiment’s custom code and look for any script you didn’t write. The report notes one variant hid the URL in base64 (atob(), so a plain text search for a domain can miss it.
  • Review who and what can write to the account: users, API tokens, integrations. Rotate credentials.
  • Keep card fields in the payment provider’s iframe. The skimmer could not reach hosted payment frames.
  • Mark session cookies HttpOnly; treat secrets in non-HttpOnly cookies from 16 November as exposed and rotate them.
  • Deploy a CSP that would have helped: a short script-src list, no 'unsafe-eval' where you can avoid it, a tight connect-src, a default-src (the CSP3 draft notes a policy without default-src “cannot mitigate exfiltration”), and reporting on. Start with Content-Security-Policy-Report-Only, which reports violations without enforcing them, then enforce.
  • To see whether your own site sends a policy at all: curl -sI https://your-site.example | grep -i content-security-policy (look for -report-only in the header name too).

What to do if you visited an affected site that day

  • Update your iPhone or iPad: the report says iOS 18.7.3 or later, or iOS 26.3 or later, are patched against the kits it saw.
  • Check any crypto transfer you made. If the address you pasted isn’t the one you meant to pay, it may have been swapped.
  • Watch your card statement if you paid by card on an affected site.

Indicators, for defenders

The report lists these attacker-owned domains (block including subdomains): 1688360.cc (the main payload and data endpoints), 5vobauua3ojpklx.icu and eil786npto9u5bq.icu (iOS routers), l7bcsnwc7nzr3uo.icu (telemetry), webshell.lol and linkforge.cc (an earlier wave through other third-party scripts), plus further fallback hosts, payload hashes and wallet addresses in the original report. The payload set the globals window._k7 and window.__k7b.

Sources