vbuterin / pybitcointools

SImple, common-sense Bitcoin-themed Python ECC library
1.3k stars 861 forks source link

base10 encoding/decoding broken #45

Closed qubez closed 9 years ago

qubez commented 9 years ago

Commit 32c454c85bac93e135b9afbe8fcc11d02520d403 (pep8) made a big bug.

code_strings = { 2: '01', 10: '012356789', 16: '0123456789abcdef',

the 4 is missing in base10, causing incorrect encoding and decoding.

bitcoin.decode('444',10) -111 bitcoin.decode('555',10) 444

vbuterin commented 9 years ago

Fixed.