[TEMP CHECK] BGD. Further Aave v1 deprecation strategy


Title: [TEMP CHECK] Further Aave v1 deprecation strategy

Author: BGD Labs @bgdlabs

Date: 2023-12-20



Summary

Approve further steps of Aave v1 off-boarding, to reduce operational overhead on deprecated Aave instances.


Motivation

The Aave protocol v1 was released in January 2020 and eventually superseded by Aave protocol v2 in December on the same year.

While Aave v1 has been deprecated for a long time, some liquidity is still stuck on the protocol. Even if this instance is not covered by the Aave Safety Module, being part of Aave, it still is monitored and evaluated whenever development and/or security decisions are made.

This creates meaningful overhead for all involved development & security teams, which directly adds cost to the Aave DAO. Additionally, the architecture of Aave v1 is quite different to Aave v2 & v3, making it the most ad-hoc instance of Aave.

For the previous reasons, we think the community should evaluate approving extra off-boarding steps.


Specification

To achieve a complete off-boarding of Aave v1, the following needs to be completed:

  • All debt has to be settled, in order to allow liquidity providers on v1 to withdraw.
  • All assets have to be withdrawn.

To minimise the impact on users we propose a phased approach, where each phase could last in the order of 1-3 weeks.

Phase 1

In a first phase we recommend to upgrade the liquidation mechanism on the protocol in the following ways:

  • It should no longer be possible to receive aTokens for liquidations (as the goal is to remove liquidity, not transfer it from user to user).
  • It should be possible to liquidate healthy (collateralised) positions with a fixed liquidationBonus (e.g. 1%). This value should be small to not hurt borrowers, while still being big enough to incentivise liquidations. If this Temp Check is successful, we will confirm the number with risk providers., but 1% at the current moment would make the liquidation profitable for approximately 85% of the positions to liquidate.
  • It should be possible to liquidate a entire position at once (currently on Aave v1 only 50% of a position can be liquidated).
  • Interest rates should be lowered to the minimum, as the previously described always-enabled dynamics remove any need of utilisation dynamics.
  • Remove flash loan fee, as there should not be extra incentives for liquidity providers.

Phase 2

In a second phase we recommend increasing the fixed liquidationBonus to a higher percentage.

The exact number must be chosen based on current market conditions to minimise user impact, but allow economical liquidations.

Phase 3

Once the big majority of debt is repaid, we recommend to introduce a forced withdrawal mechanism. With forced withdrawals anybody could withdraw on behalf of any liquidity provider on Aave v1, with the funds received by the holder of the aToken.

It is important to clarify that further technical aspects on this should be analysed before executing this step, for example smart contracts receiving funds without triggering a withdrawal.




After all the Phases are finished, additional ad-hoc steps can be executed, like Rescue Mission for locked funds.


Next Steps

First, we will create a Temp Check Snapshot, following the governance framework and standards of the community for a proposal like this one.

If approved, we will proceed with an ARFC, with the final steps including feedback from risk service providers, and precise technical decisions.

Finally, AIPs will be created for the different phases.


Copyright

Copyright and related rights waived via CC0 .

6 Likes

Following the plan, we have created a TEMP CHECK Snapshot for the community to pre-approve the initial roadmap on the v1 deprecation, with vote starting tomorrow.

Participate :ghost:
https://snapshot.org/#/aave.eth/proposal/0x7451f00809986c7cb8cce7ef4587efdfedad06089ebf2851d64122d00b035d9c

1 Like

After the pre-approval on Snapshot, and given that each one of the Phases will be pretty granular and with time in between, we think it is appropriate in this case to proceed with the AIP for Phase 1.


To highlight, what will happen in Phase 1 is the following:

  • On liquidations, it will not be possible to receive aTokens anymore.
  • In order to force off-boarding, it will be possible to liquidate healthy (collateralised) positions with a fixed liquidationBonus of 1%. This value is as small as possible as to incentivise liquidators, while not hurting borrowers, however, we urge ALL borrowers to migrate their positions to Aave v3 in order to fully avoid liquidation.
  • It will be possible to liquidate a entire position at once (currently on Aave v1 only 50% of a position can be liquidated).
  • All interest rate strategies will be replaced with one with minimal parameters: 1% slope1 and 2% slope2. In practise, this has little influence, as with all positions being liquidated, no healthy borrowings will keep open.
  • Flash loans will be disabled. Initially the idea was to remove the flash loan fee, but given that at this stage integrations should not be depending on Aave v1 flash loans, we think it is reasonable to not introduce overhead and completely disabling them.
5 Likes

Following the procedure, after the pre-approval of the community on Snapshot, we have created an on-chain AIP for the Phase 1 of the further Aave v1 deprecation.

Once again we urge ALL borrowers to migrate their positions to Aave v3 in order to fully avoid liquidation, as the proposal will introduce a new mechanism by which all borrowings are liquidated, with a fixed 1% bonus.

Voting will start in approximately 24h, participate :ghost:
https://vote.onaave.com/proposal/?proposalId=15

2 Likes

The Phase I of this off-boarding process was executed by the Aave Governance a bit more than a week ago(February 6th).

Since then some users have repaid their debt and others got liquidated with a minimal 1% bonus, reducing the outstanding debt by more than $1m from ~$1.6m to ~$550k.




