Why does DeFi need a decentralized oracle?

Original title: “Viewpoint丨Why do we need a decentralized oracle? 》

Dear Bankless community:

The oracle is an important infrastructure of the cryptocurrency economy.

This is what the author of today said- without an oracle, the blockchain is like a computer without an Internet connection. They are isolated from the outside world and can only refer to the information in the blockchain’s internal ledger.

This limits the use of cryptocurrency.

The oracle solves this problem.

Want to get real-time price information of ETH/USD to measure the clearing threshold of DeFi protocols like Maker, Aave or Compound? You need an oracle.

Want to trade synthetic versions of AMZN, AAPL or TSLA? Oracle.

Oracles need to be highly secure, because many things depend on them. If data input is corrupted, people will lose money. We have seen this happen several times.

Since DeFi has so many things that rely on oracles, we should learn more about them. Today ChainlinkGod interpreted the value of decentralized oracles.

Let’s take a closer look.


Decentralized oracle network (DONs): powering the smart contract economy

Why does DeFi need a decentralized oracle?

Smart contracts are decentralized applications with coding logic (if x events occur, y actions are executed), and they are executed deterministically on the blockchain network.

The public chain is not maintained by a single centralized organization or a technology monopoly like Facebook, Google, or Apple, but by independent computer networks around the world. Through economic incentives, these computers reach a global consensus on the current state of the blockchain without any central node coordination. As many Bankless readers may know, this provides a range of valuable attributes such as censorship resistance, permissionless access, non-custodial asset management, and irreversible transactions.

However, there is a basic problem: the blockchain is like a computer without an Internet connection.

Why does DeFi need a decentralized oracle?

Blockchain only generates its strong security attributes by tracking the activities that occur in its own ledger. Therefore, the blockchain is actually an isolated network, and it cannot be naturally connected with external resources that may be required by smart contracts in the real world without losing all the properties that make the blockchain useful.

This is a problem because the vast majority of smart contract use cases require external data, such as access to the price of ETH to USD, the average temperature in Buenos Aires, the location of shipping containers with raw materials, another block The state of the chain network (such as BTC), or any other data that has not been stored on the blockchain’s native ledger.

Why does DeFi need a decentralized oracle?

In order to overcome the lack of external connections, an additional infrastructure is needed, the “oracles”, which obtains data from off-chain sources and transfers it to the blockchain so that smart contract applications can consume this information. The oracle not only provides a delivery mechanism for transmitting data on the chain, but also serves as a verification mechanism to ensure high data integrity. If the smart contract is to retain end-to-end certainty, the oracle mechanism needs to be as safe and reliable as the underlying blockchain, because the data input of the oracle directly determines the output of the consumer smart contract.

As the famous saying goes, garbage in leads to garbage out.

Therefore, the oracle mechanism cannot be a single centralized node , because this introduces a single point of failure, such as a node being destroyed or offline. This would defeat the entire purpose of using a blockchain network consisting of thousands of nodes. In addition, the oracle mechanism should not rely on a single data source, as the data source may provide incorrect data and/or lead to offline.

Why does DeFi need a decentralized oracle?

On the contrary, the oracle mechanism must be decentralized at the node operator and data source level to ensure that there are no points of failure. Although blockchain and oracles are designed to achieve different goals (the former provides transaction consensus and the latter provides consensus on real-world data), their complementarity means that similar approaches are taken to achieve security.

A properly secured decentralized oracle network (DON) must also provide additional layers of security, such as the ability to connect to high-quality data sources (providing accuracy and uptime guarantees), and data integrity through cryptographic signatures Proof (when the data provider runs the oracle node by itself), through the data verification of the multi-layer aggregation process (reducing downtime, outliers, and damaged data), the encryption economic guarantee that incentivizes correct operation (implicit incentives and explicit mortgages) , And optionally provide data privacy (such as zero-knowledge proof).

Why does DeFi need a decentralized oracle?

Chainlink-the most widely adopted oracle solution-follows this defense method and provides a common framework for the smart contract ecosystem to build DONs with open access to any external data resources.

Currently, there are more than 450 Chainlink Price Feeds operating in multiple blockchain networks , including Ethereum, Polygon, BSC, Avalanche, xDai and Heco, and plans to extend access to more blockchains and second-layer solutions Solutions, such as Arbitrum, Optimism, Solana, etc. The oracle network not only provides decentralized data feeds, but also provides a wide range of secure off-chain computing services, including verifiable randomness, Keepers, and other forms of off-chain computing under development, such as FSS, DECO, and Town Crier .

Why does DeFi need a decentralized oracle?

With proper security DON, developers can create a hybrid smart contract–Dapp, which combines blockchain-based smart contracts and DON services to provide more advanced functions than isolated on-chain logic. These applications leverage the advantages of the on-chain and off-chain worlds to enhance use cases that have long been the core value proposition of smart contracts.

Use case of decentralized oracle network (DON)

Although there is almost no limit to the number of hybrid smart contract use cases implemented by DON, I will introduce a few use cases that I think will be significant in the short, medium and long term (including examples of DeFi applications that you may already be familiar with). As the cryptocurrency ecosystem continues to innovate and advance, these use cases will continue to expand over time to meet the needs of its users.

Let’s take a closer look.

Decentralized finance and price feedback

The first and most important use case of the DON-powered hybrid smart contract we see today is decentralized finance, also known as DeFi. It can be said that DeFi is a product market for blockchain technology, which provides a decentralized, permissionless, non-regulated, and anti-censorship alternative to replace today’s broken traditional financial system. However, what people don’t understand is that the DeFi ecosystem is possible because of the existence of DONs.

For example, based on the total value currently locked, the number one DeFi application is Aave, which is a decentralized currency market that allows users to lend and borrow dozens of different on-chain tokens.

This creates a two-sided market where lenders can obtain passive income from their idle tokens, while borrowers can obtain working capital and deploy as they please. Decentralized currency market protocols like Aave, Compound, Cream, Rari, etc., in the process of creating a position, use Chainlink Price Feeds to calculate the maximum loan size and determine when the position becomes under-collateralized and must be liquidated. Maintain the solvency of the entire market.

Why does DeFi need a decentralized oracle?

Although today’s DeFi-based currency market pays special attention to the lending of native cryptocurrencies and stablecoins, in the future , new markets can and will be created to support tokenized real-world assets. For example, this allows users to use tokenized real estate loans to replace mortgage loans, or borrow CBDCs to fund their businesses. As a general infrastructure, this market can theoretically support any type of tokenized assets. Due to token standards such as ERC20 and ERC721, these assets will exist in a backward compatible manner.

Another powerful financial function realized through Chainlink DONs is Synthetix and other protocols, which enable users to generate synthetic assets over-collateralized by on-chain cryptocurrency (SNX) and reflect the price of real-world assets, such as cryptocurrency (e. BTC, ETH, LINK), legal currencies (such as US dollar, Euro, Japanese yen), commodities (such as gold, silver, oil), indices (such as FTSE, N225, sDEFI), and stocks (such as TSLA, GOOG, AMZN). With the support of the global debt pool, users can “exchange” their synthetic assets with any other synthetic assets with zero slippage by simply switching the data source that determines the value of their token.

Why does DeFi need a decentralized oracle?

Through the combination of on-chain collateral and Chainlink data feeds, any synthetic version of assets or indicators in the real world can be brought onto the chain and into the cryptocurrency economy, including property valuation, CPI indicators, total value of raw materials, and specific agreements The number of fans of TVL, Vitalik on Twitter, or other indicators that can be quantified and digitized as data feeds on the chain.

The potential here is almost limitless, allowing users to tokenize anything and start speculation and hedging without having to leave the on-chain ecosystem.

There are many other use cases enabled by DON in the DeFi ecosystem, such as decentralized/algorithmic stablecoins, yield aggregators, decentralized exchanges, perpetual coins, options, futures, retrospective tokens, prediction markets, yields Farming, asset management, cross-chain tokens, fixed interest rates, etc.

Dynamic NFTs and verifiable randomness

In 2021, the public attention of NFTs will greatly increase, and the transaction volume and the diversity of minted tokens will increase exponentially. Although many of these NFTs are static pictures or gifs, we have also seen the rise of dynamic NFTs supported by the NFT platform, such as ether cards, which gamify the experience of acquiring and owning NFTs through external data input.

These external inputs may include real-world data that changes the properties of the NFT in real time. This includes sports NFTs whose value is linked to player performance data or NFT markets that allow artists to change their digital artwork over time, such as NFTs that change the image background based on the weather and time of New York City. An increasingly common way for NFT and on-chain game applications to be enhanced by external data is to use verifiable randomness solutions, such as Chainlink’s Verifiable Random Function (VRF).

With verifiable randomness, developers can enhance their NFT by assigning provable random features, distributions, and coinage activities. Aavegotchi is an example of an NFT-based platform that takes advantage of the verifiable randomness on the Polygon sidechain.

At the time of launch, Aavegotchi’s smart contract required thousands of randomizations on the chain to determine which Aavegotchi NFTs the user would get after opening the “portal” (their supply is limited, only 10,000). Through this kind of randomness-based gamification, users can participate in the “rarity farming meta-game,” where users try to forge rare NFTs or upgrade the ranks of existing NFTs by winning lotteries and other games.

Why does DeFi need a decentralized oracle?

Another typical example includes the increasingly popular NFT-based on-chain game application Axie Infinity, which uses verifiable randomness to determine the characteristics of newly minted Origin Axies. Such Axies can have the opportunity to own mysterious parts, and these parts have historically sold for more than 300 ETH.

By creating dynamic NFTs, a brand new user experience is introduced, which is unmatched in the Web2.0 world.

On-chain audit trail and proof of reserve

With the development of the smart contract ecosystem, the number of stablecoins, packaged cross-chain assets, and tokenized real-world assets is also increasing. However, the collateral supporting these tokens is located off-chain, which means that smart contracts cannot naturally access the data required to audit these tokens and ensure proper collateral.

The result is new risks related to transparency, insufficient collateral and partial reserve loans. DONs can overcome this problem through proof-of-reserve (PoR) feeding, which provides the necessary on-chain data to verify the off-chain collateral of a token.

By performing on-chain audit trails on the tokens mortgaged by off-chain assets, users can obtain more transparency. Smart contracts can be executed when insufficient mortgage is detected by implementing specific application logic to quickly prevent unforeseen parts. Reserve activities. For example, DeFi applications can temporarily suspend service or prevent more tokens from being minted from specific under-collateralized assets. Proof of reserve not only helps prevent systemic risks like the 2008 financial crisis, but also creates a more trustworthy DeFi ecosystem for everyone.

In the case of stable currency, the US dollar in the bank account outside the chain is usually used as collateral. We see that Paxo’s PAX stable currency and TrustToken’s TUSD stable currency have feedback on proof of reserve. For the latter, the reserve data is provided by Armanino, a top 25 audit company in the United States that provides real-time updates to prove TrustToken’s off-chain dollar bank holdings and supports the TUSD stable currency. Given that TUSD exists on multiple blockchains, they have launched a data feed of proof of reserve and proof of supply on Ethereum. Before allowing users to use stablecoins to participate in economic activities, they can be cross-referenced through smart contract applications.

Why does DeFi need a decentralized oracle?

In addition to USD-backed stablecoins, we are also seeing the inevitable multi-chain reality being staged. Users hope to bridge their cryptocurrencies between blockchains, such as bringing their BTC to Ethereum, so that it will Can be used with DeFi ecosystem. In this case, we have seen Ren Protocol’s renBTC and BitGo’s WBTC have both launched proof of reserves to audit the real BTC holdings supporting these cross-chain tokens on the Bitcoin blockchain. Similarly, smart contracts can refer to these feeds before allowing interaction with cross-chain tokens to protect users from unsupported tokens, such as opening bad loans or conducting unfair transactions.

Why does DeFi need a decentralized oracle?

The concept of enabling DON’s proof of reserve goes far beyond these use cases, allowing the auditing of real-world asset-backed tokens, such as tokenized real estate. This includes providing verification information on property ownership and cash flow on the blockchain, allowing users and smart contracts to analyze the true nature of the assets supporting these tokens. As the DeFi economy swallows the traditional economy, the demand for on-chain transparency will continue to increase.

Off-chain computing and custodian

Regarding the nature of smart contracts, a common misunderstanding is that they are autonomous, but in fact they are “sleeping” by default and must be “awakened” to perform any state changes. This requires an on-chain transaction signed and initiated by the private key holder, also known as an externally owned account (EOA). This is acceptable for use cases where users interact on the chain themselves, but there are many smart contract functions that need to be triggered on a standardized time or event-based schedule.

Although DON is known for providing data delivery services, they can also perform off-chain calculations that minimize trust. This includes providing decentralized transaction automation services in the form of “guardians”, monitoring the on-chain status of smart contracts and/or real-world events, so as to autonomously trigger on-chain functions as needed. One implementation of this is Chainlink Keepers, which utilizes the same set of reliable oracle nodes that have proven their reliability by operating decentralized data sources.

One use case for Keepers is the automatic liquidation of undersecured loans in decentralized currency markets such as Aave. Here, Keepers will monitor the position on the platform and trigger the liquidation function for any loan below the liquidation threshold of a specific fund pool. Then, Aave’s smart contract will verify the on-chain liquidation by cross-referencing Chainlink Price Feeds, and then start the liquidation process. Therefore, the currency market will provide users with more guarantees about the solvency of the platform through highly reliable clearing robots.

Why does DeFi need a decentralized oracle?

Given that Keepers provides a general transaction automation service, any smart contract function can be automated, including executing limit orders, harvesting yields, issuing betting rewards, re-issuing algorithmic stablecoins, releasing existing tokens, recharging token balances, and managing debts Positions, changing yield strategies, etc.

in conclusion

Decentralized oracle networks (DONs) expand the capabilities of blockchain networks and smart contract applications, enabling them to realize their true potential, which is to provide superior digital protocols that perform exactly as expected for a wide range of use cases.

Although DeFi is currently the most obvious evidence, it is more likely that the next major smart contract use case to be adopted on a large scale will be the direct result of developers accessing real-world data of DONs on the chain.

Many unimaginable use cases are possible, and the future has never been so bright.

Written by: ChainLinkGod
Translation: Mike Jin


Posted by:CoinYuppie,Reprinted with attribution to:https://coinyuppie.com/why-does-defi-need-a-decentralized-oracle/
Coinyuppie is an open information publishing platform, all information provided is not related to the views and positions of coinyuppie, and does not constitute any investment and financial advice. Users are expected to carefully screen and prevent risks.

Leave a Reply