Closed code423n4 closed 2 years ago
This cannot happen because of "require(unlock_time <= block.timestamp + MAXTIME, "Exceeds maxtime")" A user can call it multiple times to always have the max voting power but if MAXTIME is 1 year, then he won't be able to set an interval bigger than MAXTIME
Subtle but essentially the user has to wait for real world time to pass before calling. MAXTIME is relative to the present moment.
Lines of code
https://github.com/code-423n4/2022-08-fiatdao/blob/fece3bdb79ccacb501099c24b60312cd0b2e4bb2/contracts/VotingEscrow.sol#L504
Vulnerability details
Impact
Unlock time can exceed
MAXTIME
inincreaseUnlockTime()
Proof of Concept
increaseUnlockTime
can be called multiple times before expiration to increaseunlock_time
beyondMAXTIME
Tools Used