DeFiFoundrySolidity
16,653 OP
View results
Submission Details
Severity: low
Invalid

Missing Interface Definition for Contract's StrategyArb.sol & StrategyOp.sol function setRouter.

Summary

function setRouter is present in the contract StrategyArb.sol & StrategyOp.sol, but is not declared in its interface i.e IStrategyInterface.sol. This makes it inaccessible when interacting with the contract through its interface.

Vulnerability Details

setRouter function is implemented in the contract but not included in its interface.

Impact

  • developers cannot call the function when interacting through the interface.

  • tools and systems relying on the interface cannot detect or use the function.

POC

I am running the setUp in forked arbitrum. This is the original SetUp.sol file nothing is modified here.

function setUp() public virtual {
// ETH
// vm.createSelectFork("https://rpc.ankr.com/eth");
// ARB
vm.createSelectFork("https://rpc.ankr.com/arbitrum");
_setTokenAddrs();
_setConfig();
...
}

Then in Operation.t.sol

function test_setRouter() public {
vm.prank(management);
strategy.setRouter();
}

OUTPUT of test_setRouter

Member "setRouter" not found or not visible after argument-dependent lookup in contract IStrategyInterface.
--> src/test/Operation.t.sol:24:9:
|
24 | strategy.setRouter();
| ^^^^^^^^^^^^^^^^^^
Error:
Compilation failed

Tools Used

Manual reviwe and foundry

Recommendations

Modify the IStrategyInterface.sol, interface to suit the setRouter function.

Updates

Appeal created

inallhonesty Lead Judge 7 months ago
Submission Judgement Published
Invalidated
Reason: Non-acceptable severity
inallhonesty Lead Judge 7 months ago
Submission Judgement Published
Invalidated
Reason: Non-acceptable severity

Support

FAQs

Can't find an answer? Chat with us on Discord, Twitter or Linkedin.