DepositQueue doesn't collect fees from execution layer rewards #498
Labels
bug
Something isn't working
downgraded by judge
Judge downgraded the risk level of this issue
grade-a
primary issue
Highest quality submission among a set of duplicates
QA (Quality Assurance)
Assets are not at risk. State handling, function incorrect as to spec, issues with clarity, syntax
🤖_primary
AI based primary recommendation
🤖_230_group
AI based duplicate group recommendation
sponsor disputed
Sponsor cannot duplicate the issue, or otherwise disagrees this is an issue
sufficient quality report
This report is of sufficient quality
Lines of code
https://github.com/code-423n4/2024-04-renzo/blob/main/contracts/Deposits/DepositQueue.sol#L163-L183
Vulnerability details
The DepositQueue::receive() function is supposed to:
The function is expected to collect a fee from the rewards, fill the
WithdrawQueue
withdraw buffer if necessary and keep the remaining of the rewards in the contract:However, execution layer rewards don't trigger the
receive()
functions of smart contracts, the balance just gets updated and no code gets executed. Because of this theDepositQueue
contract will not take a fee from execution layer rewards.Impact
The
DepositQueue
contract will not collect a fee on execution layer rewards.Recommended Mitigation Steps
Use a dedicated contract to receive execution layer rewards. In that contract add an external function that allows to send the collected rewards to the
DepositQueue
, which will trigger thereceive()
function as expected and collect the appropriate fees.Assessed type
ETH-Transfer
The text was updated successfully, but these errors were encountered: