Skip to content
Business logic Audit finding Beginner

Missing withdrawal pause check in confirmWithdrawal allows bypassing withdrawal restrictions

The confirmWithdrawal function in StakingManager lacks the whenWithdrawalNotPaused modifier, so users can complete withdrawals even after the protocol pauses withdrawals. An attacker with a pending withdrawal request can bypass the pause and withdraw funds during a critical period.

dobrevaleri Follow with 0xd4ps, anchabadze and 7 others

Originally disclosed on Code4rena

Submitted by dobrevaleri, also found by 0xd4ps, anchabadze, Falendar, knight18695, marchev, siddu023, Silverwind, th3_hybrid, and Vibhakar

https://github.com/code-423n4/2025-04-kinetiq/blob/7f29c917c09341672e73be2f7917edf920ea2adb/src/StakingManager.sol#L302-L312

Vulnerability Details

The StakingManager::confirmWithdrawal() function does not include the whenWithdrawalNotPaused modifier, despite being a withdrawal operation. According to the natspec docs of pauseWithdrawal(), it should pause all withdrawal operations:

/**
 * @notice Pause withdrawal operations
 */
function pauseWithdrawal() external onlyRole(MANAGER_ROLE) {
    withdrawalPaused = true;
    emit WithdrawalPaused(msg.sender);
}

function confirmWithdrawal(uint256 withdrawalId) external nonReentrant whenNotPaused {
    uint256 amount = _processConfirmation(msg.sender, withdrawalId);
    require(amount > 0, "No valid withdrawal request");
    // ...
}

This inconsistency allows users to complete their withdrawal process by calling confirmWithdrawal() even when withdrawals are paused by the protocol. This defeats the purpose of the withdrawal pause functionality which is meant to halt all withdrawal-related operations during critical protocol conditions.

Impact

Users can bypass withdrawal restrictions by confirming existing withdrawal requests during pause

Proof of Concept

  1. Protocol identifies suspicious activity and calls pauseWithdrawal()
  2. User with pending withdrawal request calls confirmWithdrawal()
  3. The withdrawal succeeds despite protocol pause, since missing modifier allows execution

Recommended Mitigation Steps

Add withdrawal pause modifier

- function confirmWithdrawal(uint256 withdrawalId) external nonReentrant whenNotPaused {
+ function confirmWithdrawal(uint256 withdrawalId) external nonReentrant whenNotPaused whenWithdrawalNotPaused {
    uint256 amount = _processConfirmation(msg.sender, withdrawalId);
    // ...
}

Kinetiq acknowledged


The original report as published on Code4rena, by dobrevaleri. Images and videos are our own copies; raw HTML is shown as text. View it on Code4rena.

Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.

How it worked

Impact

Users can bypass withdrawal restrictions by confirming existing withdrawal requests during pause.

What the attacker needed

A pending withdrawal request; withdrawals are paused by the protocol

The fix

The confirmWithdrawal function should be fixed by adding the whenWithdrawalNotPaused modifier.

How it was found

  1. Protocol identifies suspicious activity and calls pauseWithdrawal()
  2. User with pending withdrawal request calls confirmWithdrawal()
  3. The withdrawal succeeds despite protocol pause, since missing modifier allows execution

Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.

Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.

A smart contract has a pause button meant to stop all withdrawals during emergencies. One function that finalises withdrawals forgot to check that pause button, so people could still take their money out. This means the emergency stop does not fully work.

What is Business logic?

The application works as coded but not as intended: a negative price, a skipped payment step, a limit that can be crossed.

More by dobrevaleri

View all

13 more disclosed reports, best first.

More from Kinetiq

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Business logic flaws

The lesson behind this report.

The application works as coded but not as intended: a negative price, a skipped payment step, a limit that can be crossed.