This repository has been archived by the owner on May 26, 2023. It is now read-only.
0xbepresent - fundingTotals
is not updated when funder withdraw his funding in the TieredPercentage
bounty.
#383
Labels
Duplicate
A valid issue that is a duplicate of an issue with `Has Duplicates` label
High
A valid High severity issue
Reward
A payout will be made for this issue
Sponsor Confirmed
The sponsor acknowledged this issue is valid
Will Fix
The sponsor confirmed this issue will be fixed
0xbepresent
high
fundingTotals
is not updated when funder withdraw his funding in theTieredPercentage
bounty.Summary
The refund action can be at any time after the expiration time. While the payment for the winners are processing the funder can refund his funding and the fundingTotals is not updated.
Vulnerability Detail
The refund action DepositManagerV1.sol::refundDeposit() can be at any time after the expiration time. If there is a payment proccess for the winners via ClaimManagerV1.sol::claimBounty() or ClaimManagerV1.sol::permissionedClaimTieredBounty() the refund action can destabilize the protocol. See the next situation:
Tiered percentage bounty with 3 winners:
fundingTotals
because is not the same token balance.Impact
A funder intentionally/accidentally can withdraw his funding before the winner claim his rewards causing a destabilization in the
fundingTotals
variable, therefore the next winners can not claim their rewards.I created a test in
ClaimManager.test.js
.Steps:
Code Snippet
The
claimTiered()
function is using afundingTotals
variable which is not updated in the refund action.Tool used
Vscode
Recommendation
Ensure that once the first place winner is processed the funders refunds can not be possible. Or update the
fundingTotals
in the refund action.Duplicate of #266
The text was updated successfully, but these errors were encountered: