StrategyArb::_harvestAndReport
returns wrong amount of value of _totalAssets
_harvestAndReport
function is being used to harvest all rewards, redeploy any idle funds and return an accurate accounting of all funds currently held by the Strategy. The function spesifically being used to calculate all funds being held which is returned by the _totalAssets
value.
@return _totalAssets A trusted and accurate account for the total amount of 'asset' the strategy currently holds including idle funds.
Based on the description of the returned function above, _totalAssets only contains asset
and not the underlying which means underlying
shouldn't be used as the value to be added in _totalAssets
.
https://github.com/Cyfrin/2024-12-alchemix/blob/main/src/StrategyArb.sol#L148-L170
Wrong _totalAssets
being returned by combining underlyingBalance
in the variable.
Incorrect value to be inputed while harvesting all rewards, and redeploying any idle funds.
Manual Review
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.