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

H-02 MitigationConfirmed #41

Open
c4-bot-9 opened this issue Jun 7, 2024 · 1 comment
Open

H-02 MitigationConfirmed #41

c4-bot-9 opened this issue Jun 7, 2024 · 1 comment
Labels
mitigation-confirmed MR-H-02 satisfactory satisfies C4 submission criteria; eligible for awards

Comments

@c4-bot-9
Copy link
Contributor

c4-bot-9 commented Jun 7, 2024

Lines of code

Vulnerability details

Original Issue Summary

The OperatorDelegator.getTokenBalanceFromStrategy() incorrectly uses address(this) to check for the queued amount instead of address(token).

address(this) will always return 0, which means that queuedShares[address(token)] will not be accounted for.

Mitigation

This mitigation proposes the usage of address(token) instead of address(this):

-            queuedShares[address(this)] == 0
+            queuedShares[address(token)] == 0

Comments

This mitigation succesfully mitigates the original issue. The address of the token is used, which will succesfully get the underlying token amount from the amount of shares + queued withdrawal shares.

Suggestion

n/a

Conclusion

LGTM

c4-bot-10 added a commit that referenced this issue Jun 7, 2024
@c4-judge c4-judge added the satisfactory satisfies C4 submission criteria; eligible for awards label Jun 8, 2024
@c4-judge
Copy link

c4-judge commented Jun 8, 2024

alcueca marked the issue as satisfactory

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
mitigation-confirmed MR-H-02 satisfactory satisfies C4 submission criteria; eligible for awards
Projects
None yet
Development

No branches or pull requests

2 participants