Oracle Infrastructure: Chainlink Proposal

The contracts have been deployed!

Contract Address/UniswapAnchorView config:

Reported Prices
The proposed UniswapAnchoredView has prices pushed to it by production Chainlink Price Feeds, each through a ValidatorProxy (a reporter). The frequency of the updates depends on a number of triggers, namely:

  • Deviation threshold - when a price is witnessed to have moved more than x% of the previously reported price.
  • Heartbeat threshold - If x minutes have passed without an update.

More information can be found on data.chain.link. Example: ETH / USD.

Price update events can be witnessed on the Etherscan events tab.

Market Configurations
The configuration of each market in the new UAV (which is mostly similar to the current one).

  • cToken - address
  • underlying - address
  • symbolHash - bytes32
  • baseUnit - unit256
  • PriceSource - priceSource
  • fixedPrice - unit256
  • uniswapMarket - address
  • reporter - address (new)
  • reporterMultiplier - unit256 (new)
  • isUniswapReversed - bool

reporter and reporterMultiplier are new.

  • reporter is the address that submits prices for a particular cToken. This is always a ValidatorProxy contract that is called by a price feed aggregator contract for each relevant price update posted by Chainlink oracle nodes. In this case, 0xeBa6F33730B9751a8BA0b18d9C256093E82f6bC2 is the reporter of the price of BAT.
  • reporterMultiplier is used to transform the price reported by the reporter to the correct base unit that the UniswapAnchoredView expects. This is required because Chainlink Price Feeds report prices with different decimal placement than the UniswapAnchoredView.

Here is a breakdown of all of the configs

ETH
  • cToken: 0x4Ddc2D193948926D02f9B1fE9e1daa0718270ED5
  • underlying: 0x0000000000000000000000000000000000000000
  • symbolHash: 0xaaaebeba3810b1e6b70781f14b2d72c1cb89c0b2b320c43bb67ff79f562f5ff4
  • baseUnit: 1000000000000000000
  • priceSource: 2
  • fixedPrice: 0
  • uniswapMarket: 0xB4e16d0168e52d35CaCD2c6185b44281Ec28C9Dc
  • reporter: 0x264BDDFD9D93D48d759FBDB0670bE1C6fDd50236
  • reporterMultiplier: 10000000000000000
  • isUniswapReversed: true
USDC
  • cToken: 0x39AA39c021dfbaE8faC545936693aC917d5E7563
  • underlying: 0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48
  • symbolHash: 0xd6aca1be9729c13d677335161321649cccae6a591554772516700f986f942eaa
  • baseUnit: 1000000
  • priceSource: 1
  • fixedPrice: 1000000
  • uniswapMarket: 0x0000000000000000000000000000000000000000
  • reporter: 0x0000000000000000000000000000000000000000
  • reporterMultiplier: 1
  • isUniswapReversed: false
DAI
  • cToken: 0x5d3a536E4D6DbD6114cc1Ead35777bAB948E3643
  • underlying: 0x6b175474e89094c44da98b954eedeac495271d0f
  • symbolHash: 0xa5e92f3efb6826155f1f728e162af9d7cda33a574a1153b58f03ea01cc37e568
  • baseUnit: 1000000000000000000
  • priceSource: 2
  • fixedPrice: 0
  • uniswapMarket: 0xA478c2975Ab1Ea89e8196811F51A7B7Ade33eB11
  • reporter: 0xb2419f587f497CDd64437f1B367E2e80889631ea
  • reporterMultiplier: 10000000000000000
  • isUniswapReversed: false
WBTC
  • cToken: 0xC11b1268C1A384e55C48c2391d8d480264A3A7F4
  • underlying: 0xC11b1268C1A384e55C48c2391d8d480264A3A7F4
  • symbolHash: 0xe98e2830be1a7e4156d656a7505e65d08c67660dc618072422e9c78053c261e9
  • baseUnit: 100000000
  • priceSource: 2
  • fixedPrice: 0
  • uniswapMarket: 0xBb2b8038a1640196FbE3e38816F3e67Cba72D940
  • reporter: 0x4846efc15CC725456597044e6267ad0b3B51353E
  • reporterMultiplier: 1000000
  • isUniswapReversed: false
USDT
  • cToken: 0xf650C3d88D12dB855b8bf7D11Be6C55A4e07dCC9
  • underlying: 0xdac17f958d2ee523a2206206994597c13d831ec7
  • symbolHash: 0x8b1a1d9c2b109e527c9134b25b1a1833b16b6594f92daa9f6d9b7a6024bce9d0
  • baseUnit: 1000000
  • priceSource: 1
  • fixedPrice: 1000000
  • uniswapMarket: 0x0000000000000000000000000000000000000000
  • reporter: 0x0000000000000000000000000000000000000000
  • reporterMultiplier: 1
  • isUniswapReversed: false
UNI
  • cToken: 0x35A18000230DA775CAc24873d00Ff85BccdeD550
  • underlying: 0x1f9840a85d5af5bf1d1762f925bdaddc4201f984
  • symbolHash: 0xfba01d52a7cd84480d0573725899486a0b5e55c20ff45d6628874349375d1650
  • baseUnit: 1000000000000000000
  • priceSource: 2
  • fixedPrice: 0
  • uniswapMarket: 0xd3d2E2692501A5c9Ca623199D38826e513033a17
  • reporter: 0x70f4D236FD678c9DB41a52d28f90E299676d9D90
  • reporterMultiplier: 10000000000000000
  • isUniswapReversed: false
COMP
  • cToken: 0x70e36f6BF80a52b3B46b3aF8e106CC0ed743E8e4
  • underlying: 0xc00e94cb662c3520282e6f5717214004a7f26888
  • symbolHash: 0xb6dbcaeee318e11fe1e87d4af04bdd7b4d6a3f13307225dc7ee72f7c085ab454
  • baseUnit: 1000000000000000000
  • priceSource: 2
  • fixedPrice: 0
  • uniswapMarket: 0xCFfDdeD873554F362Ac02f8Fb1f02E5ada10516f
  • reporter: 0xE270B8E9d7a7d2A7eE35a45E43d17D56b3e272b1
  • reporterMultiplier: 10000000000000000
  • isUniswapReversed: false
ZRX
  • cToken: 0xB3319f5D18Bc0D84dD1b4825Dcde5d5f7266d407
  • underlying: 0xe41d2489571d322189246dafa5ebde1f4699f498
  • symbolHash: 0xb8612e326dd19fc983e73ae3bc23fa1c78a3e01478574fa7ceb5b57e589dcebd
  • baseUnit: 1000000000000000000
  • priceSource: 2
  • fixedPrice: 0
  • uniswapMarket: 0xc6F348dd3B91a56D117ec0071C1e9b83C0996De4
  • reporter: 0x5c5db112c98dbe5977A4c37AD33F8a4c9ebd5575
  • reporterMultiplier: 10000000000000000
  • isUniswapReversed: true
BAT
  • cToken: 0x6C8c6b02E7b2BE14d4fA6022Dfd6d75921D90E4E
  • underlying: 0x0d8775f648430679a709e98d2b0cb6250d2887ef
  • symbolHash: 0x3ec6762bdf44eb044276fec7d12c1bb640cb139cfd533f93eeebba5414f5db55
  • baseUnit: 1000000000000000000
  • priceSource: 2
  • fixedPrice: 0
  • uniswapMarket: 0xB6909B960DbbE7392D405429eB2b3649752b4838
  • reporter: 0xeBa6F33730B9751a8BA0b18d9C256093E82f6bC2
  • reporterMultiplier: 10000000000000000
  • isUniswapReversed: false
TUSD
  • cToken: 0x12392F67bdf24faE0AF363c24aC620a2f67DAd86
  • underlying: 0x0000000000085d4780B73119b644AE5ecd22b376
  • symbolHash: 0xa1b8d8f7e538bb573797c963eeeed40d0bcb9f28c56104417d0da1b372ae3051
  • baseUnit: 1000000000000000000
  • priceSource: 1
  • fixedPrice: 1000000
  • uniswapMarket: 0x0000000000000000000000000000000000000000
  • reporter: 0x0000000000000000000000000000000000000000
  • reporterMultiplier: 1
  • isUniswapReversed: false
LINK
  • cToken: 0xFAce851a4921ce59e912d19329929CE6da6EB0c7
  • underlying: 0x514910771af9ca656af840dff83e8264ecf986ca
  • symbolHash: 0x921a3539bcb764c889432630877414523e7fbca00c211bc787aeae69e2e3a779
  • baseUnit: 1000000000000000000
  • priceSource: 2
  • fixedPrice: 0
  • uniswapMarket: 0xa2107FA5B38d9bbd2C461D6EDf11B11A50F6b974
  • reporter: 0xBcFd9b1a97cCD0a3942f0408350cdc281cDCa1B1
  • reporterMultiplier: 10000000000000000
  • isUniswapReversed: false
SAI
  • cToken: 0xF5DCe57282A584D2746FaF1593d3121Fcac444dC
  • underlying: 0x89d24a6b4ccb1b6faa2625fe562bdd9a23260359
  • symbolHash: 0x4dcbfd8d7239a822743634e138b90febafc5720cec2dbdc6a0e5a2118ba2c532
  • baseUnit: 1000000000000000000
  • priceSource: 0
  • fixedPrice: 5285000000000000
  • uniswapMarket: 0x0000000000000000000000000000000000000000
  • reporter: 0x0000000000000000000000000000000000000000
  • reporterMultiplier: 1
  • isUniswapReversed: false
REP
  • cToken: 0x158079Ee67Fce2f58472A96584A73C7Ab9AC95c1
  • underlying: 0x1985365e9f78359a9B6AD760e32412f4a445E862
  • symbolHash: 0x91a08135082b0a28b4ad8ecc7749a009e0408743a9d1cdf34dd6a58d60ee9504
  • baseUnit: 1000000000000000000
  • priceSource: 2
  • fixedPrice: 0
  • uniswapMarket: 0x8979A3Ef9D540480342AC0F56e9D4c88807b1CBa
  • reporter: 0x90655316479383795416B615B61282C72D8382C1
  • reporterMultiplier: 10000000000000000
  • isUniswapReversed: false

Compound Community Multisig Ownership
The owner of the proposed UniswapAnchoredView has the power to activate and deactivate the failover mechanism for each market. This was implemented based on community feedback and in case any low liquidity market on Uniswap v2 needs to be deactivated.

Currently, the community multisig is not the owner. However, the current owner has proposed a transfer of ownership in this transaction. To obtain ownership, the multisig must call acceptOwnership() at the proposed UniswapAnchoredView address: 0x34aB75D077c148F1eCAa435e7125c16842A0AeA3

Trail of Bits Audit
Trail of Bits was commissioned for audit of the contracts. Here is a link to it: link

Next Steps
Now that everything is deployed and ready for a vote the community can review the changes. I am aiming to create a governance proposal Tuesday the 1st or Wednesday the 2nd. Feel free to shoot me a message on Discord or post your questions/comments here.

11 Likes