Bitcoin Forum
October 23, 2018, 02:15:39 AM *
News: Make sure you are not using versions of Bitcoin Core other than 0.17.0 [Torrent], 0.16.3, 0.15.2, or 0.14.3. More info.
 
   Home   Help Search Donate Login Register  
Pages: [1]
  Print  
Author Topic: How many possibly bitcoin addresses are there exactly? And how long does it...  (Read 45069 times)
gigabytecoin
Sr. Member
****
Offline Offline

Activity: 280
Merit: 250


View Profile
June 29, 2011, 10:00:18 AM
 #1

How many possibly bitcoin addresses are there exactly?

How long does it take to generate one?
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction. Advertise here.
1540260939
Hero Member
*
Offline Offline

Posts: 1540260939

View Profile Personal Message (Offline)

Ignore
1540260939
Reply with quote  #2

1540260939
Report to moderator
1540260939
Hero Member
*
Offline Offline

Posts: 1540260939

View Profile Personal Message (Offline)

Ignore
1540260939
Reply with quote  #2

1540260939
Report to moderator
FreeMoney
Legendary
*
Offline Offline

Activity: 1246
Merit: 1001


Strength in numbers


View Profile WWW
June 29, 2011, 10:05:03 AM
 #2

I heard 2^160.

A fast setup could do thousands each second.

Play Bitcoin Poker at sealswithclubs.eu. We're active and open to everyone.
JoelKatz
Legendary
*
Offline Offline

Activity: 1582
Merit: 1004


Democracy is vulnerable to a 51% attack.


View Profile WWW
June 29, 2011, 03:21:07 PM
 #3

And if you're thinking what I think you're thinking, remember that you don't actually have to find their private key to claim someone else's bitcoins. All you have to do is find any one of the roughly 2^96 private keys whose corresponding public key hashes to that address.

I am an employee of Ripple. Follow me on Twitter @JoelKatz
1Joe1Katzci1rFcsr9HH7SLuHVnDy2aihZ BM-NBM3FRExVJSJJamV9ccgyWvQfratUHgN
kjj
Legendary
*
Offline Offline

Activity: 1302
Merit: 1001



View Profile
June 29, 2011, 11:06:30 PM
 #4

There are exactly 2^160 possible addresses as long as we keep using RIPE-MD160.

2^160 is 1,461,501,637,330,902,918,203,684,832,716,283,019,655,932,542,976.

17Np17BSrpnHCZ2pgtiMNnhjnsWJ2TMqq8
I routinely ignore posters with paid advertising in their sigs.  You should too.
Rob P.
Member
**
Offline Offline

Activity: 84
Merit: 10



View Profile WWW
June 29, 2011, 11:12:01 PM
 #5

The total address space is 2^160

