Omniscia Arcade Protocol Audit
V2ToV3RolloverBase Manual Review Findings
V2ToV3RolloverBase Manual Review Findings
VTR-01M: Ill-Advised Toggle Mechanism
Type | Severity | Location |
---|---|---|
Logical Fault | ![]() | V2ToV3RolloverBase.sol:L181-L185 |
Description:
The V2ToV3RolloverBase::togglePause
function will use a toggle state for the paused
variable which is ill-advised due to how multiple pending transactions may be submitted in an emergency.
Example:
contracts/v2-migration/base/V2ToV3RolloverBase.sol
181function togglePause() external override onlyOwner {182 paused = !paused;183
184 emit PausedStateChanged(paused);185}
Recommendation:
We advise the code to accept a proper bool
argument that permits the paused
state to be set rather than toggled.
Alleviation:
The V2ToV3RolloverBase::togglePause
function has been replaced by the V2ToV3RolloverBase::pause
implementation that accepts a bool
argument signifying the pause state that the contract should result in. As such, we consider this exhibit alleviated given that the toggle paradigm has been removed.