cross-chain swaps between Ethereum and Sui using 1inch Fusion+ with hashlocks & timelocks.
This project extends the 1inch Fusion+ protocol to enable trustless, atomic cross-chain token swaps between Ethereum and Sui. Built with interoperability and security in mind, it utilizes a combination of hashlock and timelock mechanisms to ensure that both sides of the swap are executed fairly, or fully refunded in the event of failure—mirroring the atomic swap pattern.
The architecture includes:
Smart Contracts on Ethereum (EVM) using the 1inch Limit Order Protocol
Move-based Contracts on Sui that mimic the same hashlock/timelock behavior to ensure symmetry
A resolver script (or off-chain relayer) that monitors both chains, facilitates swap fulfillment, and ensures atomicity
A React-based UI for users to initiate, monitor, and claim swaps across chains
Optional support for partial fill orders, enabling users to match trades even if only part of the volume is available
Key Features:
💱 Bidirectional Swaps: Ethereum → Sui and Sui → Ethereum
🔐 Hashlock + Timelock Security: Ensures atomic, non-custodial execution
🌐 Testnet Demo: End-to-end swap flow demonstrated on public Ethereum and Sui testnets
🧠 Interoperable Design: Bridges EVM and non-EVM environments using a common swap logic
💻 Optional UI: Clean, intuitive frontend for testing and demos
Why it matters: Most cross-chain DEX protocols either depend on custodians, bridges, or fail to support non-EVM chains. This project shows that secure, decentralized, and efficient swapping between EVM and Move-based chains is possible, paving the way for a more connected and permissionless DeFi ecosystem.
This project is built as a cross-chain extension of the 1inch Fusion+ protocol, enabling atomic swaps between Ethereum (EVM) and Sui (Move) through a hybrid of smart contracts, hashlock-timelock logic, and off-chain resolution.
🔧 Technologies Used: Smart Contracts (Ethereum): Developed using Solidity and deployed on Ethereum testnet using Foundry. We use 1inch's Limit Order Protocol v3 for initiating and filling swap orders.
Smart Contracts (Sui): Written in Move, these contracts implement equivalent hashlock and timelock logic, enabling the Sui side of the atomic swap. We used the Sui CLI + Sui Testnet to deploy and test contracts.
Cross-Chain Coordination (Resolver Script): Built in TypeScript, this off-chain resolver watches events on both Ethereum and Sui testnets. It acts as a relayer to complete or refund swap operations based on on-chain conditions. It listens for:
Order creation and fulfillment on Ethereum
Hashlock claims and expiries on Sui
Frontend Interface (UI): A minimal React + Ethers.js + Sui.js frontend allows users to:
Initiate swaps
Monitor swap status
Redeem tokens once the swap is valid The UI is testnet-ready and demonstrates the full atomic swap flow.
🤝 Partner Tech Integration: 1inch Fusion+ & Limit Order Protocol: These tools handled order management, off-chain RFQ order matching, and gasless order creation. We reused their contracts and SDKs wherever possible to preserve compatibility.
Sui Dev Tools (Move, CLI, RPC): The Move smart contract toolkit made it possible to replicate hashlock+timelock logic in a non-EVM environment.
🧠 Notable & Hacky Things: Cross-chain Hashlock Logic Port: We re-implemented Ethereum-style hashlock logic in Sui’s Move language, accounting for different timing models and storage structures. It required creative use of capabilities and modules in Move.
Off-chain Atomicity via Resolver: Because Ethereum and Sui can’t natively talk to each other, we simulate atomicity off-chain using the resolver script that monitors and enforces swap logic manually—this hack ensures trustless behavior without bridging.
Gasless Orders: Leveraging 1inch Fusion+'s meta-transaction-based order system allowed users to create orders without paying gas, making UX smoother.