Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

If extra reward token is "protected token" it the rewards will be taken by other protocols #44

Closed
code423n4 opened this issue May 30, 2022 · 2 comments
Labels
3 (High Risk) Assets can be stolen/lost/compromised directly bug Something isn't working duplicate This issue or pull request already exists invalid This doesn't seem right

Comments

@code423n4
Copy link
Contributor

Lines of code

https://github.com/code-423n4/2022-05-vetoken/blob/2d7cd1f6780a9bcc8387dea8fecfbd758462c152/contracts/VoterProxy.sol#L109-L119

Vulnerability details

Impact

Misallocation of extra reward tokens

Proof of Concept

Let's think of a scenario where CRV is being used as an extra incentive for a pickle finance gauge. The extra rewards will be sent to voterProxy but when the extra rewards stash tries to claim them, the tokens will be blocked because CRV is a protected token. Instead those rewards will be given to CRV stakers when claimed.

Tools Used

Recommended Mitigation Steps

When extra fees are collected, the balance before and after the claim should be logged to figure out how many tokens have been transferred and logged in a mapping to record how many are claimable by that specific protocol

@code423n4 code423n4 added 3 (High Risk) Assets can be stolen/lost/compromised directly bug Something isn't working labels May 30, 2022
code423n4 added a commit that referenced this issue May 30, 2022
@solvetony solvetony added the duplicate This issue or pull request already exists label Jun 15, 2022
@solvetony
Copy link
Collaborator

Duplicate of #255

@solvetony solvetony marked this as a duplicate of #255 Jun 15, 2022
@GalloDaSballo
Copy link
Collaborator

Disputed per #255

@GalloDaSballo GalloDaSballo added the invalid This doesn't seem right label Jul 25, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3 (High Risk) Assets can be stolen/lost/compromised directly bug Something isn't working duplicate This issue or pull request already exists invalid This doesn't seem right
Projects
None yet
Development

No branches or pull requests

3 participants