Skip to main content

Protocol

The protocol section sets the identifiers that agents exchange when a transport connection is set up. Change them to match local network policy, for example to avoid a recognizable value on the wire. Agents that connect to each other must use the same values.

Configuration​

protocol:
alpn: "muti-metroo/1" # TLS ALPN value (QUIC, HTTP/2, WebSocket over TLS)
http_header: "X-Muti-Metroo-Protocol" # HTTP/2 request and response header name
ws_subprotocol: "muti-metroo/1" # WebSocket subprotocol

Keys​

KeyTypeDefaultDescription
alpnstring"muti-metroo/1"ALPN protocol identifier offered by peers and accepted by QUIC listeners. Also used as the value of the HTTP/2 header.
http_headerstring"X-Muti-Metroo-Protocol"Header name the h2 transport sends with its request and response. An h2 listener rejects a request whose header carries a value other than its alpn.
ws_subprotocolstring"muti-metroo/1"Subprotocol the ws transport requests and accepts during the WebSocket upgrade.

Setting a key to an empty string has the same effect as leaving it at its default; the identifiers are always sent.

Examples​

All agents in the mesh share the custom values:

protocol:
alpn: "app/2"
http_header: "X-App-Channel"
ws_subprotocol: "app.v2"

See Also​

  • TLS for certificates and ClientHello profiles used in the same handshake
  • Listeners and Peers for the connections these values apply to
  • Transports for how QUIC, HTTP/2, and WebSocket connections are set up