Github user nir-sopher commented on a diff in the pull request: https://github.com/apache/incubator-trafficcontrol/pull/831#discussion_r134098817 --- Diff: traffic_ops/app/lib/API/DeliveryService/KeysUrlSig.pm --- @@ -69,14 +86,17 @@ sub copy_url_sig_keys { else { return $self->alert("Delivery Service to copy from '$copy_from_xml_id' does not exist."); } + if (!$tenant_utils->is_ds_resource_accessible($tenants_data, $copy_rs->tenant_id)) { + return $self->forbidden("Forbidden. Source delivery-service tenant is not available to the user."); + } my $copy_config_file = $self->url_sig_config_file_name($copy_from_xml_id); my $helper = new Utils::Helper( { mojo => $self } ); my $url_sig_key_values_json; #verify we can copy keys out if ( $helper->is_valid_delivery_service($copy_ds_id) ) { - if ( $is_admin || $helper->is_delivery_service_assigned($copy_ds_id) ) { + if ( $is_admin || $helper->is_delivery_service_assigned($copy_ds_id) || $tenant_utils->use_tenancy()) { --- End diff -- Correct, the "|| use_tenancy" in this line come only to disable the legacy tests in case we use tenancy. If the tenancy is on, we will not even get to this line (we will exit on line 90)
--- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. ---