To understand liquidation profitability on Aave protocol v1 (and applicable to the other instances too) one has to consider 3 things:

  • Gas cost of the liquidation action.
  • Liquidation bonus.
  • Position size.

Simplifying, one can say a liquidation is profitable as long as positionSize * liquidationBonus > gasCost .

Given that on Aave v1 there’s no reserve masks or similar optimisation techniques, the gas cost is roughly the same for each position, at around ~1M gas. Sophisticated actors will not only liquidate, but also directly swap the assets/source the liquidity, potentially increasing this cost.


So with a 30 gwei base-fee and $ETH at $2.830,00, this means a liquidation will cost around 0.03 ETH or 85$, causing the following (numbers are not completely exact, but roughly approximated):

  • With the current 1% bonus, it is likely that almost nothing else will be liquidated, given there is only a small number of positions with debt > $10k.
  • With a bonus of 3%, positions > 1 ETH should be profitable to liquidate at current market conditions, which would account for 114 ETH of debt being liquidated.
  • With a bonus of 4% positions > 0.75 ETH should be profitable to liquidate as current market conditions, which would account for 128 ETH of debt being liquidated.



Following the previous analysis, we think it is appropriate to progress to Phase 2 and raise the liquidation penalty to an intermediate level of 3%, not hurting in excess the left users, but still progressing on the off-boarding goal, with estimated extra liquidations of roughly $200k.

In order to give extra time for the community to comment and users to further repay their positions, we target creating a governance proposal end of next week or beginning of the following (week of 26th).

1 Like

Following the timeline, we have created an on-chain governance proposal to raise the liquidation bonus to an intermediate level of 3%.

Voting will start in 24 hours, participate :ghost:
https://vote.onaave.com/proposal/?proposalId=37

1 Like

Final Phase 3


Phase 2 was executed on March 3th resulting in a reduction of more than 200’000 of debt.

For next steps, when looking into the previously suggested Phase 3 in detail, we noticed that a “force withdrawal” could permanently lock funds on some contracts that are not intended to ever receive the underlying.

We did some research into different alternative (e.g. merkle distribution-based), but again there might be contracts holding funds that will not be able to claim (one of the biggest holders of aLINK is an iEARN vault with no ability to claim). While looking into crafting a custom solution for iEARN users, there are >3000 contracts holding funds and there is no way to ensure a seamless transition for everyone (especially as some of the contracts are not verified).




Therefore for this final Phase 3 we suggest the following:

  • Do a final increase of the static Liquidation Bonus from 3% to 5%.

  • Disable the asset-specific liquidationBonus in favor of always using the static one. While this might reduce the Liquidation Bonus for some positions, it will allow a code optimisation to reduce liquidation gas cost by more than 60%, which should have a major effect on the profitability of liquidating small positions.

  • Replace the interest rates of all assets with one with flat 0 parameters.

  • Disable all functions on v1, apart from liquidationCall, repay and withdraw.

  • Inject funds from the Aave Collector for users to be able to withdraw, to compensate the minor bad debt accrued since the inception of v1 years ago. The amounts to be proposed are the following:

    • 15’000 DAI.
    • 17’000 TUSD.
    • 9’500 USDC.
    • 2 ETH.
    • 2’000 sUSD.
    • 6’500 BAT.
    • 0.025 MKR.
    • 6’500 MANA.
    • 0.02 WBTC.
    • 6’000 BUSD.

    This is a slight overestimation to give users room to withdraw, even before debt is being repaid. The exact amounts needed might vary slightly due to liquidations. Once users have withdrawn their funds the DAO can claim back the assets left.


We want to highlight something: after this final Phase 3 is executed, Aave v1 will not be maintained anymore, anyhow, because the only off-boarding path is for users themselves to withdraw their funds.
There will be no more maintenance & support, in addition to the lack of coverage already approved by the community time ago.

We highly recommend users to migrate & interface maintainers to highlight the deprecation on their UIs.




In the following days, we will be creating the on-chain governance proposal for this Phase 3.

3 Likes

As an update to the community, following the plan we have created an on-chain AIP for the third and final phase of v1 deprecation.

The full content of the proposal can be found on the AIP description, but the following are some slight differences included after our previous message:

  • No funds are injected from the Collector. Levels of debt are quite low at the moment, and given that we think it is highly probable that multiple accounts will not withdraw their funds (e.g. lost private keys), it is reasonable to not provide unnecessary withdrawal liquidity at the moment. Full rationale can be found on the AIP.
  • Final update of price feeds. For safety, we included in the proposal an update of different price feeds (stablecoins) that aligns v1 with v2, introducing CAPO there.

The other changes are the previously disclosed.




Voting will start in approximately 24 hours, participate :ghost:
https://vote.onaave.com/proposal/?proposalId=98

2 Likes

As an update for the community, the final step of deprecation of Aave v1 has bee executed by proposal 98. This means that from now on, the only available actions are repayments, liquidations and withdrawals; and all interest rates are zeroed.

To reiterate: from now on, Aave v1 will be not maintained technically anyhow anymore. The recommendation is for any left users to withdraw and migrate to newer and maintained versions of Aave.

3 Likes