About
1inch Fusion enables trustless cross-chain swaps through hash-locked limit orders, but currently supports only EVM-compatible chains. This project extends the protocol to Bitcoin (both on-chain and Lightning Network) and TON blockchain by implementing the necessary bridge infrastructure and smart contracts. For Bitcoin integration, we developed HTLC scripts that use SHA256 hashing compatible with Bitcoin's native cryptographic functions, while maintaining interoperability with 1inch's keccak256-based EVM contracts through dual-hash secret generation. The Lightning Network implementation uses HODL invoices as the commitment mechanism, allowing atomic swaps between Lightning satoshis and EVM-based tokens. For TON blockchain integration, we created custom smart contracts written in FunC that handle Jetton deposits, implement hashlock mappings, and manage timelock-based refunds. The TON contracts use SHA256 hashing for compatibility and include sophisticated state management with persistent storage dictionaries for efficient swap lookups. Each swap creates a fresh contract instance with unique context IDs to ensure isolation. The implementation supports bidirectional swaps between TON Jettons and EVM tokens, with proper balance verification and atomic completion or refund mechanisms that maintain the trustless guarantees of the original 1inch Fusion protocol.
From the public ETHGlobal showcase page. Votes, swipes and the judge score are hackfeed's own.






