Wow I kind of wish I didn't post this on the holidays so I could have gotten back to it a bit quicker.
I needed some time to digest all of that but that's why I'm here so let's get into it.
Regarding The ForkConsider a race between A and A'-- if the nodes you are connected to see A first then they suppress transmission of A' by virtue having already accepted A. However, in realty A' might actually be preferred by significant hashpower while the dominance of A exists mostly just in what you are monitoring. In any case, even if your view is fair A' will still probably be the first block seen by at least the author of A' and so the probability of it being extended first is non-zero.
Later block A'B is mined, at that point it becomes the preferred tip and all the nodes that previously preferred A will now switch to A'B and relay A' (parent of A'B) to you first. So what you see is A' then A'B at once, but in reality A' could have existed in public for a long time, it just wasn't making it to you.
So the success of A has suppressed your visibility of A' until the chain with A' overtook.
This is an interesting insight. It's also actually supported by the data I've collected so far because I've noted that, from the vantage point of my probes, GDPool has a tighter distribution profile than AntPool. Which would imply that if, as you say, public nodes can only request peers on what we might say is the "public boundary" implying that miners inject block broadcasts at layers beneath these and propagate upwards, the probability of a partition happening where A (say from GDPool) and A' (from AntPool) where injected at nearly the same time (say within ~3-20ms apart) then it is very possible that all of my probes would see A first.
However, I should mention, I'm timestamping blocks in
PeerManagerImpl::ProcessMessage
and classifying them based on the
msg_type chosen. Meaning that I also capture all of the broadcasts from each peer as they come in.
For each block from my 3 probes I typically get 24 entries in my database and for this specific incident all 24 were partial to A before A'B was captured ~90s later.
Which I just mention to say, that if that's true, it means that A' was stuck at a deeper layer because A blocked all of it's exit points to the public nodes layer before it could escape. Alternatively, it may have actually made it to a few public nodes, but it must have been a limited segment of public nodes that I don't currently monitor. If the latter, then I could potentially have captured that if I added more probes to different regions to cast a wider net to get the required resolution to witness an event like this. Otherwise, as you said, it is invisible unless the protocol is modified because it has not surfaced to the public layer (and that is unfortunate).
I would wager though that odds are, both scenarios happen. So, I might be able to capture some fork partitions some of the time if I cast a wide enough net. But unfortunately, I also don't see how this could reliably tell us anything about intentional withholding.
In my defense, I wasn't originally really trying to specifically do this anyway. I just wanted to look for miner propagation invariants and evidence is mounting that I might have found them. Although, ultimately I was hoping the insights would be useful outside of my own curiosity. Of that I'm not so sure yet.
-
Including, checking across multiple nodes in different locations.
AND
making sure they are well secured and protected.
-
So Antpool may have not even fully seen the block that they orphaned.
-
..proper security and filtering takes real time.
This is actually relevant to another assumption I made about a different stage of my analysis which was based on this quote from a paper:
We also found that the probability of blocks created by utilizing nodes
to become orphan blocks is surprisingly smaller than that of the
non-utilizing nodes. Even in the worst case, the value of utilizing
nodes is 15% of the value of non-utilizing nodes.
- Effects of a Simple Relay Network on the Bitcoin Network
I had interpreted their results as that outbound propagation and inbound propagation was symmetric. But, if inbound propagation regularly is required to pass through security steps that outbound doesn't. Then obviously that can't be true. Now I'm realizing it could also have been implied from the partitioning that gmaxwell was talking about.
At this point I have to wonder how it's even possible to implement intentional withholding, especially at the typical global hashrate that exists in present day.
The P2P Protocol Addition Fortunately it would be a very trivial change needing only changes in the node software and not the rest of the ecosystem.
-
So unless you feel like doing that work yourself, I wouldn't suggest holding your breath.
Well, frankly, this work is my attempt at doing something useful that also plays to my strengths to enter Bitcoin. I'd be willing to attempt a PR if you would be willing to share the details of the change in more depth.
Quick question though, even if a patch was written - if there were miners intentionally withholding - wouldn't they just skip this version to remain undetected?