Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Griefing attack: attacker can create multiple borrow with dust amount to make protocol suffer bad debt due to lack of incentive to liquidate them #511

Closed
c4-bot-9 opened this issue Mar 15, 2024 · 4 comments
Labels
2 (Med Risk) Assets not at direct risk, but function/availability of the protocol could be impacted or leak value bug Something isn't working duplicate-455 🤖_230_group AI based duplicate group recommendation satisfactory satisfies C4 submission criteria; eligible for awards sufficient quality report This report is of sufficient quality

Comments

@c4-bot-9
Copy link
Contributor

Lines of code

https://github.com/code-423n4/2024-03-revert-lend/blob/main/src/V3Vault.sol#L550-#L602

Vulnerability details

Vulnerability details

When deploying V3Vault contract, minLoanSize is originally set to 0:

// minimal size of loan (to protect from non-liquidatable positions because of gas-cost)
uint256 public minLoanSize = 0;

And in the uniswap v3, minting position does not have any limitation in value: original code

Attacker can mint multiple positions with small amount, transfer them to V3Vault and use them to borrow. When the price change, and these positions is under-collateralzed, there is no incentive for anyone to liquidate them because cost of gas required to call them is more than value of token they receive back.

Impact

Protocol will suffer bad debt because no one is willing to liquidate them

Tools Used

Manual review

Recommended Mitigation Steps

Variable minLoanSize should be set when initalizing this contract.

Assessed type

Other

@c4-bot-9 c4-bot-9 added 2 (Med Risk) Assets not at direct risk, but function/availability of the protocol could be impacted or leak value bug Something isn't working labels Mar 15, 2024
c4-bot-9 added a commit that referenced this issue Mar 15, 2024
@c4-bot-11 c4-bot-11 added the 🤖_230_group AI based duplicate group recommendation label Mar 15, 2024
@c4-pre-sort c4-pre-sort added the insufficient quality report This report is not of sufficient quality label Mar 18, 2024
@c4-pre-sort
Copy link

0xEVom marked the issue as insufficient quality report

@c4-pre-sort c4-pre-sort removed the insufficient quality report This report is not of sufficient quality label Mar 22, 2024
@c4-pre-sort
Copy link

0xEVom marked the issue as sufficient quality report

@c4-pre-sort c4-pre-sort added the sufficient quality report This report is of sufficient quality label Mar 22, 2024
@c4-pre-sort
Copy link

0xEVom marked the issue as duplicate of #455

@c4-judge c4-judge added the satisfactory satisfies C4 submission criteria; eligible for awards label Apr 1, 2024
@c4-judge
Copy link

c4-judge commented Apr 1, 2024

jhsagd76 marked the issue as satisfactory

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
2 (Med Risk) Assets not at direct risk, but function/availability of the protocol could be impacted or leak value bug Something isn't working duplicate-455 🤖_230_group AI based duplicate group recommendation satisfactory satisfies C4 submission criteria; eligible for awards sufficient quality report This report is of sufficient quality
Projects
None yet
Development

No branches or pull requests

4 participants