Skip to content
Business logic Audit finding Intermediate

Stale transaction state in mempool when sender receiver pipe fails

When a transaction is submitted, it is added to the mempool before being forwarded to the transaction ingress. If the forwarding channel fails, the transaction remains stuck in the mempool and cannot be resubmitted because it is considered a duplicate.

Blockian Follow

Originally disclosed on Immunefi

Informational View original
  • Disclosed after under an hour

#43326 [BC-Insight] stale transaction state in mempool when sender receiver pipe fails

#43326 [BC-Insight] Stale Transaction State in Mempool When Sender/Receiver Pipe Fails

Submitted on Apr 4th 2025 at 15:59:54 UTC by @Blockian for Attackathon | Movement Labs

Description

Movement Bug Report

Stale Transaction State in Mempool When Sender/Receiver Pipe Fails

Summary

When a transaction is submitted to a node, it is first added to the core_mempool and then forwarded to the transaction_ingress via an mpsc::Sender. However, if the channel send operation fails (e.g., due to a broken pipe, etc...), the transaction remains in the mempool without any follow-up processing or cleanup. This results in a stale transaction that cannot be re-submitted or processed properly until the GC occurs.

Root Cause Analysis

In the submit_transaction method:

RS
async fn submit_transaction(
		&mut self,
		transaction: SignedTransaction,
	) -> Result<SubmissionStatus, Error> {
		// ... (omitted non-relevant code)
		let status = self.core_mempool.add_txn(
			transaction.clone(),
			0,
			sequence_number,
			TimelineState::NonQualified,
			true,
		);

		match status.code {
			MempoolStatusCode::Accepted => {
				// ... (omitted non-relevant code)
				self.transaction_sender
					.send((application_priority, transaction))
					.await
					.map_err(|e| anyhow::anyhow!("Error sending transaction: {:?}", e))?;
				// ...
		}

		// report status
		Ok((status, None))
	}

The key issue lies in the fact that the transaction is added to the core_mempool before attempting to forward it via the transaction_sender and there is no cleanup in case of failure.

If send fails, the transaction remains stuck in the mempool. Because the node considers it "already accepted," resubmission of the same transaction wont work.

Impact

  • Stale Transactions: Transactions remain stuck in the mempool but are never propagated to the DA or processed by downstream systems.
  • Submission Blockage: The user cannot re-submit the same transaction (same nonce/sequence number) due to mempool duplication checks.
  • Silent Failures: The failure mode is silent from the perspective of the user or client — the transaction appears to have been accepted but is effectively discarded.

Proposed Fixes

Rollback on Failure
If transaction_sender.send(...) fails, remove the transaction from the core_mempool to ensure the user can retry.

Proof of Concept

Proof of Concept (PoC)

  1. Modify the submit_transaction function to simulate a failure in transaction_sender.send (e.g., by manually dropping the receiver or inserting a forced error).
  2. Submit a valid transaction.
  3. Observe that the transaction is stored in the core_mempool but never forwarded to the data availability (DA) layer or any execution pipeline.
  4. Attempt to re-submit the transaction with the same sender and sequence number — it will be rejected as a duplicate, despite never being processed.

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

The transaction is added to the mempool before the send operation, and there is no rollback if the send fails.

Impact

Transactions could remain stuck in the mempool and users may be unable to resubmit them, with the failure being silent to the user.

What the attacker needed

Transaction_sender.send fails (e.g., broken pipe)

The fix

If the send fails, the transaction should be removed from the core_mempool so the user can retry.

How it was found

  1. Modify the submit_transaction function to simulate a failure in transaction_sender.send.
  2. Submit a valid transaction.
  3. Observe that the transaction is stored in the core_mempool but never forwarded.
  4. Attempt to re-submit the transaction with the same sender and sequence number; it is rejected as a duplicate.

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. This report shows that if a transaction is placed in the waiting area but then fails to be passed along, it gets stuck there and the user cannot try again because the system thinks it is already waiting.

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.

More by Blockian

View all

34 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.

Business logic flaws

The lesson behind this report.

The application works as coded but not as intended: a negative price, a skipped payment step, a limit that can be crossed.