DEX — “Decentralized Exchanges” — An overview and how Binance plans to get there!
Decentralized is a word I started hearing most in the year 2017 when Bitcoin and Blockchain technology started getting lots of public attention. The word will really sound very attractive when you understand more about the powerful things it can accomplish in our present world. When human beings started evolving into larger communities they quickly started to rely on centralized authorities since that was the most convenient way of doing things. Everything from governance, currency, legal systems were all handled by centralized authorities or organization. Over the course of time, governance became more democratized but the currency always remained controlled by Central banks and it is still like that now. In 2009 Satoshi Nakamoto came up with the idea behind bitcoin. He describes it as a peer to peer electronic cash system without involving any middlemen or banks. This definitely seems to be a better or parallel alternative for the existing currency system in our present world. The key feature of the underlying blockchain technology used in bitcoin or any other for that matter is decentralization.
Decentralization is essentially something which has no central authority or body of control and not bound to a specific geography or jurisdiction. Blockchains as per Vitalik Buterin are politically decentralized (no one controls them) and architecturally decentralized (no infrastructural central point of failure) but they are logically centralized (there is one commonly agreed state and the system behave like a single computer). The biggest irony of Blockchain technology when it comes to trading cryptocurrencies is that all the businesses or platforms which facilitate trading are all centralized or controlled by central authorities called exchanges just like banks. So we take one leap forward and take one backward essentially trying to replace one system with another similar system. Now for cryptocurrencies to survive and exist as some parallel economy it has to be decentralized at some point in time to avoid all regional regulations and restrictions imposed by the central authorities and governments across the world. This might have some bad implications as some people say but that is what in essence the underlying philosophies or core principles on which blockchain technology is defined — Decentralize!
Let’s talk a little bit about some of the aspects of present-day Centralized Crypto Exchanges.
Control of funds
The worst part of owning a decentralized entity such as cryptocurrencies or tokens is giving up the ownership to control the tokens to a centralized business. Before going into the details of how Centralized Crypto Exchanges hold your funds it is good to understand the difference between cold and hot cryptocurrency wallets. The primary difference is a cold wallet is not connected to the internet and hence considered to be safe while a hot wallet will be online and fast but prone to hacking and other security vulnerabilities. Most Crypto exchanges keep some of your funds online in their server infrastructure in order to enable faster trading. and hence the private keys associated with funds will also be stored on the same server. Private keys are very important in cryptocurrencies such that if you lose them you lose all your funds. It is not only the security that concerns me when you keep your funds in exchanges. Exchanges are prone to regulations based on the countries they operate. This might cause the Crypto exchanges to shut down without enough notice and the fate of your funds is then under the complete discretion of the exchange owners. Cryptocurrencies can function as long as the internet is not shut down. So if you are a serious Crypto investor then you should make sure you keep little of your funds in exchange for trading and move the rest to any secure cold storage.
Some cryptocurrencies can be traded anonymous and some Centralized Exchanges facilitate anonymous trading but with all the KYC — Know Your Customer and AML — Anti-Money Laundering — regulations imposed on them, this has become more challenging and less practical.
Centralized Crypto Exchanges keep order book just like any other financial exchange systems in order to perform order routing and matching. The exchange acts as the trusted intermediary between buyers and sellers and matches buy & sell orders and settle them immediately even though the specific transaction might take more time to confirm depending on the underlying blockchain network. This is, in fact, a faster method to settle transactions except the fact that a trusted central agency still needs to have relied upon like traditional stock exchanges. With blockchain technology and smart contracts, trading can be performed with much accuracy and speed in a trustless fashion.
Liquidity is important for any tradable asset including cryptocurrencies. Liquidity refers to the extent to which a market allows assets to be bought and sold at stable prices. This is where Centralized crypto exchanges outperform Decentralized Exchanges. Low liquidity causes highly volatile market where the prices are not stable. The factors which favor high liquidity with centralized exchanges are price discovery, fast order update etc. Since centralized exchanges control user funds at one place they can perform faster price discovery on trade orders. The price discovery process is the process of determining the price of an asset in the marketplace through the interactions of buyers and sellers. Orders get updated faster on the centralized exchange ledger which also favors higher liquidity. Decentralized exchanges tend to be slow because they only facilitate matching and routing of trade orders of users and do not own user funds on their centralized ledgers. This affects low liquidity and volume of trade on Decentralized exchanges. There are different solution proposed to overcome this liquidity challenge on Decentralized Exchanges.
How Decentralized Exchanges Work!
Decentralized Exchanges in a very nutshell reduce the dependency on a third party central entity on most of the exchange functions. This means traders perform a peer-to-peer trading with funds in their wallets. The role of an exchange will be more of a facilitator of trading than being the trader itself on behalf of users.There are various ways and levels at which decentralization can be achieved and many implementations currently exist.
These are some of the important implementations which exist now.
Some exchanges are partially decentralized in the sense they keep a centralized order book as a smart contract but the wallet function is decentralized and users connect their personal wallets to the exchange to make transactions. The order book is nothing but a list of buy & sell orders and traders can pick and choose from them or manually add new buy and sell orders.
Some exchanges use an open protocol for Decentralized Exchange like 0x — ‘zero-ex’. 0x provides a protocol which can be implemented by any exchange or entity to fully adapt decentralized trading of cryptocurrencies. Some decentralized exchanges keep the order book on blockchain which will slow down the order process as each and every operation needs to be confirmed on the network. In order to overcome this, 0x relays off the order book operations off-chain and only uses the blockchain for order settlement. This increases speed and hence higher liquidity.
Instead of having the order book function on the blockchain network some Decentralized Exchanges use off-chain processing for most of the trade functions like checking the authenticity and balance and updating the order book. Before the off-chain process is closed for a transaction the transaction is broadcast to Ethereum network for confirmation by a smart contract. This ensures faster trade order processing and at the same time security of blockchain.
Since trust is one factor which gets compromised by removing the central authority feature of Centralized Exchanges there should be a better other option to enforce trust in Decentralized Exchanges. Some Decentralized Exchanges use a latest smart contract technology called ‘atomic swaps’ to enforce trustless and faster trading. Atomic Swaps works like all-or-nothing fashion. An Atomic Swap is the exchange of different cryptocurrencies on different blockchains, without the need to trust a third party/intermediary. It utilizes a specific type of smart contract called ‘Hash-time locked contracts’ — HTLC- that enables two people to exchange different cryptocurrencies in a trustless manner, without the inherent risk of one person defaulting or backing out of the trade.
How Binance plans to become Decentralized?
Binance is a fastest growing Centralized Crypto Exchange which has higher trade volumes and over a year has become location decentralized. Binance as an exchange has gone through the various challenges faced by a Centralized Crypto Exchange. They have survived phishing, stealing attempts by hackers. Binance had to move out its offices from China and Japan in advance of tougher Crypto regulations there and now has servers and offices in multiple locations.
Binance has serious plans to become decentralized as they believe blockchain technology is going to change the way currency is transacted in this world and Binance will be a name associated with that change in future. They are planning to provide a hybrid solution to offer its customers the best of both worlds. The centralized component of Binance will work as such and along the way Binance is working on to develop a public blockchain called Binance Chain. Binance Chain will be used for transfer and trading of blockchain assets. The main goals behind Binance Chain are to fulfill a decentralized exchange with the focus on performance, ease-of-use, and liquidity. The Binance coin, currently an Ethereum based ERC20 token will be swapped to exist in its own Binance Chain Mainnet as a native coin. Eventually, Binance plans to transition as a community from a company.
There is no white paper published yet and so there are no details or roadmap on how Binance is planning to implement the proposed Decentralized Exchange. According to Binance CEO Changpeng Zhao both Centralized and Decentralized Exchanges will coexist for Binance. Decentralized Binance Exchange will have almost all coins listed as there will be less control and scrutiny and will have slightly higher fees compared to Centralized Exchange. They require more computing power and hence can be slower compared to the other one. Decentralized Exchange will exist for people who prefer anonymity and security. Centralized Exchange will exist for people who prefer speed and liquidity. How Binance is going to balance both of these aspects is something we have to wait and see.
Checkout the link to Binance Dexathon if you would like to contribute How Binance Decentralized Exchange should be in future!
Image and content credits: Twitter & Binance & Kanye West