# Paid step skipped via try/catch or refund

Reward paid for steps that can fail, be skipped, or be refunded without cost

_Area: Smart contract access control and control flow. Seen in 3 disclosed reports; latest 2025-03-31. Updated 2026-11-17._

## How it works
A reward or priority is granted for completing a multi-step action, but the completion check is weaker than the payment. The step can fail inside a `try/catch` and the outer call still succeeds and pays [E3](https://bugbountylibrary.com/r/c4%3A2024-01-salty%3AM-17.md); the fee that should make failure costly is only burned inside the failing path, so invalid submissions are free [E1](https://bugbountylibrary.com/r/sherlock%3A2024-05-aleo%3AH-1.md); or the fee is escrowed to set priority but the unspent tip is refunded, so overpaying costs nothing [E2](https://bugbountylibrary.com/r/c4%3A2024-11-mantra-chain%3AH-03.md). The broken assumption is that paying for a step means the step ran, or that a fee commitment makes bad input expensive.

## Where it shows up
- `performUpkeep`-style loops wrapping each step in `try/catch`, with an incentive paid after the loop [E3](https://bugbountylibrary.com/r/c4%3A2024-01-salty%3AM-17.md)
- Transaction types special-cased out of fee/collateral requirements [E1](https://bugbountylibrary.com/r/sherlock%3A2024-05-aleo%3AH-1.md)
- Fee burned only inside the function that can fail, with no seizable backup [E1](https://bugbountylibrary.com/r/sherlock%3A2024-05-aleo%3AH-1.md)
- Ante handler setting priority from full escrowed fee while post handler refunds the unspent tip [E2](https://bugbountylibrary.com/r/c4%3A2024-11-mantra-chain%3AH-03.md)
- Reward paid before or independently of verifying each step's success

## How to review
For every paid step, ask: can this step fail, revert, or be skipped while the outer call still returns success and pays? The invariant: payment must be conditional on the step's success, and failure must cost the caller. Check that (a) a caught revert does not count as completion [E3](https://bugbountylibrary.com/r/c4%3A2024-01-salty%3AM-17.md); (b) any fee/collateral is seizable even when the inner path fails [E1](https://bugbountylibrary.com/r/sherlock%3A2024-05-aleo%3AH-1.md); (c) priority and refund are derived from the same amount, so overpayment is not free [E2](https://bugbountylibrary.com/r/c4%3A2024-11-mantra-chain%3AH-03.md). Trace gas: with EIP-150's 63/64 forwarding, a caller can starve a later step so it OOGs and is caught, while 1/64 retained gas lets the outer call finish and pay [E3](https://bugbountylibrary.com/r/c4%3A2024-01-salty%3AM-17.md).

## How finders spotted it
- Read `verify.rs` fee-commitment logic and the `credits.aleo` split function, noticed single split transactions were exempt and had no seizable backup fee when the burn failed [E1](https://bugbountylibrary.com/r/sherlock%3A2024-05-aleo%3AH-1.md)
- Read the skip-mev feemarket decorator: priority set from full paid fee (line 156) but `BurnFeeAndRefund` refunds the tip (lines 164-169), implying overpayment is free; confirmed with a local-node PoC [E2](https://bugbountylibrary.com/r/c4%3A2024-11-mantra-chain%3AH-03.md)
- Observed each upkeep step was individually `try/catch`-wrapped and reasoned about EIP-150 gas forwarding to starve step 11 while still collecting the incentive [E3](https://bugbountylibrary.com/r/c4%3A2024-01-salty%3AM-17.md)

## Variants seen
- Free invalid-proof submission via fee exemption on a special transaction type [E1](https://bugbountylibrary.com/r/sherlock%3A2024-05-aleo%3AH-1.md)
- Free gas-limit inflation via full-tip refund while priority uses full fee [E2](https://bugbountylibrary.com/r/c4%3A2024-11-mantra-chain%3AH-03.md)
- Gas-starvation of a later step caught by `try/catch`, incentive still paid [E3](https://bugbountylibrary.com/r/c4%3A2024-01-salty%3AM-17.md)

## Impact and severity
Aleo: free invalid proofs waste prover CPU; attacking all provers could stop block production [E1](https://bugbountylibrary.com/r/sherlock%3A2024-05-aleo%3AH-1.md). MANTRA: repeated block-space exhaustion and priority dominance, network DoS [E2](https://bugbountylibrary.com/r/c4%3A2024-11-mantra-chain%3AH-03.md). Salty: caller skips step 11 to save gas yet collects the 5% incentive [E3](https://bugbountylibrary.com/r/c4%3A2024-01-salty%3AM-17.md). Severity rises with reach (whole network vs one function) and with whether the abuse is free and repeatable [E1](https://bugbountylibrary.com/r/sherlock%3A2024-05-aleo%3AH-1.md)[E2](https://bugbountylibrary.com/r/c4%3A2024-11-mantra-chain%3AH-03.md).

## Evidence
- E1: https://bugbountylibrary.com/r/sherlock%3A2024-05-aleo%3AH-1.md
- E2: https://bugbountylibrary.com/r/c4%3A2024-11-mantra-chain%3AH-03.md
- E3: https://bugbountylibrary.com/r/c4%3A2024-01-salty%3AM-17.md
