Platform: Code4rena
Start Date: 11/11/2022
Pot Size: $90,500 USDC
Total HM: 52
Participants: 92
Period: 7 days
Judge: LSDan
Total Solo HM: 20
Id: 182
League: ETH
Rank: 87/92
Findings: 1
Award: $40.86
🌟 Selected for report: 0
🚀 Solo Findings: 0
🌟 Selected for report: c7e7eff
Also found by: 0x4non, 9svR6w, HE1M, Jeiwan, Trust, aphak5010, arcoun, cccz, clems4ever, corerouter, koxuan, rotcivegaf, unforgiven
40.8568 USDC - $40.86
https://github.com/code-423n4/2022-11-stakehouse/blob/main/contracts/liquid-staking/SyndicateRewardsProcessor.sol#L51-L73 https://github.com/code-423n4/2022-11-stakehouse/blob/main/contracts/liquid-staking/GiantMevAndFeesPool.sol#L73 https://github.com/code-423n4/2022-11-stakehouse/blob/main/contracts/liquid-staking/GiantMevAndFeesPool.sol#L152 https://github.com/code-423n4/2022-11-stakehouse/blob/main/contracts/liquid-staking/GiantMevAndFeesPool.sol#L161 https://github.com/code-423n4/2022-11-stakehouse/blob/main/contracts/liquid-staking/GiantMevAndFeesPool.sol#L187 https://github.com/code-423n4/2022-11-stakehouse/blob/main/contracts/liquid-staking/StakingFundsVault.sol#L88 https://github.com/code-423n4/2022-11-stakehouse/blob/main/contracts/liquid-staking/StakingFundsVault.sol#L128 https://github.com/code-423n4/2022-11-stakehouse/blob/main/contracts/liquid-staking/StakingFundsVault.sol#L333 https://github.com/code-423n4/2022-11-stakehouse/blob/main/contracts/liquid-staking/StakingFundsVault.sol#L337
In _distributeETHRewardsToUserForToken() function, as there is _recipient.call() function, which may enable a malicious _recipient involved to call _distributeETHRewardsToUserForToken() function repeatedly, before the first invocation of the function was finished. Meanwhile, the _distributeETHRewardsToUserForToken() itself and most of the function's caller have no Reentrance attack resistance mechanism in place. As a result, this may cause the different invocations of the function to interact in destructive ways and a malicious user may drain out more ETH he deserves.
function _distributeETHRewardsToUserForToken( address _user, address _token, uint256 _balance, address _recipient ) internal nonReentrant
changes from:
claimed[_user][_token] = due;
to:
claimed[_user][_token] += due;
#0 - c4-judge
2022-11-21T13:58:28Z
dmvt marked the issue as duplicate of #60
#1 - c4-judge
2022-11-30T11:24:21Z
dmvt marked the issue as partial-25
#2 - c4-judge
2022-11-30T11:24:26Z
dmvt marked the issue as satisfactory
#3 - c4-judge
2022-11-30T11:30:05Z
dmvt marked the issue as not a duplicate
#4 - c4-judge
2022-11-30T11:30:13Z
dmvt marked the issue as duplicate of #59
#5 - C4-Staff
2022-12-21T05:47:22Z
JeeberC4 marked the issue as duplicate of #147