Closed sherlock-admin4 closed 4 months ago
Drynooo
medium
In RSETH_DEPOSIT_POOL, stakeAmount is allowed to be equal to minAmountToDeposit(). The check in _stake will cause this kind of stake to fail.
The protocol adds a possibility of reverting, making it more likely that stakes will be reverted.
This failure may cause the user to fail to call Tranche.issue at the source. Thus affecting user stake.
if (depositAmount == 0 || depositAmount < minAmountToDeposit) { revert InvalidAmountToDeposit(); }
if (stakeAmount <= RSETH_DEPOSIT_POOL.minAmountToDeposit()) revert MinAmountToDepositError();
Manual Review
- if (stakeAmount <= RSETH_DEPOSIT_POOL.minAmountToDeposit()) revert MinAmountToDepositError(); + if (stakeAmount < RSETH_DEPOSIT_POOL.minAmountToDeposit()) revert MinAmountToDepositError();
Duplicate of #46
Drynooo
medium
In the RsETHAdapter contract, _stake may revert
Summary
In RSETH_DEPOSIT_POOL, stakeAmount is allowed to be equal to minAmountToDeposit(). The check in _stake will cause this kind of stake to fail.
Vulnerability Detail
The protocol adds a possibility of reverting, making it more likely that stakes will be reverted.
Impact
This failure may cause the user to fail to call Tranche.issue at the source. Thus affecting user stake.
Code Snippet
Tool used
Manual Review
Recommendation
Duplicate of #46