Skip to main content

Security

This page sets out what AchSwap's contracts enforce, what you are trusting when you use AchSwap, and what is outside AchSwap's control. It describes the contracts live on Arc Mainnet (chain ID 5042). Addresses are in the contract reference.

Audit and verification status​

Status
Independent third-party auditNone published. AchSwap's contracts have had internal security reviews by the AchSwap team. An internal review is not an independent audit.
Source verificationEvery live AchSwap contract is source-verified on ArcScan: you can read the code that runs and check it matches the deployed bytecode (checked 20 October 2026).

Source verification shows you what the code is. It says nothing about whether the code is safe. Decide for yourself how much to trust any smart contract.

What the swap contracts enforce​

For an AchSwap route, the route executor guarantees, in code:

  • It only spends your input. It pulls tokens from the address that calls it, and only the input amount of that call.
  • Your minimum is enforced on what you actually receive. The executor measures the recipient's balance before and after, after all fees. Below your minimum, the whole transaction reverts.
  • One fee, capped. 0.25% of the final output, paid straight to the AchSwap treasury Safe in the same transaction. The contract caps it at 1%. An increase waits two days, and a transaction built under the old fee reverts instead of paying the new one.
  • Nothing is held. There is no vault and no balance between transactions; leftovers of a call are refunded in that call.
  • Changes are delayed. New adapters and fee increases take effect two days after they are scheduled, so they are visible on chain before they apply. The owner can pause execution or disable an adapter immediately.

KyberSwap and LI.FI routes execute on those providers' own contracts. Their minimums are enforced by their contracts, not AchSwap's.

Approvals​

An approval lets a contract move a token from your wallet, up to an amount. On AchSwap:

ActionSpender you approveAmount the app asks for
Swap on an AchSwap routeAchRouteExecutorV2 0xF690…e48EThe swap's input
Swap on a KyberSwap routeKyberSwap's routerThe swap's input
Swap on a LI.FI routeLI.FI's contractThe swap's input
First gasless swap with a tokenPermit2 0x0000…8BA3Unlimited (the largest amount Permit2 accepts), once per token
Add liquidityAchSwap's V2 router or V3 position managerThe deposit

The swap page has an Enable unlimited approval switch, off by default. With it on, swap approvals are for an unlimited amount, so later swaps of that token skip the approval step; the trade-off is that the spender can move any amount of that token while the approval stands.

USDC needs no approval on AchSwap routes: it can be paid from your native balance.

An approval stays in place after the swap. Review and revoke approvals you no longer need from your wallet or an explorer's approval tool. Approving Permit2 lets anyone with a valid signature from you move that token through Permit2, so only sign Permit2 messages on sites you trust, and read what they authorize.

Gasless authorization​

A gasless swap is authorized by one Permit2 signature that covers the whole swap: token and amount in, the executor as spender, the target contract, the token out, your minimum, the recipient, any value, and a hash of the exact call. See gasless architecture for the signed structure.

  • The relayer cannot change the trade. The executor rebuilds the signed data from the order it receives. A changed field makes Permit2 reject the signature.
  • One use only. Each signature carries a Permit2 nonce that can be used once.
  • Expiry. The signature carries a deadline. The contract refuses an expired order, and AchSwap's relay refuses deadlines more than three hours ahead.
  • Restricted reach. The executor only pulls allowlisted input tokens and only calls allowlisted targets (KyberSwap, LI.FI, AchRouteExecutorV2) through allowlisted relayers.
  • Your minimum on your balance. The executor checks your actual balance increase against the signed minimum.

The relayer can choose not to submit a signed order. Until the deadline passes, a signed order could still be submitted. To cancel one, invalidate its nonce on Permit2 (invalidateUnorderedNonces), or wait for it to expire.

Automatic mode​

In Automatic mode an AI app trades from the user's agent wallet through AchSwap's relayer, without a confirmation each time. The agent wallet is a MetaMask Delegation Framework smart account owned by the user's wallet, and the chain enforces the permissions the user signed:

  • Where funds go: only to AchSwap's contracts, back to the agent wallet, to the user's own wallet on another chain (bridges), to a LI.FI bridge's two fee wallets, and at most 1 USDC a day of gas to AchSwap's gas wallet.
  • What can be called: AchRouteExecutorV2, AchSwap's V2 router and V3 position manager, and three LI.FI bridges in a pinned layout; approvals only to those.
  • Who: only AchSwap's listed relayers, until the permissions expire or the user revokes them on chain.

The user's limits (per trade, per day, slippage, verified tokens) and the price checks are AchSwap's, not the chain's: a compromised relayer key or server could trade badly inside those fences, up to what the agent wallet holds. Users should deposit only what they want the assistant to trade. See agent wallet permissions.

What the owners can and cannot do​

ContractThe owner canThe owner cannot
AchRouteExecutorV2Pause. Disable an adapter. Add an adapter after a 2-day delay. Lower the fee at once, or raise it after a 2-day delay, up to 1%. Change the fee recipient after a 2-day delay, with the new recipient's acceptance.Move user funds. Apply a new fee to a transaction built under the old one. Point an existing adapter id at different code. Renounce ownership.
Execution adaptersDeny a Uniswap V4 hook (adapter 4).Change factories, fees or callback settings. Call an adapter directly: only the executor can.
AchSponsoredExecutorV3Curate input tokens, targets, spenders and relayers. Pause. Recover tokens or native USDC left in the contract.Change a signed swap, or pull more than the signed amount.

The executors hold nothing between transactions, so the gasless executor's recovery functions only reach tokens sent to it by mistake.

Contract ownership currently sits with AchSwap's deployer address, not a multisig. The fee recipient is the AchSwap treasury Safe.

Simulation and its limits​

AchSwap simulates transactions before showing them: the router executes each AchSwap route as an eth_call, the Developer API simulates /swap transactions from the sender, and the gasless relay simulates every order before submitting it.

Simulation reflects the chain at one block. It cannot promise the result of a transaction mined later: if the pools move, the transaction pays a different amount, or reverts if that is below your minimum. A simulation can also fail to run (the API then says simulated: false). Your on-chain minimum is the protection that always applies.

External dependencies​

AchSwap relies on services it does not control:

DependencyWhat it affects
Arc Mainnet and its RPC endpointsEvery quote and transaction.
KyberSwap and LI.FITheir quotes, routes and contracts. Their routes can fill through DEXs AchSwap does not index.
LI.FI's bridgesBridge transfers, timing and refunds.
DEX pools and Uniswap V4 hooksLiquidity and prices. A hook can change fees during a swap; AchSwap can deny a hook from its own routes.
Token contractsA token can pause, block or tax transfers. AchSwap's router refuses tokens it can't settle exactly.
DEX ScreenerMarket data on the Explore page and for AI assistants.
MetaMask's Delegation FrameworkAgent wallets and their permissions in Automatic mode.
The AI app you connectWhat it asks AchSwap to do; in Automatic mode it acts without asking you first.

Reporting a vulnerability​

Email support@achswap.app with the subject "Security". Please report privately and give the team time to respond before disclosing. Don't include private keys or seed phrases.