The Oracle Problem & Decentralized Oracles

M-Zohaib Nasir
3 min readMar 9, 2022

As we know, smart contracts are similar to the contracts that people make between each other in the real world but instead of writing these contracts on pen and paper, the terms are written in form of code and automatically executed by the decentralized blockchain network instead of being executed by multiple intermediary parties.

The Oracle Problem:

The blockchain is a deterministic system, and this determinism means that it is like a walled garden. Everything that happens in these smart contracts and on this blockchain happens in this little box. They cannot inherently interact with data and systems existing outside their native blockchain environment. Resources external to the blockchain are considered “off-chain”, while data already stored on the blockchain is considered “on-chain”. By being purposely isolated from external systems, blockchains obtain their most valuable properties like strong consensus on the validity of user transactions, prevention of double-spending attacks, and lessening of network downtime. But, of course, if you want these smart contracts to be actually digitally superior agreements, then they need a way to interact with the real world to get real data and perform external outside-the-blockchain computation. This is where oracles come into play.

Oracles & Decentraliztion:

Oracles are devices that bring data into the blockchain or execute some sort of external computation. So, great oracles are the solution. Now blockchain can talk to the real world. Right? Well, not quite! Our blockchains and smart contracts are these decentralized applications and in order for them to stay decentralized they would also need to get their data and external computation from a decentralized manner as well. Your on-chain logic will be decentralized on the blockchain, but you’ll also need your off-chain data and external computations decentralized as well. Because the data delivered by oracles to blockchains directly determines the outcomes of smart contracts, it is critically important that the oracle mechanism is correct if the agreement is to execute exactly as expected.

Blockchain oracle mechanisms using a centralized entity to deliver data to a smart contract introduce a single point of failure, defeating the entire purpose of a decentralized blockchain application. If the single oracle goes offline, then the smart contract will not have access to the data required for execution or will execute improperly based on stale data.

Even worse, if the single oracle is corrupted, then the data being delivered on-chain may be highly incorrect and lead to smart contracts executing very wrong outcomes. This is commonly referred to as the “garbage in, garbage out” problem, where bad inputs lead to bad outputs. Additionally, because blockchain transactions are automated and immutable, a smart contract outcome based on faulty data cannot be reversed, meaning user funds can be permanently lost. Therefore, centralized oracles are a non-starter for smart contract applications.
Combining these on-chain logic settlement layers and these off-chain data and computation builds what’s called hybrid smart contracts and the large majority of Defi applications are these hybrid smart contracts.
*Smart contact is generally used interchangeably with hybrid smart contract.

Truly overcoming the oracle problem necessitates decentralized oracles to prevent data manipulation, inaccuracy, and downtime. A Decentralized Oracle Network, or DON for short, combines multiple independent oracle node operators and multiple reliable data sources to establish end-to-end decentralization.

Even more, many Chainlink DONs, such as Price Feeds, incorporate three layers of decentralization— at the data source, individual node operator, and oracle network levels — to eliminate any single point of failure. Chainlink Price Feeds already help secure tens of billions of dollars across smart contract ecosystems through this multi-layered decentralization approach, ensuring smart contracts can safely rely on data inputs during their execution.

Sign up to discover human stories that deepen your understanding of the world.

Free

Distraction-free reading. No ads.

Organize your knowledge with lists and highlights.

Tell your story. Find your audience.

Membership

Read member-only stories

Support writers you read most

Earn money for your writing

Listen to audio narrations

Read offline with the Medium app

M-Zohaib Nasir
M-Zohaib Nasir

No responses yet