Submitted by KupiaSec, also found by nnez
Unlocking tokens from the permanent locking can be DoSed.
In the VotingEscrowUpgradeableV2._processLockChange function, boostedValue is added to the tokens locked amount at L465. However, boostedValue is not added to permanentTotalSupply for permanently locked tokens at L470.
In the unlockPermanent function, the tokens locked amount is subtracted from permanentTotalSupply at L219.
As a result, calling this function may be reverted by the underflow.
Lets consider the following scenario:
It is recommended to change the code in the VotingEscrowUpgradeableV2._processLockChange function as the following:
DoS
b-hrytsak (Fenix) confirmed and commented:
alcueca (judge) decreased severity to Medium
KupiaSec (warden) commented:
alcueca (judge) increased severity to High and commented:
b-hrytsak (Fenix) commented:
Ch_301 (warden) commented:
KupiaSec (warden) commented:
Ch_301 (warden) commented:
alcueca (judge) decreased severity to Medium and commented:
Note: For full discussion, see here.
