Steadefi

Steadefi
DeFiHardhatFoundryOracle
35,000 USDC
View results
Submission Details
Severity: medium
Invalid

Incorrect calculation of Lending Vault capacity

Summary

The additionalCapacity() function checks whether lending vaults have sufficient capacity to meet the funding demands for a new position based on the proposed depositValue().
There is an error in the calculation of the _maxTokenBLending variable

Vulnerability Details

Impact

Tools Used

Recommendations

uint256 _maxTokenBLending = convertToUsdValue(
self,
address(self.tokenB),
self.tokenBLendingVault.totalAvailableAsset()
) * SAFE_MULTIPLIER
/ (self.leverage * (1e18 - _tokenAWeight) / SAFE_MULTIPLIER);
Updates

Lead Judging Commences

hans Lead Judge almost 2 years ago
Submission Judgement Published
Invalidated
Reason: Lack of quality

Support

FAQs

Can't find an answer? Chat with us on Discord, Twitter or Linkedin.