pear/README.md

1.7 KiB

🍐

Experiments in libp2p connectivity

Custom libp2p-based Go binaries for testing p2p connectivity in the following scenarios:

  • Public IPv4 to public IPv4.
  • Public to private (behind NAT) and viceversa.
  • Private to private (behind NAT, using holepunching).
  • Use of the Tor transport.
  • Use of public IPFS relay & DHT.

Assumptions

I am exploring the possibility of creating network conditions which resemble those of the Scuttleverse. Peers are already offline friends and have some out-of-band method for sharing connection details (e.g. a Cabal chat).

To facilitate holepunching and avoid public IPFS relays or DHT, I want to use a private self-hosted relay. No standard bootstrapping nodes should be required, everything is "in house" (like a "pub" or "room" in SSB).

I make explicit use of Noise for encryption because we control the peer implementation on both sides (guaranteed to be available).

Sometimes, it might be handy to make use of public IPFS relays or DHT, so I will leave this as an optional approach. The important point is that this will not be the default.

Local-first connections should also work reliably.

Since libp2p was built within the context of a global connectivity mindset, I am exploring how local-first and "private" connectivity works between a small group of friends.

Goals

Simple and well documented example programs.

Show possiblities for using overlay networks from the start.

Big shout-out to the writers of this wonderful tutorial.