The SDLPoolCCIPController contract contains an Unprotected External Function vulnerability in the recoverTokens function. This vulnerability allows anyone to call the function, enabling potential malicious actors to drain the contract of all ERC20 tokens. The recommended mitigation is to implement proper access control in the recoverTokens function, restricting its usage to authorized users.
The recoverTokens function lacks proper access control, allowing anyone to call it and potentially drain the contract of all ERC20 tokens.
VsCode / Manual Review
Implement proper access control in the recoverTokens function to restrict its usage to authorized users only. Consider using the OpenZeppelin Ownable contract to manage ownership securely.
By inheriting from OpenZeppelin's Ownable contract and using the onlyOwner modifier, you ensure that only the contract owner can execute the recoverTokens function, adding a layer of access control and mitigating the vulnerability.
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.