Compound Price Feed Error: Difference between revisions

From Quadriga Initiative Cryptocurrency Hacks, Scams, and Frauds Repository
Jump to navigation Jump to search
(Created page with "{{Imported Case Study|source=https://www.quadrigainitiative.com/casestudy/compoundpricefeederror.php}} thumb|Compound FinanceCompound Finance relied on CoinBase for the price of DAI stablecoins. In a time of rapid market crash, the price on CoinBase went above $1.30 on CoinBase, while other services had prices around $1.03. This caused customers who had loans to fall below the required backing and get liquidated. This is a global/internatio...")
 
No edit summary
Line 1: Line 1:
{{Imported Case Study|source=https://www.quadrigainitiative.com/casestudy/compoundpricefeederror.php}}
{{Imported Case Study|source=https://www.quadrigainitiative.com/casestudy/compoundpricefeederror.php}}
{{Unattributed Citations}}


[[File:Compoundfinance.jpg|thumb|Compound Finance]]Compound Finance relied on CoinBase for the price of DAI stablecoins. In a time of rapid market crash, the price on CoinBase went above $1.30 on CoinBase, while other services had prices around $1.03. This caused customers who had loans to fall below the required backing and get liquidated.
[[File:Compoundfinance.jpg|thumb|Compound Finance]]Compound Finance relied on CoinBase for the price of DAI stablecoins. In a time of rapid market crash, the price on CoinBase went above $1.30 on CoinBase, while other services had prices around $1.03. This caused customers who had loans to fall below the required backing and get liquidated.


This is a global/international case not involving a specific country.
This is a global/international case not involving a specific country.
<ref name="slowmisthacked-678" /><ref name="compdotxyz-1795" /><ref name="newsdotbitcoin-1796" /><ref name="compoundfinance-1797" /><ref name="cointelegraph-1798" /><ref name="blockonomi-1799" /><ref name="scottlewistwitter-1800" /><ref name="rleshnertwitter-1801" /><ref name="compdotxyz-1802" /><ref name="compdotxyz-1803" /><ref name="googledoc-1804" /><ref name="cryptoglobe-1805" /><ref name="arbingsamtwitter-1806" /><ref name="certik-1776" /><ref name="rektnews-3728" />


== About Compound Finance ==
== About Compound Finance ==
Line 51: Line 53:


Don't Include:
Don't Include:
* Any wording which directly states or implies that the business is/was illegitimate, or that a vulnerability existed.
* Any wording which directly states or implies that the business is/was illegitimate, or that a vulnerability existed.
* Anything that wasn't reasonably knowable at the time of the event.
* Anything that wasn't reasonably knowable at the time of the event.
Line 73: Line 74:
|-
|-
|November 26th, 2020 12:00:00 AM
|November 26th, 2020 12:00:00 AM
|First Event
|Main Event
|This is an expanded description of what happened and the impact. If multiple lines are necessary, add them here.
|Expand this into a brief description of what happened and the impact. If multiple lines are necessary, add them here.
|-
|
|
|
|-
|-
|
|
Line 86: Line 83:


== Total Amount Lost ==
== Total Amount Lost ==
The total amount lost is unknown.
The total amount lost has been estimated at $4,000,000 USD.


How much was lost and how was it calculated? If there are conflicting reports, which are accurate and where does the discrepancy lie?
How much was lost and how was it calculated? If there are conflicting reports, which are accurate and where does the discrepancy lie?
Line 97: Line 94:


== Total Amount Recovered ==
== Total Amount Recovered ==
It is unknown how much was recovered.
There do not appear to have been any funds recovered in this case.


What funds were recovered? What funds were reimbursed for those affected users?
What funds were recovered? What funds were reimbursed for those affected users?
Line 105: Line 102:


== Prevention Policies ==
== Prevention Policies ==
 
Which policies could have prevented this event from happening?


== References ==
== References ==
[https://hacked.slowmist.io/en/?c=ETH%20DApp SlowMist Hacked - SlowMist Zone] (May 17)
<references><ref name="slowmisthacked-678">[https://hacked.slowmist.io/en/?c=ETH%20DApp SlowMist Hacked - SlowMist Zone] (May 17, 2021)</ref>


[https://www.comp.xyz/t/fix-the-compound-oracle-problem/723 Fix the Compound oracle problem - Ideas - Compound Community Forum] (Jul 23)
<ref name="compdotxyz-1795">[https://www.comp.xyz/t/fix-the-compound-oracle-problem/723 Fix the Compound oracle problem - Ideas - Compound Community Forum] (Jul 23, 2021)</ref>


[https://news.bitcoin.com/100-million-liquidated-on-defi-protocol-compound-following-oracle-exploit/ $100 Million Liquidated on Defi Protocol Compound Following Oracle Exploit – News Bitcoin News] (Jul 23)
<ref name="newsdotbitcoin-1796">[https://news.bitcoin.com/100-million-liquidated-on-defi-protocol-compound-following-oracle-exploit/ $100 Million Liquidated on Defi Protocol Compound Following Oracle Exploit – News Bitcoin News] (Jul 23, 2021)</ref>


[https://compound.finance/ Compound] (Jul 23)
<ref name="compoundfinance-1797">[https://compound.finance/ Compound] (Jul 23, 2021)</ref>


[https://cointelegraph.com/news/compound-liquidator-makes-4m-as-oracles-post-inflated-dai-price Compound liquidator makes $4M as oracles post inflated Dai price] (Jul 23)
<ref name="cointelegraph-1798">[https://cointelegraph.com/news/compound-liquidator-makes-4m-as-oracles-post-inflated-dai-price Compound liquidator makes $4M as oracles post inflated Dai price] (Jul 23, 2021)</ref>


[https://blockonomi.com/chainlink-compound-liquidations/ To Chainlink? That's the DeFi Question: Exploring the Recent Compound Liquidations] (Jul 23)
<ref name="blockonomi-1799">[https://blockonomi.com/chainlink-compound-liquidations/ To Chainlink? That's the DeFi Question: Exploring the Recent Compound Liquidations] (Jul 23, 2021)</ref>


[https://twitter.com/scott_lew_is/status/1332034944298782728 @scott_lew_is Twitter] (Jul 23)
<ref name="scottlewistwitter-1800">[https://twitter.com/scott_lew_is/status/1332034944298782728 @scott_lew_is Twitter] (Jul 23, 2021)</ref>


[https://twitter.com/rleshner/status/1332139014334287872 @rleshner Twitter] (Jul 23)
<ref name="rleshnertwitter-1801">[https://twitter.com/rleshner/status/1332139014334287872 @rleshner Twitter] (Jul 23, 2021)</ref>


[https://www.comp.xyz/t/dai-liquidation-event/642 DAI Liquidation Event - Compound Community Forum] (Jul 23)
<ref name="compdotxyz-1802">[https://www.comp.xyz/t/dai-liquidation-event/642 DAI Liquidation Event - Compound Community Forum] (Jul 23, 2021)</ref>


[https://www.comp.xyz/t/dai-liquidation-event/642/4 DAI Liquidation Event - #4 by cryptoguy123 - Compound Community Forum] (Jul 23)
<ref name="compdotxyz-1803">[https://www.comp.xyz/t/dai-liquidation-event/642/4 DAI Liquidation Event - #4 by cryptoguy123 - Compound Community Forum] (Jul 23, 2021)</ref>


[https://docs.google.com/spreadsheets/d/1ozVGA7mwn-xFQb1oAKsNczMRL-Dj9JgG_0UXH2IQ1s8 DAI Liquidations - Google Sheets] (Jul 23)
<ref name="googledoc-1804">[https://docs.google.com/spreadsheets/d/1ozVGA7mwn-xFQb1oAKsNczMRL-Dj9JgG_0UXH2IQ1s8 DAI Liquidations - Google Sheets] (Jul 23, 2021)</ref>


[https://www.cryptoglobe.com/latest/2020/11/103-million-liquidated-on-defi-protocol-compound-after-dai-price-rise/ $103 Million Liquidated on DeFi Protocol Compound After DAI Price Rise | Cryptoglobe] (Jul 23)
<ref name="cryptoglobe-1805">[https://www.cryptoglobe.com/latest/2020/11/103-million-liquidated-on-defi-protocol-compound-after-dai-price-rise/ $103 Million Liquidated on DeFi Protocol Compound After DAI Price Rise | Cryptoglobe] (Jul 23, 2021)</ref>


[https://twitter.com/arbingsam/status/1331922588193484800 @arbingsam Twitter] (Jul 23)
<ref name="arbingsamtwitter-1806">[https://twitter.com/arbingsam/status/1331922588193484800 @arbingsam Twitter] (Jul 23, 2021)</ref>


[https://www.certik.org/blog/blockchain-hacks-2020-15-billion-lost-how-can-we-mitigate-hacks-in-2021 Blockchain Hacks: 2020 | $15 billion lost, how can we mitigate hacks in 2021? | CertiK Foundation Blog] (Jul 22)
<ref name="certik-1776">[https://www.certik.org/blog/blockchain-hacks-2020-15-billion-lost-how-can-we-mitigate-hacks-in-2021 Blockchain Hacks: 2020 | $15 billion lost, how can we mitigate hacks in 2021? | CertiK Foundation Blog] (Jul 22, 2021)</ref>


[https://www.rekt.news/coinbase-the-oracle/ Rekt - Coinbase & The Oracle] (Sep 22)
<ref name="rektnews-3728">[https://www.rekt.news/coinbase-the-oracle/ Rekt - Coinbase & The Oracle] (Sep 22, 2021)</ref></references>

Revision as of 11:31, 17 February 2023

Notice: This page is a freshly imported case study from the original repository. The original content was in a different format, and may not have relevant information for all sections. Please help restructure the content by moving information from the 'About' section to other sections, and add any missing information or sources you can find. If you are new here, please read General Tutorial on Wikis or Anatomy of a Case Study for help getting started.

Notice: This page contains sources which are not attributed to any text. The unattributed sources follow the initial description. Please assist by visiting each source, reviewing the content, and placing that reference next to any text it can be used to support. Feel free to add any information that you come across which isn't present already. Sources which don't contain any relevant information can be removed. Broken links can be replaced with versions from the Internet Archive. See General Tutorial on Wikis, Anatomy of a Case Study, and/or Citing Your Sources Guide for additional information. Thanks for your help!

Compound Finance

Compound Finance relied on CoinBase for the price of DAI stablecoins. In a time of rapid market crash, the price on CoinBase went above $1.30 on CoinBase, while other services had prices around $1.03. This caused customers who had loans to fall below the required backing and get liquidated.

This is a global/international case not involving a specific country. [1][2][3][4][5][6][7][8][9][10][11][12][13][14][15]

About Compound Finance

"Compound is an algorithmic, autonomous interest rate protocol built for developers, to unlock a universe of open financial applications."

"Lenders on decentralized finance (defi) protocol Compound on Thursday got liquidated for a massive $103 million, according to analytics provider Loanscan. This happened after what appears to be an oracle exploit on the Dai stablecoin."

"Compound's price feed error caused the liquidation of $90 million in assets. According to DeBank founder hongbo, the huge liquidation of Compound was caused by the dramatic fluctuations in the DAI price of the oracle information source Coinbase Pro. It is a typical oracle attack to manipulate the information source that the oracle relies on to perform short-term price manipulation to achieve misleading prices on the chain."

"An apparent error or malicious attack to the Dai-dollar-peg data supplied by the Coinbase oracle pushed the price of the stablecoin to about $1.30 – a premium of 30% – leaving some users on Compound under-collateralized."

"When traders rush for the exits, the price of stablecoins generally increase as the demand for stability rises. In today’s crash, however, the effect became particularly pronounced on Dai, which briefly traded for $1.3 between 7 am and 8 am UTC."

"The Compound protocol uses Coinbase Oracle 69 for account liquidity calculations, anchored to within 20% of the Uniswap time-weighted average price. Any Ethereum address can post the signed/reported price on-chain, which allows for a permissionless and autonomous price feed 18 that rapidly de-risks accounts."

"From approximately 12:00am to 1:00am PT on Thanksgiving morning, the price of DAI on Coinbase Pro began trading at increasing prices and volume across the DAI/USDC, DAI/USD, and ETH/DAI pairs, reaching as high as $1.30. This coincided with a decline in ETH prices globally, of approximately 8% during the same time period."

"Most notably, Dai traded at this inflated valuation only on Coinbase and Uniswap, while other exchanges including Kraken and Bitfinex seem to have maintained a relatively stable price." "Coinbase and Uniswap are the two exchanges used by Compound’s Open Price Feed oracle. The former acts as the baseline, while the latter is used as a sanity check and anchor. Nonetheless, it appears that Uniswap failed in its function and also posted a much higher price than normal."

"[T]his Dai price spike, combined with an acutely falling ETH price, pushed some Dai positions on DeFi lending protocol Compound into being undercollateralized and thus capable of being liquidated." "The so called “DAI liquidation event” has shown, that the open oracle, which is used by Compound, has weaknesses. The root cause is, that the oracle uses only one price source, which is Coinbase. The effect is, that the Coinbase prices are used in Compound, even if they deviate largely from the rest of the market. The Uniswap price is used to define a +/- 20% bounding, but as seen, this doesn’t solve the problem."

“From what I’ve heard, the compound liquidations would have been much worse without the addition of [Uniswap] TWAPs to the Compound oracle … While the Coinbase oracle price spiked, Uniswap TWAPs did not increase much, causing the most extreme prices to be rejected.”

"Not only should most of these liquidations not have happened, folks that had non-DAI collateral lost ~30% of value of their collateral in the liquidation process due to the erroneous oracle allowing the collateral to be seized at an adverse and improper exchange rate."

"[I]t does not seem like the big compound liquidation was an oracle problem. [T]he market price of DAI was $1.30 in a real market with real trading."

"This morning, $DAI prices on Coinbase Pro escalated rapidly, leading to the liquidation (repayment) of 85.2M DAI borrowed from Compound."

"124 of 225,793 users were impacted; there are no under-collateralized accounts, and all markets are healthy."

"Fundamentally, the protocol and price feed performed as designed; real trading, on America’s largest exchange, was used to aggressively reduce the risk of borrowers in the protocol. What was unexpected was the adverse market condition that occurred, how quickly it occurred, and for many users, that it could occur at all."

This is a global/international case not involving a specific country.

The background of the exchange platform, service, or individuals involved, as it would have been seen or understood at the time of the events.

Include:

  • Known history of when and how the service was started.
  • What problems does the company or service claim to solve?
  • What marketing materials were used by the firm or business?
  • Audits performed, and excerpts that may have been included.
  • Business registration documents shown (fake or legitimate).
  • How were people recruited to participate?
  • Public warnings and announcements prior to the event.

Don't Include:

  • Any wording which directly states or implies that the business is/was illegitimate, or that a vulnerability existed.
  • Anything that wasn't reasonably knowable at the time of the event.

There could be more than one section here. If the same platform is involved with multiple incidents, then it can be linked to a main article page.

The Reality

This sections is included if a case involved deception or information that was unknown at the time. Examples include:

  • When the service was actually started (if different than the "official story").
  • Who actually ran a service and their own personal history.
  • How the service was structured behind the scenes. (For example, there was no "trading bot".)
  • Details of what audits reported and how vulnerabilities were missed during auditing.

What Happened

The specific events of the loss and how it came about. What actually happened to cause the loss and some of the events leading up to it.

Key Event Timeline - Compound Price Feed Error
Date Event Description
November 26th, 2020 12:00:00 AM Main Event Expand this into a brief description of what happened and the impact. If multiple lines are necessary, add them here.

Total Amount Lost

The total amount lost has been estimated at $4,000,000 USD.

How much was lost and how was it calculated? If there are conflicting reports, which are accurate and where does the discrepancy lie?

Immediate Reactions

How did the various parties involved (firm, platform, management, and/or affected individual(s)) deal with the events? Were services shut down? Were announcements made? Were groups formed?

Ultimate Outcome

What was the end result? Was any investigation done? Were any individuals prosecuted? Was there a lawsuit? Was any tracing done?

Total Amount Recovered

There do not appear to have been any funds recovered in this case.

What funds were recovered? What funds were reimbursed for those affected users?

Ongoing Developments

What parts of this case are still remaining to be concluded?

Prevention Policies

Which policies could have prevented this event from happening?

References