To put that in perspective, there are only 2^63 grains of sand on all of the beaches of the Earth (http://www.hawaii.edu/suremath/jsand.html)

Before you run out and build an RPC program to generate addresses, do some math first.

Or read this:  http://forum.bitcoin.org/index.php?topic=1387.0

The total pool of Bitcoin addresses in use is so minuscule compared to the total population of addresses you *could* create, that the odds of you creating a private key for an address that is already in use is so small (near zero), that you'd be better off just writing malware to infect computers and just steal them.

--

If you like what I've written here, consider tipping the messenger:
1GZu4CtHa6ai8iWoWiVFxV5VVoNte4SkoG

If you don't like what I've written, send me a Tip and I'll stop talking.
Ian Maxwell
Full Member
***
Offline Offline

Activity: 140
Merit: 100



View Profile WWW
June 30, 2011, 05:48:01 AM
 #6

A more profitable way to make money from generating random numbers would be the state lottery.

Ian Maxwell
PGP key | WoT rating
gigabytecoin
Sr. Member
****
Offline Offline

Activity: 280
Merit: 250


View Profile
June 30, 2011, 08:53:43 PM
 #7

And if you're thinking what I think you're thinking, remember that you don't actually have to find their private key to claim someone else's bitcoins. All you have to do is find any one of the roughly 2^96 private keys whose corresponding public key hashes to that address.

Ok so for somebody to be lucky enough to steal the bitcoins out of my main backup address...

They first need to generate my address which could be any one of 2^160 possibilities. And then they must generate the corresponding public key that gives them access to the bitcoins in my address? Of where there at 2^96 possibilities?

Or must they simple generate 2^96 bitcoin keys... at which point they would control every single bitcoin address in the world?
JoelKatz
Legendary
*
Offline Offline

Activity: 1582
Merit: 1004


Democracy is vulnerable to a 51% attack.


View Profile WWW
July 01, 2011, 12:35:02 AM
 #8

And if you're thinking what I think you're thinking, remember that you don't actually have to find their private key to claim someone else's bitcoins. All you have to do is find any one of the roughly 2^96 private keys whose corresponding public key hashes to that address.

Ok so for somebody to be lucky enough to steal the bitcoins out of my main backup address...

They first need to generate my address which could be any one of 2^160 possibilities. And then they must generate the corresponding public key that gives them access to the bitcoins in my address? Of where there at 2^96 possibilities?
Generating the public key is trivial.

Quote
Or must they simple generate 2^96 bitcoin keys... at which point they would control every single bitcoin address in the world?
The most sensible way to attempt the attack (which is still insane) is to generate random private keys, calculate the corresponding addresses, and then see if that address has a non-zero balance. I believe there are 2^160 possible addresses. So even if there are 1,000,000,000 addresses with non-zero balances, your odds of getting a non-zero balance on a single key are 1 in 2^128.

So brute-forcing a single bitcoin address with a non-zero balance (assuming there are a billion of them, which is generous), is as hard as, say, brute-forcing a given 128-bit AES key.

I am an employee of Ripple. Follow me on Twitter @JoelKatz
1Joe1Katzci1rFcsr9HH7SLuHVnDy2aihZ BM-NBM3FRExVJSJJamV9ccgyWvQfratUHgN
theymos
Administrator
Legendary
*
expert
Offline Offline

Activity: 3178
Merit: 3863


View Profile
July 01, 2011, 01:27:31 AM
 #9

Bitcoin already supports OP_HASH256 in script, so it would be trivial to increase the number of addresses if it ever became a problem.

1NXYoJ5xU91Jp83XfVMHwwTUyZFK64BoAD
schnuber
Member
**
Offline Offline

Activity: 96
Merit: 10


View Profile
December 21, 2013, 11:13:14 PM
 #10

So there are 2^160 public keys but only 2^96 private keys? Ho does that add up?
Are there private keys than unlock more than one public key?
cr1776
Legendary
*
Offline Offline

Activity: 2030
Merit: 1009


View Profile
December 22, 2013, 01:11:42 AM
 #11

So there are 2^160 public keys but only 2^96 private keys? Ho does that add up?
Are there private keys than unlock more than one public key?

This discussion might help:   :-)

https://bitcointalk.org/index.php?topic=199212.0
JoelKatz
Legendary
*
Offline Offline

Activity: 1582
Merit: 1004


Democracy is vulnerable to a 51% attack.


View Profile WWW
December 22, 2013, 07:50:30 AM
 #12

So there are 2^160 public keys but only 2^96 private keys? Ho does that add up?
Are there private keys than unlock more than one public key?
There are just under 2^256 private keys, just under 2^256 public keys, and 2^160 addresses. There are some addresses that have more than one corresponding public key and thus more than one corresponding private key.

I am an employee of Ripple. Follow me on Twitter @JoelKatz
1Joe1Katzci1rFcsr9HH7SLuHVnDy2aihZ BM-NBM3FRExVJSJJamV9ccgyWvQfratUHgN
schnuber
Member
**
Offline Offline

Activity: 96
Merit: 10


View Profile
December 22, 2013, 04:36:31 PM
 #13

Ok so the quote that there are 2^96 private keys is wrong then
bitpop
Legendary
*
Offline Offline

Activity: 2380
Merit: 1043


https://keybase.io/bitpop


View Profile WWW
December 22, 2013, 09:29:46 PM
 #14

More than atoms in the universe

Reputation  |  PGP  |  DigitalOcean  |  TorGuard  |  Ethereum Classic
Bitcoin: 3DSh6AnmvBpDJFUz2mnLirMLmTMcFs9nDm
Bitmessage: BM-2cXN9j8NFT2n1FxDVQ6HQq4D4MZuuaBFyb
ktorn
Newbie
*
Offline Offline

Activity: 32
Merit: 0


View Profile
May 07, 2014, 08:48:45 AM
 #15

More than atoms in the universe
That is not correct, not even close.
The estimated number of atoms in the observable universe (10^80) is 71 million trillion trillion times greater than 2^160.
PGSystemTester
Newbie
*
Offline Offline

