A Few More Liquidations Then Up Only

A DeFi Liquidations Primer

TL; DR: Liquidations are one of the least understood parts of all of the technical plumbing that keeps the decentralized finance ecosystem running. In this post, we will review the liquidation mechanisms for some of the most popular lending protocols.

What is an over-collateralized loan?

For the largest lending protocols like Aave, MakerDAO, Compound, and Euler finance, borrowing activity is all over-collateralized.

When a borrow is overcollateralized, this means that the borrower has posted more value in collateral than they have borrowed. For example, a borrower might be able to borrow $500 worth for each $1,000 of collateral they post. Loan-to-value (LTV) ratio is the ratio of borrowed asset value to the amount of collateral posted.

A user will deposit some collateral in the protocol, and they can then borrow up to a specific LTV amount. If this LTV goes below a certain level, then the collateral can be liquidated. Many DeFi lending protocols use this mechanism to ensure they are always solvent.

Depending on the collateral and the borrowed asset, a user will have different levels of loan-to-value ratio that they must maintain before getting liquidated. Lending protocols go to great lengths to customize the parameters of their markets to ensure that they will not incur bad debt.

If a position can not get liquidated for enough of the original borrowed asset, then the protocol can occur bad debt — they will have an outstanding borrow amount that is greater than the collateral they hold on the books.

Liquidation mechanisms are put in place to make sure that collateral that is dropping in value is quickly moved off the books and sold into the market. Since the protocols themselves can’t do this, they will set up a system of incentives and rules that allow market participants to run the liquidation. In practice, liquidations for lending protocols are a profitable business for MEV bots, which compete for the rewards inherent in a successful liquidation.

How do liquidations work?

Each protocol has a different mechanism for processing and rewarding liquidations. Here we will look at the way liquidations are done at the top lending protocols.

MakerDAO

MakerDAO, the lending protocol that issues DAI, is the largest DeFi protocol and one of the oldest. After going through numerous upgrades in response to market events, MakerDAO has settled on a liquidation mechanism that utilizes a collateral auction. When a vault holding collateral gets below its liquidation threshold, any user can submit a transaction to initiate an auction of the collateral.

Once the auction has started, users can bid in DAI. This will give the DAI to the protocol to repay the borrowed debt and in return, the successful liquidator will receive the deposited collateral. Liquidators will continually bid higher amounts of DA. If the amount of DAI offered exceeds the borrowed amount, then the auction process reverses and liquidators compete to give the best deal to the protocol.

Once the auction is closed, the winner sends their DAI to the protocol, pays off the debt, and receives the collateral. Most often, this collateral is sold off in the same transaction. Since the protocol auctions collateral with a slight discount to market price, it is a profitable activity for bots to initiate and compete for liquidations. Liquidation income is also passed back to MakerDAO through this system.

Aave

Unlike MakerDAO, Aave is a generalized lending protocol where users can deposit assets, and then these assets are made available for borrowers. Liquidations are important in this system to make sure there is no bad debt to the protocol and every depositor will be able to withdraw the original amount of assets they deposited.

Aave has also revised its liquidation mechanism several times and settled on the current version after lots of stress testing from the market.

In a single liquidation, up to 50% of a borrower’s debt can be repaid. That debt is sent back to the protocol and in exchange, the liquidator gets the deposited collateral and a liquidation bonus. The liquidation bonuses and the other relevant parameters for the loan-to-value ratio are customized per market.

Since all of the collateral is sold on the open market, the risk parameters must align with the overall market depth and liquidity to avoid the protocol incurring bad debt.

Compound

Compound is a money-market and lending protocol. Like Aave, they rely on a set of borrow and collateral parameters to keep the protocol overcollateralized. When an account gets below the liquidation level, bots will compete to liquidate the account through the protocol. The debt is repaid by the liquidator and in return, they receive discounted collateral, which they then usually sell directly in the same transaction. Similar to Aave, a borrowers debt can not be fully closed in a single liquidation.

