Bitcoin Forum
May 06, 2024, 02:02:19 PM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: Question about multisignature  (Read 79 times)
rab1040 (OP)
Newbie
*
Offline Offline

Activity: 1
Merit: 3


View Profile
April 16, 2022, 06:12:00 AM
Merited by DdmrDdmr (3)
 #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.
"Your bitcoin is secured in a way that is physically impossible for others to access, no matter for what reason, no matter how good the excuse, no matter a majority of miners, no matter what." -- Greg Maxwell
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
BlackHatCoiner
Legendary
*
Online Online

Activity: 1512
Merit: 7353


Farewell, Leo


View Profile
April 16, 2022, 06: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.

.
.HUGE.
▄██████████▄▄
▄█████████████████▄
▄█████████████████████▄
▄███████████████████████▄
▄█████████████████████████▄
███████▌██▌▐██▐██▐████▄███
████▐██▐████▌██▌██▌██▌██
█████▀███▀███▀▐██▐██▐█████

▀█████████████████████████▀

▀███████████████████████▀

▀█████████████████████▀

▀█████████████████▀

▀██████████▀▀
█▀▀▀▀











█▄▄▄▄
▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
.
CASINSPORTSBOOK
▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄
▀▀▀▀█











▄▄▄▄█
NeuroticFish
Legendary
*
Offline Offline

Activity: 3668
Merit: 6379


Looking for campaign manager? Contact icopress!


View Profile
April 16, 2022, 06:34:06 AM
Merited by o_e_l_e_o (4), pooya87 (2), ABCbits (2), hosseinimr93 (2), DdmrDdmr (2)
 #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.

.
.HUGE.
▄██████████▄▄
▄█████████████████▄
▄█████████████████████▄
▄███████████████████████▄
▄█████████████████████████▄
███████▌██▌▐██▐██▐████▄███
████▐██▐████▌██▌██▌██▌██
█████▀███▀███▀▐██▐██▐█████

▀█████████████████████████▀

▀███████████████████████▀

▀█████████████████████▀

▀█████████████████▀

▀██████████▀▀
█▀▀▀▀











█▄▄▄▄
▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
.
CASINSPORTSBOOK
▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄
▀▀▀▀█











▄▄▄▄█
pooya87
Legendary
*
Offline Offline

Activity: 3444
Merit: 10550



View Profile
April 16, 2022, 07:31:23 AM
Merited by NeuroticFish (4), o_e_l_e_o (4), ABCbits (2), hosseinimr93 (2), DdmrDdmr (2)
 #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:
<escrow's pubkey> OP_CHECKSIG
OP_IF
  <sender pubkey>
OP_ELSE
  <receiver pubkey>
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
  <time> OP_CLV OP_DROP
  OP_2 OP_1
OP_ELSE
  OP_2 <escrow pubkey>
OP_ENDIF
<sender pubkey> <receiver pubkey> OP_3 OP_CHECKMULTISIGVERIFY
Note that this is non-standard because of OP_1 (invalid pubkey).

P.S. You can and should test these things on testnet.

.
.BLACKJACK ♠ FUN.
█████████
██████████████
████████████
█████████████████
████████████████▄▄
░█████████████▀░▀▀
██████████████████
░██████████████
████████████████
░██████████████
████████████
███████████████░██
██████████
CRYPTO CASINO &
SPORTS BETTING
▄▄███████▄▄
▄███████████████▄
███████████████████
█████████████████████
███████████████████████
█████████████████████████
█████████████████████████
█████████████████████████
███████████████████████
█████████████████████
███████████████████
▀███████████████▀
█████████
.
hugeblack
Legendary
*
Offline Offline

Activity: 2506
Merit: 3647


Buy/Sell crypto at BestChange


View Profile WWW
April 16, 2022, 09: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.

.BEST..CHANGE.███████████████
██
██
██
██
██
██
██
██
██
██
██
██
██
██
██
██
██
██
██
██
██
██
██
██
███████████████
..BUY/ SELL CRYPTO..
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!