(This fell out of proptesting the new MGD BGP scrimlet reconciler.)
omicron currently has a bug if attempting to use an IPv6 numbered BGP peer; it formats the BgpPeerConfig::host field via format!("{ip}:179"}, which is incorrect for IPv6 addresses since that omits the necessary []s around the IP.
We can fix this in omicron by changing that format string to SocketAddr::new(ip, 179).to_string(), but even better would be if the client saw the field as a SocketAddr instead of a String. maghemite's API is already doing the right thing here, as best it can, and defines this field as a SocketAddr. However, as of oxidecomputer/oxnet#82 (published today in oxnet 0.1.6), if we change this field type to SocketAddrJson and add this to the mg-admin-client progenitor spec:
crates = {
std = "1.0.0",
},
then the client will know the field needs to be a SocketAddr.
(This fell out of proptesting the new MGD BGP scrimlet reconciler.)
omicron currently has a bug if attempting to use an IPv6 numbered BGP peer; it formats the
BgpPeerConfig::hostfield viaformat!("{ip}:179"}, which is incorrect for IPv6 addresses since that omits the necessary[]s around the IP.We can fix this in omicron by changing that format string to
SocketAddr::new(ip, 179).to_string(), but even better would be if the client saw the field as aSocketAddrinstead of aString. maghemite's API is already doing the right thing here, as best it can, and defines this field as aSocketAddr. However, as of oxidecomputer/oxnet#82 (published today in oxnet 0.1.6), if we change this field type toSocketAddrJsonand add this to themg-admin-clientprogenitor spec:then the client will know the field needs to be a
SocketAddr.