mirror of
https://github.com/ghndrx/prowler.git
synced 2026-02-10 14:55:00 +00:00
feat(shub_compatibility): send finding to filter regions and change checkType to list (#1341)
This commit is contained in:
@@ -304,7 +304,7 @@ def get_organizations_metadata(
|
||||
return organizations_info
|
||||
|
||||
|
||||
def generate_regional_clients(service, audit_info):
|
||||
def generate_regional_clients(service: str, audit_info: AWS_Audit_Info) -> dict:
|
||||
regional_clients = {}
|
||||
# Get json locally
|
||||
f = open_file(aws_services_json_file)
|
||||
@@ -322,3 +322,10 @@ def generate_regional_clients(service, audit_info):
|
||||
regional_clients[region] = regional_client
|
||||
# regional_clients.append(regional_client)
|
||||
return regional_clients
|
||||
|
||||
|
||||
def get_region_global_service(audit_info: AWS_Audit_Info) -> str:
|
||||
# Check if global service to send the finding to first audited region
|
||||
if audit_info.audited_regions:
|
||||
return audit_info.audited_regions[0]
|
||||
return audit_info.profile_region
|
||||
|
||||
Reference in New Issue
Block a user