Polymarket Lost 2.7 Million USD to a Monitoring Script: Why Every Third Party Tag on a Money Page Is Production Code
On October 29, 2026, a compromised performance monitoring script turned into a wallet drainer on Polymarket. No passwords were stolen and no private keys were needed. Here is how the attack worked, what is still unverified, and the controls to put on any page that moves money.
Last week's security noise was dominated by Binance, and fair enough, 6.3 billion USD is hard to ignore. But the smaller incident from the same afternoon is the one I think more engineers should read carefully, because it can happen to your app on a normal Tuesday. On October 29, 2026, Polymarket paused trading for about an hour after a script it loaded from a performance monitoring vendor started draining traders' accounts. The script was not stolen credentials. It was a tag that Polymarket had put on its own pages on purpose.
I have not seen any public source link this to Binance, so I am treating them as two separate events that happened to land on the same day.
What Is Confirmed
Polymarket said one of its third party providers was compromised, referred the matter to law enforcement, and promised that affected traders would be made whole. DebugBear, a website performance monitoring vendor, said it was affected by a security incident and told customers using its real user monitoring product to remove the embed code from their sites. Polymarket's production build removed the DebugBear script, the exchange went into cancel only mode, and trading resumed roughly an hour later.
Reimbursement is where the numbers get fuzzy. Polymarket puts the theft at about 2.7 million USD from 726 wallets, and says it is returning about 3.9 million USD in total, which includes roughly 1.2 million USD for around 5,500 wallets that lost out during the pause or had positions sold. By the morning after, it reported 689 of the 726 wallets repaid. BleepingComputer traced about 2.5 million USD to the attacker's wallet and noted that this is funds traced, not a confirmed count of user losses.
What Is Not Confirmed
Quite a lot, actually.
- Neither company has published a post mortem as of this writing.
- DebugBear said its DNS records were compromised through its domain registrar. How the registrar account was breached has not been disclosed.
- Polymarket has not said how many users were affected beyond the wallet count, and has not detailed the reimbursement process. Some users complain that larger payouts come with a release form and strict terms. I could not verify those terms myself, so treat that as unverified.
- The detailed timeline and the step by step teardown of the script come from a monitoring vendor's blog, which sells competing products and has already corrected parts of its own timeline. Useful, but a single secondary source. Where I describe the mechanism below, I am relying on it plus BleepingComputer's reporting.
Also worth saying: most coverage repeats the same two statements from Polymarket and DebugBear. There is very little independent technical detail beyond the researcher teardowns.
How The Attack Worked
This is the part I find most instructive. The script did not phish anybody and did not need a seed phrase. It ran inside the logged in page, so it inherited whatever the trader's session was already allowed to do.
According to the teardown, the flow looked roughly like this:
- The script fetched settings from a DebugBear host and checked Polymarket's geoblock endpoint, presumably to avoid targeting where it was not wanted.
- It read trader and account details from the browser's localStorage.
- It walked the React component tree to find Polymarket's own order placing client.
- It reported wallet, IP and portfolio data to endpoints that looked like ordinary monitoring traffic.
- It then used Polymarket's own relayer to sign transfers of prediction market tokens to an attacker wallet, or, for email login accounts, placed sell orders at steep discounts without any prompt.
Notice what is missing. No exploit in Polymarket's code. No stolen API key. The attacker needed one thing: the ability to change which JavaScript a trusted vendor URL returned. After that, the app's own capabilities did the rest.
The Timeline, Roughly
Times below are UTC on October 29 unless noted, and come from the single teardown source, so read them as approximate.
| Time (UTC) | Event |
|---|---|
| 12:06 | Archive captures still show the clean script |
| 16:45 | The vendor's domain registry record changes |
| 17:10 | First stolen funds reach the attacker address |
| 17:59 | Polymarket production build removes the vendor script |
| 18:01 | DebugBear says it is affected, asks customers to remove the embed |
| 18:05 | Polymarket moves the exchange to cancel only mode |
| about 19:00 | Trading resumes, reimbursement promised |
| Oct 30 | DebugBear says registrar level DNS compromise; refunds under way |
If that registry change really is the origin, the detection to containment gap on the Polymarket side is a bit over an hour. That is not bad for a client side attack, but it is a long time when funds move in minutes.
Why This Matters Outside Crypto
Swap "wallet" for "bank transfer", "payout account", "admin session" or "data export" and you have the same bug in a SaaS dashboard. A script on a page runs with the full authority of the signed in user. Browsers do not distinguish between your bundle and a vendor tag. Analytics, session replay, chat widgets, A/B testing, performance monitoring: each one is a remote code execution path into your authenticated pages, controlled by someone else's DNS, CDN and registrar accounts.
Two things make this worse than a normal dependency problem. First, the vendor URL is mutable. With npm you at least get a lockfile and a hash. With a script tag pointing at a vendor's "latest" file, whatever is at that URL today is what runs. Second, your threat model probably stops at the vendor's application security and never reaches their domain registrar.
What The Usual Defenses Do And Do Not Do
| Control | Helps with | Limit in this incident |
|---|---|---|
| Content Security Policy | Inventorying and restricting where scripts load from | The drainer ran from an approved origin and talked to an approved host |
| Subresource Integrity | Blocking a changed file | Only works for files that never change; vendor in place updates cannot be pinned |
| Bundling the SDK from npm | Locks the version in your lockfile | Loses vendor side hot fixes, needs your own update process |
| Step up confirmation | Stops silent actions even with a hijacked session | Needs UX work and has to be enforced on the server |
| Removing the tag from money pages | Eliminates the exposure | Less data for the marketing and performance team |
CSP gets oversold here. It controls where code may load from, not what allowed code does. Used in report only mode, it is still a good way to find out how many third party scripts you actually have, which in my experience of reading other people's incident writeups is usually more than anyone thought.
What I Would Check This Week
Start with an inventory. Open your most sensitive authenticated pages (checkout, payouts, settings, admin, export) and list every script origin that loads.
<script
src="https://cdn.example.com/lib/v1.4.2/widget.min.js"
integrity="sha384-REPLACE_WITH_REAL_HASH"
crossorigin="anonymous"></script>
And put a report only policy in front of it so you can see what is running before you enforce anything:
Content-Security-Policy-Report-Only: script-src 'self' https://cdn.example.com; report-uri /csp-reports
Then work through this list:
- Remove third party tags from pages that can move money, change payout details or export data. Monitor those pages with server side telemetry instead.
- Bundle vendor SDKs from your package manager where you can, so the version is locked and reviewed like the rest of your code.
- Require step up confirmation for withdrawals, new recipients and bulk sells, and enforce it on the server so a script cannot fake the confirmation.
- Time how long it takes to remove a tag, including CDN and HTML caches. Polymarket's roughly hour long window is a reasonable benchmark to beat.
- Watch vendor script URLs from outside your infrastructure and alert when the hash changes.
- Ask your vendors whether their domains have registrar lock, two factor authentication and change alerts. It is a short question and the answer tells you a lot.
- Write down which vendor tags your incident runbook can kill without a deploy.
For Users
If you trade on any platform that holds your funds, remember that being logged in is a standing permission. Use the platform's withdrawal allowlists if they exist, and keep large balances in places that need a separate confirmation to move. I am not giving financial advice here, just describing how the attack worked.
My Take
Polymarket did several things right on the day: it identified the third party quickly, pulled the script, froze trading and committed to reimbursing people publicly. That is better than many incident responses I read. The part I want to see is the post mortem, because the interesting question is not "did the vendor get hacked" but "why could one external file trigger signed transfers with no friction".
My opinion: a monitoring script should never have been able to reach the same objects that place orders. Browsers give us very few ways to isolate that, which is exactly why the safest design is to keep the tag off the page entirely, or sandbox it in an iframe on a separate origin. Third party code on a money page is production code owned by a stranger. We should review it, pin it and budget for removing it, the same way we treat any other dependency.
Also, please do not read this as a crypto story. The same pattern is waiting in every product with a payout button.
Key Takeaways
- A compromised vendor script on October 29, 2026 drained about 2.7 million USD from 726 Polymarket wallets, per Polymarket, with about 3.9 million USD in total reimbursement promised.
- The script reused the logged in session, so no passwords or private keys were needed.
- DebugBear said its DNS was compromised through its registrar; the registrar breach itself is still unexplained.
- CSP and SRI help, but neither would have stopped an approved origin serving a changed file, unless the file is pinned.
- Keep third party scripts off money pages, enforce step up checks on the server, and measure how fast you can pull a tag.
- Public details are thin: no post mortem yet, and most coverage repeats the same two company statements.
Sources
- BleepingComputer: Polymarket halts trading after crypto draining script breach, 2.5M traced
- SiteQwality: The Polymarket DebugBear Hack, How a Monitoring Script Became a Wallet Drainer
- Yahoo Finance: Polymarket Sends 3.9M Back to Traders After Vendor Script Drain
- Tech Startups: Top Tech News Today, November 2, 2026