Return value of call() in UTBExecutor is not checked causing loss of funds #700
Labels
3 (High Risk)
Assets can be stolen/lost/compromised directly
bug
Something isn't working
duplicate-25
insufficient quality report
This report is not of sufficient quality
unsatisfactory
does not satisfy C4 submission criteria; not eligible for awards
Lines of code
https://github.com/code-423n4/2024-01-decent/blob/011f62059f3a0b1f3577c8ccd1140f0cf3e7bb29/src/UTBExecutor.sol#L41
Vulnerability details
Impact
Currently in the UTBExecutor.sol contract, there are two instances where the return value of call is not checked. In the first instance, this would lead to complete loss of output tokens received from the swap. In the second instance, this would break any external application changes that were supposed to be made by calling the payload.
Proof of Concept
Both instances exist in the execute() function.
First instance:
Second instance:
Tools Used
Manual Review
Recommended Mitigation Steps
Check the return value of call() by wrapping it around a require statement.
Assessed type
Error
The text was updated successfully, but these errors were encountered: