Skip to content
This repository has been archived by the owner on Apr 28, 2024. It is now read-only.

mstpr-brainbot - Liquidity owner can burn the liquidity position to hurt borrower #146

Closed
sherlock-admin2 opened this issue Oct 23, 2023 · 0 comments
Labels
Duplicate A valid issue that is a duplicate of an issue with `Has Duplicates` label High A valid High severity issue Reward A payout will be made for this issue

Comments

@sherlock-admin2
Copy link
Contributor

sherlock-admin2 commented Oct 23, 2023

mstpr-brainbot

medium

Liquidity owner can burn the liquidity position to hurt borrower

Summary

Malicious liquidity position owner can harm borrower by burning the liquidity hence, the borrower or any liquidatior can not repay and the borrowers collateral + liquidation bonus + 1 day collateral rate is lost forever.

Vulnerability Detail

Uniswapv3 positions can be controlled by the original owner and the approval address. In this case approval address is the wagmi contract and the owner is owner of the liquidity position. So owner can remove-burn liquidity.

Assuming that Alice has a position and she has borrowed 10 WETH. She obtained this loan from Bob, who happens to be a large whale. However, Bob, seemingly for trolling purposes, decides to burn the liquidity position. Consequently, Alice becomes unable to repay her loan, and as a result, her borrowed collateral, the liquidation bonus, and the collateral she has accrued at the 1-day daily rate are now stuck. Alice has effectively lost that entire amount.

In theory, it appears that Bob has incurred a greater loss than Alice. Nevertheless, this scenario underscores the fact that Alice is a retail user with limited resources, while Bob possesses a significant amount of funds. Thus, Bob may not be concerned about losing 10 WETH, especially if it means causing harm to Alice.

Impact

Does not seem logically to do unless the liquidity position owner and the borrower has some sort of beef I guess but it is very easy to do so I will classify this as medium.

Code Snippet

https://github.com/sherlock-audit/2023-10-real-wagmi/blob/main/wagmi-leverage/contracts/LiquidityBorrowingManager.sol#L650-L661

https://github.com/sherlock-audit/2023-10-real-wagmi/blob/main/wagmi-leverage/contracts/abstract/LiquidityManager.sol#L394-L426

Tool used

Manual Review

Recommendation

Duplicate of #78

@github-actions github-actions bot added High A valid High severity issue Duplicate A valid issue that is a duplicate of an issue with `Has Duplicates` label labels Oct 26, 2023
@sherlock-admin2 sherlock-admin2 changed the title Boxy Tangerine Quail - Liquidity owner can burn the liquidity position to hurt borrower mstpr-brainbot - Liquidity owner can burn the liquidity position to hurt borrower Oct 30, 2023
@sherlock-admin2 sherlock-admin2 added the Reward A payout will be made for this issue label Oct 30, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Duplicate A valid issue that is a duplicate of an issue with `Has Duplicates` label High A valid High severity issue Reward A payout will be made for this issue
Projects
None yet
Development

No branches or pull requests

1 participant