Skip to content

Commit

Permalink
move underlay advertisement before sled-server start (#3756)
Browse files Browse the repository at this point in the history
- Fixes #3532
  • Loading branch information
rcgoodfellow authored and Alan Hanson committed Jul 24, 2023
1 parent 2a1fbb6 commit fa7db65
Showing 1 changed file with 13 additions and 13 deletions.
26 changes: 13 additions & 13 deletions sled-agent/src/bootstrap/agent.rs
Original file line number Diff line number Diff line change
Expand Up @@ -769,6 +769,19 @@ impl Agent {
monitor: hardware_monitor,
};

// Start trying to notify ddmd of our sled prefix so it can
// advertise it to other sleds.
//
// TODO-security This ddmd_client is used to advertise both this
// (underlay) address and our bootstrap address. Bootstrap addresses are
// unauthenticated (connections made on them are auth'd via sprockets),
// but underlay addresses should be exchanged via authenticated channels
// between ddmd instances. It's TBD how that will work, but presumably
// we'll need to do something different here for underlay vs bootstrap
// addrs (either talk to a differently-configured ddmd, or include info
// indicating which kind of address we're advertising).
self.ddmd_client.advertise_prefix(request.subnet);

// Server does not exist, initialize it.
let server = SledServer::start(
&self.sled_config,
Expand Down Expand Up @@ -802,19 +815,6 @@ impl Agent {
restarter.cancel();
*state = SledAgentState::After(server);

// Start trying to notify ddmd of our sled prefix so it can
// advertise it to other sleds.
//
// TODO-security This ddmd_client is used to advertise both this
// (underlay) address and our bootstrap address. Bootstrap addresses are
// unauthenticated (connections made on them are auth'd via sprockets),
// but underlay addresses should be exchanged via authenticated channels
// between ddmd instances. It's TBD how that will work, but presumably
// we'll need to do something different here for underlay vs bootstrap
// addrs (either talk to a differently-configured ddmd, or include info
// indicating which kind of address we're advertising).
self.ddmd_client.advertise_prefix(request.subnet);

Ok(SledAgentResponse { id: request.id })
}
// We have previously initialized a sled agent.
Expand Down

0 comments on commit fa7db65

Please sign in to comment.