Closed code423n4 closed 2 years ago
Unchecked return value of transfer() and transferFrom() in RubinconRouter.sol The smart contract does not check the return value for transfer() and transferFrom() in different functions in the contract. Occurrences are in: BathToken._withdraw() - https://github.com/code-423n4/2022-05-rubicon/blob/main/contracts/rubiconPools/BathToken.sol#L602 BathToken.rebalance() - https://github.com/code-423n4/2022-05-rubicon/blob/main/contracts/rubiconPools/BathToken.sol#L353 BathToken.rebalance() - https://github.com/code-423n4/2022-05-rubicon/blob/main/contracts/rubiconPools/BathToken.sol#L357 BathToken._withdraw() - https://github.com/code-423n4/2022-05-rubicon/blob/main/contracts/rubiconPools/BathToken.sol#L605 BathToken._deposit() - https://github.com/code-423n4/2022-05-rubicon/blob/main/contracts/rubiconPools/BathToken.sol#L565
Recommendations: Wrap the call into a require() or use openzeppelin's SafeERC20 library.
dup of #316
Judge has assessed an item in Issue #220 as Medium risk. The relevant finding follows: