Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Record ¶
type Record struct { Signature []byte // Cryptographic signature of record contents Sequence uint64 // The sequence number. Nodes should increase the number whenever the record changes and republish the record. IDScheme string // name of identity scheme, e.g. “v4” PrivateKey *secp256k1.PrivateKey PublicKey *secp256k1.PublicKey Ip net.IP TcpPort uint16 UdpPort uint16 Ip6 net.IP Tcp6Port uint16 // IPv6-specific TCP port. If omitted, same as TcpPort. Udp6Port uint16 // IPv6-specific UDP port. If omitted, same as UdpPort. SentPing time.Time SentPingHash [32]byte ReceivedPong time.Time ReceivedPing time.Time }
An Ethereum Node Record contains network information about a node on the dsicv5 p2p network. The specification is detailed in https://eips.ethereum.org/EIPS/eip-778.
func UnmarshalText ¶
Given a text encoding of an Ethereum Node Record, which is formatted as the base-64 encoding of its RLP content prefixed by enr:, this method decodes it into an Record struct.
func (*Record) MarshalRLP ¶
func (Record) MarshalText ¶
Click to show internal directories.
Click to hide internal directories.