Games & Quizzes
Don't forget to Sign In to save your points
This is a modal window.
Beginning of dialog window. Escape will cancel and close the window.
End of dialog window.
Games & Quizzes
You may need to watch a part of the video to unlock quizzes
Don't forget to Sign In to save your points
PERFECT HITS | +NaN | |
HITS | +NaN | |
LONGEST STREAK | +NaN | |
TOTAL | + |
So what was the first large scale bank run in DeFi all about? Â
Why is it so hard to create a working algorithmic stablecoin? And what can Â
we learn from the IronFinance fiasco? You’ll find answers to these questions in this video.
Before we begin, if you want to learn more about decentralized finance and the technology behind Â
it make sure you subscribe to my channel, hit the bell icon and enable all notifications. You Â
can also consider supporting us on Patreon and joining our DeFi community on Discord.
IronFinance initially launched on Binance Smart Chain in March 2021 Â
and aimed at creating an ecosystem for a partially collateralized algorithmic stablecoin.
As we know, building algorithmic stablecoins is hard. Most projects either completely fail or end Â
up in a no man's land by struggling to maintain their peg to the US Dollar. Because of this, Â
building an algorithmic stablecoin has become one of the holy grails in DeFi.
Achieving it would clearly revolutionize the DeFi space as we know it today.
The current ecosystem relies heavily on stablecoins that come with major trade-offs. They Â
maintain their peg to the US Dollar at the cost of either centralization or capital inefficiency.
For example, the custody of USDC or USDT is fully centralized. On the flip side, Â
stablecoins like DAI or RAI require a lot of collateral which makes them capital inefficient.
IronFinance tried to address these problems by creating a Â
partially collateralized stablecoin - IRON.
Despite a few hiccups along the road, such as short periods of time when IRON unpegged from USD Â
or when ValueDeFi exploits affected some of the IronFinance users, Â
the protocol kept marching forward.
In retrospect, recovering from these issues most likely built a false level of confidence in the Â
protocol design as its users thought they were dealing with a “battle-tested†project.
In May 2021 IronFinance expanded to Polygon and started gaining more and more traction.
Total value locked in the protocol quickly went from millions to billions of dollars, Â
surpassing 2 billion before the final collapse. The value of TITAN - protocol’s native token on Â
Polygon - went from $10 to $64 just in the last week leading to the bank run.
This parabolic growth was mostly driven by extremely high yield farming rewards Â
and subsequent high demand for both the TITAN and the IRON tokens. Â
Yield farmers were able to benefit from around 500% APR on stablecoin pairs: Â
IRON/USDC and around 1700% APR on more volatile pairs like TITAN/MATIC.
To add even more fuel to this parabolic growth, Â
IronFinance was mentioned by a famous investor - Mark Cuban - in his blog post. Â
This further legitimised the project and brought even more attention to it.
On the 16th of June 2021, the protocol experienced a massive bank run that crashed Â
the TITAN price to 0 and resulted in thousands of people experiencing major financial losses.
Before we start unfolding all of the events that led to the collapse of IronFinance, Â
let’s try to understand how the protocol was built.
It’s worth noting that reviewing the design of projects, including the ones that failed, Â
is important as it allows us to better understand what works Â
and what doesn’t work in DeFi. It also makes it easier to assess new protocols Â
that very often reuse a lot of elements of the already existing systems.
The IronFinance protocol was designed around 3 types of tokens:Â
Its own partially collateralized stablecoin - IRONÂ that should maintain a soft peg to the US Dollar,Â
Its own token: TITAN on Polygon and STEEL on BSC,Â
an established stablecoin used as collateral: USDC on Polygon and BUSD on BSC
The combination of USDC and TITAN on Polygon or BUSD and STEEL on BSC was supposed to Â
allow the protocol to decrease the amount of stablecoin collateral over time and in turn, Â
making IRON partially collateralized leading to a greater capital efficiency.
The protocol, although using different tokens on Polygon and BSC, Â
worked in an analogous way on both platforms so in order to simplify Â
this video going further I’m going to skip the BSC tokens BUSD and STEEL in the explanation.
In order to achieve price stability of the IRON token, the protocol introduced Â
a mechanism for minting and redeeming IRON that relied on market incentives and arbitrageurs.
Whenever the price of the IRON token was less than $1, anyone could purchase it on Â
the open market and redeem it for approximately $1 worth of value paid in a mix of USDC and TITAN.
Whenever the price of the IRON token was greater than $1, Â
anyone could mint new IRON tokens for approximately $1 worth of USDC and TITAN Â
and sell the freshly minted IRON tokens on the open market, driving the price of IRON back to $1.
To understand the process of minting and redeeming better, we have to introduce the Â
concept of Target Collateral Ratio (TCR)Â and Effective Collateral Ratio (ECR).
Target Collateral Ratio is used by the minting function Â
to determine the ratio between USDCÂ and TITAN required to mint IRON.
As an example, let’s say the TCR is at 75%. In this case, 75% Â
of collateral needed to mint IRON would come from USDC and 25% would come from TITAN.
The protocol started at 100% TCR and gradually lowered the TCR over time.
TCR can increase or decrease depending on the IRON price. On one hand, if the time-weighted Â
average price of IRON is greater than $1, TCR is lowered. On the other hand, Â
if the time-weighted average price of IRONÂ is less than $1, the TCR is increased.
Effective Collateral Ratio is used by the redeeming mechanism to determine the Â
ratio between USDC and TITAN when redeeming IRON. ECR is calculated Â
as current USDC collateral divided by the total IRON supply.
If TCR is lower than ECR, the protocol has excess collateral. On the flip side, Â
if TCR is higher than ECR it means the protocol is undercollateralized.
As an example, if the ECR is at 75%, Â
each time IRON is redeemed the user would get 75%Â of their collateral back in USDC and 25% in TITAN.
What is important is that every time someone mints IRON the TITAN Â
portion of collateral is burned. If someone redeems IRON, new TITAN tokens are minted.
As we can see, the whole mechanism, although a bit complicated, should work - at least in theory.
Now, let’s see how the events leading to the collapse of IronFinance unfolded.
But before we do this, Finematics is participating in Round 10 of Gitcoin Grants where even the Â
smallest contribution matters, thanks to the quadratic funding mechanism. If you enjoy our Â
videos and would like to support the channel, check out the link in the description box below.
Let’s get back to the video.
Around 10 am UTC on 16th June 2021, the team behind the protocol noticed that a few Â
larger liquidity providers a.k.a “whales†started removing liquidity from IRON/USDC and then started Â
selling their TITAN to IRON. Instead of redeeming IRON, they sold it directly to USDC via liquidity Â
pools. This caused the IRON price to unpeg from the value of the US Dollar. This in turn spooked Â
the TITAN holders who started selling their TITANÂ causing the token price to drop from around $65Â Â
to $30 in approx 2 hours. The TITAN price later came back to $52 and IRON fully recovered its peg.
This event, although quite severe, wasn’t that unusual considering that the protocol had a Â
history of native tokens sharply dropping in value and IRON unpegging for a short period of time.
Later on the same day, a few whales started selling again. This time it was different. The Â
market panicked and users started redeeming IRON and selling their TITAN in masses. Â
Because of the extremely quick and sharp drop in the TITAN price, Â
the time-weighted price oracle used for reporting TITAN prices Â
started reporting stale prices that were still higher than the actual market price of TITAN.
This created a negative feedback loop as the price oracle was used to determine Â
the number of TITAN tokens that have to be printed while redeeming IRON.
Because IRON was trading off-peg at under $1, Â
the users could buy IRON, for let’s say $0.90 and redeem it for $0.75 in USDC Â
and $0.25 in TITAN and sell TITAN immediately. This situation created a death spiral for TITAN Â
that drove its price to pretty much 0 as the lower the TITAN price was the more Â
TITAN tokens would have to be printed to account for the correct amount of the redeemed capital.
The TITAN price hitting almost 0 exposed another flaw in the protocol - users being Â
unable to redeem their IRON tokens. This was later fixed by the team and users were Â
able to recover around $0.75 worth of USDC collateral from their IRON tokens.
Unfortunately, TITAN holders didn’t get away with “only†a 25% haircut and Â
instead took heavy losses. This also included TITAN liquidity providers. Â
This is because when one token in a 50/50 liquidity pool goes to 0 the impermanent Â
loss can reach pretty much 100%. Liquidity providers end up losing both tokens in the pool Â
as the non-TITAN token is sold out for TITANÂ that keeps going lower and lower in value.
This situation exposed a major flaw in the IronFinance mechanism Â
that resulted in what we can call the first large scale bank run in DeFi.
Similarly to banks with fractional-reserve systems, where there are not enough funds Â
to cover all depositors at any one time, the IronFinance protocol didn’t have enough collateral Â
to cover all minted IRON. At least not when the TITAN token used as 25% Â
of the overall collateral became worthless in a matter of minutes.
The IronFinance fiasco also shows us why DeFi protocols Â
shouldn’t fully rely on human coordination, especially when under certain circumstances Â
incentives work against the protocol. In theory, if people just stopped selling TITAN for a short Â
period of time, the system would recover as it had previously done in the past. In practice, Â
most market participants are driven by making a profit and the arbitrage opportunity present in Â
the protocol caused them to fully take advantage of this situation. Â
This is also why all DeFi protocols should always account for the worst-case scenario.
As with most major protocol failures in DeFi, there are always some lessons to be learned.Â
In the case of IronFinance, there are a few important takeaways.
First of all, we always have to consider what would happen to the protocol in the worst-case Â
scenario. This usually involves one of the tokens used in the protocol sharply losing its value.
What happens when the protocol stops expanding and starts contracting? Â
What if the contraction is way quicker than expansion?
Another important element of the protocol design that Â
always has to be fully understood is the usage of price oracles. Â
Could they report stale prices or get manipulated by flash loan attacks? If so, what basic protocol Â
mechanisms rely on these oracles and how would they behave when the oracle is compromised.
Next lesson, providing liquidity in a pool where at least 1 asset can drop to 0 means Â
that we can lose pretty much all of our capital, even if the second token doesn’t lose any value.
Another lesson, following celebrities and their investments Â
might be risky. With great power comes great responsibility and unfortunately, Â
even a single mention of a certain protocol or a token can cause people to invest in something they Â
don’t fully understand - don’t be that person and always make sure you do your own due diligence.
One good indicator of high-risk protocols is extremely high APR in yield farming. Â
If something looks too good to be true there are usually some risks that have to be accounted for.
Last but not least, building algorithmic stablecoins is hard. I hope one day we can Â
see a fully functioning algorithmic stablecoin competing in size with USDT or USDC, but this Â
will most likely take a bit of time and hundreds of failed attempts. If you want to become an early Â
adopter of such a coin it’s great, but keep in mind that the numbers are not on your side.
So what’s next when it comes to IronFinance and algorithmic stablecoins?
At the moment, the team behind the protocol is planning on conducting an in-depth analysis of Â
the situation, in order to understand the circumstances which led to such an outcome.
It’s hard to say if the team behind IronFinance Â
will decide to fix the shortcomings of the existing protocol and relaunch it.
Historically, second versions of failed protocols usually don’t get nearly as Â
much traction as their original versions. Yam Finance was a good example of such a protocol.
After the collapse of IronFinance, there is still a lot of capital sitting on the sideline looking Â
for other high-risk opportunities. It will be interesting to see where this capital goes next.
So what do you think about the IronFinance fiasco? Are you optimistic about the future Â
of algorithmic stablecoins? Comment down below.
And as always, if you enjoyed this video, Â
smash the like button, subscribe to my channel and check out Finematics grant on Gitcoin.
Thanks for watching!
Metric | Count | EXP & Bonus |
---|---|---|
PERFECT HITS | 20 | 300 |
HITS | 20 | 300 |
STREAK | 20 | 300 |
TOTAL | 800 |
Sign in to unlock these awesome features: