Author

Topic: Question about multisignature (Read 88 times)

legendary
Activity: 2702
Merit: 4002
April 16, 2022, 04:55:41 AM
#5
You can follow this for more info ---> https://gist.github.com/anonymous/7211362 with this Scenario
Quote
Archey wants to pay Bertha 0.001 BTC for a Twitter Platinum invite, but prevent Bertha from cheating him. Archey selects Iceland to act as a neutral mediator in case something unexpected happens.

multisignature addresses are not intended to be ready made escrow addresses but to distribute the ability to control who "sends money" from one pvt key to several keys so on a simple level they can be used but for commercial use, it's best to hire a developer to start from scratch.
legendary
Activity: 3472
Merit: 10611
April 16, 2022, 02:31:23 AM
#4
This sounds like an escrow situation where the third party (or the escrow) receives their commission. This can't be automated and the 3 parties all have to agree on the rate.
You'd usually use a 2 of 3 scheme with each party having one key. Then the escrow and the sender sign the transaction to be sent out.
This is the easy way of doing it but as @NeuroticFish said the payment to escrow can not be enforced this way since the sender and receiver can also bypass the escrow and complete the transaction.

However, a more advanced way could be implemented to ensure the escrow receives his cut but it is not possible using Electrum. In this method you have to use the bitcoin smart contract capabilities through conditionals. The following script one of the ways to do it:
Code:
 OP_CHECKSIG
OP_IF
  
OP_ELSE
  
OP_ENDIF
OP_CHECKSIG
This way the escrow must always be one of the parties that signs the tx and only one of the other parties (sender OR receiver) has to be the other one signing the tx.

There is a problem with the above script which is if the escrow decided to not sign the tx, the other two can not do anything about it! We could make this script a little more complicated by adding a timelock which would remove this problem but the initial issue will rise again that the two parties could bypass the escrow after the locktime was reached.

Code:
OP_IF
 
Note that this is non-standard because of OP_1 (invalid pubkey).

P.S. You can and should test these things on testnet.
legendary
Activity: 3668
Merit: 6382
Looking for campaign manager? Contact icopress!
April 16, 2022, 01:34:06 AM
#3
Hello everyone.
I am learning about multisig and am planning to use electrum wallet.
I wanted to know how should i make it possible that from one transaction 2 parties get a % of the btc
Example : User 1 buys something from User 2 for 1 BTC, User 3 needs a 5% cut from the transaction as he helped making it happen. How does he get the 5% ?
Sorry for the bad english and thank you.

1. Multisig is not about getting a cut. Multisig is for wallet/funds security. In the same way there are multiple keys needed to allow launching a nuke, a multisig wallet allows spending funds only if multiple keys sign the transaction. So it's not related to your use case.

2. When a Bitcoin transaction is made/sent, usually the sender creates it and the receiver can check if he got the funds.
From what I know there is no such feature to create an invoice sending various amounts of funds to various addresses and it would make no sense either, since the buyer/sender could easily bypass the invoice, send the funds only to seller's address and the seller will be happy to release the goods/services.
So if you want to do something like this on your platform you'll have to implement it yourself and you can (and should) also act like an escrow. The buyer will send the full amount of funds to you and after the buyer has received the goods you send (as a new transaction) the payment to the seller, also keeping your cut for yourself.
legendary
Activity: 1512
Merit: 7340
Farewell, Leo
April 16, 2022, 01:27:00 AM
#2
Do user 1 and user 2 have a multi-sig address shared with user 3? I don't see a reason to have them paid for "making it happen" unless they routed the transaction and/or used their sending and receiving capacity to accomplishing the transaction.

Perhaps you need to clear up what exactly you want to achieve.
newbie
Activity: 1
Merit: 3
April 16, 2022, 01:12:00 AM
#1
Hello everyone.
I am learning about multisig and am planning to use electrum wallet.
I wanted to know how should i make it possible that from one transaction 2 parties get a % of the btc
Example : User 1 buys something from User 2 for 1 BTC, User 3 needs a 5% cut from the transaction as he helped making it happen. How does he get the 5% ?
Sorry for the bad english and thank you.
Jump to: