Skip to content
This repository has been archived by the owner on Dec 17, 2023. It is now read-only.

Latest commit

 

History

History
23 lines (15 loc) · 873 Bytes

053.md

File metadata and controls

23 lines (15 loc) · 873 Bytes

yy

high

Borrower can borrow without having sufficient collateral

Summary

The _getAccountLiquidity() provided does not include the logic for enforcing a minimum collateral requirement or performing explicit checks to prevent borrowing without sufficient collateral.

Vulnerability Detail

The _getAccountLiquidity() calculate the total collateral value and total debt value of the user based on their supply balances and borrow balances in each market. but minimum collateral requirement or performing explicit checks to prevent borrowing without sufficient collateral.

Impact

borrow without having sufficient collateral can be significant.

Code Snippet

https://github.com/sherlock-audit/2023-05-ironbank/blob/main/ib-v2/src/protocol/pool/IronBank.sol#L1032

Tool used

Manual Review

Recommendation

check before allowing borrowers to borrow funds