-
Notifications
You must be signed in to change notification settings - Fork 231
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Gossipsub: message filtering #122
Comments
With some help from libp2p we can make validators anonymous in the libp2p network: |
One previously raised concern of the "validation API" is that it's not defined to be async. This won't be a problem for us if we can use the following alternative approach:
This approach also gives us the opportunity to look at the pool of collected messages before deciding what should be re-transmitted. Similar prioritisation strategy is proposed for attestation aggregation here: https://notes.ethereum.org/9Ijj2RkuRiqQYB9NOfY_9Q |
To suggest the capabilities of what sort of filtering is implementable: https://github.com/ethereum/eth2.0-specs/blob/v0.9.2/specs/networking/p2p-interface.md#topics-and-messages requires the following filtering:
|
Pubsub validators were added in libp2p in vacp2p/nim-libp2p#58. This should be available to use as a filtering mechanism now. |
In terms of
such that |
This is currently impossible to do in some (most?) implementations as the gossipsub RPC message isn't exposed to the application, consequently the neither the Given that Eth2 networking spec mandates this for all clients, we should propose this changes to be included in the gossipsub spec. |
Other already-done aspects, in terms of what Additional global topics are used to propagate lower frequency validator messages. Their
Also already done:
The necessary code already exists (all those |
Items in #781 related to content-hashing in for message-ID and for max gossip message size are out of scope of this issue for March purposes, leaving only the |
For
For
|
#812 implements this. |
With regards to ethereum/eth2.0-specs#593
When messages are received on the network, we should not propagate them unless they're "good" (to be defined).
libp2p allows blacklisting peers by peer id (which is secured by the above feature, https://github.com/libp2p/go-libp2p-pubsub/blob/master/blacklist_test.go#L38-L64).
There also exists a validation api (https://github.com/libp2p/go-libp2p-pubsub/blob/bfd65a2f6b810c5b4ad2cfe6bb9cc792fd7a0171/floodsub_test.go#L360) to filter messages by content - it is making its way into the daemon api as well: libp2p/go-libp2p-daemon#71
How do we make use of this information? should it affect peer scoring?
The text was updated successfully, but these errors were encountered: