Bitcoin Forum
April 30, 2024, 12:34:50 PM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: Check BTC balance programmatically  (Read 245 times)
zzyyxx332211 (OP)
Newbie
*
Offline Offline

Activity: 1
Merit: 6


View Profile
January 31, 2024, 10:01:26 PM
Merited by LoyceV (4), ABCbits (2)
 #1

Hi,

I've got a list (200 million+) of bitcoin and ethereum addresses I need to check the balance for.

For ethereum, I'm running a geth + prysm node and I can simply check the balance for a specific address by calling `provider.getBalance(address)`.

For bitcoin, I initially assumed that this was possible in the same way by using bitcoin-core, so I synced the blocks but then find out this is not possible (I can use `client.importAddress(address, '', false)` but then I will have to rescan the blocks and it doesn't seem a viable solution considering the amount of addresses I have to check).

I also looked into bitcoin-abe and it seems that it will import all blocks in a database so then I may be able to query the data to check the balance (I probably will have to calculate it by summing up all unspent transaction outputs associated with each address).

I was wondering if anyone knew a better way of doing this or had any suggestion.

Thanks!

1714480490
Hero Member
*
Offline Offline

Posts: 1714480490

View Profile Personal Message (Offline)

Ignore
1714480490
Reply with quote  #2

1714480490
Report to moderator
Even in the event that an attacker gains more than 50% of the network's computational power, only transactions sent by the attacker could be reversed or double-spent. The network would not be destroyed.
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
1714480490
Hero Member
*
Offline Offline

Posts: 1714480490

View Profile Personal Message (Offline)

Ignore
1714480490
Reply with quote  #2

1714480490
Report to moderator
1714480490
Hero Member
*
Offline Offline

Posts: 1714480490

View Profile Personal Message (Offline)

Ignore
1714480490
Reply with quote  #2

1714480490
Report to moderator
bitmover
Legendary
*
Offline Offline

Activity: 2282
Merit: 5912


bitcoindata.science


View Profile WWW
February 01, 2024, 12:51:00 AM
Merited by LoyceV (2), hosseinimr93 (2), apogio (1)
 #2

Hi,

I've got a list (200 million+) of bitcoin and ethereum addresses I need to check the balance for.

wow, that is way too much

I created this tool which allows you to search up to 465 addresses at once (much more than that there is a URL characters limit to make requests).

https://bitcoindata.science/bitcoin-balance-check

I never thought someone would to search for so many addresses!

The API I use is this one. Maybe you can create a bot to search for them, and make a thousand requests. It might work.
https://www.blockchain.com/explorer/api/blockchain_api

Quote
https://blockchain.info/multiaddr?active=$address|$address
Multiple Addresses Allowed
separated by "|"

example
Code:
https://blockchain.info/balance?active=1BTcsMpUYghRt1C1jrgcZ5UUp3CZbcEYyr,1BtCdfQB8q4H8dwTECg2nwbvimUEvFFwqn,1BtCQFw9UJR6E4f18hQ2Wxy7JXw6pLoZio,1BtCpSAJ14d64ZHTqc6uqaLMVXoovTsSXr,1BtcijWNLFdTrqUHwUTmN98xgs3taWCUs2,1BtcszwKy8CAip7cKijiQap95EzpGa7jLP,1Btc52YEBewJDjSRwxX6ZQWncM2zPdAV7i,1BtcU1zFCrGMK6yp68UqiMmaqnmvzxPFmU,1BTCAmZgMYFKSwc3Dc6wPwwkKmnJaxgvkV,1BtCqXxKv5UaQkxc77s6FGwopvxeEk7XVi,1BTCyJFwTj5i318RxfRX3fHyxEMkwKuQWJ,1Btc1Mh2dhrQecznSDLA2Vx6rSWSa8VGVM,1BTC4U8TNPx8GzV83bHfU7z3WM36sx9ZS9,1BTCWw2kqU987ZMmfuwULR6gMD7saQeEb,1BtC5V6DjGKer9FQnki7zpmAUCj3mjbD5p,1BTCaNiobNSBuX2CrX8Vo61d2wJf6c4sa2,1BTC4UUWMkHScH18yk89QxtPRdoEGhDPxs,1BTCR26yWcgZYdarLrbg7Urj3uWjCVSA5N,1BTC16oW8qMHmYQpFrKezTaDBk7uBKgyJq,1BtCRDjQkRx6Xsxz52UWVLbGimXw1iuYRL,1BTCGPrd9AEr2DUKx4V4WPzj2EPsLFHHgP,1BTC1ztaMtZbzV7rx8L67gRn935BFcxfUn,1BTcRWD4dpYGHazLXAStfeb69LyZEw2UuE,1BTChFRXA9G2aYmS7siWZoo87wvugDDMUg,1BtCpsLxTS2t9BAHBhamMSAb5aWnfAxM3Y,1BT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Cazi3saNmLCNbaMDFJP3bN9nYBiS,1BTCC6APaUGqVeDd8SseE8QLVkGETwrvF3,1BTC2Kan19L5LTdG4wRJRTb2xyfPXFEJxB,1BTChwPbLTqM1Ey3st1j69t5kUFMyD4Wxg,1BTC472YXDehT2e9vY9jNogVksTRo23oHh,1BTCSfhMjVLBLvQcpjaEdiKSi15ctFa6sU,1BTC4CUnSrozrgxtpU6v1Twk8U4zykUfEn,1BTC1LL6Sn6smJfM9JxGdvYZb7kUbsRNU8,1BTC3goEJfLu39kUBY716ZFSNNCpXfReqv,1BTCBYNFhgxaamKqMvRoKDGXFU6azBV3Ui,1BTC392SSsS4mJgn6YqznBwYhiY1rk3bv8,1BTC7Uy72eJgVQ7L5gFM6oA3is1Zp7sTaE,1BTC5rAHZgKrCVGEHSPmqkxX6Wk7cRRUWz,1BTCSmDn3npNHnBujABTGApwjHUX4KMz5b

.
.BLACKJACK ♠ FUN.
█████████
██████████████
████████████
█████████████████
████████████████▄▄
░█████████████▀░▀▀
██████████████████
░██████████████
████████████████
░██████████████
████████████
███████████████░██
██████████
CRYPTO CASINO &
SPORTS BETTING
▄▄███████▄▄
▄███████████████▄
███████████████████
█████████████████████
███████████████████████
█████████████████████████
█████████████████████████
█████████████████████████
███████████████████████
█████████████████████
███████████████████
▀███████████████▀
█████████
.
pooya87
Legendary
*
Offline Offline

Activity: 3430
Merit: 10517



View Profile
February 01, 2024, 05:37:08 AM
Merited by LoyceV (2), ABCbits (2), hosseinimr93 (2), apogio (1)
 #3

Since it is not "normal" for people to want to check the balance of such a large number of addresses (200 million+) and there is also no logical reason to do so, there is no ready and easy to use tool you can use. You should write your own which means a full node with an indexed and optimized database for large number of lookups based on address.

Other than that, you can use available old snapshots of the blockchain such as the one that blockchair.com explorer provides (can be downloaded faster from here: https://bitcointalk.org/index.php?topic=5254914.0). Then write a script that looks up the balance of each address from that snapshot/list. I believe their snapshot updates daily, so it is not that old.
@LoyceV also has a sorted file which could be used to somewhat optimize the search (eg. using binary search).

.
.BLACKJACK ♠ FUN.
█████████
██████████████
████████████
█████████████████
████████████████▄▄
░█████████████▀░▀▀
██████████████████
░██████████████
████████████████
░██████████████
████████████
███████████████░██
██████████
CRYPTO CASINO &
SPORTS BETTING
▄▄███████▄▄
▄███████████████▄
███████████████████
█████████████████████
███████████████████████
█████████████████████████
█████████████████████████
█████████████████████████
███████████████████████
█████████████████████
███████████████████
▀███████████████▀
█████████
.
LoyceV
Legendary
*
Offline Offline

Activity: 3290
Merit: 16577


Thick-Skinned Gang Leader and Golden Feather 2021


View Profile WWW
February 01, 2024, 06:51:00 AM
Merited by hosseinimr93 (2), bitmover (2), ABCbits (1), apogio (1)
 #4

I was wondering if anyone knew a better way of doing this
Yes Tongue
Step 1: Download the latest list of all Bitcoin addresses with a balance.
Step 2: Do this:
How to use
The most likely use is to check a long list of Bitcoin addresses for a remaining balance.
On Linux, use this to find matching addresses (after extrating the compressed .gz file of course):
Code:
comm -12 Bitcoin_addresses_LATEST.txt <(cat mylist.txt | sort | uniq)
  • Bitcoin_addresses_LATEST.txt: the extracted latest version downloaded from addresses.loyce.club.
  • mylist.txt: your own list of addresses, one address per line.
This takes only seconds to check millions of addresses. If your text file has Microsoft formatting, you may need to use this instead:
Code:
comm -12 Bitcoin_addresses_LATEST.txt <(cat mylist.txt | fromdos | sort | uniq)

You can do the same for ethereum, but I only have an old list of addresses.

@LoyceV also has a sorted file which could be used to somewhat optimize the search (eg. using binary search).
"Somewhat optimize" is an understatement Tongue

apogio
Sr. Member
****
Offline Offline

Activity: 420
Merit: 956



View Profile WWW
February 01, 2024, 07:56:43 AM
 #5

Let me just say something. Not for OP, but for a friend  Tongue

If someone had 200+ million addresses:

1. trying to find if these addresses have a balance and spending from them is considered stealing. Of course it's impossible unless he they had 200+ million key-pairs instead of 200+ million addresses.

2. finding a match between these 200+ million addresses (if they are not known to be funded and are completely randomly generated) and the addresses from the "List of all bitcoin addresses with a balance" is not as easy as it seems. The address space is huge. The addresses are produced using RIPEMD160, so the number that is produced is 160 bits long. This gives a space of 2^160 ~= 1.46 * 10 ^ 48. Your number is 200M = 2 * 10 ^ 8. I think you get the point.

3. trying to trace these addresses is considered at least unethical.

NotATether
Legendary
*
Online Online

Activity: 1582
Merit: 6715


bitcoincleanup.com / bitmixlist.org


View Profile WWW
February 01, 2024, 08:09:18 AM
 #6

For bitcoin, I initially assumed that this was possible in the same way by using bitcoin-core, so I synced the blocks but then find out this is not possible (I can use `client.importAddress(address, '', false)` but then I will have to rescan the blocks and it doesn't seem a viable solution considering the amount of addresses I have to check).

Zpywallet is designed to crunch these kind of things but the full node connector is very slow because it scans all blocks for transactions. Currently I am trying to speed it up by not parsing every single transaction.

Blockstream.info's endpoint does not have any rate limits AFAIK but I would not advise you do this with 200m addresses as you will get ban hammered quickly.

.
.BLACKJACK ♠ FUN.
█████████
██████████████
████████████
█████████████████
████████████████▄▄
░█████████████▀░▀▀
██████████████████
░██████████████
████████████████
░██████████████
████████████
███████████████░██
██████████
CRYPTO CASINO &
SPORTS BETTING
▄▄███████▄▄
▄███████████████▄
███████████████████
█████████████████████
███████████████████████
█████████████████████████
█████████████████████████
█████████████████████████
███████████████████████
█████████████████████
███████████████████
▀███████████████▀
█████████
.
LoyceV
Legendary
*
Offline Offline

Activity: 3290
Merit: 16577


Thick-Skinned Gang Leader and Golden Feather 2021


View Profile WWW
February 01, 2024, 08:39:41 AM
 #7

1. trying to find if these addresses have a balance and spending from them is considered stealing.
~
3. trying to trace these addresses is considered at least unethical.
Trying to do something is not the same as actually stealing. I'm not worried about ethics when there's math to protect me. If it's unethical to check a randomly generated address for a balance, every new Electrum wallet installation is unethical too. Most people don't seem to realize it, but they're "brute-forcing" 30 addresses! And that's totally fine, they won't find a thing.

It's a different story when checking brainwallets: there's actually a chance to find funded ones. You can bet many people are trying to "hack" them.

apogio
Sr. Member
****
Offline Offline

Activity: 420
Merit: 956



View Profile WWW
February 01, 2024, 08:44:45 AM
 #8

Trying to do something is not the same as actually stealing. I'm not worried about
It's a different story when checking brainwallets: there's actually a chance to find funded ones. You can bet many people are trying to "hack" them.

Of course checking is not stealing. Only spending is stealing.

How do you know if these addresses are produced by a "brain" key or not?  Tongue Or a dictionary perhaps

LoyceV
Legendary
*
Offline Offline

Activity: 3290
Merit: 16577


Thick-Skinned Gang Leader and Golden Feather 2021


View Profile WWW
February 01, 2024, 09:05:36 AM
 #9

How do you know if these addresses are produced by a "brain" key or not?
I don't know, but it doesn't matter. If someone creates his own private key instead of using a proper random generator, he should know his funds can be stolen at any time.

apogio
Sr. Member
****
Offline Offline

Activity: 420
Merit: 956



View Profile WWW
February 01, 2024, 09:09:58 AM
 #10

How do you know if these addresses are produced by a "brain" key or not?
I don't know, but it doesn't matter. If someone creates his own private key instead of using a proper random generator, he should know his funds can be stolen at any time.

Haha we re saying the same thing. Of course his funds can be stolen. But stealing them is not right. That's what I am saying. Anyway, I think we agree on everything.

LoyceV
Legendary
*
Offline Offline

Activity: 3290
Merit: 16577


Thick-Skinned Gang Leader and Golden Feather 2021


View Profile WWW
February 01, 2024, 09:24:04 AM
 #11

Of course his funds can be stolen. But stealing them is not right.
There's also no point in pointing fingers at someone who may try this. For everyone who creates a topic here, there are probably hundreds of people doing the same quietly. Stealing is bad, but "be your own bank" comes with your own responsibilities.

If everyone uses properly generated random private keys, all OP does is prove to himself that Bitcoin is very secure.

pooya87
Legendary
*
Offline Offline

Activity: 3430
Merit: 10517



View Profile
February 02, 2024, 06:57:46 AM
 #12

@LoyceV also has a sorted file which could be used to somewhat optimize the search (eg. using binary search).
"Somewhat optimize" is an understatement Tongue
Well, considering I've never tried it I can't confidently comment on the degree of optimization. I've only used the "regular" list a while back to try some stuff out with some addresses that I only had a fraction of the string. Let's just say it took more time to compile the 10 lines of code than to get the result Roll Eyes

.
.BLACKJACK ♠ FUN.
█████████
██████████████
████████████
█████████████████
████████████████▄▄
░█████████████▀░▀▀
██████████████████
░██████████████
████████████████
░██████████████
████████████
███████████████░██
██████████
CRYPTO CASINO &
SPORTS BETTING
▄▄███████▄▄
▄███████████████▄
███████████████████
█████████████████████
███████████████████████
█████████████████████████
█████████████████████████
█████████████████████████
███████████████████████
█████████████████████
███████████████████
▀███████████████▀
█████████
.
LoyceV
Legendary
*
Offline Offline

Activity: 3290
Merit: 16577


Thick-Skinned Gang Leader and Golden Feather 2021


View Profile WWW
February 03, 2024, 10:21:43 AM
Last edit: February 06, 2024, 08:06:37 AM by LoyceV
 #13

I can't confidently comment on the degree of optimization.
It's very difficult to beat the performance of a standard Linux CLI tools.

JohanM
Member
**
Offline Offline

Activity: 137
Merit: 35


View Profile
February 05, 2024, 02:51:05 PM
Merited by ABCbits (1)
 #14

The best way to do would be to convert the actual Bitcoin UTXO database into a SQL database so you can search it.
This database is kept on every node but it is a LevelDB database that can only be accessed sequentially.
So you need a translation software to read it.
I made one myself in Java. It takes about 1 hour to convert the full UTXO to a MYSQL database. It's about 24GB large when only a few fields are saved (addresses, balance, block height, txid). It contains 162 million records as of today.

You can then do a quick search to see if a specific address is in the database.
If found you can easily calculate the balance by doing a select count(*).
Running the queries would need a pc with a very fast random access SSD and as much ram as you can spare (think 128 or 256GB).

There's probably a few projects on GitHub that convert the UTXO.

LoyceV
Legendary
*
Offline Offline

Activity: 3290
Merit: 16577


Thick-Skinned Gang Leader and Golden Feather 2021


View Profile WWW
February 06, 2024, 08:19:09 AM
 #15

The best way to do would be to convert the actual Bitcoin UTXO database into a SQL database so you can search it.
This database is kept on every node but it is a LevelDB database that can only be accessed sequentially.
So you need a translation software to read it.
I made one myself in Java. It takes about 1 hour to convert the full UTXO to a MYSQL database. It's about 24GB large when only a few fields are saved (addresses, balance, block height, txid). It contains 162 million records as of today.
For OP's purpose, he doesn't need all UTXOs, only the balances. There are only 51 million addresses, so you could reduce the size of your database to 8 GB.

Quote
You can then do a quick search to see if a specific address is in the database.
If found you can easily calculate the balance by doing a select count(*).
Running the queries would need a pc with a very fast random access SSD and as much ram as you can spare (think 128 or 256GB).
How fast can you check a million addresses from this database?

mullick
Legendary
*
Offline Offline

Activity: 1064
Merit: 1002


View Profile
February 06, 2024, 08:24:47 AM
 #16

For OP's purpose the amount of time it would take to parse a fully indexed chain into an sql database is probably the same time frame to query that list for all 200m+ addresses. In the long term the database would be the way to go though imo. Plus its a great way to learn more about the protocol.

I'm guessing OP set keypool=200000000 and now wants to check for collisions  Grin
ABCbits
Legendary
*
Offline Offline

Activity: 2856
Merit: 7428


Crypto Swap Exchange


View Profile
February 06, 2024, 11:41:14 AM
 #17

The best way to do would be to convert the actual Bitcoin UTXO database into a SQL database so you can search it.
This database is kept on every node but it is a LevelDB database that can only be accessed sequentially.
So you need a translation software to read it.
I made one myself in Java. It takes about 1 hour to convert the full UTXO to a MYSQL database. It's about 24GB large when only a few fields are saved (addresses, balance, block height, txid). It contains 162 million records as of today.

You can then do a quick search to see if a specific address is in the database.
If found you can easily calculate the balance by doing a select count(*).
Running the queries would need a pc with a very fast random access SSD and as much ram as you can spare (think 128 or 256GB).

There's probably a few projects on GitHub that convert the UTXO.

At this stage, IMO it's better to run self-hosted block explorer or electrum server which already index for UTXO/address where you just need to either,
1. Use their API to obtain balance of address.
2. Access their SQL database directly.

█▀▀▀











█▄▄▄
▀▀▀▀▀▀▀▀▀▀▀
e
▄▄▄▄▄▄▄▄▄▄▄
█████████████
████████████▄███
██▐███████▄█████▀
█████████▄████▀
███▐████▄███▀
████▐██████▀
█████▀█████
███████████▄
████████████▄
██▄█████▀█████▄
▄█████████▀█████▀
███████████▀██▀
████▀█████████
▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
c.h.
▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄
▀▀▀█











▄▄▄█
▄██████▄▄▄
█████████████▄▄
███████████████
███████████████
███████████████
███████████████
███░░█████████
███▌▐█████████
█████████████
███████████▀
██████████▀
████████▀
▀██▀▀
WhyFhy
Hero Member
*****
Offline Offline

Activity: 1430
Merit: 513



View Profile
February 07, 2024, 04:18:59 AM
 #18

Ahh the old collision checker. (possible yes, probable no)

infinity/200,000,000 is still infinity.

You have much better chances hitting a solo mining block with a proc or playing provably fair lottery on freebitcoin

even better chances getting struck by lightning.

Do the same thing you would with a barcode scanner for dvd's.

rate limit 10-30 a second depending, if something file it. if nothing ignore it.

check it out in a few days and learn your pissing in the wind.

modify JLVS to scan realtime.

Lets say you do get a hit , what are you going to do clean them out?

even if there was an asic keysearcher chewing out quadrillions of keys a second you are wasting time.

the only way this could be feasible is knowing the keyspace. even then odds are shit. https://privatekeys.pw/puzzles/bitcoin-puzzle-tx

Personally, I wouldn't waste the resources.

https://vanitypool.appspot.com/availableWork solve these at least you have a chance.



  BTC
.
BTC
.
 BTC
.
BTC
/]..[banned mixer]..
██
██
██
██
██
██
██

██

██

██

██
/]YOUR OPPORTUNITY TO
HAVE BITCOIN BUSINESS

██
██
██
██
██
██
██

██

██

██

██
.
  BTC
. BTC
.
.
 
BTC
  BTC
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!