Activity: 1
Merit: 4


View Profile
July 07, 2018, 08:50:09 PM
Merited by theymos (2), DarkStar_ (2)
 #16

Ok so the quote that there are 2^96 private keys is wrong then

I realize this is an old discussion but this thread now appears towards the top of searches for "How many bitcoin addresses are there."

Here are some exact numbers for Bitcoin and Ethereum... and all of their relatives.

The total possible number of addresses is exactly 2^160.
As a decimal number (what most people consider "normal") this is 1,461,501,637,330,902,918,203,684,832,716,283,019,655,932,542,975.
As a hexidecimal, this number is: FFFF FFFF FFFF FFFF FFFF FFFF FFFF FFFF FFFF FFFF

The total number of possible private keys is frequently listed as 2^256 and for all sensible discussion, this is correct.
However, technically there are a few less because of the secp256k1 Curve usage. Words cannot express how insignificant of a difference this is from 2^256. Imagine all of earth's beaches. Now imagine them with one less grain of sand. Even that is overstating the difference.

But since we're talking exact numbers, here are the exact number of private keys possible. I'll list them compared to 2^256
Code:
Decimal
115,792,089,237,316,195,423,570,985,008,687,907,852,837,564,279,074,904,382,605,163,141,518,161,494,336 (exact private key maximum)
115,792,089,237,316,195,423,570,985,008,687,907,853,269,984,665,640,564,039,457,584,007,913,129,639,935 (2^256)

Hexidecimal
FFFF FFFF FFFF FFFF FFFF FFFF FFFF FFFE BAAE DCE6 AF48 A03B BFD2 5E8C D036 4140 (exact private key maximum)
FFFF FFFF FFFF FFFF FFFF FFFF FFFF FFFF FFFF FFFF FFFF FFFF FFFF FFFF FFFF FFFF (2^256)


Going back to the discussion of how long it would take to brute force attack a specific address -- quite simply not possible with today's technology. The quote of 2^96 represented how many potential PRIVATE keys would work for a single PUBLIC key  if they were evenly distributed (not how many total private keys were there). A brute force attack would require an approach of using all 2^256 since there's no way to tell if a private key will generate an address that's been used or not. At some point (2^200?) all 2^160 addresses would be accounted for, but again, impossible with today's technology.
vit05
Sr. Member
****
Offline Offline

Activity: 434
Merit: 311



View Profile WWW
July 08, 2018, 03:49:44 AM
 #17

Ok so the quote that there are 2^96 private keys is wrong then

I realize this is an old discussion but this thread now appears towards the top of searches for "How many bitcoin addresses are there."

Here are some exact numbers for Bitcoin and Ethereum... and all of their relatives.

The total possible number of addresses is exactly 2^160.
As a decimal number (what most people consider "normal") this is 1,461,501,637,330,902,918,203,684,832,716,283,019,655,932,542,975.
As a hexidecimal, this number is: FFFF FFFF FFFF FFFF FFFF FFFF FFFF FFFF FFFF FFFF

