free web page hit counter
P2P questions on operation of Bitcoin Core

P2P questions on operation of Bitcoin Core

Bitcoin Reddit

More / Bitcoin Reddit 15 Views

I've been playing around with Core, and had a random collection of questions regarding the P2P operations of the protocol. I've looked through some of the source but C++ is not my strongest language. Hopefully someone knows some of the answers off the top of their head.

  1. What whoami info is transmitted when a node connects to a peer, particularly on onion? Since all onion connections happen through the tor service on 127.0.0.1 how do the peers know where to find me? Is the externalip argument and port bindings transmitted to peers (must be right)? And if this info is transmitted, why don't I know the names of onion peers that connect to me, they always show as 127.0.0.1.
  2. How is a peer that listens on a non-default port discovered? When I look at DNS seeding, the DNS digs only give IP addresses. Most of the time hosts listed in a DNS seed DIG are listening on the default port, but is there any way to discover nodes listening on a nondefault port? Are they only discovered when they connect to peers and give their whoami or whatever message that may be.
  3. If I'm connected to a peer, say 1.2.3.4:8333, then that would be an outgoing connection my by tally. Can that peer then turn around and issue and incoming connection to me? Specifically, can I hold both an outgoing and incoming connection to the same peer? Does this create and type of spanning tree violation?
  4. Generally, how soon after a peer connects do the two peers begin to sync their mempools. Is that the first order of business, or is there some random timer that triggers the sync between the peers?
  5. When I issue a sendrawtransaction API call, does that just push the TXN to my own mempool, or does that force a message to all my peers that I have a new TXN to send?
submitted by /u/brianddk
[link] [comments]

Comments