The RAAC protocol’s auction mechanism currently permits extremely low bids for liquidated NFTs, regardless of their underlying debt. This design flaw means NFTs can be acquired at a fraction of their debt value, potentially leading to significant financial loss for the protocol.
Protocols liquidate users primarily to manage and mitigate risk. When value of collateral falls below the borrowed amount, the position of the user becomes risky for the protocol to handle. Hence they are liquidated to keep the protocol safe from bad debt.
In RAAC NFTs are liquidated for the same reason and they are auctioned.
The purpose of auctions can be to cover up a certain portion of the debt which a particular NFT has. But here, liquidated NFTs can be acquired by paying extremely low bids.
The placeBid() function is reponsible for letting users bid on liquidated auctions.
TokenData storage data = tokenData[tokenId]; fetches the details of the particular tokenId.
TokenData is a struct:
When the NFTs are liquidated by liquidateNFT() function, it updates the TokenData struct associated with the particular tokenId.
So we can see that for each tokenId liquidated, the TokenData struct contains it's underlying debt.
Let us consider a token is being auctioned for the first time, and first bid is placed with 1 wei and analyse the placeBid() function:
So even if the actual debt associated with NFT was 10ETH(assumption) the NFT can be bought by paying a fraction of it. Which overtime would accrue bad debt to the protocol.
On the contrary if we look at buyBackNFT() function:
It ensures that user has to pay a 110% premium to buy back their NFT which is a good design choice.
The design flaw allows NFTs with significant debt to be acquired for a fraction of their value. This mispricing can lead to financial losses for the protocol.
Manual review
The protocol can implement a mechanism in which the base price of NFT i.e. minBidAmount takes in consideration of the debt value associated with the NFT. The base price can be set at a discounted price, which would help the protocol to cover up the bad debt partially.
E.g.
The actual formula for calculation minBidAmount while introducing a discount, can differ from the example. The above example is just a representation on how it** might be done.**
The contest is live. Earn rewards by submitting a finding.
This is your time to appeal against judgements on your submissions.
Appeals are being carefully reviewed by our judges.