Skip to content
DoS Audit finding Intermediate

DoS in Redemption Due to Unchecked Asset Support in Subvaults

The vault's redemption logic aggregates token balances from all subvaults without checking whether each subvault supports the asset. An attacker can send a tiny amount of an unsupported asset to a subvault, causing redemptions to revert and locking funds.

7 Follow with HeckerTrieuTien, Sparrow_Jac and 3 others

Originally disclosed on Sherlock

Source: https://github.com/sherlock-audit/2025-07-mellow-flexible-vaults-judging/issues/688

Found by

7, HeckerTrieuTien, Sparrow_Jac, dan__vinci, jasonxiale, silver_eth

Summary

In Mellow Flexible Vaults, the getLiquidAssets() logic aggregates token balances from all subvaults without checking whether a given asset is supported by each subvault. Since subvaults are expected to restrict supported assets via the allowedAssets mapping, calling hookPullAssets() on a subvault holding an unsupported asset (even 1 wei) will trigger a revert due to the NotAllowedAsset check inside modifySubvaultBalance().

This leads to a denial-of-service condition as any user can send a trivial amount of the queue asset (1 wei) to a subvault that doesn't support it. As a result, future redemption requests for that asset via redeem() will revert during the callHook() phase, making redemptions impossible.

Root Cause

The root cause lies in the fact that the system aggregates IERC20(asset).balanceOf(subvault) across all subvaults during getLiquidAssets() and then attempts to hookPullAssets() from each of them, without verifying if the asset is permitted by that subvault. If even a single subvault holds a non-zero balance of an unsupported asset, modifySubvaultBalance() will revert.

Internal Pre-conditions

A Subvault exists but does not include the given asset in its allowedAssets.

External Pre-conditions

nill

Attack Path

  1. Attacker identifies a subvault that does not support the redemption asset.

  2. Sends 1 wei of the redemption asset directly to the subvault.

  3. When any user tries to redeem via redeem(), it calls callHook() internally.

  4. callHook() attempts to aggregate and pull assets from all subvaults.

  5. The presence of 1 wei in the unsubscribed subvault causes modifySubvaultBalance() to revert with NotAllowedAsset, permanently breaking redemption functionality.

Impact

Any user can prevent all redemptions for an asset by sending a trivial amount to a subvault that does not support it. This breaks a core vault function, locking user funds indefinitely unless manually cleaned up by governance.

PoC

nill

Affected Code

https://github.com/sherlock-audit/2025-07-mellow-flexible-vaults/blob/eca8836d68d65bcbfc52c6f04cf6b4b1597555bf/flexible-vaults/src/queues/SignatureRedeemQueue.sol#L13-L27

https://github.com/sherlock-audit/2025-07-mellow-flexible-vaults/blob/eca8836d68d65bcbfc52c6f04cf6b4b1597555bf/flexible-vaults/src/hooks/BasicRedeemHook.sol#L33-L41

https://github.com/sherlock-audit/2025-07-mellow-flexible-vaults/blob/eca8836d68d65bcbfc52c6f04cf6b4b1597555bf/flexible-vaults/src/managers/RiskManager.sol#L236-L253

Mitigation

Before summing up the liquid assets or attempting to pull balances from subvaults, explicitly check that the subvault allows the asset:

Solidity
if (!vault.riskManager().isAllowedAsset(subvault, asset)) {
    continue;
}

Discussion

sherlock-admin2

The protocol team fixed this issue in the following PRs/commits: https://github.com/mellow-finance/flexible-vaults/pull/14/files

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

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

Root cause

The system aggregates token balances from all subvaults and attempts to pull assets without verifying that each subvault permits the asset, causing a revert when an unsupported asset is present.

Impact

Any user can prevent all redemptions for an asset by sending a trivial amount to a subvault that does not support it, locking user funds indefinitely unless manually cleaned up by governance.

What the attacker needed

A subvault that does not support the asset; attacker can send tokens to the subvault

The fix

The protocol team fixed this issue by adding a check to skip subvaults that do not allow the asset before aggregating or pulling balances.

How it was found

  1. Attacker identifies a subvault that does not support the redemption asset.
  2. Attacker sends 1 wei of the redemption asset directly to the subvault.
  3. When a user tries to redeem via redeem(), it calls callHook() internally.
  4. callHook() attempts to aggregate and pull assets from all subvaults.
  5. The presence of 1 wei in the unsupported subvault causes modifySubvaultBalance() to revert with NotAllowedAsset, breaking redemption.

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 vault lets users deposit and withdraw tokens. It uses smaller subvaults to hold tokens, and each subvault is supposed to only accept certain tokens. The code that handles withdrawals checks all subvaults for the token balance, but it doesn't check if each subvault actually allows that token. So if someone sends a tiny amount of a disallowed token to a subvault, the withdrawal process breaks for everyone.

What is DoS?

A request that exhausts resources or crashes a component. Many programs forbid testing it; reports usually show it from code, not by attacking.

More by 7

View all

2 more disclosed reports, best first.

More from Mellow Flexible Vaults

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Denial of service

The lesson behind this report.

A request that exhausts resources or crashes a component. Many programs forbid testing it; reports usually show it from code, not by attacking.