A cross-chain atomic swap protocol enabling seamless asset transfers between Ethereum and the Cosmos ecosystem, with multi-hop IBC routing capabilities.
This project implements a cross-chain atomic swap protocol that supports swaps between Ethereum (EVM) and Cosmos-based chains. It leverages HTLCs (Hash Time Lock Contracts), IBC (Inter-Blockchain Communication), and integrates with Osmosis DEX for optimal liquidity routing.
- Atomic Cross-Chain Swaps: Secure asset transfers between Ethereum and Cosmos
- Multi-Hop IBC Routing: Route through multiple Cosmos chains for optimal paths
- Dynamic Route Discovery: Real-time path optimization using Chain Registry
- Osmosis DEX Integration: Direct access to Cosmos ecosystem liquidity
- MEV Protection: Commit-reveal scheme and threshold encryption
- Automatic Recovery: Timeout handling and refund mechanisms
- Frontend UI: Modern React interface with Tailwind CSS for intuitive cross-chain swaps
- Partial Fills: Advanced order splitting functionality with percentage-based execution
See STRETCH_GOALS_SUMMARY.md for details.
EVMore/
├── libs/ # Enterprise libraries (Turborepo)
│ ├── @evmore/types # Core type definitions
│ ├── @evmore/interfaces # Service contracts
│ ├── @evmore/errors # Structured error handling
│ ├── @evmore/config # Configuration management
│ ├── @evmore/utils # Infrastructure utilities
│ ├── @evmore/connection-pool # Connection management
│ └── @evmore/test-utils # Testing framework
│
├── contracts/ # Smart contracts
│ ├── ethereum/ # Ethereum/EVM contracts
│ └── cosmwasm/ # CosmWasm contracts
│
├── relayer/ # Cross-chain relayer
├── sdk/ # TypeScript SDK
├── frontend/ # React web interface
├── tests/ # Comprehensive test suites
├── scripts/ # Deployment & setup
└── docs/ # Documentation
- Node.js >= 18.0.0
- Rust >= 1.70.0
- CosmWasm CLI tools
- Docker (for local testing)
# Clone the repository
git clone https://github.com/hydepwns/evmore
cd evmore
# Install dependencies
npm install
# Build contracts
npm run build:contracts
# Run tests
npm test
# Start local blockchain environment
docker-compose up -d
# Deploy contracts locally
npm run deploy:local
# Run relayer in development mode
npm run dev:relayer
# Start frontend
cd frontend && npm run dev
# Open http://localhost:5173
- Atomic cross-chain swaps between Ethereum and Cosmos
- Multi-hop IBC routing for optimal paths
- Hash Time Lock Contracts (HTLCs) on both chains
- Automated relayer service
- Native IBC packet handling
- Packet Forward Middleware support
- Multi-hop transfer logic with timelock cascades
- Comprehensive integration testing
- Osmosis pool integration for liquidity
- Dynamic price discovery
- Slippage protection mechanisms
- Multi-DEX aggregation
- Enterprise-grade TypeScript libraries
- Comprehensive test coverage (99.14% pass rate)
- Performance optimized bundles
- Security audited contracts
-
Order Creation (Ethereum)
- User creates cross-chain limit order
- Assets locked in HTLC contract
- Order broadcast to relayers
-
Route Discovery (Multi-Chain)
- Relayer finds optimal path through Cosmos chains
- Considers fees, liquidity, and timeouts
- May route through multiple DEXs
-
Execution (Cosmos)
- Relayer initiates IBC transfers
- Assets hop through intermediate chains
- Final swap executed on target chain
-
Settlement (Atomic)
- Secret revealed on target chain
- Propagated back through all hops
- Original HTLC unlocked on Ethereum
- Atomic Execution: All-or-nothing via HTLCs
- Timelock Cascade: Each hop has decreasing timelock
- No Trust Required: Cryptographic proofs only
- MEV Resistant: Commit-reveal and encryption
- Ethereum (Mainnet, Sepolia)
- Osmosis (Primary DEX hub)
- Cosmos Hub (ATOM native chain)
- Juno (Smart contract platform)
- Secret Network (Privacy features)
- Any IBC-enabled Cosmos chain
- Additional EVM chains (Polygon, BSC, etc.)
- Non-EVM chains via adapters
- Smart Contracts: Solidity (EVM), Rust/CosmWasm (Cosmos)
- Relayer: TypeScript, Node.js
- IBC: Go, Cosmos SDK
- Testing: Hardhat, Jest, CosmWasm Test Tube
- Infrastructure: Docker, Kubernetes
We welcome contributions! Please see our Contributing Guide for details.
- Fork the repository
- Create feature branch (
git checkout -b feature/amazing-feature
) - Commit changes (
git commit -m 'Add amazing feature'
) - Push to branch (
git push origin feature/amazing-feature
) - Open Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
- 1inch Limit Order Protocol
- Cosmos SDK Documentation
- CosmWasm Documentation
- IBC Protocol Specification
Status: This project is under active development. Use at your own risk on mainnet.