Author

Topic: Multisig transactions with more than 2-of-3 (Read 1183 times)

legendary
Activity: 1260
Merit: 1019
Quote
There are various benefits to doing small open source tools.
Sorry, right now my code is not a "small tool" but piece of big bullshit project.
Yes, it is able to dump all P2SH addresses (~23200..23300) and decode some of them (not all addresses can be decoded)
I need time to separate this from all other code to do a really "small tool". But I do not want to spend time now.
Anyway, you can speak with my wife and tell her about benefits of open-source Smiley
full member
Activity: 518
Merit: 101
> My wife disallows me to write freeware.
> PM me for more details if you want.

And how well is it going so far?

There are various benefits to doing small open source tools. You gain publicity, you can meet other interesting programmers, get involved in cool projects, etc. Saying "I don't share my code for free" is a bit like saying "I don't share my thoughts for free".

I'd argue that you stand to gain far more by sharing small scripts like this, than you could by charging money. You'll be earning thousands of dollars on your scripts, and losing tens of thousands on opportunities you'd get otherwise.
legendary
Activity: 1260
Merit: 1019
Care to share the tool?
Sorry, not for free.
My wife disallows me to write freeware.
PM me for more details if you want.
full member
Activity: 518
Merit: 101
Care to share the tool?

By the way, why the interest in more than 2 of 3?
legendary
Activity: 1260
Merit: 1019
Today I've written a small tool which dumps all P2SH addresses from blockchain
Something like this:

Code:
[...]
3CUgLbAQUoJV4Bea3gNUAprcg7rsMeejHN msig  1-of-1 { 1K7eMkbrNjbaiPWZjhKz9Nf5RAc8XvqHC3 }
3FH2jvRApWBaMckuuxJLrB2DwQmcrocMAe msig  1-of-2 { 1BNAjfnBV1y8vAwciekFM8KPxFph5mdzgv, 12rRqgQyw2rShyaTQtoj9FwUaFmuaiU3Pz }
3Hqy8mN46HcMo34z1DYMrXiKjPre181fQm msig  3-of-4 { 1GxLcaoRvhhDQkrntHCvarDkiNxBoyjTcC, 13rjSt92G4KXnmwi9z5zfp6dSieZ2eYeDU, 16GTkGJyQdi2QtLCkYmmYFpg2e82g7eaU8, 16ZMUYtAJF8sN91DHBtPDWSfpEvXvFoSyW }
3E3edFtWarsnztYDgTF5qoETE6WVkEr5Kg msig  5-of-10 { 1Ps6Mso99vgXAvhr6ZstojMhtnpJrCJ1Kt, 1L9jD3c8uU3B7Wx5bpRE2Y4DifgMRNz7Je, 16FPYkAXNTxcVsTWsjvYKMhmN2yXfJKuuQ, 1BnzzPAs35rE6sSFAgqbdUFFVDdZB3zi3s, 1827Jif4vLsoh34AK8RLiLZXCKkhdZUbhp, 1AvuyQ4qQEUA45hRuHyEbHm2ocRMrPKbPG, 1MH2JQazifaYWj7nu7Dy3mJd49oALdbC96, 1DLDdEc2B7E5T7zSdH95g2unKxdnCLwVb1, 1L6u2HEddyZSmZ2zWnAo1xtLkDvp6ZCLX9, 1N7uYBVL6ENAV2Xx1oLPgURZueD9QnDY4Q }
3QFAvLouP3Zpbzmx9pXSHZMfsZ9gq8yaB2 msig  6-of-10 { 1BsV7jWXsEHaAYSwtXPGjzUFN8rKP98ZWT, 1HK4Xdz9X2uX4eXi1DNRwz2keKGc3cJTkj, 15s8akPKrXoVahikp1cGrs48NQV1ygByVi, 1DuGR4aiVN7SWqcp1HXX8AYrH1XPegq7KA, 19oqXpZSd2DPwC81ZVCxhPVvKgSsv1X8x8, 1GtwFQVuP7mrNkEjdSMBvBFGbnBGcTPkUr, 1LVb6dgpyQvmdYc2vfVhW9QjQ92gJ1BQdf, 18TtEFkrho2PPt5a92QzicsW469skxv6Tv, 1HdKKeCNX7heUZ2yQ4W2CQezY6CvWkNmkT, 1NaixJe3Tkjc6Twr2qRUbdSMvp6nJfJaQu }
[...]
full member
Activity: 518
Merit: 101
Ah, we were going through exactly the same problem with our distributed oracles implementation. Ultimately we pushed 8 of 15 through Eligius pool two weeks ago. Still haven't implemented the compressed keys, which should bring the transaction size down - just like Edmund said.

You might want to check our github repo: http://github.com/orisi/orisi to see how it's all being implemented. (and http://orisi.org for details about the project)
sr. member
Activity: 352
Merit: 250
https://www.realitykeys.com
Thanks for your answers.

So if I understand correctly, I should currently be able to use... let's say a 4 of 7 address using P2SH right?

I just want to make sure I'm not going to start implementing something that's going to produce transactions that will end up being rejected by the network Smiley

Yes, you understand correctly. Implement away...

Make sure to use compressed keys, and watch out for those redeem script size limits if you go higher than 4/7, because since the network doesn't know what's in your redeem script until you try to redeem it, so it'll merrily let you fund a P2SH address that you'll never actually be able to spend...
newbie
Activity: 14
Merit: 0
Thanks for your answers.

So if I understand correctly, I should currently be able to use... let's say a 4 of 7 address using P2SH right?

I just want to make sure I'm not going to start implementing something that's going to produce transactions that will end up being rejected by the network Smiley
donator
Activity: 1218
Merit: 1079
Gerald Davis
It is important to distinguish between "native multisig" (the output contains the actual script) and P2SH (the output contains a hash of the script).

The former is limited to 3 of 3 (and honestly even if you only need 2 of 3 there is very little reason to use it over P2SH).  The later as pointed out above is constrained by the 520 byte limit on the size of the redeemscript.  It is a max of 15 keys but only if all the keys are compressed.   If using uncompressed keys they are twice as big so you will be able to use less.   There is also a 500 byte soft ( IsStandard() ) limit on the scriptSig which means the m is going to be less or the tx will not be relayed by default (but it is still valid unlike the redeemScript being over 520 bytes).   
sr. member
Activity: 345
Merit: 250
From:
https://github.com/bitcoin/bips/blob/master/bip-0016.mediawiki
Quote
For instance while the OP_CHECKMULTISIG opcode can itself accept up to 20 pubkeys, with 33-byte compressed pubkeys it is only possible to spend a P2SH output requiring a maximum of 15 pubkeys to redeem: 3 bytes + 15 pubkeys * 34 bytes/pubkey = 513 bytes.
newbie
Activity: 14
Merit: 0
Hey guys,

I saw that the network was supporting only 2-of-3 multisig transactions.
Is there a reason behind this choice? I think I read somewhere that the hard limit was 16.

Cheers.
Jump to: