dex-integration-security

Analyze external DEX integrations in smart contracts for slippage, deadline, and approval vulnerabilities.

276|56|Updated Mar 16, 2026
One-click install
npx skills add https://github.com/PlamenTSV/plamen --skill dex-integration-security
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: dex-integration-security
Source: https://github.com/PlamenTSV/plamen/tree/main/agents/skills/injectable/dex-integration-security
Command: npx skills add https://github.com/PlamenTSV/plamen --skill dex-integration-security

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

External DEX integrations in smart contracts can introduce slippage, timing, and approval risks that lead to loss of funds or unfavorable trades.

Core Features & Use Cases

  • Slippage and parameter handling: analyze how amountOutMin is sourced, forwarded, and enforced across multi-hop routes and fee-tier pools.
  • Deadline and timing controls: verify that deadlines protect users against MEV and queue delays, including L2 sequencing concerns.
  • Router approval safety: audit token approvals, upgradeability, and stale approvals to prevent unauthorized spend.

Quick Start

Audit a protocol’s external DEX integration by verifying slippage handling, deadlines, pool selection, and router approvals.

Frequently Asked Questions about dex-integration-security

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I audit smart contract DEX integrations for slippage and deadline vulnerabilities?

To audit smart contract DEX integrations for slippage and deadline vulnerabilities, analyze how amountOutMin is sourced and forwarded across multi-hop routes, and verify that deadline parameters protect users against MEV and queue delays. This identifies unfavorable trade risks.

What security risks should I check when calling external DEX routers in EVM protocols?

When calling external DEX routers in EVM protocols, check parameter origins, return-value handling, pool and fee tier assumptions, and token approval safety. Verifying these areas prevents unauthorized token spends and mitigates risks from router upgradeability.

How does deadline enforcement protect DEX swaps from MEV and L2 sequencing delays?

Deadline enforcement protects DEX swaps by ensuring transactions execute within a valid timeframe, mitigating MEV extraction and L2 sequencing delays. Analyzing deadline parameters confirms that timing controls actively prevent stale transaction execution.

Can I use this to analyze multi-hop swaps and fee-tier pool assumptions in external DEX calls?

Yes, you can analyze multi-hop swaps and fee-tier pool assumptions in external DEX calls. The audit evaluates how amountOutMin is enforced across complex routes and validates whether pool selection logic introduces integration risks.

What is the best way to audit router approval safety and upgradeability for external DEX integrations?

The best way to audit router approval safety for external DEX integrations is to verify token approvals, check for stale approvals, and assess router upgradeability. This process prevents unauthorized token spending and highlights risks from contract upgrades.

Why does my external DEX integration return unfavorable trades despite setting amountOutMin?

External DEX integrations return unfavorable trades despite amountOutMin when parameter forwarding fails across multi-hop routes or fee-tier pools. Auditing return-value handling and parameter origins reveals where slippage enforcement breaks down.