feat(mutelist): add description field (#6221)

Co-authored-by: Pepe Fagoaga <pepe@prowler.com>
This commit is contained in:
Pedro Martín
2024-12-17 15:13:55 +01:00
committed by GitHub
parent 0ec3ed8be7
commit 001fa60a11
8 changed files with 12 additions and 0 deletions
+5
View File
@@ -42,6 +42,7 @@ Mutelist:
Resources:
- "user-1" # Will mute user-1 in check iam_user_hardware_mfa_enabled
- "user-2" # Will mute user-2 in check iam_user_hardware_mfa_enabled
Description: "Findings related with the check iam_user_hardware_mfa_enabled will be muted for us-east-1 region and user-1, user-2 resources"
"ec2_*":
Regions:
- "*"
@@ -140,6 +141,9 @@ Mutelist:
| `resource` | The resource identifier. Use `*` to apply the mutelist to all resources. | `ANDed` |
| `tag` | The tag value. | `ORed` |
### Description
This field can be used to add information or some hints for the Mutelist rule.
## How to Use the Mutelist
@@ -171,6 +175,7 @@ If you want to mute failed findings only in specific regions, create a file with
- "ap-southeast-2"
Resources:
- "*"
Description: "Description related with the muted findings for the check"
### Default Mutelist
For the AWS Provider, Prowler is executed with a default AWS Mutelist with the AWS Resources that should be muted such as all resources created by AWS Control Tower when setting up a landing zone that can be found in [AWS Documentation](https://docs.aws.amazon.com/controltower/latest/userguide/shared-account-resources.html).
+1
View File
@@ -10,6 +10,7 @@ Mutelist:
- "*"
Resources:
- "aws-controltower-NotificationForwarder"
Description: "Checks from AWS lambda functions muted by default"
"cloudformation_stack*":
Regions:
- "*"
+1
View File
@@ -14,6 +14,7 @@ Mutelist:
Resources:
- "user-1" # Will ignore user-1 in check iam_user_hardware_mfa_enabled
- "user-2" # Will ignore user-2 in check iam_user_hardware_mfa_enabled
Description: "Check iam_user_hardware_mfa_enabled muted for region us-east-1 and resources user-1, user-2"
"ec2_*":
Regions:
- "*"
@@ -15,6 +15,7 @@ Mutelist:
Resources:
- "sqlserver1" # Will ignore sqlserver1 in check sqlserver_tde_encryption_enabled located in westeurope
- "sqlserver2" # Will ignore sqlserver2 in check sqlserver_tde_encryption_enabled located in westeurope
Description: "Findings related with the check sqlserver_tde_encryption_enabled is muted for westeurope region and sqlserver1, sqlserver2 resources"
"defender_*":
Regions:
- "*"
+1
View File
@@ -15,6 +15,7 @@ Mutelist:
Resources:
- "instance1" # Will ignore instance1 in check compute_instance_public_ip located in europe-southwest1
- "instance2" # Will ignore instance2 in check compute_instance_public_ip located in europe-southwest1
Description: "Findings related with the check compute_instance_public_ip will be muted for europe-southwest1 region and instance1, instance2 resources"
"iam_*":
Regions:
- "*"
@@ -15,6 +15,7 @@ Mutelist:
Resources:
- "prowler-pod1" # Will ignore prowler-pod1 in check core_minimize_allowPrivilegeEscalation_containers located in namespace1
- "prowler-pod2" # Will ignore prowler-pod2 in check core_minimize_allowPrivilegeEscalation_containers located in namespace1
Description: "Findings related with the check core_minimize_allowPrivilegeEscalation_containers will be muted for namespace1 region and prowler-pod1, prowler-pod2 resources"
"kubelet_*":
Regions:
- "*"
+1
View File
@@ -15,6 +15,7 @@ mutelist_schema = Schema(
Optional("Resources"): list,
Optional("Tags"): list,
},
Optional("Description"): str,
}
}
}
+1
View File
@@ -106,6 +106,7 @@ class Mutelist(ABC):
- 'i-123456789'
Tags:
- 'Name=AdminInstance | Environment=Prod'
Description: 'Field to describe why the findings associated with these values are muted'
```
The check `ec2_instance_detailed_monitoring_enabled` will be muted for all accounts and regions and for the resource_id 'i-123456789' with at least one of the tags 'Name=AdminInstance' or 'Environment=Prod'.