Why have cross-chain bridges been a common target for large hacks, and how would you design a safer cross-chain system?
What the interviewer wants to hear
- Bridges hold large pooled funds and rely on message verification
- Weak validator sets or key compromise
- Bugs in message verification logic
- Prefer native or proof-based verification, or burn-and-mint designs
- Rate limits, delays, monitoring and defence in depth
Model answer
Bridges usually lock assets on one chain and mint wrapped versions on another, so the lock contract holds huge pooled funds, making it a prime target. Security depends entirely on how the destination chain verifies that a deposit really happened. Many hacks came from small validator sets or multisigs where attackers stole enough keys, like the Ronin hack, or from bugs in signature and message verification, like Wormhole and Nomad. For a safer design, I would prefer verification that does not depend on a few trusted signers: the canonical rollup bridge for L2s, light clients or ZK proofs of source-chain state, or established messaging protocols with independent verifier networks. Where possible, use burn-and-mint for tokens we control, which avoids a single big honeypot. I would add rate limits per time window, delays for large transfers, independent monitoring with automatic pause, and audits focused on message encoding and replay protection.
Can you answer it under time pressure?
Take a timed hard round and get scored on every answer.
More hard Blockchain Developer questions
- You are designing a new lending protocol. What are the biggest security risks and how do you address them?
- What is MEV, and how would you protect your protocol's users from harmful MEV?
- How do you prepare a codebase for a security audit, and what happens after the audit?
- How do you decide what logic and data should live on chain versus off chain in a dApp?
- Your protocol is being exploited right now on mainnet. What do you do in the first hour and afterwards?
- How does EIP-7702 change assumptions that smart contracts and dApps make about EOAs, and what would you change in your code?
- How do you make sure an upgrade to a proxy-based contract does not corrupt storage or break the system?
- You are building an ERC-4626 yield vault. What design and security issues do you consider?
- Your team wants to deploy the same protocol to five EVM chains, including L2s. What can go wrong and how do you prepare?