Software oracles
The most common kind of oracle is software that aggregates data already available on the internet and feeds it to a Smart Contract, such as price data for cryptocurrencies.
Hardware Oracles
Some blockchain-based applications need to reference data from the physical world, which can only come through a piece of hardware such as a sensor or scanner. This could include data on weather, traffic or physical sales.
Human Oracles
Sometimes the source of data can only be provided via a human, who feeds the data into an oracle application and signs it cryptographically. An example could be in-game data from a low tier tennis match powering a betting dApp.
Each type of oracle simply delivers data to a destination, but the manner and direction can vary.
Input oracle – The most common type of oracle fetches off-chain data (from the outside world) and feeds it into blockchain applications.
Output oracle – In some cases, an oracle can push data in the other direction, from a blockchain (on-chain) to an external service. This could be because a Smart Contract has a function to trigger a bank payment when a certain condition is met.
Cross-chain oracle – Though enabling blockchains to exchange data without the outside world is hugely important, the same is true of data sharing between blockchains. Cross-chain oracles enable this, though they face the difficulty of reconciling different consensus methods.
Computer Enabled – In some cases, an oracle can act as a random number generator for a Smart Contract with the outcome confirmed on-chain before the dApp uses it. A good example is a lottery draw where the oracle acts as a VRF – verified random function – the equivalent of the ball machine you might have seen in televised lottery draws.
Though there are many ways for oracles to access information and feed it into Smart Contracts, they risk becoming a single point of failure for blockchain applications and open up the potential for data manipulation. This challenge is known as the Oracle Problem and has no easy solution.
Leave a Reply