eth2libp2p

package module
v0.0.0-...-477efe5 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 29, 2021 License: Apache-2.0 Imports: 5 Imported by: 0

README

eth2libp2p

This repo is a demonstration on how Ethereum public/private keys can be used to generate equivalents on libp2p using Go

Test

go test ./...

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func P2PIDFromEthPubKey

func P2PIDFromEthPubKey(ethPubKey *ecdsa.PublicKey) (id peer.ID, err error)

Types

type LibP2PIdentity

type LibP2PIdentity struct {
	PrivateKey     p2pCrypto.PrivKey
	PublicKey      p2pCrypto.PubKey
	ID             peer.ID
	IdentityOption libp2p.Option // Used for host creation using this identity
}

func NewLibP2PIdentityFromEthPrivKey

func NewLibP2PIdentityFromEthPrivKey(ethPrivKey *ecdsa.PrivateKey) (wallet LibP2PIdentity, err error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL