1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
|
Received: from sog-mx-3.v43.ch3.sourceforge.com ([172.29.43.193]
helo=mx.sourceforge.net)
by sfs-ml-3.v29.ch3.sourceforge.com with esmtp (Exim 4.76)
(envelope-from <luke@dashjr.org>) id 1RY2Yz-0003xO-7i
for bitcoin-development@lists.sourceforge.net;
Tue, 06 Dec 2011 21:28:33 +0000
X-ACL-Warn:
Received: from zinan.dashjr.org ([173.242.112.54])
by sog-mx-3.v43.ch3.sourceforge.com with esmtp (Exim 4.76)
id 1RY2Yw-0001Fm-1o for bitcoin-development@lists.sourceforge.net;
Tue, 06 Dec 2011 21:28:33 +0000
Received: from ishibashi.localnet (fl-184-4-160-40.dhcp.embarqhsd.net
[184.4.160.40]) (Authenticated sender: luke-jr)
by zinan.dashjr.org (Postfix) with ESMTPSA id EA5052042A8
for <bitcoin-development@lists.sourceforge.net>;
Tue, 6 Dec 2011 21:28:22 +0000 (UTC)
From: "Luke-Jr" <luke@dashjr.org>
To: bitcoin-development@lists.sourceforge.net
Date: Tue, 6 Dec 2011 16:28:16 -0500
User-Agent: KMail/1.13.7 (Linux/3.1.0-gentoo; KDE/4.6.5; x86_64; ; )
References: <201112061610.41083.luke@dashjr.org>
In-Reply-To: <201112061610.41083.luke@dashjr.org>
X-PGP-Key-Fingerprint: CE5A D56A 36CC 69FA E7D2 3558 665F C11D D53E 9583
X-PGP-Key-ID: 665FC11DD53E9583
X-PGP-Keyserver: x-hkp://subkeys.pgp.net
MIME-Version: 1.0
Content-Type: Text/Plain;
charset="iso-8859-1"
Content-Transfer-Encoding: 7bit
Message-Id: <201112061628.18634.luke@dashjr.org>
X-Spam-Score: -1.2 (-)
X-Spam-Report: Spam Filtering performed by mx.sourceforge.net.
See http://spamassassin.org/tag/ for more details.
-1.2 RP_MATCHES_RCVD Envelope sender domain matches handover relay
domain 0.0 AWL AWL: From: address is in the auto white-list
X-Headers-End: 1RY2Yw-0001Fm-1o
Subject: Re: [Bitcoin-development] Version bytes "2.0"
X-BeenThere: bitcoin-development@lists.sourceforge.net
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: <bitcoin-development.lists.sourceforge.net>
List-Unsubscribe: <https://lists.sourceforge.net/lists/listinfo/bitcoin-development>,
<mailto:bitcoin-development-request@lists.sourceforge.net?subject=unsubscribe>
List-Archive: <http://sourceforge.net/mailarchive/forum.php?forum_name=bitcoin-development>
List-Post: <mailto:bitcoin-development@lists.sourceforge.net>
List-Help: <mailto:bitcoin-development-request@lists.sourceforge.net?subject=help>
List-Subscribe: <https://lists.sourceforge.net/lists/listinfo/bitcoin-development>,
<mailto:bitcoin-development-request@lists.sourceforge.net?subject=subscribe>
X-List-Received-Date: Tue, 06 Dec 2011 21:28:33 -0000
Some bugs I found in my spec so far:
- Bitcoin public keys begin with '2' (same as testnet data)
- For the first first-class "aux" network, signatures and private keys will
start with the same character.
- More "collisions" are possible if the "reserved" values were ever assigned.
To address these slightly better, here's a revised proposal:
* Bits 128/64 define network class
** 0 = main network
** 64,128 = reserved
** 192 = test network
* Bits 32/16 define network
** 0 = Bitcoin
** 16,32 = reserved
** 48 = OTHER (next octet)
* Bits 8/4/2 define data class
** 0 = Public key hash
** 2 = reserved
** 4 = Script hash
** 6 = Public key (raw)
** 8 = Signature
** 10 = reserved
** 12 = Private key (raw)
** 14 = OTHER (next octet)
* Bit 1 is freely chosen (for aesthetic assignment)
Note that under this scheme, both script hashes and raw public keys begin with
'3'; I consider this a non-issue since neither are supported by current-
generation clients, and both pubkey-hash and script-hash are quite capable of
the same functionality as a raw public key. Also, the raw public key will
presumably be noticably longer.
For reference, a table of version number to first-base58-char mappings:
+........ 0 => 1
-.......1 1 => QRSTUVWXYZabcdefghijkmno
-......1. 2 => 2opqrstuvwxyz
+......11 3 => 2
-.....1.. 4 => 23
+.....1.1 5 => 3
+.....11. 6 => 3
-.....111 7 => 34
+....1... 8 => 4
-....1..1 9 => 45
+....1.1. 10 => 5
+....1.11 11 => 5
-....11.. 12 => 56
+....11.1 13 => 6
-....111. 14 => 67
+....1111 15 => 7
+...1.... 16 => 7
-...1...1 17 => 78
+...1..1. 18 => 8
-...1..11 19 => 89
+...1.1.. 20 => 9
+...1.1.1 21 => 9
-...1.11. 22 => 9A
+...1.111 23 => A
-...11... 24 => AB
+...11..1 25 => B
+...11.1. 26 => B
-...11.11 27 => BC
+...111.. 28 => C
-...111.1 29 => CD
+...1111. 30 => D
+...11111 31 => D
-..1..... 32 => DE
+..1....1 33 => E
-..1...1. 34 => EF
+..1...11 35 => F
+..1..1.. 36 => F
-..1..1.1 37 => FG
+..1..11. 38 => G
-..1..111 39 => GH
+..1.1... 40 => H
+..1.1..1 41 => H
-..1.1.1. 42 => HJ
+..1.1.11 43 => J
-..1.11.. 44 => JK
+..1.11.1 45 => K
+..1.111. 46 => K
-..1.1111 47 => KL
+..11.... 48 => L
-..11...1 49 => LM
+..11..1. 50 => M
+..11..11 51 => M
-..11.1.. 52 => MN
+..11.1.1 53 => N
-..11.11. 54 => NP
+..11.111 55 => P
+..111... 56 => P
-..111..1 57 => PQ
+..111.1. 58 => Q
-..111.11 59 => QR
+..1111.. 60 => R
+..1111.1 61 => R
-..11111. 62 => RS
+..111111 63 => S
-.1...... 64 => ST
+.1.....1 65 => T
+.1....1. 66 => T
-.1....11 67 => TU
+.1...1.. 68 => U
-.1...1.1 69 => UV
+.1...11. 70 => V
+.1...111 71 => V
-.1..1... 72 => VW
+.1..1..1 73 => W
-.1..1.1. 74 => WX
+.1..1.11 75 => X
+.1..11.. 76 => X
-.1..11.1 77 => XY
+.1..111. 78 => Y
-.1..1111 79 => YZ
+.1.1.... 80 => Z
+.1.1...1 81 => Z
-.1.1..1. 82 => Za
+.1.1..11 83 => a
-.1.1.1.. 84 => ab
+.1.1.1.1 85 => b
-.1.1.11. 86 => bc
+.1.1.111 87 => c
+.1.11... 88 => c
-.1.11..1 89 => cd
+.1.11.1. 90 => d
-.1.11.11 91 => de
+.1.111.. 92 => e
+.1.111.1 93 => e
-.1.1111. 94 => ef
+.1.11111 95 => f
-.11..... 96 => fg
+.11....1 97 => g
+.11...1. 98 => g
-.11...11 99 => gh
+.11..1.. 100 => h
-.11..1.1 101 => hi
+.11..11. 102 => i
+.11..111 103 => i
-.11.1... 104 => ij
+.11.1..1 105 => j
-.11.1.1. 106 => jk
+.11.1.11 107 => k
+.11.11.. 108 => k
-.11.11.1 109 => km
+.11.111. 110 => m
-.11.1111 111 => mn
+.111.... 112 => n
+.111...1 113 => n
-.111..1. 114 => no
+.111..11 115 => o
-.111.1.. 116 => op
+.111.1.1 117 => p
+.111.11. 118 => p
-.111.111 119 => pq
+.1111... 120 => q
-.1111..1 121 => qr
+.1111.1. 122 => r
+.1111.11 123 => r
-.11111.. 124 => rs
+.11111.1 125 => s
-.111111. 126 => st
+.1111111 127 => t
+1....... 128 => t
-1......1 129 => tu
+1.....1. 130 => u
-1.....11 131 => uv
+1....1.. 132 => v
+1....1.1 133 => v
-1....11. 134 => vw
+1....111 135 => w
-1...1... 136 => wx
+1...1..1 137 => x
+1...1.1. 138 => x
-1...1.11 139 => xy
+1...11.. 140 => y
-1...11.1 141 => yz
+1...111. 142 => z
+1...1111 143 => z
-1..1.... 144 => 2z
+1..1...1 145 => 2
+1..1..1. 146 => 2
+1..1..11 147 => 2
+1..1.1.. 148 => 2
+1..1.1.1 149 => 2
+1..1.11. 150 => 2
+1..1.111 151 => 2
+1..11... 152 => 2
+1..11..1 153 => 2
+1..11.1. 154 => 2
+1..11.11 155 => 2
+1..111.. 156 => 2
+1..111.1 157 => 2
+1..1111. 158 => 2
+1..11111 159 => 2
+1.1..... 160 => 2
+1.1....1 161 => 2
+1.1...1. 162 => 2
+1.1...11 163 => 2
+1.1..1.. 164 => 2
+1.1..1.1 165 => 2
+1.1..11. 166 => 2
+1.1..111 167 => 2
+1.1.1... 168 => 2
+1.1.1..1 169 => 2
+1.1.1.1. 170 => 2
+1.1.1.11 171 => 2
+1.1.11.. 172 => 2
+1.1.11.1 173 => 2
+1.1.111. 174 => 2
+1.1.1111 175 => 2
+1.11.... 176 => 2
+1.11...1 177 => 2
+1.11..1. 178 => 2
+1.11..11 179 => 2
+1.11.1.. 180 => 2
+1.11.1.1 181 => 2
+1.11.11. 182 => 2
+1.11.111 183 => 2
+1.111... 184 => 2
+1.111..1 185 => 2
+1.111.1. 186 => 2
+1.111.11 187 => 2
+1.1111.. 188 => 2
+1.1111.1 189 => 2
+1.11111. 190 => 2
+1.111111 191 => 2
+11...... 192 => 2
+11.....1 193 => 2
+11....1. 194 => 2
+11....11 195 => 2
+11...1.. 196 => 2
+11...1.1 197 => 2
+11...11. 198 => 2
+11...111 199 => 2
+11..1... 200 => 2
+11..1..1 201 => 2
+11..1.1. 202 => 2
+11..1.11 203 => 2
+11..11.. 204 => 2
+11..11.1 205 => 2
+11..111. 206 => 2
+11..1111 207 => 2
+11.1.... 208 => 2
+11.1...1 209 => 2
+11.1..1. 210 => 2
+11.1..11 211 => 2
+11.1.1.. 212 => 2
+11.1.1.1 213 => 2
+11.1.11. 214 => 2
+11.1.111 215 => 2
+11.11... 216 => 2
+11.11..1 217 => 2
+11.11.1. 218 => 2
+11.11.11 219 => 2
+11.111.. 220 => 2
+11.111.1 221 => 2
+11.1111. 222 => 2
+11.11111 223 => 2
+111..... 224 => 2
+111....1 225 => 2
+111...1. 226 => 2
+111...11 227 => 2
+111..1.. 228 => 2
+111..1.1 229 => 2
+111..11. 230 => 2
+111..111 231 => 2
+111.1... 232 => 2
+111.1..1 233 => 2
+111.1.1. 234 => 2
+111.1.11 235 => 2
+111.11.. 236 => 2
+111.11.1 237 => 2
+111.111. 238 => 2
+111.1111 239 => 2
+1111.... 240 => 2
+1111...1 241 => 2
+1111..1. 242 => 2
+1111..11 243 => 2
+1111.1.. 244 => 2
+1111.1.1 245 => 2
+1111.11. 246 => 2
+1111.111 247 => 2
+11111... 248 => 2
+11111..1 249 => 2
+11111.1. 250 => 2
+11111.11 251 => 2
+111111.. 252 => 2
+111111.1 253 => 2
+1111111. 254 => 2
+11111111 255 => 2
|