Permanent infinite approval of assets gives EigenLayer Strategy Manager more access than necessary #244
Labels
bug
Something isn't working
downgraded by judge
Judge downgraded the risk level of this issue
duplicate-70
grade-b
insufficient quality report
This report is not of sufficient quality
QA (Quality Assurance)
Assets are not at risk. State handling, function incorrect as to spec, issues with clarity, syntax
Lines of code
https://github.com/code-423n4/2023-11-kelp/blob/main/src/NodeDelegator.sol#L45
Vulnerability details
Impact
The
NodeDelegator.maxApproveToEigenStrategyManager()
function sets an infinite approval for the corresponding asset to the EigenLayer Strategy Manager.In the current implementation this function must be called in order to deposit the asset into the EigenLayer Strategy Manager. There is no functionality to revoke or reduce the approval.
In case the EigenLayer Strategy Manager was compromised, this approval would put the full amount of the asset held by the NodeDelegator at risk, even if the NodeDelegator contract was paused. This drastically reduces the effectiveness of such countermeasures.
Proof of Concept
https://github.com/code-423n4/2023-11-kelp/blob/main/src/NodeDelegator.sol#L45
Tools Used
Manual review.
Recommended Mitigation Steps
NodeDelegator.depositAssetIntoStrategy()
beforedepositIntoStrategy()
is called.Assessed type
ERC20
The text was updated successfully, but these errors were encountered: