Liquidating positions with bounded Kerosen could be unprofitable for liquidators
mediumLines of code
Vulnerability details
Description
Bounded Kerosene is not attractive for liquidation. First of all bounded kerosene has twice the value of unbounded kerosene. E.g if 1 Kerosene is worth 10 usd in the unbounded vault then 0.5 Kerosen will be worth the same amount in a bounded vault. Twice the valuation is justified for users and Liquidity Providers. The problem however is if we take the prespective of a liquidator. If he liquidates a position that has a significant percentage of the position value in bounded Kerosene Vault. The liquidator will recieve the amount locked in the bounded kerosene vault, which he can't withdraw so the liquidator actually wouldn't be necessary be able to swap the kerosene against stable coins to make a profit for example. He will also recieve half the amount of kerosene if this was an unbounded kerosene Vault. This might not be clear, so we encourage the reader to see the following example to understand the need to rework liquidations for bounded kerosene vaults.
N.B please note that there is a bug in the liquidate() function and Kerosene Collateral are not sent to the liquidator, but as I have confirmed with the sponsor, The protocol intended to send the Kerosene Tokens to the liquidators along side the seized Eth
Proof of Concept
As an example to show the huge disadvantage a liquidator will face when liquidating bounded kerosene vs unbounded kerosen vs exo collateral (like eth)
let's take similar context but with different composition of collateral
Collateral worth 1.4k and minted dyad is worth 1k usd: -> collRatio =140 % which is elligible for liquidation. percentage of coll to seize is (100%+ 40%*20%)/140% => 77.14% of collateral to seize
For simplicity let's say 1 unbounded kerosene Token is worth 100 usd and 1 bounded kerosene Token is worth 200 usd (twice the asset price) in the vaults as collateral ( however the value of Kerosene outside the vaults in exchanges is gonna be near the 100 usd valuation)
The liquidator needs to pay down 1k dyads (1k usd) ||Bounded Kerosene| Unbounded Kerosene | Eth (no Kerosen) | | -------- | ------- | -------- | ------- | |Liquidation cost for liquidators| 1k DYAD|1k DYAD|1k DYAD| |collateral composition|1k worth of eth + 2 kerosene Tokens|1k worth of eth + 4 kerosene Tokens| 1.4k usd worth of eth | |seized coll |771 usd worth of eth + 1.54 Kerosene Token (not withdrawable)|771 usd worth of eth + 3.08 Kerosene Tokens(withdrawable) |1.08k usd worth of eth| |usd worth of seized collateral|925 usd (154 usd value is locked, not tradable)|1.08k usd |1.08 k usd|
Recomendation
Having twice the value for kerosene if locked, might make sense for Protocol user, this however will result in problems for liquidators. We recommend the protocol to implement a solution that addresses the following issues:
- Liquidators of kerosene type collateral, should always be able to withdraw the token (whetether seized from bounded or unbounded Vaults)
- When calculating the amount of tokens to seize (incentive), Kerosene tokens should be valued the same, for unbounded and bounded kerosene Vaults, so it would make economic sense for the liquidator
Assessed type
Context
