Subscribe Now
Trending News

Blog Post

THEY SOLD YOU SELF-CUSTODY — THEN GENERATED YOUR SEED WITH MATH.RANDOM(). 1,400 WALLETS JUST WENT TO ZERO.
News

THEY SOLD YOU SELF-CUSTODY — THEN GENERATED YOUR SEED WITH MATH.RANDOM(). 1,400 WALLETS JUST WENT TO ZERO. 

They told you self-custody means nobody can take your coins. Then they generated your seed with the same "random" function that decides which button you see in a JavaScript tutorial.

1,400 wallets. One weekend. Zero hardware touched.

Quick Summary

  • Qubic, a Layer-1 blockchain, halted its entire network on Sunday, October 18, 2026, at tick 85,371,949 — and at the time of writing it is still frozen.
  • An attacker drained roughly $1.4 million from more than 1,400 wallets by exploiting wallet seeds generated with JavaScript’s Math.random() — a function that was never built to create cryptographic secrets.
  • The vulnerable seeds came from any browser on an iPhone or iPad, Safari on a Mac until October 18, 2026, and the Qubic iOS app before July 2025.
  • 87.1% of the stolen 2.94 trillion QU never left the network and sits frozen in place. The other 12.9% hit the exchange MEXC, whose team froze the receiving account in about an hour.
  • The patch is one line in wallet version 4.26.4: Math.random() was swapped for crypto.getRandomValues().

What Happened

Qubic paused its chain at tick 85,371,949 after attackers walked through wallet seeds that were never actually random.

Here is the part that should make you angry. The wallet generated your recovery phrase in the browser. To do that, it needed randomness. Instead of pulling from the operating system’s cryptographically secure generator, it called Math.random() — a function designed for animations, shuffling deck order in a card game, and picking a random banner ad. It is fast, it is convenient, and it is completely predictable.

Predictable randomness is not randomness. It is a pattern. And a pattern can be reversed.

The attacker did not need your device. They did not need malware on your machine. They did not need to meet you, threaten you, or trick you. They needed to guess the pattern, recompute your keys, and sweep. That is the whole attack. Math.

Qubic says 87.1% of the drained funds never left its network and remain frozen, and that MEXC froze the rest. Validators are preparing to vote on a recovery plan. The full technical report is not out yet, and the network has not announced when it restarts.

So the money might come back. The trust does not.

Why This Matters for Bitcoin

You can shrug and say "that is an altcoin problem." You would be wrong, and here is why.

The exact same class of failure has already hit Bitcoin users — repeatedly.

In July 2026, Coldcard disclosed that attackers had stolen funds from wallets whose seeds were weakened by a firmware bug. No malware. No stolen device. The attacker simply recomputed the keys because the randomness was weak. That one cost users roughly $38 million.

In 2023, the same disease showed up in Trust Wallet’s browser extension and in the Libbitcoin Explorer tool.

Four incidents, three years, one root cause: the wallet generated your keys from randomness that was not random.

Now look at the shape of it. The hardware wallet you bought to be safe. The browser wallet you opened because it was convenient. The phone app you trusted because it had a nice logo. All of them live or die on one thing you never see and never check: the quality of the entropy that created your seed.

Self-custody does not fix bad math. It just means you are holding the bag when the math fails.

The Love Is Bitcoin Takeaway

Here is the hypocrisy nobody in this industry wants to say out loud.

Wallet vendors have spent a decade selling you a slogan — "not your keys, not your coins" — and almost none of them have shown you the one line of code that decides whether those keys are guessable. They will talk about secure elements, air gaps, metal backups, titanium plates, and engraved seed words. They will sell you a $200 box with a screen and a tamper-proof seal.

And then the seed generator underneath it was rolling dice that were not dice.

Pick a side. Either entropy is the foundation of everything, or the whole self-custody pitch is marketing. There is no middle ground. A wallet that cannot prove how it generates randomness is a wallet that is asking you to trust it — which is exactly what you were trying to escape.

