Skip to content

pooled tx stays pending after its sender is denylisted, and executes in the next locally built block #513

Open

Description

@Jr-kenny

Hey, first time filing here. I have been going through the denylist enforcement, testing what happens to a transaction that is already sitting in the pool when its sender gets denylisted, and this one stood out.

This is a follow-up to #495, which was closed without a fix. That issue was about the doc claim. This one is the runtime behaviour, the locally built payload half of the design question osr21 asked there.

Problem

The Denylist contract (contracts/src/Denylist.sol) is a registry only. It enforces nothing on chain by itself. Enforcement lives in exactly one place: mempool admission in ArcTransactionValidator::validate_one_with_state (crates/execution-txpool/src/validator.rs), which calls is_denylisted (crates/execution-validation/src/denylist.rs) for the sender, to, and recovered EIP-7702 authorities. A repo-wide grep confirms is_denylisted has no other production caller. No EVM pre-execution check, no consensus block validation check, and the payload builder (crates/execution-payload/src/payload.rs) has no denylist reference at all. The module doc still claims "Call from both mempool and execution/Revm" (denylist.rs:18-20). The execution half does not exist.

The blocklist, by contrast, is enforced at three layers: mempool, EVM pre-execution, and nested value transfers. A blocklisted address cannot receive value even if a tx reaches a block another way. A denylisted address has no such backstop.

What breaks

  1. Tx T from sender S is admitted while S is clean, and sits in the pool as pending.
  2. Circle denylists S on chain (Denylist.denylist([S]), effective next block).
  3. Nothing evicts T. ArcTransactionValidator::on_new_head_block (validator.rs:423-427) only delegates to the inner reth validator, whose maintenance re-checks nonce, balance and gas, never Arc policy. The payload builder executes pooled txs with no denylist re-check.
  4. The next locally built block includes T, and it executes.

This is systematic, not a race. Any tx admitted before the denylist tx is included will still execute afterwards.

Reproduction

Repro test crates/execution-txpool/tests/repro_round2.rs::repro_denylist_stale_tx_stays_in_pool (release/0.8):

  • Step 1: admit a legacy tx from a clean sender into a real Pool. It is pending and buildable.
  • Step 2: denylist the sender in the mock provider state. A fresh tx from the same sender is rejected at admission with DenylistedAddressError.
  • Step 3: the already pooled tx is still present and still pending (get=true, pending=true).

Output:

STEP1 OK: tx 0x2f4ba29ac1ecd741ad257d0fcbb1a8097fb90bc006a6e37ffa428b2045efb8a3 admitted and pending
STEP2 OK: fresh tx from denylisted sender rejected at admission
STEP3: pooled tx still present after denylisting: get=true pending=true
test repro_denylist_stale_tx_stays_in_pool ... ok

Fix

Re-check the denylist at payload build time, when the builder iterates best_txs, skip and evict any tx whose sender, to, or authorities are denylisted at the build head. Or evict pooled txs on a new head when the denylist set changes. Either keeps the admission check as the fast path and closes the stale pool window.

What this is not

This is not the doc claim from #495, and it is not about imported blocks. It is the locally built payload half of the design question osr21 asked in #495: is the denylist a txpool admission filter or a consensus/execution invariant? If it is admission only, the doc comment and the stale pool window should both be acknowledged.

Activity

  1. Jr-kenny commented on Nov 13, 2026

    @Jr-kenny
    Author

    can I take this one please ser?

  2. osr21 commented on Nov 13, 2026

    @osr21

    One distinction may help scope the fix: a payload-builder check or pool eviction on new-head updates can close the local stale-pool path, but neither by itself makes denylisting a consensus invariant—externally supplied payloads still need deterministic execution/block validation if the intended policy is to reject denylisted transactions network-wide. It would help to state explicitly whether this is txpool-admission policy only or an all-block execution rule.

    For a txpool-level fix, revalidate or evict existing entries when the relevant denylist state changes, and test already-pending transactions plus nonce descendants. The recheck should cover the same address set as admission (sender, recipient, and recovered EIP-7702 authorities). If the requirement is consensus-level, add validation tests for payloads produced elsewhere, not only a local-builder test. That gives the fix a clear acceptance criterion and avoids presenting a local-only mitigation as network-wide enforcement.

    Related context: #495, txpool validator, payload builder.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions