Skip to content
DoS Audit finding Intermediate

Expired transactions prevent new submissions due to delayed garbage collection

The mempool's garbage collection runs only after a new transaction is submitted, so when the mempool is full with expired transactions, new submissions are rejected. An attacker could keep the mempool full and prevent legitimate transactions from being accepted until they are resubmitted.

KlosMitSoss Follow

Originally disclosed on Immunefi

Informational View original
  • Disclosed after under an hour

#43221 [BC-Insight] Expired transactions prevent new submissions due to delayed garbage collection

Submitted on Apr 3rd 2025 at 19:46:19 UTC by @KlosMitSoss for Attackathon | Movement Labs

Description

Brief/Intro

A transaction cannot be submitted when the mempool is full. This remains true even if there are expired transactions that could be garbage collected since the transaction is initially submitted before the garbage collection process occurs.

Vulnerability Details

The garbage collection functions are called only after submit_transaction() is executed. Consequently, even when the mempool is full and contains expired transactions, the new transaction cannot be submitted.

As a result, the transaction must be resubmitted, despite the presence of expired transactions in the mempool. To address this issue, the garbage collection functions should be invoked at the start of the receive_transaction_tick() function.

Impact Details

A transaction cannot be submitted even when there are expired transactions in the mempool. As a result, the transaction needs to be submitted again.

References

Code references are provided throughout the report

Proof of Concept

Proof of Concept

  1. The mempool is full but there is at least one transaction that could be garbage collected.
  2. The transaction cannot be submitted since the mempool is full and gc() is only called after the call to submit_transaction() (https://github.com/immunefi-team/attackathon-movement/blob/a2790c6ac17b7cf02a69aea172c2b38d2be8ce00/protocol-units/execution/maptos/opt-executor/src/background/transaction\\_pipe.rs#L140-L161).
  3. The function needs to be called again to submit the transaction.

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

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 garbage collection function is called after the transaction submission check, so expired transactions are not removed before deciding if the mempool is full.

Impact

A transaction cannot be submitted even when there are expired transactions in the mempool, so it must be resubmitted.

What the attacker needed

Mempool is full; at least one expired transaction in mempool

The fix

The garbage collection functions should be invoked at the start of the `receive_transaction_tick()` function.

How it was found

  1. Fill the mempool so it is full but contains at least one expired transaction.
  2. Attempt to submit a new transaction; it is rejected because the mempool is full and garbage collection has not run yet.
  3. Resubmit the transaction after garbage collection has occurred.

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 mempool is a waiting area for transactions before they are processed. The system only cleans out expired transactions after trying to add a new one, so if the waiting area is full, new transactions are turned away even though some old ones could be removed. This means users have to try again 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 KlosMitSoss

View all

25 more disclosed reports, best first.

More from Movement Labs

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.