Published in


Cross-chain DEX Prototype

The Wanchain team is currently building a prototype cross-chain DEX with deposit / withdrawal to and from various native chains

Moving towards a DEX model

Decentralized exchanges or DEXes as they are commonly referred to have slowly but surely been gaining in popularity of the last several years. Centralized exchanges have been plagued by a variety of problems since their inception. Hacks, scams, and lost funds are a common issue. Other issues include fake or manipulated trading data. Decentralized exchanges aim to address many of these issues by moving all accounts, transactions and trading away from centralized databases to a blockchain powered model. With a DEX, the user holds their own private key, and all transactions are made directly on the blockchain, greatly reducing third party risk and increasing transparency.

What’s still missing?

While DEXes do address some of the issues discussed above, they are not without their own issues. The user experience of DEXes is often slower and more complex than that of centralized exchanges, as they are limited by the blockchain technology they are built in which is generally slower and less flexible than traditional relational databases. This, however, is becoming less of an issue as blockchain technology improves. Another issue is how to trade assets from multiple different blockchains on the same DEX. Centralized exchanges do not need to worry about the underlying architecture of the blockchain assets their users are trading, since all trading is happening on the exchange’s own centralized orderbooks. However, generally speaking, a DEX only allows for trading of assets from the native blockchain the DEX is built on. This is the issue which the Wanchain cross-chain DEX aims to solve.

Multi-chain assets on one DEX:

The current situation:

There have already been some attempts to solve the issue of how to trade assets from multiple chains on one DEX. The current most widely used approach is to trade wrapped versions of tokens from other chains on the DEX. For example, WBTC from https://www.wbtc.network/ (not to be confused with Wanchain’s WBTC), is an ERC20 wrapped BTC. In order to generate WBTC, BTC is locked on the native Bitcoin chain, and WBTC placeholder ERC20 tokens are released 1:1 on the Ethereum network. This allows for smart contracts on Ethereum to interact with WBTC, enabling its trading on Ethereum DEXes.

The above approach is currently live and in use on a number of different Ethereum based DEXes, but it has limitations. Perhaps most significantly, the process of converting back and forth from BTC to WBTC relies on trusted third party gateways, including going through KYC/AML procedures. Similar approaches have been used to trade BTC on other blockchains, such as Bitshares.

Wanchain’s approach to cross-chain

Wanchain’s approach to a cross-chain DEX is different from current cross-chain DEXes in one key way. Whereas the current approach to trading foreign chain’s tokens on a native chain relies on trusted third parties to wrap tokens, Wanchain’s approach is built on top of its decentralized cross-chain storeman mechanism. Through this mechanism, a token is locked in an account on its native chain (Bitcoin, for example) which is managed by a distributed group of storeman nodes rather than any individual trusted organization or company. A WRC20 wrapped token is then released on Wanchain (Wanchain’s WBTC, for example), which is then available for trading. Cross-chain storeman groups have already been established for a number of crypto assets including Bitcoin (BTC), Ethereum (ETH), Maker (MKR), Dai (DAI), Aurora DAO (AURA), Loopring (LRC), Chainlink (LINK), Gemini Dollar (GUSD), USD Coin (USDC), TrueUSD (TUSD), and soon to include EOS.

Wanchain Decentralized Exchange Proof of Concept

Wanchain’s dev team is currently in the process of developing a proof of concept for a Wanchain blockchain based DEX. The team is building the POC by integrating Wanchain’s own cross-chain technology together with DDEX’s Hydro protocol SDK. The basic UI should be familiar to any user of Ethereum DEXes:

The POC will allow for users to connect either through Wanmask or with hardware wallets such as Trezor or Ledger.

Wallet Selection

Users will be able to view their balances and wrap or unwrap assets from within the wallet interface to allow for trading on Wanchain.

Native Chain Deposit and Withdrawal

One of the key features enabled by the Wanchain DEX is the deposit and withdrawal of assets directly to and from their native chains. Take trading EOS with WAN, for example. To do so, a user will wrap EOS as a WRC20 token (WEOS), trade with WAN, and then unwrap back to EOS on the native chain after finishing trading. The entire process occurs through a totally decentralized mechanism.

More to Come

Currently the project is the proof of concept stage. It is being designed in order to demonstrate the possibilities of a totally decentralized multi chain Wanchain based exchange. As an open source project, DEX operators will be free to make use of Wanchain’s cross-chain DEX code in order to set up their own multi-chain exchange, and wallet developer will be free to integrate the exchange into their wallets. We believe that totally decentralized cross-chain trading is the future, and we are working hard to make that a reality.

About Wanchain

Wanchain is the infrastructure connecting the decentralized financial world. Wanchain’s live cross-blockchain solution is EVM-based, includes optional private transactions, and provides a decentralized, permissionless, and secure approach for interoperability. Wanchain has employees globally with teams in Beijing (China), Austin (USA), Kuala Lumpur (Malaysia), and Madrid (Spain).

Website | Documentation | Telegram| Twitter | Newsletter | Blockchain Explorer | Developer Portal




Our mission is to drive blockchain adoption through interoperability by building fully decentralised bridges that connect the world’s many siloed blockchain networks.

Recommended from Medium

Telos Blockchain Network — Weekly Report — November 29th, 2018

Community Newsletter #4 — January 2021

A community push to create a brand new Crown Platform website

Welcome Unity Validators

What Is The Future Of Non-Fungible Tokens(NFT)?

Cartesi Incubator Spotlight-Infrastructure: Carti

Is Blockchain a Breakthrough for New Retail?

Building a Tokenization Infrastructure

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Noah Maizels

Noah Maizels

https://www.linkedin.com/in/noah-maizels/ https://github.com/noahniuwa

More from Medium

X Protocol Staking Program on Encentive

Chainlink AMA Recap Update

How to bridge Zap Protocol Tokens Using Multichain

$HID Staking Migration & Withdrawal Guide