Skip to content

mainnet_pat CCS proposal for completion of XMR-BCH atomic swaps

mainnet-pat requested to merge mainnet-pat/ccs-proposals:master into master

Complete XMR-BCH atomic swaps


layout: fr title: "Complete XMR-BCH atomic swaps project" author: mainnet_pat date: Oct 25, 2024 amount: 200 milestones:

  • name: M0 Finalize the libp2p message exchange protocol and implementation funds: 50 XMR done: Dec 1 2024 status: unfinished
  • name: M1 Basic web app to visualize the swap process funds: 50 XMR done: Jan 1 2025 status: unfinished
  • name: M2 Improved web app to track many ongoing swaps funds: 50 XMR done: Feb 1 2025 status: unfinished
  • name: M3 Enhanced swap security with libp2p onion routing, reduced trust with electrum and monero-rpc clusters, final web app funds: 50 XMR done: Mar 1 2025 status: unfinished payouts:
  • date: Nov 1 2024 amount: 50 XMR
  • date: Dec 1 2024 or upon M0 completion amount: 50 XMR
  • date: Jan 1 2025 or upon M1 completion amount: 50 XMR
  • date: Feb 1 2024 or upon M2 completion amount: 50 XMR

Complete XMR-BCH atomic swaps

Proposal

This proposal seeks the support from Monero community to finalize the effort to create the web platform for XMR-BCH atomic swap utilizing the adaptor signatures. Unlike the COMIT or other approaches we aim to swap assets both ways, trustless. See details in refs Hoenisch, P. & Pino, L. (2021)

The work on server-side is mostly done and being tested, funded by generous donors from BCH Flipstarter campaign [https://atomic-flip.pat.mn]

As we have initially underestimated (in the framework of BCH flipstarter) the effort to finish the task, we are asking for extended funding from Monero Community to complete the implementation of the Web application to execute the atomic swaps between Monero and BCH chains.

We have contributed significantly to our core dependency monero-ts to enhance out swap library. Moreover, we have deployed the first ever Monero light web wallet with WalletConnect integration https://monujo.cash

In the framework of this CCS our main focus currently is on the Web Application, creating the captivating UX for a user to easily navigate through, pick the best deals, and keep track of their ongoing swaps.

Next immediate milestone is the liquidity providing / market making tool (server and browser), which becomes an essential interest point for both networks to have swap activity and for users to farm the XMR/BCH ratio spread for their benefit.

Background

As I have mentioned above, I have underestimated the initial development and time cost. At the time of flipstarter submission I have had a working atomic swap concept, but not the end solution. Running tests in vscode's console turned out much different from deploying a web app which does not use any coordination servers but libp2p only - for orderbooks and trade message exchanges. The flipstarter have targeted to pay for effort already spent by me and BitcoinCashAutist as well as to fund further work. BCA is a brilliant thinker and he delivered his promised part - the BCH covenant contract to enable the atomic swaps. Moreover he overdelivered by optimizing and improving the contracts and paving the way towards other BTC-like (LTC, DOGE, etc) swap pairs and also by continuously supporting me on conceptual level. BCA does not help me write code and/or otherwise help with the web app, so I am alone here.

Also as being mentioned, in the framework of this flipstarter I have worked on monujo wallet and improving monero-ts, which was required for my work and benefited woodser's but consumed the resources.

I seek additional funding to complete the project and make it ready for web. Currently I am working hard on the web app to ensure the failsafe execution of the swaps, which are prolonged multistep processes, especially in context of several concurrent ongoing swaps. Particular challenge is making libp2p-based orderbook and swap message exchange work properly in browsers and with vpns enabled. Another big topic is to support libp2p onion routing for enhanced security.

I've spent October 2024 integrating our swap approach into BasicSwapDEX in close cooperation with ofrnxmr and BSX team. At the time of submission (October 25 2024) it is almost complete and being debugged and polished - see progres on GitHub https://github.com/basicswap/basicswap/pull/124

Merge request reports