The afterLiquidationExecution function in the PerpetualVault contract pauses deposits indefinitely upon liquidation, requiring manual intervention to resume operations.
When a liquidation occurs during vault rebalancing, the afterLiquidationExecution function sets depositPaused to true, effectively pausing all deposits. There is no automatic mechanism to unpause deposits, which means that the protocol requires manual intervention by the owner to resume normal operations. This can lead to a situation where all subsequent operations are blocked until the owner manually resets the state.
Root Cause:
The root cause of this issue is the lack of an automatic unpause mechanism in the afterLiquidationExecution function. The function sets depositPaused to true without providing a way to automatically resume deposits.
Proof of Concept: Copy and paste this test into PerpetualVault.t.sol
Protocol pauses deposits indefinitely: Deposits are paused indefinitely until manually unpaused by the owner.
All subsequent operations blocked: All subsequent deposit operations are blocked until manual reset.
Potential disruption of user experience: Users may be unable to deposit funds, leading to potential disruption and dissatisfaction.
Manual
To mitigate this issue, implement an automatic unpause mechanism or provide a way to resume deposits after a certain condition is met. Here are some recommendations:
Automatic Unpause Mechanism: Implement logic to automatically unpause deposits after a certain condition is met, such as after a certain time period or after a successful rebalance.
Manual Unpause with Notification: Provide a way to manually unpause deposits with a notification to the owner to take action.
The contest is live. Earn rewards by submitting a finding.
This is your time to appeal against judgements on your submissions.
Appeals are being carefully reviewed by our judges.