mirror of
https://github.com/slackhq/nebula.git
synced 2026-11-15 19:16:52 +01:00
Relays always speak directly with peers; enforced RelayRequest msgs (#1980)
* Relays always speak directly with peers; enforce this in RelayRequest messages
This commit is contained in:
1 parent
f552cebc51
commit
fb2c153dfa
2 files changed
+61
No files matched your search
@@ -528,6 +528,10 @@ func (rm *relayManager) handleCreateRelayRequest(v cert.Version, h *HostInfo, f
|
||||
if !rm.GetAmRelay() {
|
||||
return
|
||||
}
|
||||
if !slices.Contains(h.vpnAddrs, from) {
|
||||
logMsg.Info("Discarding relay request where relayFrom is not the sending peer")
|
||||
return
|
||||
}
|
||||
peer := rm.hostmap.QueryVpnAddr(target)
|
||||
if peer == nil {
|
||||
// Try to establish a connection to this host. If we get a future relay request,
|
||||
|
||||
Reference in new issue
Block a user