Spellcheck

This commit is contained in:
barry 2024-02-03 07:17:48 -06:00
parent aa022e1375
commit e0c7081a67

View File

@ -10,7 +10,7 @@ This is a multipart DeepDive that will focus on the Liquid Sidechain. It will be
[In Part II](https://stacker.news/items/407806), we focused on issuing Assets. Now let's look at the ways you can *use* assets.
One of the most basic usecases for a custom issued asset is to exchange it for something else. For purposes of discussion, let's assume that a company - say StackerNews Airline - wants to issue their clients "Air Miles" for each flight they take. The idea is clients will accrue these *points* and then be able to exchange them for either discounts off future flights or direct cash (ie. USD / BTC).
One of the most basic use cases for a custom issued asset is to exchange it for something else. For purposes of discussion, let's assume that a company - say StackerNews Airline - wants to issue their clients "Air Miles" for each flight they take. The idea is clients will accrue these *points* and then be able to exchange them for either discounts off future flights or direct cash (ie. USD / BTC).
If we start thinking like a developer for second, this implies many things to build:
* An accounting system to manage the points
@ -30,7 +30,7 @@ We could build some type of typical web-stack of NodeJS / SQL that would accept
Luckily, due to the additional OPCODEs in Liquid, Atomic Swaps are supported[^2]. In fact, [Blockstream has a tool](https://github.com/Blockstream/liquid-swap) to simplify using it[^3].
To do a swap we will need another wallet, as you can't swap between the same wallet (techically you can use the *same node* and use 2 different wallets on that node[^4]). In my case, I have 2 nodes each running their own `elementsd` server (Umbrel and my desktop). So I will use those, but you can use a single node by setting up mutliple wallets and using distinct URL connect strings for each.
To do a swap we will need another wallet, as you can't swap between the same wallet (technically you can use the *same node* and use 2 different wallets on that node[^4]). In my case, I have 2 nodes each running their own `elementsd` server (Umbrel and my desktop). So I will use those, but you can use a single node by setting up multiple wallets and using distinct URL connect strings for each.
Before we start, let's look at state of our 2 wallets:
@ -56,7 +56,7 @@ The swap offer proposal is: StackerNews Airline (Node 1) is willing to accept a
$ liquidswap-cli -u http://$E_RPCUSER:$E_RPCPASS@localhost:7041 propose -o proposal.txt 3e62af3c80c56ab6fec3d1e5646637152afebaf2a86ace075bbb7a88702e1fe5 1 6f0279e9ed041c3d710a9f57d0c02928416460c4b722ae3457a11eec381c526d 0.000023
```
This file was exported to `proposal.txt` and transfered to Node2 (the customer), which was then inspected:
This file was exported to `proposal.txt` and transferred to Node2 (the customer), which was then inspected:
![](1-part3-clientaccept.png)
@ -101,7 +101,7 @@ Now lets review the state our wallets post swap:
|Post-Swap: L-BTC| 129180 sat | 12656 sat |
|TOTAL FEES PAID| 251 sat | 291 sat |
(NOTE: Obviously the workflow here is a little clunky with the back-and-forth Propsal/Accept/Finalize routine, but I wanted the steps to be transparent. In a production case this would be built into the service and client app such that the proposal and acceptance strings were automiatically transferred between the parties.)
(NOTE: Obviously the workflow here is a little clunky with the back-and-forth Proposal/Accept/Finalize routine, but I wanted the steps to be transparent. In a production case this would be built into the service and client app such that the proposal and acceptance strings were automatically transferred between the parties.)
## Securities / Transfer Restricted / etc
@ -121,16 +121,16 @@ Yes, probably one of the best ways to do that is to use it as a *staging area* f
|| eCash | Lightning | Liquid | BTC |
|-| ------| -------- | -------- | ---- |
|UTXO Model:| No UTXO. Bearer token | Your UTXO is in a multisig. | You own UTXO in sidechain | You own UTXO in mainchain |
|Redemption:| Depends on mint | No dependency (might require fee) | Depends on Federation | No dependecy |
|Longevity: | Mint must survive | Channels will close at somepoint | Federation must survive | UTXO forever |
|Online:| Must be online to verify eCash token | You must be online to recieve. You must stay online (or hire watchtower) to secure channel state | Offline receive | Offline receive |
|Redemption:| Depends on mint | No dependency (might require fee) | Depends on Federation | No dependency |
|Longevity: | Mint must survive | Channels will close at some point | Federation must survive | UTXO forever |
|Online:| Must be online to verify eCash token | You must be online to receive. You must stay online (or hire watchtower) to secure channel state | Offline receive | Offline receive |
|TXN Time:| Instant transactions | Instant transactions | Fixed 2 min transactions | Variable ~10 min transactions |
|Fees:| No fees | Neglible fees (msat) | "Low" fees (~200 sats) | High fees (~15,000 sats)|
|Fees:| No fees | Negligible fees (msat) | "Low" fees (~200 sats) | High fees (~15,000 sats)|
|Liquidity:| No liquidity management | Must manage liquidity (in/out) | No liquidity management | No liquidity management|
|Privacy:| Mints can aggregate and assemble transaction data | Nodes could aggregate and assemble transaction data | Confidential transactions | Absolute public ledger |
|Federation: | Must vet each Mint | You choose channel partner | Known federation members | Soverign |
|Federation: | Must vet each Mint | You choose channel partner | Known federation members | Sovereign |
| Frac Reserve Possible: | Yes | No | Verifiable Issues | No |
|Likely Threat:| Debasement or Mint rug | Theft of funds while offline | Federation censorship | Losing keys / unspendable UTXO for fees
|Likely Threat:| Debasement or Mint rug | Theft of funds while offline | Federation censorship | Losing keys / non-spendable UTXO for fees
|Maturity: | 2023-2024 | 2018 | 2018 | 2009
## Building Your Own Federation
@ -144,4 +144,4 @@ Yes, probably one of the best ways to do that is to use it as a *staging area* f
[^1]: BlockStream Green, AQUA, Anser (web wallet), Specter, Marina (web wallet)
[^2]: Atomic Swaps allow parties to exchange different tokens directly without the need for a 3rd party, eliminating most of the risk of fraud and counterparty default.In fact, Blockstream has a tool to simplify using it.
[^3]: Please `git clone` the repo and don't rely on the pre-compiled downloads in repo (they are out of date from source)
[^4]: You can specify to individual wallets in the swap-tool URL connect string by using the `http://user:password@localhost:7041/wallet/walletname` syntax
[^4]: You can specify to individual wallets in the swap-tool URL connect string by using the `http://user:password@localhost:7041/wallet/walletname` syntax