16
16
17
17
This BIP defines a structure for hierarchical deterministic P2SH multi-party
18
18
multi-signature wallets (HDPM wallets from now on) based on the algorithm
19
- described in BIP-0032 (BIP32 from now on) and purpose scheme described in
19
+ described in BIP-0032 (BIP32 from now on) and purpose scheme described in
20
20
BIP-0043 (BIP43 from now on).
21
21
This BIP is a particular application of BIP43.
22
22
@@ -63,7 +63,7 @@ Hardened derivation is used at this level.
63
63
The index of the party creating a P2SH multisig address. The indices can
64
64
be determined independently by lexicographically sorting the purpose public
65
65
keys of each cosigner. Each cosigner creates addresses on its own branch,
66
- even though they have independent extended master public key, as explained
66
+ even though they have independent extended master public key, as explained
67
67
in the "Address generation" section.
68
68
69
69
Note that the master public key is not shared amongst the cosigners. Only the
@@ -79,12 +79,12 @@ purpose public keys:
79
79
03f76588e06c0d688617ef365d1e58a7f1aa84daa3801380b1e7f12acc9a69cd13
80
80
</pre>
81
81
82
- it should use ` m / 45 ' / 0 / *` for
83
- ` 039863fb5f07b667d9b1ca68773c6e6cdbcac0088ffba9af46f6f6acd153d44463`,
84
- ` m / 45 ' / 1 / *` for
85
- ` 03a473275a750a20b7b71ebeadfec83130c014da4b53f1c4743fcf342af6589a38` ,
86
- and ` m / 45 ' / 2 / *` for
87
- ` 03f76588e06c0d688617ef365d1e58a7f1aa84daa3801380b1e7f12acc9a69cd13` ,
82
+ it should use <code> m / 45 ' / 0 / * </code> for
83
+ <code> 039863fb5f07b667d9b1ca68773c6e6cdbcac0088ffba9af46f6f6acd153d44463 </code>,
84
+ <code> m / 45 ' / 1 / * </code> for
85
+ <code> 03a473275a750a20b7b71ebeadfec83130c014da4b53f1c4743fcf342af6589a38 </code> ,
86
+ and <code> m / 45 ' / 2 / * </code> for
87
+ <code> 03f76588e06c0d688617ef365d1e58a7f1aa84daa3801380b1e7f12acc9a69cd13 </code> ,
88
88
as dictated by their lexicographical order.
89
89
90
90
@@ -102,7 +102,7 @@ chain is used for addresses which are not meant to be visible outside of the
102
102
wallet and is used for return transaction change.
103
103
104
104
For example, if cosigner 2 wants to generate a change address, he would use
105
- ` m / 45 ' / 2 / 1 / *` , and ` m / 45 ' / 2 / 0 / *` for a receive
105
+ <code> m / 45 ' / 2 / 1 / * </code> , and <code> m / 45 ' / 2 / 0 / * </code> for a receive
106
106
address.
107
107
108
108
Non-hardened derivation is used at this level.
@@ -118,7 +118,7 @@ Non-hardened derivation is used at this level.
118
118
Each party generates their own extended master keypair and shares the
119
119
extended purpose' public key with the others, which is stored encrypted.
120
120
Each party can generate any of the other's derived public keys, but only
121
- his own private keys.
121
+ his own private keys.
122
122
123
123
===Address Generation Procedure ===
124
124
When generating an address, each party can independently generate the N needed
@@ -137,18 +137,18 @@ others using the next index, and calculate the needed script for the address.
137
137
138
138
Example: Cosigner #2 wants to receive a payment to the shared wallet. His last
139
139
used index on his own branch is 4. Then, the path for the next receive
140
- address is ` m/45'/2/0/5` . He uses this same path in all of the cosigners
140
+ address is <code> m/45'/2/0/5 </code> . He uses this same path in all of the cosigners
141
141
trees to generate a public key for each one, and from that he gets the new
142
142
p2sh address.
143
143
====Change address case ====
144
144
Again, each cosigner generates addresses only on his own branch. One of the
145
145
n cosigners wants to create an outgoing payment, for which he'll need a change
146
146
address. He generates a new address using the same procedure as above, but
147
- using a separate index to track the used change addresses.
147
+ using a separate index to track the used change addresses.
148
148
149
149
Example: Cosigner #5 wants to send a payment from the shared wallet, for which
150
150
he'll need a change address. His last used change index on his own branch is
151
- 11. Then, the path for the next change address is ` m/45'/5/1/12` . He uses
151
+ 11. Then, the path for the next change address is <code> m/45'/5/1/12 </code> . He uses
152
152
this same path in all of the cosigners trees to generate a public key for each
153
153
one, and from that he gets the new p2sh address.
154
154
@@ -163,16 +163,16 @@ that specific address (using the same path that generated the public key in
163
163
that address, but deriving the private key instead), and sign it. Once the
164
164
proposal reaches m signatures, any cosigner can broadcast it to the network,
165
165
becoming final. The specifics of how this proposal is structured, and the
166
- protocol to accept or reject it, belong to another BIP, in my opinion.
166
+ protocol to accept or reject it, belong to another BIP, in my opinion.
167
167
168
168
===Address discovery ===
169
169
170
170
When the master seed is imported from an external source the software should
171
171
start to discover the addresses in the following manner:
172
172
173
173
# for each cosigner:
174
- # derive the cosigner's node (` m / 45' / cosigner_index` )
175
- # for both the external and internal chains on this node (` m / 45' / cosigner_index / 0` and ` m / 45' / cosigner_index / 1` ):
174
+ # derive the cosigner's node (<code> m / 45' / cosigner_index </code> )
175
+ # for both the external and internal chains on this node (<code> m / 45' / cosigner_index / 0 </code> and <code> m / 45' / cosigner_index / 1 </code> ):
176
176
# scan addresses of the chain; respect the gap limit described below
177
177
178
178
Please note that the algorithm uses the transaction history, not address
@@ -182,7 +182,7 @@ even if the earlier ones don't have transactions
182
182
183
183
===Address gap limit ===
184
184
185
- Address gap limit is currently set to 20. If the software hits 20 unused
185
+ Address gap limit is currently set to 20. If the software hits 20 unused
186
186
addresses (no transactions associated with that address) in a row, it expects
187
187
there are no used addresses beyond this point and stops searching the address chain.
188
188
@@ -198,7 +198,7 @@ parties. Here are some explanations about the design decisions made.
198
198
The reason for using separate branches for each cosigner is we don't want
199
199
two of them generating the same address and receiving simultaneous payments
200
200
to it. The ideal case is that each address receives at most one payment,
201
- requested by the corresponding cosigner.
201
+ requested by the corresponding cosigner.
202
202
203
203
==Examples ==
204
204
0 commit comments