# CS 4501 ### Cryptocurrency
Aaron Bloomfield
(aaron@virginia.edu)
@github
|
↑
|
## Stablecoins & Oracles
# Contents [Introduction](#/intro) [Collateralized centralized](#/collcent) [Uncollateralized centralized](#/uncollcent) [Collateralized decentralized](#/colldecen) [Uncollateralized decentralized](#/uncolldecen) [Oracles](#/oracles) [Case study: LUNA/UST](#/casestudy) [Conclusions](#/coinclusion)
# Introduction
## Motivations - A big criticism is that cryptocurrencies are too volatile - Stablecoins attempt to solve this - What if you think a cryptocurrency is going to drop in value? - Exchange your shares for a stablecoin, then when it plunges, you buy more shares back - If you did this with actual US Dollars, you would be paying capital gains taxes on these transactions - And short-term sales pay *much* more in taxes - Creating a stablecoin can still make the creators money - Even if it doesn't make as much as, say, BTC or ETH ## Review: Types of currencies
- Commodity currency: made from actual valuable commodities, such as gold - Representative currency: one that is backed up by a valuable "thing", such as gold - Fiat currency: established by the government "by fiat" - What the US dollar is (now) - Cryptocurrency (obviously) ## Stablecoins - A coin whose value is meant to not be *non*-volatile - Usually *pegged* in value to a fiat currency - Most use the US Dollar - Thus, `$`1 is called the coin's *peg* - If it's value lowers (significantly) below the peg, it's called *depegged* or *depegging* ## Stablecoin categories - *Collateral:* property (such as securities) pledged by a borrower to protect the interests of the lender ([ref](https://www.merriam-webster.com/dictionary/collateral)) - *Collateralized* stablecoins means that there is some collateral (financial investment) backing up the value of the stablecoin - Ideally as much as the value of the minted stablecoin - If less, then it's *under-collateralized* - Collateral could be cryptocurrency or fiat currency (typically not both) - *Uncollateralized* means there is no collateral backing up the value of the stablecoin - Fiat currencies are uncollateralized - *Hybrid* stablecoins use some of both categories ## Stablecoin categories - *Centralized* means it is run by a single company or entity - Government, corporation, individual, etc. - They may *use* a smart contract to manage the stablecoin, but it's still a single entity that manages it - *Decentralized* means it's not run by a single company or entity - Instead by a group, DAO, or algorithm - Often by a smart contract; these are often called *algorithmic* ## Stablecoin Types
Centralized
Decentralized
Collateralized
custodial
stablecoins
(USDC, USDT)
algorithmic
(SAI, DAI)
Non-collateralized
central bank digital currency
(XPD)
algorithmic
(FEI, TRIBE,
FRAX, TOMB)
Un(der)-collateralized
???
???
undercollateralized stablecoins, seigniorage shares
## Definitions > Peg: to have the price of one asset (say, a cryptocurrency) exactly match the price of another asset (say, USD) > Depeg: when the asset (say, a cryptocurrency) looses its pegged price against the other asset (say, USD) ## Coins Studied - We are going to see a *lot* of coins in this slide set: - A total of 15: [![aust logo](../slides/images/logos/aust-coin-symbol.svg)](https://coinmarketcap.com/currencies/anchorust/) [![dai logo](../slides/images/logos/dai-coin-symbol.svg)](https://coinmarketcap.com/currencies/multi-collateral-dai/) [![fei logo](../slides/images/logos/fei-coin-symbol.svg)](https://coinmarketcap.com/currencies/fei-usd/) [![frax logo](../slides/images/logos/frax-coin-symbol.svg)](https://coinmarketcap.com/currencies/frax/) [![luna logo](../slides/images/logos/lunac-coin-symbol.svg)](https://coinmarketcap.com/currencies/terra-luna/) [![mim logo](../slides/images/logos/mim-coin-symbol.svg)](https://coinmarketcap.com/currencies/magic-internet-money/) [![mkr logo](../slides/images/logos/mkr-coin-symbol.svg)](https://coinmarketcap.com/currencies/maker/) [![sai logo](../slides/images/logos/sai-coin-symbol.svg)](https://coinmarketcap.com/currencies/single-collateral-dai/) [![spell logo](../slides/images/logos/spell-coin-symbol.svg)](https://coinmarketcap.com/currencies/spell-token/) [![tomb logo](../slides/images/logos/tomb-coin-symbol.svg)](https://coinmarketcap.com/currencies/tomb/) [![tribe logo](../slides/images/logos/tribe-coin-symbol.svg)](https://coinmarketcap.com/currencies/tribe/) [![usdc logo](../slides/images/logos/usdc-coin-symbol.svg)](https://coinmarketcap.com/currencies/usd-coin/) [![usdt logo](../slides/images/logos/usdt-coin-symbol.svg)](https://coinmarketcap.com/currencies/tether/) [![ustc logo](../slides/images/logos/ustc-coin-symbol.svg)](https://coinmarketcap.com/currencies/terrausd/) [![xpd logo](../slides/images/logos/xpd-coin-symbol.svg)](https://coinmarketcap.com/currencies/petrodollar/) - They are meant as examples of the concepts taught - You don't have to memorize them all!
# Collateralized centralized
## Collateralized centralized - Defining characteristics: 1. A single entity manages the coin - The entity could be a bank, company, non-profit, consortium, etc. - That entity is typically *not* a smart contract - Although they may operate through a smart contract - Meaning a centralized agency calls the shots, but uses a ERC-20 contract for the token cryptocurrency 2. When coins are purchased, the fiat money used for the purchase goes somewhere it can be retrieved - Investments, equities, bank account, safe, under a mattress, etc. ## [![usdc logo](../slides/images/logos/usdc-coin-symbol.svg)](https://coinmarketcap.com/currencies/usd-coin/) USD coin (USDC) - Managed by a consortium named Centre, which is founded by Coinbase (and others) - As per [coinmarketcap.com](https://coinmarketcap.com/), it has the 5th largest market capitalization (`$`33 billion as of 4/9/23) - After Bitcoin (`$`548 billion) and Ethereum (`$`224 billion) and two others ## [![usdc logo](../slides/images/logos/usdc-coin-symbol.svg)](https://coinmarketcap.com/currencies/usd-coin/) USD coin (USDC) - Backed by actual monetary investments in various accounts - An accounting agency (Grant Thornton) attests monthly to these deposits - If you buy one, the money you pay goes into these accounts - But how risky are those deposits? - If their value goes down, the number of USDC does not change! - Not backed by the US government in any way! ## [![usdt logo](../slides/images/logos/usdt-coin-symbol.svg)](https://coinmarketcap.com/currencies/tether/) Tether (USDT) - Similar to USDC in how it works - Run by Tether Ltd - As per [coinmarketcap.com](https://coinmarketcap.com/), it has the 3rd largest market capitalization (`$`80 billion as of 4/9/23) - Scandal-ridden (next slide) - Many accusations that their reserves are much less than the 1:1 ratio they claim - Not backed by the US government in any way! ## [![usdt logo](../slides/images/logos/usdt-coin-symbol.svg)](https://coinmarketcap.com/currencies/tether/) Tether Issues - February 3, 2021: [Tether pays `$`18.5 million in penalties; NY Attorney General alleges they don't have the cash reserves they claim](https://web3isgoinggreat.com/?id=tether-pays-18-5-million-in-penalties) - December 4, 2021: [Tether mints `$`3 billion in two weeks](https://web3isgoinggreat.com/?id=tether-mints-3-billion-in-two-weeks) - January 1, 2022: [Tether adds `$`1 billion to their supply](https://web3isgoinggreat.com/?id=tether-adds-1-billion) - May 12, 2022: [Tether drops below `$`0.95](https://web3isgoinggreat.com/?id=tether-loses-peg-drops-below-095) ## Disadvantages - The centralized entity may make risky investments - What happens when they lose much of that collateral? - If their investments gain value, the owners of the stablecoins aren't getting any of the growth - Lack of transparency about how *much* collateral there is - Even with the "attestations" about the collateral backings - It's still controlled by a centralized agency - Could the government withhold your money? Perhaps - It's not regulated like the US Dollar is - That can be a good thing or a bad thing
# Uncollateralized centralized
## Uncollateralized centralized - Because it is *centralized*, it is managed by a single entity - Because it is *uncollateralized*, it is basically the cryptocurrency equivalent of a fiat currency - Only a government could issue a fiat cryptocurrency and have anybody consider it to have value - Thus, these would be a national central bank issued cryptocurrency ## Examples - In the US: none -
UAE: Dubai issues Emcash (launched in 2017)
-
Venezuela: Petro (launched in Feb 2018)
- [![xpd logo](../slides/images/logos/xpd-coin-symbol.svg)](https://coinmarketcap.com/currencies/petrodollar/) Petro (XPD) is the only one here [listed on coinmarketcap.com](https://coinmarketcap.com/currencies/petrodollar/)
-
Estonia: Estcoin (planned in 2018, not launched)
-
Russia: Cryptoruble (still in development)
-
Sweden: E-Krona (still in development, launch in 2022?)
-
Japan: J-Coin (not actually a cryptocurrency, more like a bank account / credit card combination)
## [![xpd logo](../slides/images/logos/xpd-coin-symbol.svg)](https://coinmarketcap.com/currencies/petrodollar/) Petro - Created in 2017/2018, it was meant to: - Bypass US sanctions - Shore up the then plummeting bolivar currency - General reception was quite negative - Bloomberg: [Crypto Rating Sites Are Already Calling Venezuela’s Petro a Scam](https://www.bloomberg.com/news/articles/2018-04-03/crypto-rating-sites-are-already-calling-venezuela-s-petro-a-scam), April 3, 2018 - [Wikipedia article](https://en.wikipedia.org/wiki/Petro_(cryptocurrency%29) ## Drawbacks - The government can track this - Many people who get into cryptocurrency do not want government centralization - It's unclear how this would be better than, say, a credit card or a debit card
# Collateralized Decentralized
## [![dai logo](../slides/images/logos/dai-coin-symbol.svg)](https://coinmarketcap.com/currencies/multi-collateral-dai/) Dai (DAI) - Originally only backed by (only) ETH, created in 2017 - An ERC-20 token via a smart contract - This coin is [![sai logo](../slides/images/logos/sai-coin-symbol.svg)](https://coinmarketcap.com/currencies/single-collateral-dai/) Sai ([SAI](https://coinmarketcap.com/currencies/single-collateral-dai/)) for Single-Collateral DAI - In 2019, [![dai logo](../slides/images/logos/dai-coin-symbol.svg)](https://coinmarketcap.com/currencies/multi-collateral-dai/) DAI was created, and is pegged at `$`1 USD - An ERC-20 token cryptocurrency we've [talked about before](tokens.html#/dai) - All SAI was upgraded to DAI; SAI no longer (really) exists - DAI is backed by multiple types of collateral - [![mkr logo](../slides/images/logos/mkr-coin-symbol.svg)](https://coinmarketcap.com/currencies/maker/) Maker ([MKR](https://coinmarketcap.com/currencies/maker/)) is the governance token - [MakerDAO white paper on DAI](https://makerdao.com/en/whitepaper/) - The MakerDAO votes to allow additional types of ERC-20 collateral (and their risk factor) - Source code for [SAI](https://github.com/makerdao/sai) and [DAI](https://github.com/makerdao/dss) ## How to buy DAI - Create a 'vault' via a smart contract that contains the asset you want to convert to DAI - This vault is the collateral; one asset per vault - Via the MakerDAO contract, one 'locks' the vault (transfers it to the contract) and receives DAI in return - Anybody with a vault can do this; you don't need MKR - Only the MakerDAO contract can lock and unlock the vault - This DAI is the 'debt' -- hence *Collateralized Debt Position (CDP)* - To redeem (some or all of) the original assets: - Pay back the DAI generated above - Pay a 'stability fee' (aka interest) on the DAI generated - Withdraw the asset(s) from the vault ## Current DAI stats - See them at https://daistats.com/ - On the 'Collateral' tab the stability fees are listed - It varies by asset, typically 2%-6%, but can be higher or lower - ETH-? provides different levels of risk and reward; see [here](https://forum.defisaver.com/t/converting-between-eth-a-eth-b-and-eth-c-maker-vault-types-using-the-loan-shifter/39) for details - The "Collat. Ratio" is how much DAI has been minted versus the collateral - Above 100% means more collateral is locked than DAI is issued ## Target Rate Feedback Mechanism (TRFM) - The target price (aka peg) for DAI is `$`1 USD - If DAI's price falls below the peg, then there is too much supply (or too little demand) - Stabilization goal: reduce supply and increase demand - The smart contract automatically increases the target rate(s) - DAI is now more expensive to mint - This decreases supply (fewer DAI for the same collateral) - This increases price (DAI are worth more collateral) - If DAI's price rises above the peg, then there is too little supply (too much demand) - The smart contract decreases the target rate(s) - The reverse of the above happens ## DAI Liquidation - [Liquidation](https://makerdao.com/en/whitepaper/#liquidation-of-risky-maker-vaults) is discussed in the [DAI whitepaper](https://makerdao.com/en/whitepaper) - Each asset type has a liquidation ratio - Determined and adjusted by MakerDAO votes) - If the collateral-to-debt ratio - [Here](https://itovault.com/how-dai-liquidation-work-makerdaos-mcd-system/) is how it works ([direct image link](https://itovault.com/wp-content/uploads/2020/12/MakerDAO-Liquidation-1024x916.png)) - You can see the recently [liquidated assets](https://makerburn.com/#/liquidations) - MKR is minted to make up the shortfall - This dilutes the MKR price - But since it's worth so much, there is typically no shortfall - And it' doesn't happen often - Read more about liquidations [here](https://itovault.com/how-dai-liquidation-work-makerdaos-mcd-system/) ## What keeps DAI's peg stable? - Stability fees: these fees build additional collateral in the smart contract - Liquidation if a vault's assets are too low - And minting MKR to make up for any difference in bankrupt vaults - Target Rate Feedback Mechanism ## SAI / DAI stability - How well does it work? - Coefficient of Variation (CV) is the standard deviation divided by the mean - It describes the variability of a sample relative to the average - Usually expressed as a percentage - 0% means no variation - For [![sai logo](../slides/images/logos/sai-coin-symbol.svg)](https://coinmarketcap.com/currencies/single-collateral-dai/) SAI, it's 1.33% - For [![dai logo](../slides/images/logos/dai-coin-symbol.svg)](https://coinmarketcap.com/currencies/multi-collateral-dai/) DAI, it's 0.83% - For [![eth logo](../slides/images/logos/eth-coin-symbol.svg)](https://coinmarketcap.com/currencies/ethereum/) ETH, it's 131.6% - These values as of 4/9/23 - We can also see it as a graph... - I included SAI data until the end of 2019; DAI was introduced Nov 19, 2019; SAI's price has fluctuated quite a lot since then
# Uncollateralized Decentralized
## Two Sub-categories - Uncollateralized or Under-collateralized stablecoins: FRAX, FEI, IRON, OHM, Gyroscope - There can be little or no collateral backing the stablecoin - Zero collateral backing usually doesn't interest many investors, so most are under-collateralized - Of those, [![fei logo](../slides/images/logos/fei-coin-symbol.svg)](https://coinmarketcap.com/currencies/fei-usd/) FEI has the highest market capitalization (#91 as of 4/9/23) - Seigniorage shares: Basis, Maker (as a backstop), Tomb, Frax - Similar to the previous category, but uses a different mechanism to maintain the peg ## Under-collateralized: [![fei logo](../slides/images/logos/fei-coin-symbol.svg)](https://coinmarketcap.com/currencies/fei-usd/) FEI - [![fei logo](../slides/images/logos/fei-coin-symbol.svg)](https://coinmarketcap.com/currencies/fei-usd/) Fei [FEI](https://coinmarketcap.com/currencies/fei-usd/) is a stable coin pegged at `$`1 USD - Launched in March 2021 - Main website is [fei.money](https://fei.money/); [whitepaper](https://fei.money/static/media/whitepaper.7d5e2986.pdf) - An ERC-20 token on the Ethereum blockchain - [![tribe logo](../slides/images/logos/tribe-coin-symbol.svg)](https://coinmarketcap.com/currencies/tribe/) [TRIBE](https://coinmarketcap.com/currencies/tribe/) is its governance (DAO) token - The TRIBE DAO can allow: - More DEXes to be used (Uniswap was the only one at first) - More assets to be used as collateral - Etc. ## Collateralized stablecoin disadvantages - With many stablecoins, you can withdraw your collateral at any time - But what if: - A lot of people, or a whale, withdraw at once? - The price has fluctuated greatly? - This could lower the overall price ## [![fei logo](../slides/images/logos/fei-coin-symbol.svg)](https://coinmarketcap.com/currencies/fei-usd/) Fei (FEI) - FEI will not allow withdrawal of collateral - The collateral is locked into the contract, and used to help maintain the peg - One can trade the FEI for other assets, of course - But that's not "redeeming" one's collateral, but few would see the difference - They call this *Price Controlled Value* (PCV) - Used to help maintain the peg - Direct incentives - FEI holders get benefits from holding or using FEI - Examples: better interest rates, DEX transaction fees, etc. ## [![fei logo](../slides/images/logos/fei-coin-symbol.svg)](https://coinmarketcap.com/currencies/fei-usd/) Fei (FEI) - If the price drops below the peg... - Then the liquidity is used to buy back FEI tokens, increasing supply - Thus increasing the price - If the price rises above the peg... - Then there is more demand than supply - More FEI tokens are issued until the price stabilizes - Usually distributed to existing stakers or holders ## Seigniorage (pronounced *senior-idge*; [source](https://www.investopedia.com/terms/s/seigniorage.asp)) > Seigniorage: the cost of a unit of currency minus the cost to create it Examples:
- A USD `$`20 bill cost 11.5¢ to make in 2019 - Seigniorage: `$`19.885 - A USD `$`100 bill cost 14.2¢ to make in 2019 - Seigniorage: `$`99.858 - A USD penny cost 1.5¢ to make in 2016 - Seigniorage: -0.5¢ ## Seigniorage: Keeping the peg - An algorithmic (aka decentralized) stablecoin - If the value of stablecoin rises above the peg, then more are minted - Usually distributed to existing stakers or holders - If the value of the stable coin dips below the peg... - A bond is issued: basically an IOU for more of the stablecoin - Those bonds are sold for lower than the peg amount - People buy these bonds, with the intent to redeem them for the stablecoin once the price rises to the peg, this making a profit - [Reference](https://dailydefi.org/articles/what-are-seigniorage-stablecoins/) ## Seigniorage: Keeping the peg ![](https://upload.wikimedia.org/wikipedia/commons/1/1d/Cribbage_board_with_pegs2.jpg) - Some (not many!) will burn coins that holders *have* - This means that the amount you own can *vary* - Few people like this - Which is more important: keeping the peg, or keeping your account balance the same? - Most would choose the latter, but these coins choose the former ## Seigniorage: the name - There is a *cost* to making this money - The bonds are issued at a lower price, then sold at a higher price - Or one loses their shares if they are burned - Hence the name: *seigniorage* is the value of the money minus the cost to make the money ## Seigniorage Stablecoins ![](https://sciencevibe.com/wp-content/uploads/2017/01/sc-death-spiral.jpg) - But what if it never rises to the peg? - Then more bonds are issued as the price decreases - As the price drops, people lose faith, decreasing demand to buy the bonds - The price continues to decrease - This repeats as the price continues to drop - This is called the *death sprial* - A disadvantage of this type of mechanism to maintain a peg ## Seigniorage Stablecoins - These coins have often had trouble holding their peg - Consider the [top seigniorage coins by market cap](https://www.coingecko.com/en/categories/seigniorage) (as of 4/9/23): - [![frax logo](../slides/images/logos/frax-coin-symbol.svg)](https://coinmarketcap.com/currencies/frax/) [FRAX](https://coinmarketcap.com/currencies/frax/) (#51 overall, #1 top seigniorage) has been fairly stable - Number 2 is Frax Share, the DAO for FRAX, at #95 - Number 3 is Terra Classic USD, at #120 - We'll talk about this shortly; it's a "stablecoin" worth 3.5¢ - [![tomb logo](../slides/images/logos/tomb-coin-symbol.svg)](https://coinmarketcap.com/currencies/tomb/) [TOMB](https://coinmarketcap.com/currencies/tomb/) (#4,628 overall) has not been stable at all - A "stablecoin" worth 3.1¢ - The next highest is #955 overall, so clearly it's not used much - The one after that is #2,781... ## [![frax logo](../slides/images/logos/frax-coin-symbol.svg)](https://coinmarketcap.com/currencies/frax/) FRAX - An ERC-20 token on Ethereum, launched in November 2020 - It's "Fractional-Algorithmic", aka hybrid - Some of it is collateralized, some of it is algorithmic - If it is trading below the `$`1 peg... - The ratio of collateralized to algorithmic is *increased* (more collateral) to bring the price back up - If it is trading above the `$`1 peg... - The ratio of collateralized to algorithmic is *decreased* (more algorithmic) to bring the price back up - Has been fairly stable, relative to other seigniorage stablecoins
# Oracles
## Oracles ![](https://upload.wikimedia.org/wikipedia/en/f/f0/The_Oracle_%28i%29.gif) - A smart contract can only use the data on the blockchain - Complex situations require more data than that: - Current exchange rates - Random numbers - The ability to interact with other blockchains - The solution: Oracles > Oracle (n): a person who delivers authoritative, wise, or highly regarded and influential pronouncements ## Oracles We can easily create an oracle: ``` contract Oracle { address deployer; uint public price; // public, so creates a getter constructor() { deployer = msg.sender; } function updatePrice (uint update) external { require (msg.sender == deployer, "Only the Oracle can update this"); price = update; } } ``` - Getting people to trust it is another matter ## Oracle: trusted signer ![](images/stablecoins/oracles/oracles.dot.1.svg) - The oracle signer (often the deployer) updates the price, and anybody can read it - This works well when the source is centralized - Examples: the oracles on Ethereum that interact with the Polkadot or Polygon chains - Can be a set of trusted signers, any one of which can update the oracle - But a corrupt signer can maliciously manipulate the price ## Oracle: $m$ of $n$ signers ![](images/stablecoins/oracles/oracles.dot.2.svg) - So we have multiple signers - We expect some variance in the values - Different exchanges will provide slightly different exchange rates - We have to take the *median* value, not the *mean* - We'll see why next ## Oracle: $m$ of $n$ signers ![](images/stablecoins/oracles/oracles.dot.3.svg) - What if some nodes are corrupted? - We have to take the *median* value, not the *mean* - Here the mean is `$`71 - The median is `$`101 - If more than half are trustworthy, then the oracle will have a (mostly) correct price - Less than half can be traitors! ## Oracle: Schelling oracles ![](images/stablecoins/oracles/oracles.dot.4.svg) - Each signer puts a *stake* in their vote - We accept the value that has the most stake - Traitors have their stake *slahsed* - Although we allow for some variance in the price - But if we allow for too much variance, a traitor can just give a valid, but low, price ## Schelling oracles & whales ![](images/stablecoins/oracles/oracles.dot.5.svg) - A *whale* could put in a huge stake to manipulate the price - Knowing full well s/he will lose their stake - Presumably so s/he can make a (bigger) profit off of the price difference
# Case study: LUNAC/USTC
## Terra, LUNAC, and USTC - Terra is the ecosystem, built upon the Cosmos SDK - Company is called Terraform Labs - Allows devs to build custom blockchains for dApps - [![luna logo](../slides/images/logos/lunac-coin-symbol.svg)](https://coinmarketcap.com/currencies/terra-luna/) LUNA Classic ([LUNAC](https://coinmarketcap.com/currencies/terra-luna/)) is the (volatile) cryptocurrency
- Was backed by billions in Bitcoin - Previously just LUNA; had a high of `$`118.74 on April 5, 2022 - Terra vs LUNAC is like the difference between Ethereum & ETH - [![ustc logo](../slides/images/logos/ustc-coin-symbol.svg)](https://coinmarketcap.com/currencies/terrausd/) USD Terra Classic ([USTC](https://coinmarketcap.com/currencies/terrausd/)) (previously just UST) is the stablecoin that was pegged at `$`1 USD
- The LUNAC cryptocurrency was used to keep the USTC stablecoin on its peg - It's an Ethereum ERC-20 token ## The Terra Crash - See the [graph of LUNC](https://coinmarketcap.com/currencies/terra-luna/) - $45 *billion* was wiped out in the crash of LUNAC in one week alone - Which caused the stable coin to crash as well - This dragged down the broader crypto market, causing losses of 100s of billions of dollars - But why did this happen to a respected cryptocurrency? ## Do Kwon
- Kwon Do-hyung, known as Do Kwon, is the founder of Terraform Labs (along with Daniel Shin) - Stanford graduate, Korean national - Founded Terraform Labs in Singapore - Was on CoinDesk's [2021 Most Influential list](https://www.coindesk.com/policy/2021/12/10/most-influential-2021-do-kwon/) - Now widely reviled, and many legal actions are pending against him ## Do Kwon's current status
- The [Do Kwon Wikipedia article](https://en.wikipedia.org/wiki/Do_Kwon) sums it up nicely: - On 23 March 2023, Kwon was arrested in Montenegro, while attempting to travel to Dubai using falsified documents. Following his arrest, he was charged by a US federal grand jury of eight counts, including securities fraud, commodities fraud and wire fraud and conspiracy. ## Terra bridges - The Terra protocol allows cross-chain transfers - The particular one between Terra and Ethereum is called the Shuttle ([source code](https://github.com/terra-money/shuttle)) - As far as I can tell: - Both sides have ERC-20 (or equivalent) contracts - And an Oracle for the other blockchain - When you transfer assets into one, the oracle on the other sees that, and gives you assets on the other blockchain - Likely done via the minting and burning of tokens on each side - Also, Terra can presumably read from other blockchains other than its own ## Abracadabra - Abracadabra is the protocol at [abracadabra.money](https://abracadabra.money/) - [![spell logo](../slides/images/logos/spell-coin-symbol.svg)](https://coinmarketcap.com/currencies/spell-token/) Spell ([SPELL](https://coinmarketcap.com/currencies/spell-token/)) is their native token - [![mim logo](../slides/images/logos/mim-coin-symbol.svg)](https://coinmarketcap.com/currencies/magic-internet-money/) Magic Internet Money ([MIM](https://coinmarketcap.com/currencies/magic-internet-money/)) is the stablecoin - Abracadabra / SPELL / MIM is analogous to Terra / LUNA / USTC - Their promise: a non-interest bearing asset (coin or token) can be used to generate interest - Like staking - The relevant product is called Degenbox - It "deploys strategies" to generate interest on non-interest bearing coins/tokens ## Abracadabra's Degenbox - On the Ethereum blockchain: - You deposit an asset into a 'cauldron' and MIM is minted - Similar to depositing an asset into a 'vault' for DAI - Only some assets are allowed; we'll only talk about USTC - 15% stays on Ethereum mainnet for withdrawals - 85% of that is bridged back to the Terra blockchain - On the Terra blockchain: - The 85% bridged back is deposited into the [Anchor Protocol](https://www.terrablockchain.org/anchor) (also [here](https://theanchor.io/)) to generate aUST - [![aust logo](../slides/images/logos/aust-coin-symbol.svg)](https://coinmarketcap.com/currencies/anchorust/) AnchorUST ([aUST](https://coinmarketcap.com/currencies/anchorust/)) was their stablecoin, and was interest-bearing ([coingecko.com](https://www.coingecko.com/en/coins/anchorust) has a price graph)
- Those aUST are then bridged back to Degenbox on Ethererum mainnet ## Degenbox - The assets bounce back and forth between the blockchains - The users see only this: - On Ethereum, they deposit an asset (coin or ERC-20 token) - They get another ERC-20 asset (aUST) on Ethereum worth the same amount that is generating interest - That ERC-20 asset, aUST, can be used like any other asset ## Looping Stablecoin buys - What if you could use your aUST to borrow more USTC - As aUST is a stablecoin and can be collateral to obtain more USTC - Perhaps using an intermediary coin between aUST and USTC - Then you can invest the USTC into more aUST - Then take use that aUST to borrow more USTC - And so on... - This is *looping* a stablecoin buy - It artificially increases demand, since more and more USTC is being minted ## So what happened? - See [FatMatTerra's twitter thread](https://twitter.com/FatManTerra/status/1535623662153437185) - And a [watcher.guru article](https://watcher.guru/news/how-do-kwon-allegedly-cashed-out-2-7b-from-terra-network) that helps explain it (but not all that well) ## The Big Terra Error - The founder of the company had full access to the Bitcoin liquidity - It wasn't, say, locked in a smart contract - Or controlled by a DAO that required many people's votes to liquidate - This allowed him to plunder these assets and (gradually) transfer them to himself ## Takeaways - Most people who invested in LUNA didn't know much about what it did - The scam to loot LUNA was quite complex - Beyond the knowledge of most (almost all?) LUNA investors ## References - [Medium: Abracadabra Degenbox -- Let’s cast spell on UST](https://everythingblockchain.medium.com/abracadabra-degenbox-lets-cast-spell-on-ust-7d2dd8d6e43c) - [How To Use The Terra Bridge](https://www.altcoinbuzz.io/bitcoin-and-crypto-guide/how-to-use-the-terra-bridge/) - [A Complete Guide to Abracadabra Money – SPELL, MIM and sSPELL](https://blocmates.com/blogmates/a-complete-guide-to-abracadabra-money-spell-mim-and-sspell/) - [Article on LUNA / UST background](https://www.coindesk.com/learn/what-is-luna-and-ust-a-guide-to-the-terra-ecosystem/) - [Overview of the crash](https://www.cnet.com/personal-finance/crypto/terras-luna-crypto-crash-how-ust-broke-and-whats-next/) - [Do Kwon reportedly cashed out $2.7 billion in the span of a few months prior to the LUNA/UST collapse](https://watcher.guru/news/how-do-kwon-allegedly-cashed-out-2-7b-from-terra-network?c=70) (and [twitter announcement](https://twitter.com/watcherguru/status/1535707516784476163?s=21&t=cZ9G69kuatTgBDdnliEieQ)) - [This reddit thread](https://www.reddit.com/r/CryptoCurrency/comments/v9ypa6/heres_how_do_kwon_cashed_out_27_billion_using/) describes the article also - [Votium](https://votium.app/) and [Votium quick start guide](https://docs.votium.app/explainers/quickstart-guide) - [Convex](https://www.convexfinance.com/)
# Conclusions
## So many choices... - Stablecoins have been created using a large number of algorithms - Some algorithms have not really succeeded - But may in the future; FRAX was the first seigniorage coin to do well - The most stable have been the collateralized versions (USDC, USTC, SAI, and DAI) - New algorithms will surely come out ## Coef of Variations (as of 4/9/23) - [![dai logo](../slides/images/logos/dai-coin-symbol.svg)](https://coinmarketcap.com/currencies/multi-collateral-dai/) Dai (DAI): 0.83% - [![eth logo](../slides/images/logos/eth-coin-symbol.svg)](https://coinmarketcap.com/currencies/ethereum/) Ether (ETH): 131.6% - [![fei logo](../slides/images/logos/fei-coin-symbol.svg)](https://coinmarketcap.com/currencies/fei-usd/) Fei (FEI): 3.41% - [![lunc logo](../slides/images/logos/lunac-coin-symbol.svg)](https://coinmarketcap.com/currencies/terra-luna/) Luna Classic (LUNC): 193.7% - [![sai logo](../slides/images/logos/sai-coin-symbol.svg)](https://coinmarketcap.com/currencies/single-collateral-dai/) Sai (SAI): 1.33% - [![usdc logo](../slides/images/logos/usdc-coin-symbol.svg)](https://coinmarketcap.com/currencies/usd-coin/) USD Coin (USDC): 0.47% - [![usdt logo](../slides/images/logos/usdt-coin-symbol.svg)](https://coinmarketcap.com/currencies/tether/) Tether (USDT): 1.58% - [![xpd logo](../slides/images/logos/xpd-coin-symbol.svg)](https://coinmarketcap.com/currencies/petrodollar/) PetroDollar (XPD): 57.92% - XPD's as of Nov 2022, as the price history no longer available ## Sketchy-ness - Stablecoins still are subject to scams and sketchy-ness - And, for some, the government can take away your funds - But are still not regulated - Or taxed, until you sell them