Atomic Swaps — The Interoperability Revolution in Cryptos
The developers of the Cryptocurrencies have been working to introduce the revolutionary & much-needed feature of Atomic swaps for quite some time now. A broad-based implementation is still a little further down the road but the experimentation with the micro level projects has shown the great potential of this feature. Atomic swaps can come in really handy if you are trying to move from one cryptocurrency to another. The ability of individual blockchains to interact with each other — for example cross-chain transactions between Bitcoin & Ethereum networks is extremely limited — mostly due to the fact that individual blockchains employ varying protocols, algorithms & security procedures to conduct transactions. Most of the digital exchanges still expect you to convert to a base currency which is usually Bitcoin (being the most liquid & easily available) before converting to another digital asset. With the kind of volatility that we have in Cryptocurrencies, this means you might end up paying a higher amount for your choice of the digital asset. Don’t forget all the transaction fees that you would rack up in executing these back & forth transactions.
Atomic swaps are basically a smart contract enabled technology that gives you the ability to exchange digital assets on-chain or off-chain seamlessly & securely without the involvement of a third-party like the centralized exchanges. You must be wondering what about decentralized exchanges then? Well, Atomic swaps differ from DEXs in the sense that they create an encrypted escrow account via a cryptographic protocol which guarantees instant refunds to the users if the transaction is not completed for some reason or aborted by one party or the other — literally reducing the default risk to zero. Having decentralized peer-to-peer based digital currencies doesn’t make too much sense when you are going to trade them on centralized exchanges prone to security vulnerabilities, government regulations, mismanagement & liquidity concerns.
The theoretical work on Atomic swaps has existed since 2012 when Sergio Demian Lerner created the first trust-less exchange protocol, but it didn’t get much traction till May 2013 when Tier Nolan came out with details of how the technology works — and eventually got the recognition for being the creator of Atomic Swaps. The practical implementation, however, came much later in Sep. 2017 between first Decred and Litecoin. The beauty of Atomic swaps is that they can be employed on two separate blockchains with two different native coins like Bitcoin & Ethereum or via off-chain secondary layer solutions like Bitcoin’s Lightning network. Today, a bunch of decentralized exchanges including Lightning Labs, Altcoin.io, Komodo, & 0x offer the capability of Atomic swaps. We will be talking about Komodo in detail a little later since it offers the most extensive use of the technology.
Atomic swaps are executed via Hashed TimeLock Contracts (HTLC) — special form of off-chain payment channels. This means no clogging of the main network & reducing the processing time significantly as well. HTLC is a special type of smart contract which enables time bound transactions between the two parties. The transacting parties are required to complete the transaction in stipulated time by providing the cryptographic proof (private key) thus reducing the counterparty risk.
Atomic Swap Implementations
❶ DEx.top, a decentralized digital Exchange (DEX) & iBitcome, a mobile wallet provider collaborated to develop an Open Federated Gateway Protocol(OFGP) based on an open source technology. The protocol basically enables the cross-chain transactions between the Bitcoin & Ethereum blockchains. The first version of this federated blockchain technology called Mallow was launched on Oct. 24 accompanied by a block explorer, which gives the users the ability to keep an eye on the flow of their digital assets & the transactions on the network as and when they please.
❷ Another solution for cross-chain transactions has been presented by Wanchain which wants to bridge the Ethereum & Bitcoin Blockchains — an interaction between the two networks. Similar to OFGP, an intermediary digital coin called WBTC (Wanchain’s Bitcoin cross-chain token) will be used to seamlessly conduct cross chain transactions on the Wanchain network. Wanchain’s partner, Kyber DEX (a decentralized exchange), will be offering BTC trading pairs based on the Wanchain’s BTC token allowing for drastic increases in trading volume & liquidity.
❸ Atomic provides is an infrastructure layer which provides Cross-Blockchain P2P Financial Services infrastructure which is both personal & secure. The service is available for all kinds of businesses including digital exchanges, lending, Credit lines, e-commerce & point-of-sale solutions
❹ One of the more popular companies which offers on-chain Atomic swaps is Bitcoin Atom (BCA). They are also working on the Lightning network implementation for off-chain Atomic swaps. The BCA network is secured by employing the hybrid consensus of PoW & PoS which increases stability & reduces the probability of a 51% attack. The users can exchange Cryptocurrencies safely & without intermediaries with the use of BCA’s Hash Time Locked Contracts & its own HTLC API.
❺ Most recently, Qtum — blockchain platform that incorporates smart contracts & dApps has incorporated Atomic swaps to its main net using HTLCs. Qtum is similar to Ethereum network in using smart contracts & dApps — the former however uses Unspent Transaction Output (UTXO) which enables much faster & lighter transactions.
❻ And finally the contribution of the decentralized exchange Komodo to Atomic swap solutions can’t be emphasized enough — it presents an Open-Source Infrastructure for an Interoperable Blockchain Ecosystem. A year after Nolan presented the idea of Atomic swaps, the lead developer of the Komodo team, jl777, wrote the code which allowed some of the very first Atomic swaps to take place. Initially, the code was restricted to the exchange NXT assets only, but gradually it was improved to include other digital assets also. Komodo receives the credit for bringing the technology to the mainstream — by developing the first GUI for an Atomic Swap crypto trading marketplace, called BarterDEX & then in Feb. 2018 conducted the first Atomic swap for Bitcoin & Ethereum based coins between DOGE and ETH. The DEX has since then performed thousands of Atomic swaps & expanded on the ecosystem by including almost 95% of all available digital coins & tokens.
⏭ Interoperability — Lack of an exchange mechanism between different Cryptocurrencies is one of the major problems plaguing the digital assets (after scalability) which Atomic swaps have set out to rectify. Free movement of digital currencies among each other would create the independence that is needed to mainstream adoption.
⏭ Cheaper & Faster — Skipping the registration (KYC), confirmation & validations makes the process much faster since you are not going through a third-party like a centralized exchange. A direct wallet to wallet transfer is possible, which saves you precious change since you are not charged any fees for the P2P exchange. Current procedures on most digital exchanges have a tedious & fee-intensive structure for exchanging different digital assets. For example, if you are planning to buy Litecoin, you first have to buy Bitcoin, then sell it to buy LTC paying fees twice. On top of that if you are trying to transfer your digital tokens to a wallet, it incurs another fee.
⏭ Transparency & Security — It’s no secret that most of the current centralized digital exchanges are prone to security breaches & massive hacks causing a huge pain for the customers. Atomic swap, on the other hand, offers a secure channel between the two transacting parties where private keys are known only to them. The time-constrained transaction ensures the transparency of the transaction where a non-committal party or denial by both results in the refund of their money.
⏭ Diversification — Since Atomic swaps give you the ability to trade all the digital coins easily in a Peer to Peer exchange, it gives the investors the ability to diversify in different digital assets of their choice rather than getting stuck with the coins that are only offered by the exchange. Investors in traditional financial instruments like stocks, derivatives, mutual funds etc. know the importance of diversification in any financial portfolio.
⏭ Better Privacy — Since the transactions in Atomic swaps are conducted in a completely trust-less manner — where there is no third party involved & you being in charge of your personal data like the private key etc. the information you exchange is not sitting on some third-party server, but in your hands gives you the peace of mind.
🞕 Technical specifications — Although Atomic swaps offer some enticing features, it still has some drawbacks to work out of before becoming easier to implement. The following technical specs. unfortunately greatly limit the Cryptos that can be exchanged using the Atomic swaps. However, considering Atomic swaps are still in very early stage of implementation, better solutions should emerge to work around this limitation in the future.
- Swapping cryptocurrencies must have the same hashing algorithm.
- Both the transacting Cryptos should be able to initiate the HTLCs.
- The digital assets in question should also have specialized programming functionalities.
- Atomic swaps don’t work with digital assets which don’t support smart contracts.
🞕 Transactional capacity — The speed of individual Atomic swaps is actually a plus point, but it becomes a drag when we talk about large volumes of data transactions. The scalability issue surrounding the swapping of large volumes of Crypto coins is something of a challenge that would need attention.
🞕 Wallet adoption — The last but not the least is the support by different digital wallets for Atomic swaps. Right now, the choice is pretty limited. This is something which would automatically get better as technology gets adopted.
It’s great to know that developers of the Cryptocurrencies & other digital assets have been working diligently to hammer out the solutions for major roadblocks like scalability & interoperability. With the crash of the hype-induced rally & the exuberance behind us, the next revolution in Cryptos is going to be based on how we trade & use digital assets, based on the addition & implementation of these value-added features. Until then… don’t lose faith!
Despite the massive price declines in the Cryptos for the past 12 months the institutional interest has continued to…medium.com
Another good week with some nice educational content coming your way. My most favorite & one of the most popular posts…medium.com
As we step into the first full week of Financial markets in the New year — the momentum for now seems to be in the same…medium.com
Originally published at www.datadriveninvestor.com on January 11, 2019.