The total possible private keys is frequently listed as 2^256 and for all sensible discussion, this is correct.
However, technically there are a few less because of the secp256k1 Curve usage. Below is the exact amount of private keys that can be used.
(I'm comparing them against the 2^256 just to illustrate how inconsequential the difference is)
Code:
Decimal
115,792,089,237,316,195,423,570,985,008,687,907,852,837,564,279,074,904,382,605,163,141,518,161,494,336 (actual private key maximum)
115,792,089,237,316,195,423,570,985,008,687,907,853,269,984,665,640,564,039,457,584,007,913,129,639,935 (2^256)

Hexidecimal
FFFF FFFF FFFF FFFF FFFF FFFF FFFF FFFE BAAE DCE6 AF48 A03B BFD2 5E8C D036 4140 (actual private key maximum)
FFFF FFFF FFFF FFFF FFFF FFFF FFFF FFFF FFFF FFFF FFFF FFFF FFFF FFFF FFFF FFFF (2^256)

Going back to the discussion of how long it would take to brute force attack a specific address -- quite simply not possible with today's technology. The quote of 2^96 represented how many potential PRIVATE keys would work for a single PUBLIC key (not how many total private keys were there). A brute force attack would require an approach of using all 2^256 since there's no way to tell if a private key will generate an address that's been used or not. At some point (2^200?) all 2^160 addresses would be accounted for, but again, impossible with today's technology.

I hope it's not a totally stupid question. But has bech32 changed anything about this number of public addresses? I think the private keys do not change anything, right? Since they follow the same pattern.


````````````````███████████
```````````█████████████████████
```````█████████████████████████████
`````````█████████████████████████
````````````████████████████████
```████``````````````````````````````████
`████████`````````````````````````███████
`█████████``````██████████````````████████
█████████`````██████████████```````████████
████████`````████████████████``````████████
`████████`````███████████████``````████████
``████████`````████████████```````████████
``███████````````████████``````````███████
```███```````````````````````````````████
````````````███████████████████
`````````██████████████████████████
```````█████████████████████████████
``````````██████████████████████
````````````````██████████
EtherMium██
██
██
██
██
██
██
██
██
██
██
██
██
██
██
██
██
██
██
██
██
██
██
██
██
██
██
██
██
██
theymos
Administrator
Legendary
*
expert
Offline Offline

Activity: 3178
Merit: 3863


View Profile
July 08, 2018, 11:39:31 PM
 #18

I hope it's not a totally stupid question. But has bech32 changed anything about this number of public addresses? I think the private keys do not change anything, right? Since they follow the same pattern.

Short-style bech32 addresses have the same maximum possible addresses of 2160. There is also a long-style bech32 address format (used for multisig and other more complex scripts) which has 2256 possible addresses.

1NXYoJ5xU91Jp83XfVMHwwTUyZFK64BoAD
Devawnm367
Member
**
Offline Offline

Activity: 280
Merit: 25

https://ico.agatechain.org/?ref=1e69bd03


View Profile
September 15, 2018, 12:12:04 AM
 #19

So is that the total number of possibilities, or is that the total number of addresses? If I use a phrase and unlock one would that mean it was being used or are all of the wallets pre created with prestored key phrases,  lets say if I typed random words for days and somehow unlock one would that mean that it is of use or I just found a random address?

I guess running a program would be simpler,  just saying I never knew that... your odds would be less than one unlock in a million years!!!!

◯ AGATE◯    Facebook Telegram Twitter Medium      ◯ AGATE◯
█ █ █ █ █ █ █ █    PayPal of Cryptocurrencies    █ █ █ █ █ █ █ █   
 ████  Blockchain Protocol + 12 Working Modules - Use Crypto as Cash
Coding Enthusiast
Sr. Member
****
Offline Offline

Activity: 515
Merit: 389


Novice C♯ Coder


View Profile WWW
September 15, 2018, 04:01:19 AM
Merited by theymos (5), ETFbitcoin (1)
 #20

In case you are wondering where are these numbers coming from, you should know that these aren't magic numbers or constants anywhere. These are simply the size of the "data" that represent an address! The first thing you should ask is "what is an address?" This will also clarify things for the question above regarding Bech32 and @theymos answer regarding 2160 and 2256 number of addresses.

An address such as 1BgGZ9tcN4rm9KBzDn7KprQz87SZ26SAMH or bc1qw508d6qejxtdg4y5r3zarvary0c5xw7kv8f3t4 is simply the "human readable" encoding of some data. Now that data simply has a fixed size. In case of P2PKH and P2WPH address examples above this data is RIPEMD160(SHA256(publickey)). Basically you are encoding (to be human readable) the result of RIPEMD160 cryptographic hash function. The encoding can be anything, in bitcoin we use Base58 encoding for first address example and use bech32 for the second.
This hash function as its name suggests is 160 bits in size. So the number of possible results it can have is 2160.
Math:
Code:
1 bit (2^1):
0
1

2 bit (2^2):
00
01
10
11

160 bit (2^160)
...

What about 2256 then?
That "data" is not always the same. We have different types of addresses. For instance it can be a scriptHash, in which case it is the result of a SHA256 cryptographic hash function which is obviously 256 bits of data hence the 2256 possible addresses.

Projects List+Suggestion box
Donation link using BIP21
Bech32 Donation link!
BitcoinTransactionTool (0.9.2):  Ann - Source Code
Watch Only Bitcoin Wallet (supporting SegWit) (3.1.0):  Ann - Source Code
SharpPusher (broadcast transactions) (0.10.0): Ann - Source Code

Pages: [1]
  Print  
 
Jump to:  

Sponsored by , a Bitcoin-accepting VPN.
Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!