Post
Topic
Board Beginners & Help
Merits 1 from 1 user
Re: Collisions on private addresses? Balances?
by
PowerGlove
on 30/06/2022, 02:22:42 UTC
⭐ Merited by nc50lc (1)
Hi, is the hash 160 for legacy addresses?

That's a little beside the point. As nc50lc said, if you want to be able spend what you find, then you need to search the "private key" space and not the "address" space.

Let's consider "legacy" P2PKH addresses for the moment. To create one you have to choose a number between 1 and 115792089237316195423570985008687907852837564279074904382605163141518161494336.

Then you take this number and do some irreversible math on it (elliptic curve cryptography) to produce another number.

Then you take this number and do some more irreversible math on it (cryptographic hash) to produce the final "address".

If you try to search for non-empty addresses by "cheating" and not doing the full address derivation, then when you find an address that has money in it, you won't be able to spend it (because you don't have the first number, the private key).

The figures above are quoted to cycle through the entire range of addresses from start to finish.

No, those figures are for illustrating how much harder searching a space gets as you add bits. The takeaway should be that if you can search a 2^160 space in 9 days, then searching a 2^256 space will take you roughly 2 octillion years (~140 quadrillion times longer than the age of the universe).

It may be a case that your my particular address gets cycled in the first hour.

That's true, but 2^256 is a massive search space. It's tempting to visualize it as a line and think that there "must" be some addresses near the beginning of that line, but with a space this big "near" can still be really, really far. If you've selected your private key at random, you have nothing to worry about.