Closed stalker474 closed 1 year ago
Agree with setting a max rebase reward limit, in three steps:
uint256 private maxRebaseReward;
Set maxRebaseReward: == 2 EEFI in constructor
Update setRebaseReward with require statement (as below):
function setRebaseReward(uint256 newRebaseReward) external onlyOwner() { require(newRebaseReward <= maxRebaseReward, "Rebase reward cannot be higher than maxRebaseReward."); rebaseCallerReward = newRebaseReward; emit RebaseRewardChanged(newRebaseReward); }
Closes #51
The issue with this implementation is that we can potentially mint any amount of EEFI so it's a security issue and a decentralization issue. I suggest we add a limit to the reward amount.