Euler

Euler is a new lending protocol that offers the unique ability to create permissionless markets for long-tail assets. They allow this by only allowing some assets to be collateral for borrowing all assets in the market. Some assets are kept “isolated” meaning you can only deposit and borrow in the same market. This lets long-tail assets be safely added to the protocol and allows for short-selling opportunities on any asset with willing depositors.

Euler’s liquidation mechanism also functions differently from the other money markets like Aave and Compound. Euler has risk-adjusted parameters for both the collateral and borrow asset. When an account’s health factor goes below 1, a liquidator can initiate a liquidation. However, instead of allowing most of the collateral to be sold in the liquidation, Euler limits the amount of collateral liquidated to a smaller amount that will just bring the account up to an acceptable health factor. This is beneficial for borrowers since they will end up with less of their collateral liquidated compared to a similar position in another borrowing market.

Euler also implements a liquidation premium that allows bots to profit from quickly executing liquidations. In addition to the flat starting discount, the lower the borrower’s health factor, the higher the liquidation bonus. This allows the market to process liquidations on long-tail assets profitably.

When liquidations go wrong

Even though each protocol has different rules for when and how collateral is liquidated, at the end of the day, the collateral must be sold on the open market to process the liquidation. This means that is always important to have a liquid enough market to support the sale of posted collateral. When these factors are not aligned, then liquidations can’t happen properly and the protocol can be left with bad debt.

We have seen this play out a few times in the last months. Mango market on Solana was left with bad debt after Avraham Eisenberg conducted a market manipulation to pump the value of Mango’s native token. Since users could use this token to borrow in the protocol, a user pumped the price, deposited a bunch of Mango, and used this to borrow all of the hard assets from the protocol. Once the price of Mango fell, the protocol was left with a lot of worthless collateral and bad debt.

In a previous episode on Mango markets, a single whale had a large borrow collateralized with SOL tokens. It turned out that this account was so large that there would be no profitable way to sell the SOL collateral on-chain, ensuring that in a liquidation the protocol would be left with bad debt.

In a more recent example, Avraham Eisenberg struck again, this time targeting the Aave v2 protocol on mainnet. In a similar scheme to the one that broke Mango, he started to amass a large borrow position in CRV tokens. By continually borrowing and selling CRV, then taking the proceeds, depositing USDC, and borrowing more CRV, he was able to build a multi-million dollar short position against CRV. The episode ended with even more drama when the price started to pump towards his liquidation price and it turned out that there was not enough CRV on the market to profitably liquidate the position.

Changes to Avoid Bad Debt

While the Aave liquidation engine performed admirably, in the end, the protocol was left with a few million in CRV bad debt.

Aave has already put in a place plans to take care of the debt left over from the liquidation cascade. In the scheme of things it was an exciting, but rather inexpensive lesson for the protocol. In response, a number of governance proposals were voted through to reduce risk from long tail assets like CRV. It also serves a bit as a a wakeup call for the space, highlighting the importance of risk management and prudent protocol parameters.

Tags

Integral Insights

Updates

June 13th, 2024

Integral Insights May ‘24

Business

June 6th, 2024

How to Participate in the Arbitrum Rewards Campaign

125,000 $ARB will be dedicated to a 3-month liquidity mining program focusing on store-of-value (SoV) token pairs such as WETH-USDC, WETH-USDT, WETH-wstETH, and WETH-ARB.

Updates

June 6th, 2024

Unlock High Yields with Integral's $225K ARB Grant from Arbitrum Foundation – Join Our Liquidity Mining Program Today

