mirror of
https://github.com/libp2p/go-libp2p-core.git
synced 2025-03-22 12:20:07 +08:00
also removes the seq field from PeerMessage proto, since it was moved to the SignedEnvelope
26 lines
961 B
Protocol Buffer
26 lines
961 B
Protocol Buffer
syntax = "proto3";
|
|
package peer.pb;
|
|
|
|
// PeerRecord messages contain information that is useful to share with other peers.
|
|
// Currently, a PeerRecord contains the public listen addresses for a peer, but this
|
|
// is expected to expand to include other information in the future.
|
|
//
|
|
// PeerRecords are designed to be serialized to bytes and placed inside of
|
|
// SignedEnvelopes before sharing with other peers.
|
|
// See https://github.com/libp2p/go-libp2p-core/record/pb/envelope.proto for
|
|
// the SignedEnvelope definition.
|
|
message PeerRecord {
|
|
|
|
// AddressInfo is a wrapper around a binary multiaddr. It is defined as a
|
|
// separate message to allow us to add per-address metadata in the future.
|
|
message AddressInfo {
|
|
bytes multiaddr = 1;
|
|
}
|
|
|
|
// peerId contains a libp2p peer id in its binary representation.
|
|
bytes peerId = 1;
|
|
|
|
// addresses is a list of public listen addresses for the peer.
|
|
repeated AddressInfo addresses = 3;
|
|
}
|