Skip to main content

local_host_label

Function local_host_label 

Source
pub fn local_host_label() -> String
Expand description

This machine’s host label — the hostname half of an agent’s WAN instance identity, paired with local_channel_id to identify which AgentMux instance under an account owns a given agent’s WAN keypair.

Lowercased and trimmed so the value a sender binds into its signature and the value an instance publishes alongside its public key can’t differ by case alone — the same normalization discipline agent_id already has, and for the same reason: a mismatch here doesn’t fail loudly, it selects a different key and renders a valid message as an active forgery.

Falls back to "unknown" exactly as bootstrap/network.rs already does for the LAN advertisement, rather than erroring — an unresolvable hostname must not block spawning an agent.