From 43ae0affbc6ca3159b8499b057b477194d48a8dd Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 23 Sep 2024 19:35:31 +0000 Subject: [PATCH 1/2] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/pre-commit/pre-commit-hooks: v4.4.0 → v4.6.0](https://github.com/pre-commit/pre-commit-hooks/compare/v4.4.0...v4.6.0) - [github.com/antonbabenko/pre-commit-terraform: v1.77.0 → v1.96.1](https://github.com/antonbabenko/pre-commit-terraform/compare/v1.77.0...v1.96.1) --- .pre-commit-config.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 11d16c9..5351bab 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -2,7 +2,7 @@ # See https://pre-commit.com/hooks.html for more hooks repos: - repo: https://github.com/pre-commit/pre-commit-hooks - rev: v4.4.0 + rev: v4.6.0 hooks: - id: trailing-whitespace - id: end-of-file-fixer @@ -10,7 +10,7 @@ repos: args: ["--allow-multiple-documents"] - id: check-added-large-files - repo: https://github.com/antonbabenko/pre-commit-terraform - rev: v1.77.0 # Get the latest from: https://github.com/antonbabenko/pre-commit-terraform/releases + rev: v1.96.1 # Get the latest from: https://github.com/antonbabenko/pre-commit-terraform/releases hooks: - id: terraform_fmt # args: ["--enable require-variable-braces,deprecate-which"] - id: terraform_tflint From ca50dacb656ccde8272b167aa37e43ae243d63e6 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 23 Sep 2024 19:36:11 +0000 Subject: [PATCH 2/2] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- account_alias/README.md | 2 +- account_alias/main.tf | 2 +- role/main.tf | 10 +++++----- role/variables.tf | 2 +- sdl_logs/README.md | 1 - sdl_logs/eventbridge.tf | 6 +++--- sdl_logs/guardduty.tf | 2 +- sdl_logs/kms.tf | 2 +- sdl_logs/main.tf | 1 - sdl_logs/s3.tf | 4 ++-- sdl_logs/sns.tf | 2 +- security-alerts/cloudwatch.tf | 2 +- security-alerts/code/sechub_transform.py | 4 ++-- security-alerts/data.tf | 2 +- security-alerts/events.tf | 2 +- security-alerts/iam.tf | 2 +- security-alerts/lambda.tf | 2 +- security-alerts/step_function.tf | 2 +- security-alerts/variables.tf | 2 +- 19 files changed, 25 insertions(+), 27 deletions(-) diff --git a/account_alias/README.md b/account_alias/README.md index 2d0e002..6efbd50 100644 --- a/account_alias/README.md +++ b/account_alias/README.md @@ -2,4 +2,4 @@ Sets the account alias for an AWS account. https://docs.aws.amazon.com/IAM/latest/UserGuide/console_account-alias.html -Variable account_alias will be set for the account, e.g. "batcave-dev". Queryable with [ListAccountAliases](https://docs.aws.amazon.com/IAM/latest/APIReference/API_ListAccountAliases.html) \ No newline at end of file +Variable account_alias will be set for the account, e.g. "batcave-dev". Queryable with [ListAccountAliases](https://docs.aws.amazon.com/IAM/latest/APIReference/API_ListAccountAliases.html) diff --git a/account_alias/main.tf b/account_alias/main.tf index bb9e232..50eff4d 100644 --- a/account_alias/main.tf +++ b/account_alias/main.tf @@ -9,4 +9,4 @@ variable "alias_name" { condition = length(var.alias_name) >= 3 && length(var.alias_name) <= 63 error_message = "Account Alias must have between 3 and 63 characters." } -} \ No newline at end of file +} diff --git a/role/main.tf b/role/main.tf index 17994c7..4e53c41 100644 --- a/role/main.tf +++ b/role/main.tf @@ -10,7 +10,7 @@ resource "aws_iam_role" "api-service-role" { permissions_boundary = var.permissions_boundary tags = var.tags assume_role_policy = <<-EOF - { + { "Version": "2012-10-17", "Statement": [ { @@ -39,7 +39,7 @@ resource "aws_iam_role" "job-scheduler-service-role" { permissions_boundary = var.permissions_boundary tags = var.tags assume_role_policy = <<-EOF - { + { "Version": "2012-10-17", "Statement": [ { @@ -70,7 +70,7 @@ resource "aws_iam_role" "cms-cloud-s3-snowflake-role" { assume_role_policy = <<-EOF { "Version": "2012-10-17", - "Statement": + "Statement": [ { "Effect": "Allow", @@ -84,10 +84,10 @@ resource "aws_iam_role" "cms-cloud-s3-snowflake-role" { "StringEquals": { "sts:ExternalId": "${var.SDLExternalId}" } - } + } } ] - } + } EOF } diff --git a/role/variables.tf b/role/variables.tf index 5709602..941e33a 100644 --- a/role/variables.tf +++ b/role/variables.tf @@ -61,4 +61,4 @@ variable "tags" { description = "A mapping of tags to assign to all resources" type = map(string) default = {} -} \ No newline at end of file +} diff --git a/sdl_logs/README.md b/sdl_logs/README.md index 0ae14dc..8a3c37c 100644 --- a/sdl_logs/README.md +++ b/sdl_logs/README.md @@ -1,4 +1,3 @@ # SDL logs Sends all object create events on the logging bucket to eventbridge, a trigger to SNS, and connection to the Panther SQS queue for ingestion. - diff --git a/sdl_logs/eventbridge.tf b/sdl_logs/eventbridge.tf index 06718de..0cdf132 100644 --- a/sdl_logs/eventbridge.tf +++ b/sdl_logs/eventbridge.tf @@ -42,9 +42,9 @@ resource "aws_cloudwatch_event_target" "target" { "awsRegion":, "eventTime":