The uncomfortable truth about air-gapped wallets: by keeping the device offline, you also cut off the entropy from the host computer. If the device’s own randomness is weak, the most paranoid setup you can buy is the one that can be drained without ever touching the device.

The good news is that this is fixable, and the fix is boring. Verify where your seed came from. Prefer wallets that mix multiple independent entropy sources instead of trusting one. If you are holding serious Bitcoin, generate your seed with physical dice against the BIP39 wordlist and let the device calculate the checksum — the Blockstream Jade does exactly this, which is one of the reasons we recommend it.

If you want hardware that puts entropy and open-source verifiability in front of the marketing, that is what we point people to: https://loveisbitcoin.com/bull — and the coupon LOVEISBITCOIN gets you the deal.

Your keys are only as safe as the randomness they were born from.

What Beginners Should Do Next

No financial advice here, just the security basics nobody teaches you.

  • Find out how your wallet generates its seed. Not the brand. Not the box. The entropy source. If you cannot find the answer, that is your answer.
  • Never trust a browser-based wallet with a real stack. Browser JavaScript is a hostile place to generate cryptographic secrets. Qubic just proved it in public.
  • Prefer wallets that mix multiple independent entropy sources. One source can be broken. Four sources are hard to break at once.
  • Consider dice-generated seeds. Physical dice plus the BIP39 wordlist removes the software entirely from the most important step. Let the device calculate the final checksum word.
  • Test your recovery before you need it. Wipe the device, restore from the backup, confirm the addresses match. If you have never restored, you do not know that you can.
  • Move coins off any wallet whose seed generation you cannot verify. Sitting still is a decision too.

FAQ

What is entropy in a Bitcoin wallet?
Entropy is the randomness used to generate your seed phrase and, from it, your private keys. If that randomness is predictable, your keys can be recomputed by anyone who figures out the pattern.

What is wrong with Math.random()?
It is a JavaScript function built for convenience and speed, not for cryptography. It is deterministic and predictable. Cryptographically secure code uses crypto.getRandomValues() instead.

Was Bitcoin itself hacked in the Qubic attack?
No. Qubic is a separate Layer-1 chain, and Bitcoin’s protocol was not affected. The lesson applies to Bitcoin users because the same class of weak-entropy bug has already hit Coldcard, Trust Wallet, and Libbitcoin Explorer.

Does self-custody protect me from weak randomness?
No. Self-custody protects you from a custodian. It does nothing about bad math. If your seed was predictable, your coins were never really yours.

Are air-gapped hardware wallets always safer?
Not automatically. Air-gapping cuts off the host’s entropy, so a device with weak internal randomness can be the weakest link while looking like the strongest.

How do I generate a seed with dice?
Roll physical dice against the BIP39 wordlist, then let a verifiable device calculate the checksum word. Blockstream Jade supports exactly this method, which removes software from the most critical step.

Is this financial advice?
No. This is education. Verify your own setup before you move anything.

Final Thoughts

A blockchain with a billion-dollar narrative just froze itself because 1,400 people used a wallet that generated their "random" seed with a function designed to shuffle card decks.

Coldcard cost users $38 million the same way. Trust Wallet and Libbitcoin Explorer did it in 2023. The industry promised lessons were learned. They were not learned. They were rebranded.

So here is the question, and I want a real answer in the comments: do you actually know where your seed’s randomness came from — or did you just trust the logo on the box?

If you cannot answer that in one sentence, you have homework tonight.

This article is for education only and is not financial advice.

Previous

THEY SOLD YOU SELF-CUSTODY — THEN GENERATED YOUR SEED WITH MATH.RANDOM(). 1,400 WALLETS JUST WENT TO ZERO.

Related posts

Leave a Reply

Please authenticate to comment:

Required fields are marked *

⚡ Zap This!

Support this content with sats on Nostr

Zap QR

Lightning Address (tap to copy):

✅ Copied!

Or zap via Nostr client:

🟣 Open in Primal