Skip to content
DoS Audit finding Intermediate

DOS of Launchpad Graduation via addLiquidity with 1 Wei donation

An attacker can send a tiny donation of quote tokens to a Launchpad token's Uniswap-style pair and call sync(), leaving one reserve at zero. When graduation then calls the router's addLiquidity, the library's quote() check fails and the graduation transaction reverts, temporarily blocking the token launch.

gizzy Follow with 0xShitgem, IvanAlexandur and 6 others

Originally disclosed on Code4rena

Submitted by gizzy, also found by 0xShitgem, IvanAlexandur, levantequarini, mrMorningstar, Pelz, pro_king, r1ver, and serial-coder

launchpad/Launchpad.sol #L500

An attacker can prevent Launchpad token graduation by front-running with a small donation to the target pair and calling sync(). This causes the router’s addLiquidity function to revert during graduation, effectively DOSing the graduation process .

Root Cause Analysis

The Problem

  1. Attacker donates small amount of quote token to target pair before graduation
  2. Calls sync(): This sets reserves to one-sided: (reserveA=0, reserveB>0)
// 1. Attacker sees  created token
// 2. sends  donation + call  sync
IERC20(quoteToken).transfer(targetPair, 1 wei);
IUniswapV2Pair(targetPair).sync();
  1. Router Fails: addLiquidity calls quote() which requires both reserves > 0 as per sponsor comment

yes for the router, you can assume it is identical to uniswap. The only difference between vanilla and gte univ2 (aside from solc version) would be the fee accrual in Pair.sol, and the factory needing to be customized so we could pass more information to the constructor of Pair https://code4rena.com/audits/2025-08-gte-perps-and-launchpad/inbox/16?replyUid=257

  1. Graduation DOS: Launchpad graduation reverts, preventing token launch completion

UniswapV2Library.quote() - Used by Router

function quote(uint amountA, uint reserveA, uint reserveB) internal pure returns (uint amountB) {
    require(amountA > 0, 'UniswapV2Library: INSUFFICIENT_AMOUNT');
    require(reserveA > 0 && reserveB > 0, 'UniswapV2Library: INSUFFICIENT_LIQUIDITY'); // ← FAILS HERE
    amountB = amountA.mul(reserveB) / reserveA;
}

Launchpad._graduate() - Vulnerable Call

uniV2Router.addLiquidity({
    tokenA: token,
    tokenB: address(data.quote),
    amountADesired: tokensToLock,
    amountBDesired: quoteToLock,
    amountAMin: 0,        // ← Won't help, fails before this check
    amountBMin: 0,        // ← Won't help, fails before this check
    to: address(launchpadLPVault),
    deadline: block.timestamp
});

Impact

This will cause a temporary DOS on the graduation of that pair.

Recommended mitigation steps

function _graduate(address token) internal {
    // ... existing code ...

    // Check if pair has one-sided reserves
    (uint112 reserve0, uint112 reserve1,) = pair.getReserves();

    if (reserve0 == 0 || reserve1 == 0) {
        // Bypass router, use direct pair.mint()
        token.safeTransfer(address(pair), tokensToLock);
        data.quote.safeTransfer(address(pair), quoteToLock);
        pair.mint(address(launchpadLPVault));
    } else {
        // Normal router path
        uniV2Router.addLiquidity({...});
    }
}

View detailed Proof of Concept


The original report as published on Code4rena, by gizzy. 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

Root cause

Likely the graduation path relies on the router's addLiquidity, which calls a library function requiring both pair reserves to be greater than zero, so a one-sided reserve state makes it revert.

Impact

This causes a temporary denial of service on graduation for that pair, though the attacker must keep repeating the donation and sync to sustain it.

What the attacker needed

A Launchpad token nearing graduation; attacker can send tokens and call sync

The fix

The graduation code should detect one-sided reserves and, in that case, transfer the tokens directly to the pair and call mint on it instead of going through the router.

How it was found

  1. Attacker notices a token created on the Launchpad that is approaching graduation.
  2. Attacker sends a tiny amount of the quote token directly to the token's pair.
  3. Attacker calls sync() on the pair, setting one reserve to zero.
  4. Graduation runs and the router's addLiquidity reverts, so the launch does not complete.

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 liquidity pair is a pot holding two tokens that lets people trade between them. The pair tracks how much of each token it holds, and some operations refuse to run if one of those amounts is zero. Here an attacker can make one amount zero with a tiny transfer, so the step that finishes launching the token fails and has to be retried later.

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 gizzy

View all

6 more disclosed reports, best first.

More from GTE Perps and Launchpad

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.