In the OperatorVault contract's deposit function, the logic sends the tokens to stakeController contract by calling IERC677::transferAndCall function which returns a boolean flag to indicate the success or failure of the transaction.
The return value should be checked to ensure that underlying transaction was successful.
The return values of certain functions returns information about whether the underlying transaction was successful or failed. It is important for the caller contract to conclude the success or failure of the transaction. This is to ensure that contracts are performing correct accounting of funds based on the transactions.
The issue with the below code is that the return value is not being checked.
Incorrect accounting
Manual
If the flag being returned is not reliable due to different implementations of IERC677 contracts, then it is recommended to implement logic similar to safe transfer library from openzepplien.
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.