The claim
function of the staking
contract is setting the claimable mapping after a token transfer.
Solidity recommends the usage of the Check-Effects-Interaction Pattern to avoid potential security issues, such as reentrancy.
claim
function of Staking.sol
contract is updating the claimable
mapping after the external call which can be used by attacker to control the flow of the contract and further reenter into the function. It is advisable to follow CEI pattern.
May cause minimal or un-noticeable impact, But this should be remediated as external call may lead of reentrancy to other functions as well.
manual
Although the impact is very limited, it is recommended to implement:
modifier such as nonReentrant
checks-effects-interactions pattern.
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.