Closed sherlock-admin closed 2 years ago
We do not consider lack of incentives for autoRedeem
to be a major problem. Users will be able to conduct redemptions on their own.
As sourabh is mentioning, due to the multitude of redemption methods no funds would really be at risk and this would be an incentivization discussion.
However I also dont think this is a valid issue either?
When you use a feenominator, you are always doing a % of the deposits, meaning regardless of the # of decimals, you are always taking the same proportional fee.
hyh
medium
Redeemer autoRedeem will not have meaningful incentives in the case of high decimal underlyings
Summary
Redeemer doesn't have the functionality to change the fee set on construction. For high decimal underlyings, for example DAI, initially set fee is just
4e-11 basis points
, which provides no incentives for third parties to run autoRedeem().Vulnerability Detail
feeChange
is missing in Redeemer, which hard codes the feenominator to one set on construction, that is basically only feasible for 6 decimals underlying (40 bp
in this case).For all others, especially for 18 decimal ones, like DAI or LUSD, it is very close to zero and provides no incentives.
Impact
The funds that are normally retrieved via autoRedeem will remain on the balance. Say for accounts that are unable to run redeem directly for any reason.
Setting the severity to be medium as that's an unavailability of functionality leading to temporal funds freeze.
Code Snippet
setFee() will always revert if
feeChange
is zero:https://github.com/sherlock-audit/2022-10-illuminate/blob/main/src/Redeemer.sol#L165-L187
But there is no functionality to set
feeChange
in Redeemer, it's always zero:https://github.com/sherlock-audit/2022-10-illuminate/blob/main/src/Redeemer.sol#L58-L59
autoRedeem() uses the fee for incentivizing the third-party redeem:
https://github.com/sherlock-audit/2022-10-illuminate/blob/main/src/Redeemer.sol#L479-L548
This way the
feenominator
being set on construction cannot change:https://github.com/sherlock-audit/2022-10-illuminate/blob/main/src/Redeemer.sol#L102-L119
But, taking DAI as an example,
4000 / 1e18
, i.e.4e-15
, is a meaningless fee, providing no incentives for autoRedeem().Tool used
Manual Review
Recommendation
Consider adding the feeChange management functionality to Redeemer as it is done in Lender:
https://github.com/sherlock-audit/2022-10-illuminate/blob/main/src/Lender.sol#L812-L829