SAS: Succinct Atomic Swap



Summary:

In a discussion between Ruben and ZmnSCPxj about the CoinSwap protocol, it was noted that if Bob neglects to broadcast success tx before refund tx #1 becomes valid, Alice can broadcast it, potentially causing chaos. However, as long as Alice chooses the path for refund tx #2, it won't cause chaos for her. They also discussed the importance of ensuring the TXO is spent before refund tx #1 becomes valid and suggested using sighash_single + anyonecanpay to achieve this. They also discussed the roles of the client and server in a client-server CoinSwap. ZmnSCPxj suggested that the server take Alice's position and the client take Bob's position, as the client may want to make multiple CoinSwaps in sequence to obscure their history. Additionally, whoever is planning to spend their UTXO first should be Bob to reduce the risk of wasting resources. For the final swap, the client can spend the final coins to an HD wallet they control, reducing the key backup load on the client. Finally, they discussed how Bob can specify a set of address/value pairs to be put in the success tx instead of just Bob pubkey, giving additional leeway later for RBF once Alice hands over the Alice privkey and Bob can remake the success tx.


Updated on: 2023-06-14T01:28:53.637615+00:00