-
Notifications
You must be signed in to change notification settings - Fork 10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Scheme for locked funds with non responsive peers #275
Comments
I fear that does not work because there will be a race of both traders and none has a guarantee that the other is not publishing as well. So if Alice was honest and want to avoid a refund agent case then she would wait until block X+Y to publish the tx where she receives all funds. Assume Bob is dishonest and try to get also the funds without having fulfilled the trade contract. He can also wait for block X+Y and publish the tx to him. Then there are 2 competing transactions and a 50% chance or each to win. Bob has better odds as he has less to lose (only the sec. deposit). So it is rational for Alice to not enter that game where she has worse odds and open a refund agent case instead and not risk to lose all the funds. Also: The motivation to reduce refund agent cases are more on Bisq's/DAO side. For a user it is quite comfortable (in case the amount is not high and refund agent pays directly from his pocked without DAO reimbursement). Users are delegating the burden to the DAO (it was designed so to avoid too much friction for users). |
There is no race. If Bob publishes txB, then Alice publishes txBP, which spends txB to the donation address, to take the case to the refund agent. If there is sign of life before X+Y time has passed, either party would publish txP to avoid the extra transaction. For now, it works for the users as long as the refund agent is around and handling cases. For the cases where there is no refund agent and the counterparty disappeared, it would be much more comfortable to get the funds back immediately rather than having to rely on DAO voting. |
Ah ok, read it again and yes, it seems it works. Have you thought about the process how the txs are created and who is the last signer? The seller is the one who has more to lose so we use the seller as the one who has more control over the tx creation. |
Didn't think closely on the practical part. I'm not sure we want to implement this as it adds more complexity and users need to know about it. It might be better to spend our time on reducing the number of transactions created rather than adding more. But my instinct is that the current protocol with an extra step for the six new transactions can be part of and appended to the delayed payout tx signing. The initial risk doesn't change, seller is on the hook. Protocol won't continue without the full tree of transactions completed. It might be good to let only Alice have the fully signed txA and only Bob have txB. That way blame can be attributed, although I'm not sure there is much value in attributing blame. The end result is a refund case which would've been the case if txP were broadcast anyway. |
This proposal would reduce the load on the arbitration system and thus the cost for the DAO. 15 of the last 20 cases for the Refund Agent have been due to disappearing traders. I see anything that can be automatic in software to be beneficial, and even more so if Bisq grows substantially. |
The number of transactions would only increase in the event that it will be used, otherwise they are just signed not broadcast txs... Once we see that its feasible to add to the current protocol we should think about how we implement it from a UX perspective. As its an exceptional case I would prefer to not confuse users with it as long its not needed... But thats another field we should get a bit deeper. |
It's one extra transaction if Alice tries to take the funds with txA and Bob has to publish txAP. The extra fees is not really a problem, but it would be a problem if one of these transactions don't get confirmed. In particular, if txAP don't confirm soon enough, then Alice can broadcast txAA and then spend that output with a high fee, CPFP. Let I suspect one more roundtrip, or half a roundtrip more will be needed, quick logic on it:
This is one round more. It could be shortened by one step by letting both parties have access to fully signed Alice could stop after step 3 when she has |
Hi @sqrrm thanks for the proposal. I am doing some housekeeping on the proposals. Please can you take steps to move this forward or alternatively close the proposal. Many thanks. |
This would be part of the #279 protocol, closing. |
Problem
Users are leaving funds locked up in the 2of2 and not responding to mediators. This forces the responsive party to spend the delayed payout tx, sending the funds to the donation address and taking the case to the refund agent. This adds a burden on the refund agent and the donation address holder, adds annoyance for the user and is costly for the DAO.
Current delayed payout
During trade initiation the buyer and seller send coins to a 2of2 multisig address, this is the deposit tx. They also sign a transaction that spends the output from the deposit tx to the donation address, the so called delayed payout tx. This transaction can only be spent after a certain block height.
Optional delayed spending scheme
Inspiration - lightning network
In the lightning network the setup is similar to Bisq's deposit tx, two parties, Alice and Bob, prepare spendable transactions from a 2of2 address. During normal operations these transactions are not broadcast, but they are used as a backup to motivate the counterparty to adhere to the rules of their lightning channel. If Bob disappears, Alice can spend one of these prepared transactions to cancel the channel and get her money back. Bob then has a time window to get his share before Alice can spend it all for herself.
Bisq case
For Bisq a similar scheme could be used in conjunction with the donation address.
This setup helps releasing funds to the users without going through the donation address in the cases where one party has disappeared. When both parties are active either one can broadcast txP to take the case to refund agent.
If Bob is not responsive, Alice can wait X+Y blocks to broadcast txA. If Bob is indeed gone, after another Z blocks she can then broadcast txAA to recover the funds. If Bob happens to be around, he can broadcast txAP before txAA can be spent to send the funds to donation address and continue with a refund case.
If Alice is not responsive Bob can do the same as Alice in the the previous case to recover the funds through the txB path.
Considerations
This adds an extra step in the non happy payout path. Not ideal when fees are increasing as they are. It also requires both parties to monitor for the personalized payout txs txA and txB respectively and spend to donation address if they don't want to lose the funds. This shouldn't be a big problem as txP could be broadcast earlier if they intended to take the case to refund agent. It's only a problem when one side is maliciously non responsive to try to steal the funds. A case which is handled and would not be possible to exploit.
The text was updated successfully, but these errors were encountered: