The whenNotPaused modifier in manualProcessExpiredLocks() can be bypassed simply by calling performUpkeep(...) with any argument. Those two functions do the same.
Tools Used
Manual analysis
Recommended Mitigation Steps
If the design is not to allow such such call when paused, a whenNotPaused modifier should be used also in performUpkeep(...).
Lines of code
https://github.com/Badger-Finance/vested-aura/blob/v0.0.2/contracts/MyStrategy.sol#L370-L375 https://github.com/Badger-Finance/vested-aura/blob/v0.0.2/contracts/MyStrategy.sol#L390-L394
Vulnerability details
Impact
The
whenNotPaused
modifier inmanualProcessExpiredLocks()
can be bypassed simply by callingperformUpkeep(...)
with any argument. Those two functions do the same.Tools Used
Manual analysis
Recommended Mitigation Steps
If the design is not to allow such such call when paused, a
whenNotPaused
modifier should be used also inperformUpkeep(...)
.