363
// Here we handle authorization for all such commands: SignalExternalWorkflow,
364
// StartChildWorkflow, and RequestCancelExternalWorkflow targeting a different namespace.
365
>
wftRequest, ok := req.(*workflowservice.RespondWorkflowTaskCompletedRequest)
interceptor.go
366
>
if !ok {
367
return nil
368
}
369
370
// Track namespace+API combinations we've already authorized to avoid duplicate checks
371
>
authorizedNamespaceAPIs := make(map[string]struct{})
interceptor.go
372
>
373
>
for _, cmd := range wftRequest.GetCommands() {
374
>
var targetNamespace string
375
>
var apiName string
376
>
377
>
switch cmd.GetCommandType() {
378
case enumspb.COMMAND_TYPE_SIGNAL_EXTERNAL_WORKFLOW_EXECUTION:
379
if attr := cmd.GetSignalExternalWorkflowExecutionCommandAttributes(); attr != nil {