execute function in Executor.sol will return true when calling non-existent contracts. As stated in the solidity docs "The low-level functions call, delegatecall and staticcall return true as their first return value if the account called is non-existent, as part of the design of the EVM."
Lines of code
https://github.com/code-423n4/2023-01-biconomy/blob/53c8c3823175aeb26dee5529eeefa81240a406ba/scw-contracts/contracts/smart-contract-wallet/base/Executor.sol#L13-L34
Vulnerability details
Impact
execute
function inExecutor.sol
will returntrue
when calling non-existent contracts. As stated in the solidity docs "The low-level functions call, delegatecall and staticcall return true as their first return value if the account called is non-existent, as part of the design of the EVM."There is no check for contract existence before calling
execute
, nor insideexecute
function. Therefore this function can fail silently.Recommended Mitigation Steps
Please consider checking for the account's existence before doing
call
/executecall