Documentation
¶
Overview ¶
Deprecated: This package has moved into go-libp2p as a sub-package: github.com/libp2p/go-libp2p/core/pnet.
Package pnet provides interfaces for private networking in libp2p.
Index ¶
Constants ¶
const EnvKey = pnet.EnvKey
EnvKey defines environment variable name for forcing usage of PNet in libp2p When environment variable of this name is set to "1" the ForcePrivateNetwork variable will be set to true. Deprecated: use github.com/libp2p/go-libp2p/core/pnet.EnvKey instead
Variables ¶
var ErrNotInPrivateNetwork = pnet.ErrNotInPrivateNetwork
ErrNotInPrivateNetwork is an error that should be returned by libp2p when it tries to dial with ForcePrivateNetwork set and no PNet Protector Deprecated: use github.com/libp2p/go-libp2p/core/pnet.ErrNotInPrivateNetwork instead
var ForcePrivateNetwork = pnet.ForcePrivateNetwork
ForcePrivateNetwork is boolean variable that forces usage of PNet in libp2p Setting this variable to true or setting LIBP2P_FORCE_PNET environment variable to true will make libp2p to require private network protector. If no network protector is provided and this variable is set to true libp2p will refuse to connect. Deprecated: use github.com/libp2p/go-libp2p/core/pnet.ForcePrivateNetwork instead
Functions ¶
func IsPNetError ¶
IsPNetError checks if given error is PNet Error Deprecated: use github.com/libp2p/go-libp2p/core/pnet.IsPNetError instead
Types ¶
type Error ¶
Error is error type for ease of detecting PNet errors Deprecated: use github.com/libp2p/go-libp2p/core/pnet.Error instead