Skip to content

Commit

Permalink
check netbox_to_diode key for any non-internal method
Browse files Browse the repository at this point in the history
  • Loading branch information
ltucker committed Dec 30, 2024
1 parent 6465edc commit bbbb511
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions diode-server/reconciler/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -177,14 +177,12 @@ func isAuthenticated(logger *slog.Logger, rpcMethod string, apiKeys APIKeys, aut
return false
}
return apiKey == ingesterToReconcilerAPIKey
case reconcilerpb.ReconcilerService_RetrieveIngestionLogs_FullMethodName:
default:
netboxToDiode, ok := apiKeys["NETBOX_TO_DIODE"]
if !ok {
logger.Debug("missing NETBOX_TO_DIODE API key")
return false
}
return apiKey == netboxToDiode
}

return false
}

0 comments on commit bbbb511

Please sign in to comment.