back to lessons
$ ~/learn/oracles-and-bridges cat
6 min read
// 14 · infrastructure

Oracles & bridges

Blockchains can't see the outside world or each other on their own — oracles and bridges are the plumbing that connects them, and the biggest attack surface in crypto.

> What oracles do

A smart contract can't natively fetch a price, a sports score, or a weather report. Oracles (Chainlink, Pyth, RedStone) are networks of nodes that fetch off-chain data, aggregate it, and push it on-chain. DeFi lending, derivatives, and stablecoins all depend on them.

> Bridges connect chains

A bridge locks tokens on chain A and mints an equivalent representation on chain B. When you move ETH from Ethereum to Arbitrum, that's a bridge. Native bridges (built by the chain team) are safer than third-party bridges.

> Why they get hacked

Bridges concentrate huge amounts of value in a single contract or multisig — over $2 billion has been stolen from bridge exploits alone. Rule of thumb: minimize how much you keep bridged and prefer canonical, well-audited bridges only.