Bitcoin Forum
May 12, 2024, 09:53:14 PM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: Compact Blocks: How are blocks validated in high bandwidth mode?  (Read 548 times)
1t0ph20 (OP)
Newbie
*
Offline Offline

Activity: 16
Merit: 7


View Profile
March 17, 2017, 02:50:23 PM
Merited by ABCbits (1)
 #1

Hi! Quick clarifying question.

Compact blocks can be used in both high-bandwidth mode and low-bandwidth mode. In high-bandwidth mode, peer A (sending to B) validates just the block header then relays cmpctblock.

My question is what if the rest of the block is invalid? If the majority of the network was using compact blocks in high-bandwidth mode, wouldn't this mean many only partially validated blocks circulating the network?

Thanks!
1715550794
Hero Member
*
Offline Offline

Posts: 1715550794

View Profile Personal Message (Offline)

Ignore
1715550794
Reply with quote  #2

1715550794
Report to moderator
1715550794
Hero Member
*
Offline Offline

Posts: 1715550794

View Profile Personal Message (Offline)

Ignore
1715550794
Reply with quote  #2

1715550794
Report to moderator
Even if you use Bitcoin through Tor, the way transactions are handled by the network makes anonymity difficult to achieve. Do not expect your transactions to be anonymous unless you really know what you're doing.
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
achow101
Moderator
Legendary
*
expert
Offline Offline

Activity: 3388
Merit: 6635


Just writing some code


View Profile WWW
March 17, 2017, 03:26:23 PM
Merited by ABCbits (2)
 #2

No. The partially validated block may propagate but nodes will still validate it fully and then reject the block if it is invalid. Relaying a block before validation does not mean that the block will never be validated by the node; the node will still validate it fully.

1t0ph20 (OP)
Newbie
*
Offline Offline

Activity: 16
Merit: 7


View Profile
March 17, 2017, 04:15:47 PM
Merited by ABCbits (1)
 #3

Thank you for the reply.  A follow up then, how are the compact blocks uncompressed (if you get relayed a cmpctblock)?
achow101
Moderator
Legendary
*
expert
Offline Offline

Activity: 3388
Merit: 6635


Just writing some code


View Profile WWW
March 17, 2017, 04:19:47 PM
Merited by ABCbits (2)
 #4

Thank you for the reply.  A follow up then, how are the compact blocks uncompressed (if you get relayed a cmpctblock)?
The compact block contains shortened versions of the transaction ids in a block. The node, when it receives the cmpctblock message, will calculate the shortened txids of all of the transactions that it has in its mempool. It retrieves the transactions that have matching shortened txids from the mempool in order to rebuild the full block. If it cannot find a transaction, it will request it from the peer that sent it the cmpctblock message. In this way the block is relayed without needing to actually send all of the data for the block when the block is relayed; most, if not all, of the transactions in the block will likely be found in the node's mempool and can be rebuilt from there.

1t0ph20 (OP)
Newbie
*
Offline Offline

Activity: 16
Merit: 7


View Profile
March 17, 2017, 06:12:30 PM
 #5

Great explanation! Thank you!
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!