Operational Security Cluster
MEV Sandwich Attack Defense
This page explains how DeFi teams should reduce sandwich attack harm in real execution environments. It focuses on slippage governance, execution-aware routing, optional private flow, and rapid containment when abnormal extraction begins clustering around specific routes or users.
Within this cluster
Why Is Sandwich Risk Still Operationally Important?
Sandwich attacks are predictable, repeated, and often treated as background market noise until losses concentrate enough to become a support or trust problem. Teams should treat them as execution-integrity failures that can be reduced even if they cannot be eliminated entirely.
| Phase | Main condition | Best disruption point |
|---|---|---|
| Observation | Transaction visible and economically attractive | Reduce discoverability or exploitability |
| Front-run | Attacker reorders around victim path | Tighten slippage and route quality |
| Victim fill | User executes inside unsafe tolerance | Policy-gated execution bounds |
| Back-run | Attacker captures spread | Reduce extractable payoff |
This operational-security topic overlaps with oracle integrity and frontend execution safety because sandwich exposure depends on what users are shown and how routes are selected.
What Should Teams Harden First?
Start by treating slippage and route choice as security policy rather than convenience defaults. Tighten riskier routes, degrade aggressively under volatility, and warn users in outcome-oriented language.
- Set asset-class slippage ceilings.
- Score routes by manipulability, not just quoted output.
- Offer chunked execution or safer alternatives for large trades.
- Expose private-flow options where they genuinely reduce risk.
{
"routeRisk": "high",
"slippageCapBps": 30,
"privateFlowSuggested": true,
"decision": "require_user_ack"
}Which Signals Matter Most?
Monitor execution gap, clustered victim windows, route-specific harm concentration, and sudden slippage anomalies under similar market conditions. These signals should trigger a policy profile change, not just a dashboard note.
- Expected versus realized output gap widening.
- Same route repeatedly harming users in short windows.
- High-value trades seeing concentrated adverse execution.
- Volatility-independent slippage spikes.
How Should Teams Respond During Active Waves?
Move into a protective profile quickly: tighten global slippage, throttle vulnerable routes, publish clearer execution guidance, and preserve route telemetry so defenders understand what actually changed.
- Activate protective execution profile.
- Throttle or disable especially harmful route families.
- Surface safer execution alternatives to users.
- Archive evidence for post-incident route tuning.
Frequently Asked Questions
Can teams eliminate sandwich attacks completely?
Usually no, but they can reduce exploitability, attacker payoff, and user harm substantially through stronger routing, slippage policy, and execution controls.
What is the best first hardening step?
Treat slippage defaults as security policy rather than UX convenience and tighten them dynamically when route risk rises.