pull down to refresh

In this post, I will briefly describe the needs of a bitcoin light client and why compact block filters satisfy these needs better than Bloom filters do. Then I will dive into exactly how compact block filters work and will follow this with a step by step guide for constucting such a filter from a testnet block.

The purpose of block filters

A bitcoin light client is software that can back a bitcoin wallet without storing the blockchain. This means that it needs to be able to broadcast transactions to the network but most importantly it must be able to pick up when there is a new transaction that is relevant to the wallet it is backing. There are two ways a transaction becomes relevant to a wallet: either it is sending money to the wallet (creating a new output to a wallet address) or it is spending one of the UTXOs that the wallet owns.
Yeah this is cool and is part of the Neutrino mode (together with BIP157) so you can run a LN node without dealing with huge amount of data for the bitcoin blockchain. Literally can run a LND node on any cheap VPS or home PC. Read more here: https://docs.lightning.engineering/lightning-network-tools/lnd/enable-neutrino-mode-in-bitcoin-core
This is how mobile nodes like Zeus, Blixt, Breez can run on any mobile device. And you get also some more privacy, is perfectly fine to connect to any neutrino peer (if you do not run your own BTC node with neutrino activated).
reply
Yeah, I thought it was cool and super informative too! This article was courtesy of @Andreasgriffin. This whole Core vs Knots war actually has a good side, I’ve been learning a ton about stuff I barely knew anything about.
reply
The only "downsize" of neutrino is that it still depend of a good connection, the client must have a good response time (ping) to the server, usually under 150ms. Otherwise will get really bad syncing issues and even getting banned from the peer for too many intents.
So if you have a client like Zeus, Blixt, Breez or a simple LND private node on a PC at home that connect to neutrino peers, I suggest to not use any Tor and if you really want to use a VPN for that node (is not really necessary) at least use a decent one with a good ping. Tor connection for a neutrino client is a real pain in the ass and is totally useless.
If you ever want to run a LND in neutrino mode here are some good peers, by region to connect to:
btcd1.lnolymp.us | btcd2.lnolymp.us - for US region
sg.lnolymp.us - for Asia region
btcd-mainnet.lightning.computer - for US region
uswest.blixtwallet.com (Seattle) - for US region
europe.blixtwallet.com (Germany) - for EU region
asia.blixtwallet.com - for Asia region
node.eldamar.icu - for US region
noad.sathoarder.com - for US region
bb1.breez.technology | bb2.breez.technology - for US region
neutrino.shock.network - US region (167.88.11.203)
You can make your own general list of nodes with neutrino activated from https://bitnodes.io/nodes/?q=NODE_COMPACT_FILTERS
I will encourage all bitcoin node runners to activate neutrino on their servers. It cost nothing in terms of resources but could help a pleb around.
reply
Thanks!
Tor connection for a neutrino client is a real pain in the ass and is totally useless.
I’m guessing the way Tor works probably adds some latency to the connection. Is there only one peer in Europe? Or is that just the best one?
reply
yeah unfortunately I do not know another well known big neutrino peer in Europe, but you can find ones from that bitnodes.io list, choose the ones closer to your location and keep them in your own list. Save 2-3 because sometimes they go offline so is better to have some backup.
Or the best way (if you do not run a Bitcoin node with neutrino activated), ask a friend in your area to give his node IP (if they activate neutrino) and just connect.
reply
"Floresta uses BIP158 compact block filters to search for your wallet’s historical transactions and monitor new blocks."
an embeddable utreexo library / node. lightweight yet fully validating.
The future is decentralized and private.
reply
also (ibid)
"One of Bitcoin’s most fascinating properties is the fact you can have a level of security that once was only available to the people in power. You can verify that a payment is valid (you’re not receiving fool’s gold) without any special tool. You can make sure the monetary policy is being followed without needing to trust anyone’s information. But to achieve this, you have to run a node. Your security dramatically declines if you’re using someone else’s node. But running a node has historically been an onerous task, requiring a good 24/7 running computer and a good internet connection. Floresta changes that by enabling you to run a full node on almost any device, without hassle."
reply