ChainSafe / gossamer

🕸️ Go Implementation of the Polkadot Host
https://chainsafe.github.io/gossamer
GNU Lesser General Public License v3.0
428 stars 110 forks source link

Validate radiumblock bootnode multihash against go-multihash implementation #3712

Open q9f opened 5 months ago

q9f commented 5 months ago
          > I took it from the upstream PR here: [paseo-network/runtimes#12](https://github.com/paseo-network/runtimes/pull/12)

How can I double check the issue is upstream and not our implementation?

We use https://github.com/multiformats/go-multiaddr to parse these p2p addresses, so I think we should investigate its implementation, the parse is done at dot/network/utils.go in the function stringToAddrInfo

Originally posted by @EclesioMeloJunior in https://github.com/ChainSafe/gossamer/issues/3703#issuecomment-1898976058

q9f commented 5 months ago

Just posting this here for myself as a homework.

dimartiro commented 5 months ago

Based on this spec

I think the right addrs should be:

"/dns/paseo-bootnode.radiumblock.com/tcp/30333/p2p/12D3KooWADeayZC8zag4Qrb4GosSn65MmfVZztRPMaBdgZnQqXRo"
"/dns/paseo-bootnode.radiumblock.com/tcp/30335/wss/p2p/12D3KooWADeayZC8zag4Qrb4GosSn65MmfVZztRPMaBdgZnQqXRo"

I tested them and they passed the test