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

Rewards from native restaking kept in the DelayedWithdrawalRouter are not accounted for in calculateTVLs #269

Closed
howlbot-integration bot opened this issue May 9, 2024 · 5 comments
Labels
bug Something isn't working downgraded by judge Judge downgraded the risk level of this issue duplicate-528 grade-b QA (Quality Assurance) Assets are not at risk. State handling, function incorrect as to spec, issues with clarity, syntax 🤖_216_group AI based duplicate group recommendation sufficient quality report This report is of sufficient quality unsatisfactory does not satisfy C4 submission criteria; not eligible for awards

Comments

@howlbot-integration
Copy link

Lines of code

https://github.com/code-423n4/2024-04-renzo/blob/main/contracts/RestakeManager.sol#L274
https://github.com/Layr-Labs/eigenlayer-contracts/blob/dev/src/contracts/pods/EigenPod.sol#L274

Vulnerability details

Impact

Users rewards from native stake are in the DelayedWithdrawalRouter and wil lbe claimed later, leading to incorrect TVL and allowing users to easily frontrun tvl updates and profit.

Proof of Concept

RestakeManager::calculateTVLs() does not take into account ETH in the DelayedWithdrawalRouter, which will happen every time a ETH withdrawal is executed in OperatorDelegator::completeQueuedWithdrawal(). In this function, the rewards from native staking will be sent to the DelayedWithdrawalRouter, where they will be kept until they are claimed and sent to the OperatorDelegator, where they are correctly accounted for. Thus, in the meantime users can buy ezETH cheaper than intended and sellers will take a loss.

Tools Used

Vscode

Recommended Mitigation Steps

Include the balance of the DelayedWithdrawalRouter in the calculation of the total TVL.

Assessed type

Other

@howlbot-integration howlbot-integration bot added 3 (High Risk) Assets can be stolen/lost/compromised directly 🤖_216_group AI based duplicate group recommendation bug Something isn't working sufficient quality report This report is of sufficient quality labels May 9, 2024
howlbot-integration bot added a commit that referenced this issue May 9, 2024
@c4-judge
Copy link
Contributor

alcueca marked the issue as duplicate of #528

@c4-judge c4-judge added the unsatisfactory does not satisfy C4 submission criteria; not eligible for awards label May 23, 2024
@c4-judge
Copy link
Contributor

alcueca marked the issue as unsatisfactory:
Invalid

@Simao123133
Copy link

This was incorrectly marked invalid, an explanation was already given in the main issue.

@c4-judge
Copy link
Contributor

alcueca changed the severity to QA (Quality Assurance)

@c4-judge c4-judge added downgraded by judge Judge downgraded the risk level of this issue QA (Quality Assurance) Assets are not at risk. State handling, function incorrect as to spec, issues with clarity, syntax and removed 3 (High Risk) Assets can be stolen/lost/compromised directly labels May 27, 2024
@alcueca
Copy link

alcueca commented May 27, 2024

Pending on sponsor review and actual proof of impact being higher than dust.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working downgraded by judge Judge downgraded the risk level of this issue duplicate-528 grade-b QA (Quality Assurance) Assets are not at risk. State handling, function incorrect as to spec, issues with clarity, syntax 🤖_216_group AI based duplicate group recommendation sufficient quality report This report is of sufficient quality unsatisfactory does not satisfy C4 submission criteria; not eligible for awards
Projects
None yet
Development

No branches or pull requests

4 participants