Integral has been awarded a significant grant of 225,000 $ARB from the Arbitrum Foundation under the Long-Term Incentive Pilot Program (LTIPP). This funding will drive the growth and adoption of Integral on Arbitrum, benefiting the entire ecosystem. With 125,000 $ARB dedicated to a 3-month liquidity mining program focused on key token pairs like WETH-USDC and WETH-ARB, liquidity providers can enjoy high yields and reduced trading costs. Additionally, 100,000 $ARB will be allocated to incentivize integrations with aggregators, solvers, and vaults, fostering a more interconnected DeFi environment. Join us and be part of this exciting journey to enhance liquidity and trading on Arbitrum!

Updates

May 9th, 2024

Integral Insights April ‘24

The combined average daily volume across Ethereum and Arbitrum is now at 8.8 million USD, a remarkable 22% increase compared to last month.

Product

April 25th, 2024

Introducing New Pool Analytics: Elevate Your Liquidity Provision Experience

A standout feature in our latest update is the "LP vs Hold" tab, which provides a comparative analysis of various holding strategies against Integral's LP positions.

Business

April 1st, 2024

Integral Insights March ‘24

We achieved several important milestones, including a new all-time-high daily volume for Arbitrum and the addition of four new pools on the Ethereum mainnet.

Updates

March 4th, 2024

Integral Insights February ‘24

Another milestone was reached on February 21st when Integral processed over $2 billion in cumulative volume.

Updates

February 1st, 2024

Integral Insights: January ‘24

Our initial launch with the ETH-RPL pool was a success, quickly elevating us to the second most utilized liquidity pool for this pair’s trading.

Research

January 17th, 2024

Is Liquidity Fragmentation Really That Bad?

When the token evolves into a store of value, it attracts outside traders, focusing on trading costs and slippage. This is when concentrated liquidity truly shines.

Updates

January 2nd, 2024

2023 Review

At Integral, our focus remains on developing a sustainable product for on-chain trading, serving both traders and liquidity providers.

Updates

December 12th, 2023

Integral Now Rewards Liquidity Providers with Trading Fees on Ethereum Mainnet

This enhancement enables liquidity providers (LPs) to directly receive a portion or all trading fees from Integral pools.

Updates

December 6th, 2023

Integral Insights: November ‘23

During November, Integral processed an average of approximately 6 million in volume with around 1.5 million in TVL. The system’s overall capital utilization sits at around 350%. It is the 10th most used DEX on Ethereum.

Updates

November 28th, 2023

Integral Now Rewards Liquidity Providers with Trading Fees

This enhancement enables liquidity providers (LPs) to directly receive a portion or all trading fees from Integral pools.

Research

November 15th, 2023

How Do University Blockchain Societies Gain So Many Votes?

Explore how university blockchain societies like FranklinDAO and Michigan Blockchain have grown into influential players in DAO governance, utilizing delegated votes and strategic partnerships to shape the future of DeFi protocols like Uniswap, Compound, and Aave.

Updates

November 6th, 2023

Integral Insight: October ‘23

We give an update for our work in October and highlight a profitable LP position from a long-term user.

Research

October 26th, 2023

Understanding the Stakes in Lido’s Growing Share of Staked ETH

The community is arguing whether a protocol may have too much control over the Ethereum network. Lido controls a large percentage of staked ETH, which could have consequences for the network’s future security and neutrality.

News

October 14th, 2023

Changes to Staking and Farming

Looking back at our progress so far and to the future with new updates to staking and farming.

Updates

October 11th, 2023

Integral Insight: September ‘23

We give an update for our work in September with utilization going up on higher volume for our new pools.

Research

October 11th, 2023

The Hottest Narratives of the Summer

What were the hottest narratives of the summer? Our DeFi research team delves into the growth of trading bots, RFV traders and more in this overview.

Research

October 2nd, 2023

Uniswap Governance: A Deep Dive

Governance is considered a critical component for the decentralization and community-driven development of DeFi protocols. We take a look at one of the largest goverance ecostystems in DeFi, Uniswap. In this blog post, we'll discuss the landscape of Uniswap's governance, pulling data from empirical research to dissect the system's delegates and proposals, revealing some interesting findings.