MakerDAO Oracles: The Backbone of Decentralized Finance Niklas Kunkel MakerDAO Oracles V1 • Individuals/orgs that push asset prices • Currently 15 of them • Oracle price is the median of all Feeds • Appointed by MKR Governance Feed Oracle V1 Architecture • Redundant Transactions • Expensive On-Chain Operations e.g., sorting • Reliability and Accuracy during network congestion • Scalability & Costs Problems Why not use on-chain price sources? e.g., Uniswap, OasisDEX, Kyber 1. On-Chain Liquidity << Off-Chain Liquidity 2. Atomic Synchronous Transaction Bundling Vulnerability Criticism An attacker can atomically execute a sequence of transactions in a single block to manipulate the price while only losing gas fees with zero risk. Recently published exploits compromise DDEX and Fulcrum (bZx) due to sourcing prices from Uniswap, Kyber, and OasisDEX respectively. DEX as an Oracle is an Anti-Pattern “DDEX and bZx assumed that Uniswap and Kyber would be a source of accurate price data. However, an accurate rate for a DEX means that a trade can be made using that rate, while an accurate rate for a DeFi project means that it is close to the FMV.” - samczsun Oracles V2 • Scalability • Reduce Costs • Reliability • Latency Goals • P2P Gossip Network Protocol • Everything is a message, messages are JSON • Similar to a blockchain: immutable hash-linked message chain Secure Scuttlebutt Strategy: Offload computation off-chain as much as possible Reduce # of transactions from O(N) to O(1) Reduce # of SSTORE operations from 2N to 2 Blockchain agnostic & data-agnostic Oracle V2 Architecture • Dark Feeds are pseudonymous individuals/orgs that submit price data. • Dark Feeds are pseudonymous out of necessity to prevent Oracle attacks. • Downside to Dark Feeds: 1. No sybil-resistance 2. Users don’t trust pseudonymous Feeds Dark Feeds • Light Feeds are organizations with public identities • Organizations are more resilient against coercion. • Users trust the reputation of organizations • A hybrid model is optimal; one which preserves hardness properties of Dark Feeds but benefits from the reputation of stakeholders in the ecosystem. Light Feeds Governance This morning, MKR Governance ratified 4 Oracle proposals. 1. DeFi Public Feed Proposal 2. Oracle Incentives Restructuring Proposal 3. Responsible Oracle Migration Proposal 4. Oracle Team Mandate Proposal Proposals Appoint each of the following DeFi organizations to run a Light Feed. DeFi Light Feed Proposal • Decentralized systems, do not just need to be self-governed but also self-sustainable systems. • Feeds are paid monthly by MKR token holders in Dai. • Access to Oracle prices is governed by a whitelist controlled by MKR Governance. • Data consumers pay MKR token holders monthly in Dai to utilize the Oracles. Oracle Incentives Restructuring Proposal • MakerDAO’s Oracles V1 have seen enormous proliferation throughout the DeFi space. The DAO has a responsibility to its users. • This makes it very challenging to plan a migration. • Oracle V1 will run in parallel with Oracles V2 until at least single-collateral Dai is shutdown (6+ months). • Anyone can get whitelisted access to any Oracle for free for one year. • This allows us to support innovation within the ecosystem while still maintaining a long-term benefit Responsible Oracle Migration Proposal Join the community @MakerDAO r/MakerDAO makerdaoOfficial chat.makerdao.com forum.makerdao.com