Function addLiquidity is external and allows users to add liquidity, but it doesn't check for zero collateralAmount.
There is no restriction on the minimum collateralAmount
, allowing users to add liquidity without depositing any collateral.
The vulnerability allows users to add liquidity without depositing any collateral. This could result in liquidity pools being manipulated by malicious actors who exploit the lack of a zero-collateral check. The system might become vulnerable to attacks. Without a proper check, it may also cause unexpected behavior in further functions relying on liquidity amounts.
Manual review
Add a require to check that collateralAmount can't be zero.
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.