Skip to content

Commit 800e492

Browse files
committed
fix(exclusions): excluding results against files in the scanners directory
1 parent fdba3b2 commit 800e492

File tree

3 files changed

+11
-10
lines changed

3 files changed

+11
-10
lines changed

automated_security_helper/plugin_modules/ash_aws_plugins/cloudwatch_logs_reporter.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
from datetime import datetime, timezone
44
import json
55
import logging
6+
import os
67
from pydantic import Field
78
import boto3
89

@@ -28,8 +29,8 @@ class CloudWatchLogsReporterConfigOptions(ReporterOptionsBase):
2829
Field(
2930
pattern=r"(af|il|ap|ca|eu|me|sa|us|cn|us-gov|us-iso|us-isob)-(central|north|(north(?:east|west))|south|south(?:east|west)|east|west)-\d{1}"
3031
),
31-
] = None
32-
log_group_name: str | None = None
32+
] = os.environ.get("AWS_REGION", os.environ.get("AWS_DEFAULT_REGION", None))
33+
log_group_name: str | None = os.environ.get("ASH_LOG_GROUP_NAME", None)
3334
log_stream_name: str = "ASHScanResults"
3435

3536

automated_security_helper/schemas/AshAggregatedResults.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1418,7 +1418,7 @@
14181418
"name": "cloudwatch-logs",
14191419
"options": {
14201420
"aws_account_id": null,
1421-
"aws_region": null,
1421+
"aws_region": "us-west-2",
14221422
"log_group_name": null,
14231423
"log_stream_name": "ASHScanResults"
14241424
}
@@ -2786,7 +2786,7 @@
27862786
"$ref": "#/$defs/CloudWatchLogsReporterConfigOptions",
27872787
"default": {
27882788
"aws_account_id": null,
2789-
"aws_region": null,
2789+
"aws_region": "us-west-2",
27902790
"log_group_name": null,
27912791
"log_stream_name": "ASHScanResults"
27922792
}
@@ -2821,7 +2821,7 @@
28212821
"type": "null"
28222822
}
28232823
],
2824-
"default": null,
2824+
"default": "us-west-2",
28252825
"title": "Aws Region"
28262826
},
28272827
"log_group_name": {
@@ -12916,7 +12916,7 @@
1291612916
"name": "cloudwatch-logs",
1291712917
"options": {
1291812918
"aws_account_id": null,
12919-
"aws_region": null,
12919+
"aws_region": "us-west-2",
1292012920
"log_group_name": null,
1292112921
"log_stream_name": "ASHScanResults"
1292212922
}

automated_security_helper/schemas/AshConfig.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -180,7 +180,7 @@
180180
"name": "cloudwatch-logs",
181181
"options": {
182182
"aws_account_id": null,
183-
"aws_region": null,
183+
"aws_region": "us-west-2",
184184
"log_group_name": null,
185185
"log_stream_name": "ASHScanResults"
186186
}
@@ -1022,7 +1022,7 @@
10221022
"$ref": "#/$defs/CloudWatchLogsReporterConfigOptions",
10231023
"default": {
10241024
"aws_account_id": null,
1025-
"aws_region": null,
1025+
"aws_region": "us-west-2",
10261026
"log_group_name": null,
10271027
"log_stream_name": "ASHScanResults"
10281028
}
@@ -1057,7 +1057,7 @@
10571057
"type": "null"
10581058
}
10591059
],
1060-
"default": null,
1060+
"default": "us-west-2",
10611061
"title": "Aws Region"
10621062
},
10631063
"log_group_name": {
@@ -2064,7 +2064,7 @@
20642064
"name": "cloudwatch-logs",
20652065
"options": {
20662066
"aws_account_id": null,
2067-
"aws_region": null,
2067+
"aws_region": "us-west-2",
20682068
"log_group_name": null,
20692069
"log_stream_name": "ASHScanResults"
20702070
}

0 commit comments

Comments
 (0)