Bitcoin–Monero Cross-chain Atomic Swap
Go to file
bors[bot] 8eb04a5c8f
Merge #357
357: Bump tokio from 1.3.0 to 1.4.0 r=thomaseizinger a=dependabot[bot]

Bumps [tokio](https://github.com/tokio-rs/tokio) from 1.3.0 to 1.4.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a href="https://github.com/tokio-rs/tokio/releases">tokio's releases</a>.</em></p>
<blockquote>
<h2>Tokio v1.4.0</h2>
<h3>Added</h3>
<ul>
<li>macros: introduce biased argument for <code>select!</code> (<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/3603">#3603</a>)</li>
<li>runtime: add <code>Handle::block_on</code> (<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/3569">#3569</a>)</li>
</ul>
<h3>Fixed</h3>
<ul>
<li>runtime: avoid unnecessary polling of <code>block_on</code> future (<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/3582">#3582</a>)</li>
<li>runtime: fix memory leak/growth when creating many runtimes (<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/3564">#3564</a>)</li>
<li>runtime: mark <code>EnterGuard</code> with <code>must_use</code> (<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/3609">#3609</a>)</li>
</ul>
<h3>Documented</h3>
<ul>
<li>chore: mention fix for building docs in contributing guide (<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/3618">#3618</a>)</li>
<li>doc: add link to <code>PollSender</code> (<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/3613">#3613</a>)</li>
<li>doc: alias sleep to delay (<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/3604">#3604</a>)</li>
<li>sync: improve <code>Mutex</code> FIFO explanation (<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/3615">#3615</a>)</li>
<li>timer: fix double newline in module docs (<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/3617">#3617</a>)</li>
</ul>
<p><a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/3564">#3564</a>: <a href="https://github-redirect.dependabot.com/tokio-rs/tokio/pull/3564">tokio-rs/tokio#3564</a>
<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/3613">#3613</a>: <a href="https://github-redirect.dependabot.com/tokio-rs/tokio/pull/3613">tokio-rs/tokio#3613</a>
<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/3618">#3618</a>: <a href="https://github-redirect.dependabot.com/tokio-rs/tokio/pull/3618">tokio-rs/tokio#3618</a>
<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/3617">#3617</a>: <a href="https://github-redirect.dependabot.com/tokio-rs/tokio/pull/3617">tokio-rs/tokio#3617</a>
<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/3582">#3582</a>: <a href="https://github-redirect.dependabot.com/tokio-rs/tokio/pull/3582">tokio-rs/tokio#3582</a>
<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/3615">#3615</a>: <a href="https://github-redirect.dependabot.com/tokio-rs/tokio/pull/3615">tokio-rs/tokio#3615</a>
<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/3603">#3603</a>: <a href="https://github-redirect.dependabot.com/tokio-rs/tokio/pull/3603">tokio-rs/tokio#3603</a>
<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/3609">#3609</a>: <a href="https://github-redirect.dependabot.com/tokio-rs/tokio/pull/3609">tokio-rs/tokio#3609</a>
<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/3604">#3604</a>: <a href="https://github-redirect.dependabot.com/tokio-rs/tokio/pull/3604">tokio-rs/tokio#3604</a>
<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/3569">#3569</a>: <a href="https://github-redirect.dependabot.com/tokio-rs/tokio/pull/3569">tokio-rs/tokio#3569</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a href="dcac336dc7"><code>dcac336</code></a> chore: prepare Tokio v1.4.0 (<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/3621">#3621</a>)</li>
<li><a href="c39d9867bb"><code>c39d986</code></a> runtime: add Handle::block_on (<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/3569">#3569</a>)</li>
<li><a href="e4f76688a0"><code>e4f7668</code></a> runtime: fix memory leak/growth when creating many runtimes (<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/3564">#3564</a>)</li>
<li><a href="e6103d6661"><code>e6103d6</code></a> docs: add link to PollSender (<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/3613">#3613</a>)</li>
<li><a href="cc90a5c679"><code>cc90a5c</code></a> chore: mention fix for building docs in contributing guide (<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/3618">#3618</a>)</li>
<li><a href="f107c4f49b"><code>f107c4f</code></a> timer: fix double newline in module docs (<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/3617">#3617</a>)</li>
<li><a href="e6a9167bb7"><code>e6a9167</code></a> runtime: avoid unnecessary polling of block_on future (<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/3582">#3582</a>)</li>
<li><a href="345b29ca11"><code>345b29c</code></a> sync: improve Mutex FIFO explanation (<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/3615">#3615</a>)</li>
<li><a href="b75d02a2b6"><code>b75d02a</code></a> macros: introduce biased argument for select! (<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/3603">#3603</a>)</li>
<li><a href="a1b4bdee61"><code>a1b4bde</code></a> runtime: mark EnterGuard with must_use (<a href="https://github-redirect.dependabot.com/tokio-rs/tokio/issues/3609">#3609</a>)</li>
<li>Additional commits viewable in <a href="https://github.com/tokio-rs/tokio/compare/tokio-1.3.0...tokio-1.4.0">compare view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=tokio&package-manager=cargo&previous-version=1.3.0&new-version=1.4.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
- `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)


</details>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-03-23 06:50:38 +00:00
.cargo .cargo/config.toml for specifying linker 2021-03-15 14:36:05 +11:00
.github Update the preview release text 2021-03-18 12:09:44 +11:00
monero-harness Bump dependency versions 2021-03-22 14:48:39 +11:00
monero-rpc Remove unused field 2021-03-11 15:34:27 +11:00
swap Merge #339 2021-03-23 00:09:49 +00:00
tokio-tar Download and run monero wallet rpc on swap cli startup 2021-02-25 11:21:41 +11:00
.gitignore Push cargo lock to git as we are building a binary 2020-12-01 09:31:41 +11:00
bors.toml Re-introduce punish test 2021-03-16 18:34:00 +11:00
Cargo.lock Bump tokio from 1.3.0 to 1.4.0 2021-03-23 03:55:01 +00:00
Cargo.toml Split monero-harness into harness and rpc 2021-02-23 14:30:20 +11:00
LICENSE Change license to GPLv3 2020-10-12 17:13:25 +11:00
README.md Minor fixes in README.md 2021-03-16 13:05:43 +11:00
rust-toolchain Add asb to release including ARM build 2021-03-15 09:58:18 +11:00
rustfmt.toml Change imports_granularity to module 2021-03-04 14:48:13 +11:00

XMR to BTC Atomic Swap

This repository hosts an MVP for atomically swapping BTC to XMR. It implements the protocol described in section 3 of this paper.

Quick start

  1. Download the latest release for your operating system
  2. Run the binary: ./swap buy-xmr --receive-address <YOUR MONERO ADDRESS>
  3. Follow the instructions printed to the terminal

Limitations

For now, the MVP is limited to testnet3 on Bitcoin and stagenet on Monero.

How it works

This repository primarily hosts two components:

  • the swap CLI
  • the asb service

swap CLI

The swap CLI acts in the role of Bob and swaps BTC for XMR. See ./swap --help for a description of all commands. The main command is buy-xmr which automatically connects to an instance of asb.

asb service

asb is short for automated swap backend (we are open to suggestions for better names!). The service acts as the counter-party for the swap CLI in the role of Alice. It provides the CLI with a quote and the liquidity necessary for swapping BTC into XMR.

Contact

Feel free to reach out to us in the COMIT-Monero Matrix channel.