Author

Topic: Why does blockchain.info let me import an invalid WIF private key? (Read 4470 times)

legendary
Activity: 3472
Merit: 4801
WIF has a checksum, Base 58 does not.

Can anyone point me to the spec on this? I just keep finding Base58 specs that *do* include 4 byte checksums e.g.

https://en.bitcoin.it/wiki/Base58Check_encoding

That is Base58Check encoding.  That is Wallet Import Format (WIF).

Base 58 itself (not base58check) is just a numbering system with a radix of 58 (like binary has a radix of 2, octal a radix of 8, hexadecimal a radix of 16, decimal a radix of 10, etc.)

Are there such things as Base58 checkless keys?

Yes.  When it is not in WIF, a private key is just a very big number.  Any number between 0x1 and 0xFFFF FFFF FFFF FFFF FFFF FFFF FFFF FFFE BAAE DCE6 AF48 A03B BFD2 5E8C D036 4141 is a valid private key.  Using base 58 simply allows you to represent that number with fewer digits (making it easier to type/write).
sr. member
Activity: 261
Merit: 285
WIF has a checksum, Base 58 does not.

Can anyone point me to the spec on this? I just keep finding Base58 specs that *do* include 4 byte checksums e.g.

https://en.bitcoin.it/wiki/Base58Check_encoding

Are there such things as Base58 checkless keys?
legendary
Activity: 3472
Merit: 4801
It's a bug with the pk format detection. The Key is no longer a valid WIF key however it is still a valid base 58 key so the key is imported as base 58 instead.
But if I was randomly futzing around with the digits, shouldn't this fail as a valid base 58 of any kind, since the checksums won't add up?

WIF has a checksum, Base 58 does not.
sr. member
Activity: 261
Merit: 285
It's a bug with the pk format detection. The Key is no longer a valid WIF key however it is still a valid base 58 key so the key is imported as base 58 instead.

But if I was randomly futzing around with the digits, shouldn't this fail as a valid base 58 of any kind, since the checksums won't add up?
hero member
Activity: 910
Merit: 1005
It's a bug with the pk format detection. The Key is no longer a valid WIF key however it is still a valid base 58 key so the key is imported as base 58 instead.
sr. member
Activity: 261
Merit: 285
Because here's the thing, if I click to import a private wallet, and then type in a valid wallet import key, but then intentionally mess up five or six of the characters, blockchain.info still reassures me that it imported the wallet.

Isn't there supposed to be a WIF wallet import format checksum or something that would alert you if you'd made a typo?

Jump to: