rust-libp2p/protocols/dcutr/src/message.proto
Max Inden 0bb8ee98d5
protocols/: Implement Direct Connection Upgrade through Relay (DCUtR) (#2438)
Enables two peers to coordinate a hole punch (direct connection upgrade)
via a relayed connection.

See https://github.com/libp2p/specs/blob/master/relay/DCUtR.md for
specification.
2022-02-08 15:56:35 +01:00

20 lines
588 B
Protocol Buffer

syntax = "proto2";
package holepunch.pb;
message HolePunch {
enum Type {
CONNECT = 100;
SYNC = 300;
}
required Type type=1;
// For hole punching, we'll send some additional observed addresses to the remote peer
// that could have been filtered by the Host address factory (for example: AutoRelay removes all public addresses if peer has private reachability).
// This is a hack!
// We plan to have a better address discovery and advertisement mechanism in the future.
// See https://github.com/libp2p/go-libp2p-autonat/pull/98
repeated bytes ObsAddrs = 2;
}