Skip to content
DoS Write-up Advanced

Deprecating Yield DTF Batch Auctions: EasyAuction.sol Division-by-Zero

A division-by-zero bug in the Gnosis EasyAuction contract could be triggered by an attacker who forces a batch auction and places a tiny bid, then calls a helper function to advance the auction's internal cursor. This would cause settlement to revert permanently, locking up to $1M of protocol collateral and all bidder funds in the non-upgradeable contract.

blog.reserve.org

Published on blog.reserve.org

A whitehat security researcher GregoAI (@therealgregoAI) / X recently uncovered a vulnerability in the backup auction infrastructure used by Reserve Yield Protocol DTFs. The bug affected the Gnosis EasyAuction contract — a third-party, non-upgradeable contract that the Reserve Yield Protocol used as a fallback trading…

Patrick Mckelvy, on blog.reserve.org

The full write-up lives on its author's site

It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.

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

How it worked

Root cause

Likely a missing check in the settlement logic that allows a public helper function to advance the bid cursor past the end of the bid list, leading to a division by zero when settlement later tries to process remaining bids.

Impact

If exploited, up to $1M of protocol collateral and all third-party bids could be permanently locked, and the protocol's trade counter would be stuck, blocking all future trades until governance intervenes; however, the attack requires the auction lot to remain unfilled, and batch auctions had not been used in over two years, making the risk low.

What the attacker needed

Batch auctions enabled; auction lot not fully filled; attacker can call rebalance(); attacker places a minimal bid

The fix

The fix was to pause trading on affected DTFs and set batchAuctionLength to 0 via governance, disabling batch auctions entirely.

How it was found

  1. Call rebalance() and specify Batch Auction mode, sending up to $1M of DTF into the EasyAuction contract.
  2. During the auction window, place a minimal bid (as little as a fraction of a cent), ensuring the full lot is not filled.
  3. After the auction ends, call the public helper function precalculateSellAmountSum() with carefully chosen parameters to advance the auction's internal cursor to the end of the bid list.
  4. When anyone tries to settle the auction, the settlement logic hits a 0 ÷ 0 operation and reverts permanently.

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 write-up has not been written yet. The Original tab links to the source.

This report describes a flaw in a smart contract used for auctions. An attacker could make the auction get stuck forever by sending a tiny bid and then calling a function that messes up the auction's internal state, so that when someone tries to finish the auction, the code tries to divide zero by zero and crashes. Because the contract cannot be fixed or upgraded, any money inside would be locked permanently.

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.

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.