You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Trivy will check the following folders:
terraform/environments/electronic-monitoring-data
terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
Running Trivy in terraform/environments/electronic-monitoring-data
2025-01-16T11:47:57Z INFO [vulndb] Need to update DB
2025-01-16T11:47:57Z INFO [vulndb] Downloading vulnerability DB...
2025-01-16T11:47:57Z INFO [vulndb] Downloading artifact... repo="public.ecr.aws/aquasecurity/trivy-db:2"
2025-01-16T11:47:59Z INFO [vulndb] Artifact successfully downloaded repo="public.ecr.aws/aquasecurity/trivy-db:2"
2025-01-16T11:47:59Z INFO [vuln] Vulnerability scanning is enabled
2025-01-16T11:47:59Z INFO [misconfig] Misconfiguration scanning is enabled
2025-01-16T11:47:59Z INFO [misconfig] Need to update the built-in checks
2025-01-16T11:47:59Z INFO [misconfig] Downloading the built-in checks...
160.80 KiB / 160.80 KiB [---------------------------------------------------------] 100.00% ? p/s 0s2025-01-16T11:48:00Z INFO [secret] Secret scanning is enabled
2025-01-16T11:48:00Z INFO [secret] If your scanning is slow, please try '--scanners vuln' to disable secret scanning
2025-01-16T11:48:00Z INFO [secret] Please see also https://aquasecurity.github.io/trivy/v0.57/docs/scanner/secret#recommendation for faster secret detection
2025-01-16T11:48:01Z INFO [terraform scanner] Scanning root module file_path="."
2025-01-16T11:48:01Z WARN [terraform parser] Variable values was not found in the environment or variable files. Evaluating may not work correctly. module="root" variables="networking"
2025-01-16T11:48:03Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.api_gateway_authorizer.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:48:03Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.api_gateway_authorizer.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:48:03Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.calculate_checksum.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:48:03Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.calculate_checksum.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:48:03Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.copy_mdss_data.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:48:03Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.copy_mdss_data.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:48:03Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.format_json_fms_data.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:48:03Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.format_json_fms_data.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:48:03Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:48:03Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:48:03Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.rds_bastion.aws_s3_object.user_public_keys" value="cty.NilVal"
2025-01-16T11:48:03Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.rds_bastion.data.aws_subnet.local_account" value="cty.NilVal"
2025-01-16T11:48:03Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.rds_bastion.aws_autoscaling_group.bastion_linux_daily" err="1 error occurred:\n\t* invalid for-each in aws_autoscaling_group.bastion_linux_daily.dynamic.tag block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:48:03Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.rds_bastion.aws_autoscaling_group.bastion_linux_daily" err="1 error occurred:\n\t* invalid for-each in aws_autoscaling_group.bastion_linux_daily.dynamic.tag block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:48:03Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.rotate_iam_key.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:48:03Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.rotate_iam_key.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:48:03Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:48:03Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:48:04Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:48:04Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:48:04Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:48:04Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:48:04Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:48:04Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:48:04Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:48:04Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:48:04Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:48:04Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:48:04Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.s3-mdss-general-landing-bucket.module.kms_key.aws_kms_grant.this" value="cty.NilVal"
2025-01-16T11:48:04Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:48:04Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:48:04Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-general-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:48:04Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-general-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:48:04Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.s3-mdss-ho-landing-bucket.module.kms_key.aws_kms_grant.this" value="cty.NilVal"
2025-01-16T11:48:04Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-ho-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:48:04Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-ho-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:48:04Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-ho-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:48:04Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-ho-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:48:05Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.s3-mdss-specials-landing-bucket.module.kms_key.aws_kms_grant.this" value="cty.NilVal"
2025-01-16T11:48:05Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:48:05Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:48:05Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-specials-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:48:05Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-specials-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:48:05Z INFO [terraform scanner] Scanning root module file_path="glue-job/Archived"
2025-01-16T11:48:12Z INFO [terraform executor] Ignore finding rule="aws-s3-enable-versioning" range="s3.tf:1133-1152"
2025-01-16T11:48:12Z INFO [terraform executor] Ignore finding rule="aws-iam-no-user-attached-policies" range="modules/landing_bucket_iam_user_access/main.tf:2-10"
2025-01-16T11:48:12Z INFO [terraform executor] Ignore finding rule="aws-iam-no-user-attached-policies" range="modules/landing_bucket_iam_user_access/main.tf:2-10"
2025-01-16T11:48:12Z INFO [terraform executor] Ignore finding rule="aws-s3-enable-bucket-encryption" range="s3.tf:1133-1152"
2025-01-16T11:48:12Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T11:48:12Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T11:48:12Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T11:48:12Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T11:48:12Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T11:48:12Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T11:48:12Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T11:48:12Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T11:48:12Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T11:48:12Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T11:48:12Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T11:48:12Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T11:48:12Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T11:48:12Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T11:48:12Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T11:48:12Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T11:48:12Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-bastion-linux?ref=95ed3c3/github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=568694e50e03630d99cb569eafa06a0b879a1239/main.tf:171-179"
2025-01-16T11:48:12Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="s3.tf:1133-1152"
2025-01-16T11:48:12Z INFO [terraform executor] Ignore finding rule="aws-cloudwatch-log-group-customer-key" range="modules/api_step_function/main.tf:295-300"
2025-01-16T11:48:12Z INFO [terraform executor] Ignore finding rule="aws-cloudwatch-log-group-customer-key" range="modules/api_step_function/main.tf:421-425"
2025-01-16T11:48:12Z INFO [terraform executor] Ignore finding rule="aws-ssm-secret-use-customer-key" range="analytical_platform_share.tf:53-71"
2025-01-16T11:48:12Z INFO [terraform executor] Ignore finding rule="aws-s3-enable-logging" range="s3.tf:1133-1152"
2025-01-16T11:48:12Z INFO Number of language-specific files num=0
2025-01-16T11:48:12Z INFO Detected config files num=13
trivy_exitcode=0
Running Trivy in terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
2025-01-16T11:48:12Z INFO [vuln] Vulnerability scanning is enabled
2025-01-16T11:48:12Z INFO [misconfig] Misconfiguration scanning is enabled
2025-01-16T11:48:12Z INFO [secret] Secret scanning is enabled
2025-01-16T11:48:12Z INFO [secret] If your scanning is slow, please try '--scanners vuln' to disable secret scanning
2025-01-16T11:48:12Z INFO [secret] Please see also https://aquasecurity.github.io/trivy/v0.57/docs/scanner/secret#recommendation for faster secret detection
2025-01-16T11:48:13Z INFO [terraform scanner] Scanning root module file_path="."
2025-01-16T11:48:13Z WARN [terraform parser] Variable values was not found in the environment or variable files. Evaluating may not work correctly. module="root" variables="data_locations, databases_to_share, destination_account_id"
2025-01-16T11:48:13Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="aws_lakeformation_data_cells_filter.data_filter" value="cty.NilVal"
2025-01-16T11:48:13Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="aws_lakeformation_permissions.data_location_share" value="cty.NilVal"
2025-01-16T11:48:13Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="aws_lakeformation_permissions.share_filtered_data" value="cty.NilVal"
2025-01-16T11:48:13Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="aws_lakeformation_resource.data_location" value="cty.NilVal"
2025-01-16T11:48:13Z INFO Number of language-specific files num=0
2025-01-16T11:48:13Z INFO Detected config files num=1
trivy_exitcode=0
</details> #### `Checkov Scan` Success
<details><summary>Show Output</summary>
```hcl
*****************************
Checkov will check the following folders:
terraform/environments/electronic-monitoring-data
terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
*****************************
Running Checkov in terraform/environments/electronic-monitoring-data
Excluding the following checks: CKV_GIT_1,CKV_AWS_126,CKV2_AWS_38,CKV2_AWS_39
2025-01-16 11:48:16,458 [MainThread ] [WARNI] Failed to download module github.com/ministryofjustice/modernisation-platform-terraform-bastion-linux?ref=95ed3c3:None (for external modules, the --download-external-modules flag is required)
2025-01-16 11:48:16,458 [MainThread ] [WARNI] Failed to download module github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060:None (for external modules, the --download-external-modules flag is required)
2025-01-16 11:48:16,459 [MainThread ] [WARNI] Failed to download module terraform-aws-modules/iam/aws//modules/iam-assumable-role:5.48.0 (for external modules, the --download-external-modules flag is required)
2025-01-16 11:48:16,459 [MainThread ] [WARNI] Failed to download module terraform-aws-modules/kms/aws:3.1.1 (for external modules, the --download-external-modules flag is required)
2025-01-16 11:48:16,459 [MainThread ] [WARNI] Failed to download module terraform-aws-modules/secrets-manager/aws:1.3.0 (for external modules, the --download-external-modules flag is required)
terraform scan results:
Passed checks: 2752, Failed checks: 0, Skipped checks: 120
checkov_exitcode=0
*****************************
Running Checkov in terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
Excluding the following checks: CKV_GIT_1,CKV_AWS_126,CKV2_AWS_38,CKV2_AWS_39
checkov_exitcode=0
CTFLint Scan Success
Show Output
*****************************
Setting default tflint config...
Running tflint --init...
Installing "terraform" plugin...
Installed "terraform" (source: github.com/terraform-linters/tflint-ruleset-terraform, version:0.9.1)
tflint will check the following folders:
terraform/environments/electronic-monitoring-data
terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
*****************************
Running tflint in terraform/environments/electronic-monitoring-data
Excluding the following checks: terraform_unused_declarations
tflint_exitcode=0*****************************
Running tflint in terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
Excluding the following checks: terraform_unused_declarations
tflint_exitcode=0
Trivy Scan Success
Show Output
*****************************
Trivy will check the following folders:
terraform/environments/electronic-monitoring-data
terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
*****************************
Running Trivy in terraform/environments/electronic-monitoring-data
2025-01-16T11:47:57Z INFO [vulndb] Need to update DB
2025-01-16T11:47:57Z INFO [vulndb] Downloading vulnerability DB...2025-01-16T11:47:57Z INFO [vulndb] Downloading artifact...repo="public.ecr.aws/aquasecurity/trivy-db:2"2025-01-16T11:47:59Z INFO [vulndb] Artifact successfully downloaded repo="public.ecr.aws/aquasecurity/trivy-db:2"2025-01-16T11:47:59Z INFO [vuln] Vulnerability scanning is enabled
2025-01-16T11:47:59Z INFO [misconfig] Misconfiguration scanning is enabled
2025-01-16T11:47:59Z INFO [misconfig] Need to update the built-in checks
2025-01-16T11:47:59Z INFO [misconfig] Downloading the built-in checks...160.80 KiB /160.80 KiB [---------------------------------------------------------] 100.00%? p/s 0s2025-01-16T11:48:00Z INFO [secret] Secret scanning is enabled
2025-01-16T11:48:00Z INFO [secret] If your scanning is slow, please try '--scanners vuln' to disable secret scanning
2025-01-16T11:48:00Z INFO [secret] Please see also https://aquasecurity.github.io/trivy/v0.57/docs/scanner/secret#recommendation for faster secret detection2025-01-16T11:48:01Z INFO [terraformscanner] Scanning root module file_path="."2025-01-16T11:48:01Z WARN [terraformparser] Variable values was not found in the environment or variable files. Evaluating may not work correctly.module="root"variables="networking"2025-01-16T11:48:03Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.api_gateway_authorizer.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:48:03Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.api_gateway_authorizer.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:48:03Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.calculate_checksum.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:48:03Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.calculate_checksum.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:48:03Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.copy_mdss_data.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:48:03Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.copy_mdss_data.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:48:03Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.format_json_fms_data.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:48:03Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.format_json_fms_data.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:48:03Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:48:03Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:48:03Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.rds_bastion.aws_s3_object.user_public_keys"value="cty.NilVal"2025-01-16T11:48:03Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.rds_bastion.data.aws_subnet.local_account"value="cty.NilVal"2025-01-16T11:48:03Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.rds_bastion.aws_autoscaling_group.bastion_linux_daily"err="1 error occurred:\n\t* invalid for-each in aws_autoscaling_group.bastion_linux_daily.dynamic.tag block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:48:03Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.rds_bastion.aws_autoscaling_group.bastion_linux_daily"err="1 error occurred:\n\t* invalid for-each in aws_autoscaling_group.bastion_linux_daily.dynamic.tag block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:48:03Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.rotate_iam_key.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:48:03Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.rotate_iam_key.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:48:03Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:48:03Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:48:04Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:48:04Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:48:04Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:48:04Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:48:04Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:48:04Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:48:04Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:48:04Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:48:04Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:48:04Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:48:04Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.s3-mdss-general-landing-bucket.module.kms_key.aws_kms_grant.this"value="cty.NilVal"2025-01-16T11:48:04Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:48:04Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:48:04Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-general-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:48:04Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-general-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:48:04Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.s3-mdss-ho-landing-bucket.module.kms_key.aws_kms_grant.this"value="cty.NilVal"2025-01-16T11:48:04Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-ho-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:48:04Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-ho-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:48:04Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-ho-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:48:04Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-ho-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:48:05Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.s3-mdss-specials-landing-bucket.module.kms_key.aws_kms_grant.this"value="cty.NilVal"2025-01-16T11:48:05Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:48:05Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:48:05Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-specials-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:48:05Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-specials-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:48:05Z INFO [terraformscanner] Scanning root module file_path="glue-job/Archived"2025-01-16T11:48:12Z INFO [terraformexecutor] Ignore finding rule="aws-s3-enable-versioning"range="s3.tf:1133-1152"2025-01-16T11:48:12Z INFO [terraformexecutor] Ignore finding rule="aws-iam-no-user-attached-policies"range="modules/landing_bucket_iam_user_access/main.tf:2-10"2025-01-16T11:48:12Z INFO [terraformexecutor] Ignore finding rule="aws-iam-no-user-attached-policies"range="modules/landing_bucket_iam_user_access/main.tf:2-10"2025-01-16T11:48:12Z INFO [terraformexecutor] Ignore finding rule="aws-s3-enable-bucket-encryption"range="s3.tf:1133-1152"2025-01-16T11:48:12Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T11:48:12Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T11:48:12Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T11:48:12Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T11:48:12Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T11:48:12Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T11:48:12Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T11:48:12Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T11:48:12Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T11:48:12Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T11:48:12Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T11:48:12Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T11:48:12Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T11:48:12Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T11:48:12Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T11:48:12Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T11:48:12Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-bastion-linux?ref=95ed3c3/github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=568694e50e03630d99cb569eafa06a0b879a1239/main.tf:171-179"2025-01-16T11:48:12Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="s3.tf:1133-1152"2025-01-16T11:48:12Z INFO [terraformexecutor] Ignore finding rule="aws-cloudwatch-log-group-customer-key"range="modules/api_step_function/main.tf:295-300"2025-01-16T11:48:12Z INFO [terraformexecutor] Ignore finding rule="aws-cloudwatch-log-group-customer-key"range="modules/api_step_function/main.tf:421-425"2025-01-16T11:48:12Z INFO [terraformexecutor] Ignore finding rule="aws-ssm-secret-use-customer-key"range="analytical_platform_share.tf:53-71"2025-01-16T11:48:12Z INFO [terraformexecutor] Ignore finding rule="aws-s3-enable-logging"range="s3.tf:1133-1152"2025-01-16T11:48:12Z INFO Number of language-specific files num=02025-01-16T11:48:12Z INFO Detected config files num=13trivy_exitcode=0*****************************
Running Trivy in terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
2025-01-16T11:48:12Z INFO [vuln] Vulnerability scanning is enabled
2025-01-16T11:48:12Z INFO [misconfig] Misconfiguration scanning is enabled
2025-01-16T11:48:12Z INFO [secret] Secret scanning is enabled
2025-01-16T11:48:12Z INFO [secret] If your scanning is slow, please try '--scanners vuln' to disable secret scanning
2025-01-16T11:48:12Z INFO [secret] Please see also https://aquasecurity.github.io/trivy/v0.57/docs/scanner/secret#recommendation for faster secret detection2025-01-16T11:48:13Z INFO [terraformscanner] Scanning root module file_path="."2025-01-16T11:48:13Z WARN [terraformparser] Variable values was not found in the environment or variable files. Evaluating may not work correctly.module="root"variables="data_locations, databases_to_share, destination_account_id"2025-01-16T11:48:13Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="aws_lakeformation_data_cells_filter.data_filter"value="cty.NilVal"2025-01-16T11:48:13Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="aws_lakeformation_permissions.data_location_share"value="cty.NilVal"2025-01-16T11:48:13Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="aws_lakeformation_permissions.share_filtered_data"value="cty.NilVal"2025-01-16T11:48:13Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="aws_lakeformation_resource.data_location"value="cty.NilVal"2025-01-16T11:48:13Z INFO Number of language-specific files num=02025-01-16T11:48:13Z INFO Detected config files num=1trivy_exitcode=0
Trivy will check the following folders:
terraform/environments/electronic-monitoring-data
terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
Running Trivy in terraform/environments/electronic-monitoring-data
2025-01-16T11:54:03Z INFO [vulndb] Need to update DB
2025-01-16T11:54:03Z INFO [vulndb] Downloading vulnerability DB...
2025-01-16T11:54:03Z INFO [vulndb] Downloading artifact... repo="public.ecr.aws/aquasecurity/trivy-db:2"
2025-01-16T11:54:06Z INFO [vulndb] Artifact successfully downloaded repo="public.ecr.aws/aquasecurity/trivy-db:2"
2025-01-16T11:54:06Z INFO [vuln] Vulnerability scanning is enabled
2025-01-16T11:54:06Z INFO [misconfig] Misconfiguration scanning is enabled
2025-01-16T11:54:06Z INFO [misconfig] Need to update the built-in checks
2025-01-16T11:54:06Z INFO [misconfig] Downloading the built-in checks...
160.80 KiB / 160.80 KiB [---------------------------------------------------------] 100.00% ? p/s 0s2025-01-16T11:54:07Z INFO [secret] Secret scanning is enabled
2025-01-16T11:54:07Z INFO [secret] If your scanning is slow, please try '--scanners vuln' to disable secret scanning
2025-01-16T11:54:07Z INFO [secret] Please see also https://aquasecurity.github.io/trivy/v0.57/docs/scanner/secret#recommendation for faster secret detection
2025-01-16T11:54:08Z INFO [terraform scanner] Scanning root module file_path="."
2025-01-16T11:54:08Z WARN [terraform parser] Variable values was not found in the environment or variable files. Evaluating may not work correctly. module="root" variables="networking"
2025-01-16T11:54:11Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.api_gateway_authorizer.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:54:11Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.api_gateway_authorizer.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:54:11Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.calculate_checksum.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:54:11Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.calculate_checksum.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:54:11Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.copy_mdss_data.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:54:11Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.copy_mdss_data.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:54:11Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.format_json_fms_data.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:54:11Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.format_json_fms_data.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:54:11Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:54:11Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:54:11Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.rds_bastion.aws_s3_object.user_public_keys" value="cty.NilVal"
2025-01-16T11:54:11Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.rds_bastion.data.aws_subnet.local_account" value="cty.NilVal"
2025-01-16T11:54:11Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.rds_bastion.aws_autoscaling_group.bastion_linux_daily" err="1 error occurred:\n\t* invalid for-each in aws_autoscaling_group.bastion_linux_daily.dynamic.tag block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:54:11Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.rds_bastion.aws_autoscaling_group.bastion_linux_daily" err="1 error occurred:\n\t* invalid for-each in aws_autoscaling_group.bastion_linux_daily.dynamic.tag block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:54:12Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.rotate_iam_key.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:54:12Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.rotate_iam_key.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:54:12Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:54:12Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:54:12Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:54:12Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:54:13Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:54:13Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:54:13Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:54:13Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:54:13Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:54:13Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:54:13Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:54:13Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:54:13Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.s3-mdss-general-landing-bucket.module.kms_key.aws_kms_grant.this" value="cty.NilVal"
2025-01-16T11:54:13Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:54:13Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:54:13Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-general-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:54:13Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-general-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:54:13Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.s3-mdss-ho-landing-bucket.module.kms_key.aws_kms_grant.this" value="cty.NilVal"
2025-01-16T11:54:13Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-ho-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:54:13Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-ho-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:54:13Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-ho-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:54:13Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-ho-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:54:13Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.s3-mdss-specials-landing-bucket.module.kms_key.aws_kms_grant.this" value="cty.NilVal"
2025-01-16T11:54:13Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:54:13Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:54:13Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-specials-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:54:13Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-specials-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T11:54:13Z INFO [terraform scanner] Scanning root module file_path="glue-job/Archived"
2025-01-16T11:54:21Z INFO [terraform executor] Ignore finding rule="aws-s3-enable-logging" range="s3.tf:1133-1152"
2025-01-16T11:54:21Z INFO [terraform executor] Ignore finding rule="aws-cloudwatch-log-group-customer-key" range="modules/api_step_function/main.tf:295-300"
2025-01-16T11:54:21Z INFO [terraform executor] Ignore finding rule="aws-cloudwatch-log-group-customer-key" range="modules/api_step_function/main.tf:421-425"
2025-01-16T11:54:21Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T11:54:21Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T11:54:21Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T11:54:21Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T11:54:21Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T11:54:21Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T11:54:21Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T11:54:21Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T11:54:21Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T11:54:21Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T11:54:21Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T11:54:21Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T11:54:21Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T11:54:21Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T11:54:21Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T11:54:21Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T11:54:21Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-bastion-linux?ref=95ed3c3/github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=568694e50e03630d99cb569eafa06a0b879a1239/main.tf:171-179"
2025-01-16T11:54:21Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="s3.tf:1133-1152"
2025-01-16T11:54:21Z INFO [terraform executor] Ignore finding rule="aws-s3-enable-versioning" range="s3.tf:1133-1152"
2025-01-16T11:54:21Z INFO [terraform executor] Ignore finding rule="aws-iam-no-user-attached-policies" range="modules/landing_bucket_iam_user_access/main.tf:2-10"
2025-01-16T11:54:21Z INFO [terraform executor] Ignore finding rule="aws-iam-no-user-attached-policies" range="modules/landing_bucket_iam_user_access/main.tf:2-10"
2025-01-16T11:54:21Z INFO [terraform executor] Ignore finding rule="aws-ssm-secret-use-customer-key" range="analytical_platform_share.tf:53-71"
2025-01-16T11:54:21Z INFO [terraform executor] Ignore finding rule="aws-s3-enable-bucket-encryption" range="s3.tf:1133-1152"
2025-01-16T11:54:21Z INFO Number of language-specific files num=0
2025-01-16T11:54:21Z INFO Detected config files num=13
trivy_exitcode=0
Running Trivy in terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
2025-01-16T11:54:21Z INFO [vuln] Vulnerability scanning is enabled
2025-01-16T11:54:21Z INFO [misconfig] Misconfiguration scanning is enabled
2025-01-16T11:54:21Z INFO [secret] Secret scanning is enabled
2025-01-16T11:54:21Z INFO [secret] If your scanning is slow, please try '--scanners vuln' to disable secret scanning
2025-01-16T11:54:21Z INFO [secret] Please see also https://aquasecurity.github.io/trivy/v0.57/docs/scanner/secret#recommendation for faster secret detection
2025-01-16T11:54:22Z INFO [terraform scanner] Scanning root module file_path="."
2025-01-16T11:54:22Z WARN [terraform parser] Variable values was not found in the environment or variable files. Evaluating may not work correctly. module="root" variables="data_locations, databases_to_share, destination_account_id"
2025-01-16T11:54:22Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="aws_lakeformation_data_cells_filter.data_filter" value="cty.NilVal"
2025-01-16T11:54:22Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="aws_lakeformation_permissions.data_location_share" value="cty.NilVal"
2025-01-16T11:54:22Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="aws_lakeformation_permissions.share_filtered_data" value="cty.NilVal"
2025-01-16T11:54:22Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="aws_lakeformation_resource.data_location" value="cty.NilVal"
2025-01-16T11:54:22Z INFO Number of language-specific files num=0
2025-01-16T11:54:22Z INFO Detected config files num=1
trivy_exitcode=0
</details> #### `Checkov Scan` Success
<details><summary>Show Output</summary>
```hcl
*****************************
Checkov will check the following folders:
terraform/environments/electronic-monitoring-data
terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
*****************************
Running Checkov in terraform/environments/electronic-monitoring-data
Excluding the following checks: CKV_GIT_1,CKV_AWS_126,CKV2_AWS_38,CKV2_AWS_39
2025-01-16 11:54:25,128 [MainThread ] [WARNI] Failed to download module github.com/ministryofjustice/modernisation-platform-terraform-bastion-linux?ref=95ed3c3:None (for external modules, the --download-external-modules flag is required)
2025-01-16 11:54:25,128 [MainThread ] [WARNI] Failed to download module github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060:None (for external modules, the --download-external-modules flag is required)
2025-01-16 11:54:25,128 [MainThread ] [WARNI] Failed to download module terraform-aws-modules/iam/aws//modules/iam-assumable-role:5.48.0 (for external modules, the --download-external-modules flag is required)
2025-01-16 11:54:25,128 [MainThread ] [WARNI] Failed to download module terraform-aws-modules/kms/aws:3.1.1 (for external modules, the --download-external-modules flag is required)
2025-01-16 11:54:25,128 [MainThread ] [WARNI] Failed to download module terraform-aws-modules/secrets-manager/aws:1.3.0 (for external modules, the --download-external-modules flag is required)
terraform scan results:
Passed checks: 2752, Failed checks: 0, Skipped checks: 120
checkov_exitcode=0
*****************************
Running Checkov in terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
Excluding the following checks: CKV_GIT_1,CKV_AWS_126,CKV2_AWS_38,CKV2_AWS_39
checkov_exitcode=0
CTFLint Scan Success
Show Output
*****************************
Setting default tflint config...
Running tflint --init...
Installing "terraform" plugin...
Installed "terraform" (source: github.com/terraform-linters/tflint-ruleset-terraform, version:0.9.1)
tflint will check the following folders:
terraform/environments/electronic-monitoring-data
terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
*****************************
Running tflint in terraform/environments/electronic-monitoring-data
Excluding the following checks: terraform_unused_declarations
tflint_exitcode=0*****************************
Running tflint in terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
Excluding the following checks: terraform_unused_declarations
tflint_exitcode=0
Trivy Scan Success
Show Output
*****************************
Trivy will check the following folders:
terraform/environments/electronic-monitoring-data
terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
*****************************
Running Trivy in terraform/environments/electronic-monitoring-data
2025-01-16T11:54:03Z INFO [vulndb] Need to update DB
2025-01-16T11:54:03Z INFO [vulndb] Downloading vulnerability DB...2025-01-16T11:54:03Z INFO [vulndb] Downloading artifact...repo="public.ecr.aws/aquasecurity/trivy-db:2"2025-01-16T11:54:06Z INFO [vulndb] Artifact successfully downloaded repo="public.ecr.aws/aquasecurity/trivy-db:2"2025-01-16T11:54:06Z INFO [vuln] Vulnerability scanning is enabled
2025-01-16T11:54:06Z INFO [misconfig] Misconfiguration scanning is enabled
2025-01-16T11:54:06Z INFO [misconfig] Need to update the built-in checks
2025-01-16T11:54:06Z INFO [misconfig] Downloading the built-in checks...160.80 KiB /160.80 KiB [---------------------------------------------------------] 100.00%? p/s 0s2025-01-16T11:54:07Z INFO [secret] Secret scanning is enabled
2025-01-16T11:54:07Z INFO [secret] If your scanning is slow, please try '--scanners vuln' to disable secret scanning
2025-01-16T11:54:07Z INFO [secret] Please see also https://aquasecurity.github.io/trivy/v0.57/docs/scanner/secret#recommendation for faster secret detection2025-01-16T11:54:08Z INFO [terraformscanner] Scanning root module file_path="."2025-01-16T11:54:08Z WARN [terraformparser] Variable values was not found in the environment or variable files. Evaluating may not work correctly.module="root"variables="networking"2025-01-16T11:54:11Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.api_gateway_authorizer.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:54:11Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.api_gateway_authorizer.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:54:11Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.calculate_checksum.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:54:11Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.calculate_checksum.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:54:11Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.copy_mdss_data.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:54:11Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.copy_mdss_data.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:54:11Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.format_json_fms_data.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:54:11Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.format_json_fms_data.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:54:11Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:54:11Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:54:11Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.rds_bastion.aws_s3_object.user_public_keys"value="cty.NilVal"2025-01-16T11:54:11Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.rds_bastion.data.aws_subnet.local_account"value="cty.NilVal"2025-01-16T11:54:11Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.rds_bastion.aws_autoscaling_group.bastion_linux_daily"err="1 error occurred:\n\t* invalid for-each in aws_autoscaling_group.bastion_linux_daily.dynamic.tag block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:54:11Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.rds_bastion.aws_autoscaling_group.bastion_linux_daily"err="1 error occurred:\n\t* invalid for-each in aws_autoscaling_group.bastion_linux_daily.dynamic.tag block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:54:12Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.rotate_iam_key.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:54:12Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.rotate_iam_key.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:54:12Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:54:12Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:54:12Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:54:12Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:54:13Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:54:13Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:54:13Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:54:13Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:54:13Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:54:13Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:54:13Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:54:13Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:54:13Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.s3-mdss-general-landing-bucket.module.kms_key.aws_kms_grant.this"value="cty.NilVal"2025-01-16T11:54:13Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:54:13Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:54:13Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-general-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:54:13Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-general-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:54:13Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.s3-mdss-ho-landing-bucket.module.kms_key.aws_kms_grant.this"value="cty.NilVal"2025-01-16T11:54:13Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-ho-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:54:13Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-ho-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:54:13Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-ho-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:54:13Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-ho-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:54:13Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.s3-mdss-specials-landing-bucket.module.kms_key.aws_kms_grant.this"value="cty.NilVal"2025-01-16T11:54:13Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:54:13Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:54:13Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-specials-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:54:13Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-specials-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T11:54:13Z INFO [terraformscanner] Scanning root module file_path="glue-job/Archived"2025-01-16T11:54:21Z INFO [terraformexecutor] Ignore finding rule="aws-s3-enable-logging"range="s3.tf:1133-1152"2025-01-16T11:54:21Z INFO [terraformexecutor] Ignore finding rule="aws-cloudwatch-log-group-customer-key"range="modules/api_step_function/main.tf:295-300"2025-01-16T11:54:21Z INFO [terraformexecutor] Ignore finding rule="aws-cloudwatch-log-group-customer-key"range="modules/api_step_function/main.tf:421-425"2025-01-16T11:54:21Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T11:54:21Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T11:54:21Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T11:54:21Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T11:54:21Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T11:54:21Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T11:54:21Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T11:54:21Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T11:54:21Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T11:54:21Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T11:54:21Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T11:54:21Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T11:54:21Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T11:54:21Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T11:54:21Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T11:54:21Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T11:54:21Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-bastion-linux?ref=95ed3c3/github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=568694e50e03630d99cb569eafa06a0b879a1239/main.tf:171-179"2025-01-16T11:54:21Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="s3.tf:1133-1152"2025-01-16T11:54:21Z INFO [terraformexecutor] Ignore finding rule="aws-s3-enable-versioning"range="s3.tf:1133-1152"2025-01-16T11:54:21Z INFO [terraformexecutor] Ignore finding rule="aws-iam-no-user-attached-policies"range="modules/landing_bucket_iam_user_access/main.tf:2-10"2025-01-16T11:54:21Z INFO [terraformexecutor] Ignore finding rule="aws-iam-no-user-attached-policies"range="modules/landing_bucket_iam_user_access/main.tf:2-10"2025-01-16T11:54:21Z INFO [terraformexecutor] Ignore finding rule="aws-ssm-secret-use-customer-key"range="analytical_platform_share.tf:53-71"2025-01-16T11:54:21Z INFO [terraformexecutor] Ignore finding rule="aws-s3-enable-bucket-encryption"range="s3.tf:1133-1152"2025-01-16T11:54:21Z INFO Number of language-specific files num=02025-01-16T11:54:21Z INFO Detected config files num=13trivy_exitcode=0*****************************
Running Trivy in terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
2025-01-16T11:54:21Z INFO [vuln] Vulnerability scanning is enabled
2025-01-16T11:54:21Z INFO [misconfig] Misconfiguration scanning is enabled
2025-01-16T11:54:21Z INFO [secret] Secret scanning is enabled
2025-01-16T11:54:21Z INFO [secret] If your scanning is slow, please try '--scanners vuln' to disable secret scanning
2025-01-16T11:54:21Z INFO [secret] Please see also https://aquasecurity.github.io/trivy/v0.57/docs/scanner/secret#recommendation for faster secret detection2025-01-16T11:54:22Z INFO [terraformscanner] Scanning root module file_path="."2025-01-16T11:54:22Z WARN [terraformparser] Variable values was not found in the environment or variable files. Evaluating may not work correctly.module="root"variables="data_locations, databases_to_share, destination_account_id"2025-01-16T11:54:22Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="aws_lakeformation_data_cells_filter.data_filter"value="cty.NilVal"2025-01-16T11:54:22Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="aws_lakeformation_permissions.data_location_share"value="cty.NilVal"2025-01-16T11:54:22Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="aws_lakeformation_permissions.share_filtered_data"value="cty.NilVal"2025-01-16T11:54:22Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="aws_lakeformation_resource.data_location"value="cty.NilVal"2025-01-16T11:54:22Z INFO Number of language-specific files num=02025-01-16T11:54:22Z INFO Detected config files num=1trivy_exitcode=0
Trivy will check the following folders:
terraform/environments/electronic-monitoring-data
terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
Running Trivy in terraform/environments/electronic-monitoring-data
2025-01-16T12:06:09Z INFO [vulndb] Need to update DB
2025-01-16T12:06:09Z INFO [vulndb] Downloading vulnerability DB...
2025-01-16T12:06:09Z INFO [vulndb] Downloading artifact... repo="public.ecr.aws/aquasecurity/trivy-db:2"
2025-01-16T12:06:12Z INFO [vulndb] Artifact successfully downloaded repo="public.ecr.aws/aquasecurity/trivy-db:2"
2025-01-16T12:06:12Z INFO [vuln] Vulnerability scanning is enabled
2025-01-16T12:06:12Z INFO [misconfig] Misconfiguration scanning is enabled
2025-01-16T12:06:12Z INFO [misconfig] Need to update the built-in checks
2025-01-16T12:06:12Z INFO [misconfig] Downloading the built-in checks...
160.80 KiB / 160.80 KiB [------------------------------------------------------] 100.00% ? p/s 100ms2025-01-16T12:06:12Z INFO [secret] Secret scanning is enabled
2025-01-16T12:06:12Z INFO [secret] If your scanning is slow, please try '--scanners vuln' to disable secret scanning
2025-01-16T12:06:12Z INFO [secret] Please see also https://aquasecurity.github.io/trivy/v0.57/docs/scanner/secret#recommendation for faster secret detection
2025-01-16T12:06:14Z INFO [terraform scanner] Scanning root module file_path="."
2025-01-16T12:06:14Z WARN [terraform parser] Variable values was not found in the environment or variable files. Evaluating may not work correctly. module="root" variables="networking"
2025-01-16T12:06:15Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.api_gateway_authorizer.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:06:15Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.api_gateway_authorizer.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:06:15Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.calculate_checksum.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:06:15Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.calculate_checksum.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:06:15Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.copy_mdss_data.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:06:15Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.copy_mdss_data.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:06:15Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.format_json_fms_data.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:06:15Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.format_json_fms_data.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:06:15Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:06:15Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:06:15Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.rds_bastion.aws_s3_object.user_public_keys" value="cty.NilVal"
2025-01-16T12:06:15Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.rds_bastion.data.aws_subnet.local_account" value="cty.NilVal"
2025-01-16T12:06:15Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.rds_bastion.aws_autoscaling_group.bastion_linux_daily" err="1 error occurred:\n\t* invalid for-each in aws_autoscaling_group.bastion_linux_daily.dynamic.tag block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:06:15Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.rds_bastion.aws_autoscaling_group.bastion_linux_daily" err="1 error occurred:\n\t* invalid for-each in aws_autoscaling_group.bastion_linux_daily.dynamic.tag block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:06:15Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.rotate_iam_key.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:06:15Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.rotate_iam_key.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:06:15Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:06:15Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:06:16Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:06:16Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:06:16Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:06:16Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:06:16Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:06:16Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:06:16Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:06:16Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:06:16Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:06:16Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:06:16Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.s3-mdss-general-landing-bucket.module.kms_key.aws_kms_grant.this" value="cty.NilVal"
2025-01-16T12:06:16Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:06:16Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:06:16Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-general-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:06:16Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-general-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:06:16Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.s3-mdss-ho-landing-bucket.module.kms_key.aws_kms_grant.this" value="cty.NilVal"
2025-01-16T12:06:16Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-ho-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:06:16Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-ho-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:06:16Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-ho-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:06:16Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-ho-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:06:16Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.s3-mdss-specials-landing-bucket.module.kms_key.aws_kms_grant.this" value="cty.NilVal"
2025-01-16T12:06:16Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:06:16Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:06:16Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-specials-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:06:16Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-specials-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:06:17Z INFO [terraform scanner] Scanning root module file_path="glue-job/Archived"
2025-01-16T12:06:24Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T12:06:24Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T12:06:24Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T12:06:24Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T12:06:24Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T12:06:24Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T12:06:24Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T12:06:24Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T12:06:24Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T12:06:24Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T12:06:24Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T12:06:24Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T12:06:24Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T12:06:24Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T12:06:24Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T12:06:24Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T12:06:24Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-bastion-linux?ref=95ed3c3/github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=568694e50e03630d99cb569eafa06a0b879a1239/main.tf:171-179"
2025-01-16T12:06:24Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="s3.tf:1133-1152"
2025-01-16T12:06:24Z INFO [terraform executor] Ignore finding rule="aws-iam-no-user-attached-policies" range="modules/landing_bucket_iam_user_access/main.tf:2-10"
2025-01-16T12:06:24Z INFO [terraform executor] Ignore finding rule="aws-iam-no-user-attached-policies" range="modules/landing_bucket_iam_user_access/main.tf:2-10"
2025-01-16T12:06:24Z INFO [terraform executor] Ignore finding rule="aws-s3-enable-versioning" range="s3.tf:1133-1152"
2025-01-16T12:06:24Z INFO [terraform executor] Ignore finding rule="aws-s3-enable-bucket-encryption" range="s3.tf:1133-1152"
2025-01-16T12:06:24Z INFO [terraform executor] Ignore finding rule="aws-cloudwatch-log-group-customer-key" range="modules/api_step_function/main.tf:295-300"
2025-01-16T12:06:24Z INFO [terraform executor] Ignore finding rule="aws-cloudwatch-log-group-customer-key" range="modules/api_step_function/main.tf:421-425"
2025-01-16T12:06:24Z INFO [terraform executor] Ignore finding rule="aws-ssm-secret-use-customer-key" range="analytical_platform_share.tf:53-71"
2025-01-16T12:06:24Z INFO [terraform executor] Ignore finding rule="aws-s3-enable-logging" range="s3.tf:1133-1152"
2025-01-16T12:06:24Z INFO Number of language-specific files num=0
2025-01-16T12:06:24Z INFO Detected config files num=13
trivy_exitcode=0
Running Trivy in terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
2025-01-16T12:06:24Z INFO [vuln] Vulnerability scanning is enabled
2025-01-16T12:06:24Z INFO [misconfig] Misconfiguration scanning is enabled
2025-01-16T12:06:24Z INFO [secret] Secret scanning is enabled
2025-01-16T12:06:24Z INFO [secret] If your scanning is slow, please try '--scanners vuln' to disable secret scanning
2025-01-16T12:06:24Z INFO [secret] Please see also https://aquasecurity.github.io/trivy/v0.57/docs/scanner/secret#recommendation for faster secret detection
2025-01-16T12:06:25Z INFO [terraform scanner] Scanning root module file_path="."
2025-01-16T12:06:25Z WARN [terraform parser] Variable values was not found in the environment or variable files. Evaluating may not work correctly. module="root" variables="data_locations, databases_to_share, destination_account_id"
2025-01-16T12:06:25Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="aws_lakeformation_data_cells_filter.data_filter" value="cty.NilVal"
2025-01-16T12:06:25Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="aws_lakeformation_permissions.data_location_share" value="cty.NilVal"
2025-01-16T12:06:25Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="aws_lakeformation_permissions.share_filtered_data" value="cty.NilVal"
2025-01-16T12:06:25Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="aws_lakeformation_resource.data_location" value="cty.NilVal"
2025-01-16T12:06:25Z INFO Number of language-specific files num=0
2025-01-16T12:06:25Z INFO Detected config files num=1
trivy_exitcode=0
</details> #### `Checkov Scan` Success
<details><summary>Show Output</summary>
```hcl
*****************************
Checkov will check the following folders:
terraform/environments/electronic-monitoring-data
terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
*****************************
Running Checkov in terraform/environments/electronic-monitoring-data
Excluding the following checks: CKV_GIT_1,CKV_AWS_126,CKV2_AWS_38,CKV2_AWS_39
2025-01-16 12:06:27,880 [MainThread ] [WARNI] Failed to download module github.com/ministryofjustice/modernisation-platform-terraform-bastion-linux?ref=95ed3c3:None (for external modules, the --download-external-modules flag is required)
2025-01-16 12:06:27,880 [MainThread ] [WARNI] Failed to download module github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060:None (for external modules, the --download-external-modules flag is required)
2025-01-16 12:06:27,880 [MainThread ] [WARNI] Failed to download module terraform-aws-modules/iam/aws//modules/iam-assumable-role:5.48.0 (for external modules, the --download-external-modules flag is required)
2025-01-16 12:06:27,880 [MainThread ] [WARNI] Failed to download module terraform-aws-modules/kms/aws:3.1.1 (for external modules, the --download-external-modules flag is required)
2025-01-16 12:06:27,880 [MainThread ] [WARNI] Failed to download module terraform-aws-modules/secrets-manager/aws:1.3.0 (for external modules, the --download-external-modules flag is required)
terraform scan results:
Passed checks: 2752, Failed checks: 0, Skipped checks: 120
checkov_exitcode=0
*****************************
Running Checkov in terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
Excluding the following checks: CKV_GIT_1,CKV_AWS_126,CKV2_AWS_38,CKV2_AWS_39
checkov_exitcode=0
CTFLint Scan Success
Show Output
*****************************
Setting default tflint config...
Running tflint --init...
Installing "terraform" plugin...
Installed "terraform" (source: github.com/terraform-linters/tflint-ruleset-terraform, version:0.9.1)
tflint will check the following folders:
terraform/environments/electronic-monitoring-data
terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
*****************************
Running tflint in terraform/environments/electronic-monitoring-data
Excluding the following checks: terraform_unused_declarations
tflint_exitcode=0*****************************
Running tflint in terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
Excluding the following checks: terraform_unused_declarations
tflint_exitcode=0
Trivy Scan Success
Show Output
*****************************
Trivy will check the following folders:
terraform/environments/electronic-monitoring-data
terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
*****************************
Running Trivy in terraform/environments/electronic-monitoring-data
2025-01-16T12:06:09Z INFO [vulndb] Need to update DB
2025-01-16T12:06:09Z INFO [vulndb] Downloading vulnerability DB...2025-01-16T12:06:09Z INFO [vulndb] Downloading artifact...repo="public.ecr.aws/aquasecurity/trivy-db:2"2025-01-16T12:06:12Z INFO [vulndb] Artifact successfully downloaded repo="public.ecr.aws/aquasecurity/trivy-db:2"2025-01-16T12:06:12Z INFO [vuln] Vulnerability scanning is enabled
2025-01-16T12:06:12Z INFO [misconfig] Misconfiguration scanning is enabled
2025-01-16T12:06:12Z INFO [misconfig] Need to update the built-in checks
2025-01-16T12:06:12Z INFO [misconfig] Downloading the built-in checks...160.80 KiB /160.80 KiB [------------------------------------------------------] 100.00%? p/s 100ms2025-01-16T12:06:12Z INFO [secret] Secret scanning is enabled
2025-01-16T12:06:12Z INFO [secret] If your scanning is slow, please try '--scanners vuln' to disable secret scanning
2025-01-16T12:06:12Z INFO [secret] Please see also https://aquasecurity.github.io/trivy/v0.57/docs/scanner/secret#recommendation for faster secret detection2025-01-16T12:06:14Z INFO [terraformscanner] Scanning root module file_path="."2025-01-16T12:06:14Z WARN [terraformparser] Variable values was not found in the environment or variable files. Evaluating may not work correctly.module="root"variables="networking"2025-01-16T12:06:15Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.api_gateway_authorizer.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:06:15Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.api_gateway_authorizer.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:06:15Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.calculate_checksum.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:06:15Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.calculate_checksum.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:06:15Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.copy_mdss_data.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:06:15Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.copy_mdss_data.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:06:15Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.format_json_fms_data.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:06:15Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.format_json_fms_data.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:06:15Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:06:15Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:06:15Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.rds_bastion.aws_s3_object.user_public_keys"value="cty.NilVal"2025-01-16T12:06:15Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.rds_bastion.data.aws_subnet.local_account"value="cty.NilVal"2025-01-16T12:06:15Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.rds_bastion.aws_autoscaling_group.bastion_linux_daily"err="1 error occurred:\n\t* invalid for-each in aws_autoscaling_group.bastion_linux_daily.dynamic.tag block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:06:15Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.rds_bastion.aws_autoscaling_group.bastion_linux_daily"err="1 error occurred:\n\t* invalid for-each in aws_autoscaling_group.bastion_linux_daily.dynamic.tag block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:06:15Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.rotate_iam_key.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:06:15Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.rotate_iam_key.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:06:15Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:06:15Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:06:16Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:06:16Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:06:16Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:06:16Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:06:16Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:06:16Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:06:16Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:06:16Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:06:16Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:06:16Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:06:16Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.s3-mdss-general-landing-bucket.module.kms_key.aws_kms_grant.this"value="cty.NilVal"2025-01-16T12:06:16Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:06:16Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:06:16Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-general-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:06:16Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-general-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:06:16Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.s3-mdss-ho-landing-bucket.module.kms_key.aws_kms_grant.this"value="cty.NilVal"2025-01-16T12:06:16Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-ho-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:06:16Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-ho-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:06:16Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-ho-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:06:16Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-ho-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:06:16Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.s3-mdss-specials-landing-bucket.module.kms_key.aws_kms_grant.this"value="cty.NilVal"2025-01-16T12:06:16Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:06:16Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:06:16Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-specials-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:06:16Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-specials-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:06:17Z INFO [terraformscanner] Scanning root module file_path="glue-job/Archived"2025-01-16T12:06:24Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T12:06:24Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T12:06:24Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T12:06:24Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T12:06:24Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T12:06:24Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T12:06:24Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T12:06:24Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T12:06:24Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T12:06:24Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T12:06:24Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T12:06:24Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T12:06:24Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T12:06:24Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T12:06:24Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T12:06:24Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T12:06:24Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-bastion-linux?ref=95ed3c3/github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=568694e50e03630d99cb569eafa06a0b879a1239/main.tf:171-179"2025-01-16T12:06:24Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="s3.tf:1133-1152"2025-01-16T12:06:24Z INFO [terraformexecutor] Ignore finding rule="aws-iam-no-user-attached-policies"range="modules/landing_bucket_iam_user_access/main.tf:2-10"2025-01-16T12:06:24Z INFO [terraformexecutor] Ignore finding rule="aws-iam-no-user-attached-policies"range="modules/landing_bucket_iam_user_access/main.tf:2-10"2025-01-16T12:06:24Z INFO [terraformexecutor] Ignore finding rule="aws-s3-enable-versioning"range="s3.tf:1133-1152"2025-01-16T12:06:24Z INFO [terraformexecutor] Ignore finding rule="aws-s3-enable-bucket-encryption"range="s3.tf:1133-1152"2025-01-16T12:06:24Z INFO [terraformexecutor] Ignore finding rule="aws-cloudwatch-log-group-customer-key"range="modules/api_step_function/main.tf:295-300"2025-01-16T12:06:24Z INFO [terraformexecutor] Ignore finding rule="aws-cloudwatch-log-group-customer-key"range="modules/api_step_function/main.tf:421-425"2025-01-16T12:06:24Z INFO [terraformexecutor] Ignore finding rule="aws-ssm-secret-use-customer-key"range="analytical_platform_share.tf:53-71"2025-01-16T12:06:24Z INFO [terraformexecutor] Ignore finding rule="aws-s3-enable-logging"range="s3.tf:1133-1152"2025-01-16T12:06:24Z INFO Number of language-specific files num=02025-01-16T12:06:24Z INFO Detected config files num=13trivy_exitcode=0*****************************
Running Trivy in terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
2025-01-16T12:06:24Z INFO [vuln] Vulnerability scanning is enabled
2025-01-16T12:06:24Z INFO [misconfig] Misconfiguration scanning is enabled
2025-01-16T12:06:24Z INFO [secret] Secret scanning is enabled
2025-01-16T12:06:24Z INFO [secret] If your scanning is slow, please try '--scanners vuln' to disable secret scanning
2025-01-16T12:06:24Z INFO [secret] Please see also https://aquasecurity.github.io/trivy/v0.57/docs/scanner/secret#recommendation for faster secret detection2025-01-16T12:06:25Z INFO [terraformscanner] Scanning root module file_path="."2025-01-16T12:06:25Z WARN [terraformparser] Variable values was not found in the environment or variable files. Evaluating may not work correctly.module="root"variables="data_locations, databases_to_share, destination_account_id"2025-01-16T12:06:25Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="aws_lakeformation_data_cells_filter.data_filter"value="cty.NilVal"2025-01-16T12:06:25Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="aws_lakeformation_permissions.data_location_share"value="cty.NilVal"2025-01-16T12:06:25Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="aws_lakeformation_permissions.share_filtered_data"value="cty.NilVal"2025-01-16T12:06:25Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="aws_lakeformation_resource.data_location"value="cty.NilVal"2025-01-16T12:06:25Z INFO Number of language-specific files num=02025-01-16T12:06:25Z INFO Detected config files num=1trivy_exitcode=0
Trivy will check the following folders:
terraform/environments/electronic-monitoring-data
terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
Running Trivy in terraform/environments/electronic-monitoring-data
2025-01-16T12:19:19Z INFO [vulndb] Need to update DB
2025-01-16T12:19:19Z INFO [vulndb] Downloading vulnerability DB...
2025-01-16T12:19:19Z INFO [vulndb] Downloading artifact... repo="public.ecr.aws/aquasecurity/trivy-db:2"
2025-01-16T12:19:22Z INFO [vulndb] Artifact successfully downloaded repo="public.ecr.aws/aquasecurity/trivy-db:2"
2025-01-16T12:19:22Z INFO [vuln] Vulnerability scanning is enabled
2025-01-16T12:19:22Z INFO [misconfig] Misconfiguration scanning is enabled
2025-01-16T12:19:22Z INFO [misconfig] Need to update the built-in checks
2025-01-16T12:19:22Z INFO [misconfig] Downloading the built-in checks...
160.80 KiB / 160.80 KiB [------------------------------------------------------] 100.00% ? p/s 100ms2025-01-16T12:19:23Z INFO [secret] Secret scanning is enabled
2025-01-16T12:19:23Z INFO [secret] If your scanning is slow, please try '--scanners vuln' to disable secret scanning
2025-01-16T12:19:23Z INFO [secret] Please see also https://aquasecurity.github.io/trivy/v0.57/docs/scanner/secret#recommendation for faster secret detection
2025-01-16T12:19:24Z INFO [terraform scanner] Scanning root module file_path="."
2025-01-16T12:19:24Z WARN [terraform parser] Variable values was not found in the environment or variable files. Evaluating may not work correctly. module="root" variables="networking"
2025-01-16T12:19:27Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.api_gateway_authorizer.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:19:27Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.api_gateway_authorizer.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:19:27Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.calculate_checksum.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:19:27Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.calculate_checksum.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:19:27Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.copy_mdss_data.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:19:27Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.copy_mdss_data.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:19:27Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.format_json_fms_data.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:19:27Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.format_json_fms_data.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:19:27Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:19:27Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:19:27Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.rds_bastion.aws_s3_object.user_public_keys" value="cty.NilVal"
2025-01-16T12:19:27Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.rds_bastion.data.aws_subnet.local_account" value="cty.NilVal"
2025-01-16T12:19:27Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.rds_bastion.aws_autoscaling_group.bastion_linux_daily" err="1 error occurred:\n\t* invalid for-each in aws_autoscaling_group.bastion_linux_daily.dynamic.tag block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:19:27Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.rds_bastion.aws_autoscaling_group.bastion_linux_daily" err="1 error occurred:\n\t* invalid for-each in aws_autoscaling_group.bastion_linux_daily.dynamic.tag block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:19:28Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.rotate_iam_key.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:19:28Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.rotate_iam_key.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:19:28Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:19:28Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:19:29Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:19:29Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:19:30Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:19:30Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:19:30Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:19:30Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:19:30Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:19:30Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:19:30Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:19:30Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:19:30Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.s3-mdss-general-landing-bucket.module.kms_key.aws_kms_grant.this" value="cty.NilVal"
2025-01-16T12:19:30Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:19:30Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:19:30Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-general-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:19:30Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-general-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:19:30Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.s3-mdss-ho-landing-bucket.module.kms_key.aws_kms_grant.this" value="cty.NilVal"
2025-01-16T12:19:30Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-ho-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:19:30Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-ho-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:19:30Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-ho-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:19:30Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-ho-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:19:30Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.s3-mdss-specials-landing-bucket.module.kms_key.aws_kms_grant.this" value="cty.NilVal"
2025-01-16T12:19:30Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:19:30Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:19:30Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-specials-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:19:30Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-specials-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-16T12:19:30Z INFO [terraform scanner] Scanning root module file_path="glue-job/Archived"
2025-01-16T12:19:37Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T12:19:37Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T12:19:37Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T12:19:37Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T12:19:37Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T12:19:37Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T12:19:37Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T12:19:37Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T12:19:37Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T12:19:37Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T12:19:37Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T12:19:37Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T12:19:37Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T12:19:37Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T12:19:37Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T12:19:37Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-16T12:19:37Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-bastion-linux?ref=95ed3c3/github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=568694e50e03630d99cb569eafa06a0b879a1239/main.tf:171-179"
2025-01-16T12:19:37Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="s3.tf:1133-1152"
2025-01-16T12:19:37Z INFO [terraform executor] Ignore finding rule="aws-cloudwatch-log-group-customer-key" range="modules/api_step_function/main.tf:295-300"
2025-01-16T12:19:37Z INFO [terraform executor] Ignore finding rule="aws-cloudwatch-log-group-customer-key" range="modules/api_step_function/main.tf:421-425"
2025-01-16T12:19:37Z INFO [terraform executor] Ignore finding rule="aws-s3-enable-logging" range="s3.tf:1133-1152"
2025-01-16T12:19:37Z INFO [terraform executor] Ignore finding rule="aws-s3-enable-versioning" range="s3.tf:1133-1152"
2025-01-16T12:19:37Z INFO [terraform executor] Ignore finding rule="aws-s3-enable-bucket-encryption" range="s3.tf:1133-1152"
2025-01-16T12:19:37Z INFO [terraform executor] Ignore finding rule="aws-ssm-secret-use-customer-key" range="analytical_platform_share.tf:53-71"
2025-01-16T12:19:37Z INFO [terraform executor] Ignore finding rule="aws-iam-no-user-attached-policies" range="modules/landing_bucket_iam_user_access/main.tf:2-10"
2025-01-16T12:19:37Z INFO [terraform executor] Ignore finding rule="aws-iam-no-user-attached-policies" range="modules/landing_bucket_iam_user_access/main.tf:2-10"
2025-01-16T12:19:37Z INFO Number of language-specific files num=0
2025-01-16T12:19:37Z INFO Detected config files num=13
trivy_exitcode=0
Running Trivy in terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
2025-01-16T12:19:38Z INFO [vuln] Vulnerability scanning is enabled
2025-01-16T12:19:38Z INFO [misconfig] Misconfiguration scanning is enabled
2025-01-16T12:19:38Z INFO [secret] Secret scanning is enabled
2025-01-16T12:19:38Z INFO [secret] If your scanning is slow, please try '--scanners vuln' to disable secret scanning
2025-01-16T12:19:38Z INFO [secret] Please see also https://aquasecurity.github.io/trivy/v0.57/docs/scanner/secret#recommendation for faster secret detection
2025-01-16T12:19:38Z INFO [terraform scanner] Scanning root module file_path="."
2025-01-16T12:19:39Z WARN [terraform parser] Variable values was not found in the environment or variable files. Evaluating may not work correctly. module="root" variables="data_locations, databases_to_share, destination_account_id"
2025-01-16T12:19:39Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="aws_lakeformation_data_cells_filter.data_filter" value="cty.NilVal"
2025-01-16T12:19:39Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="aws_lakeformation_permissions.data_location_share" value="cty.NilVal"
2025-01-16T12:19:39Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="aws_lakeformation_permissions.share_filtered_data" value="cty.NilVal"
2025-01-16T12:19:39Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="aws_lakeformation_resource.data_location" value="cty.NilVal"
2025-01-16T12:19:39Z INFO Number of language-specific files num=0
2025-01-16T12:19:39Z INFO Detected config files num=1
trivy_exitcode=0
</details> #### `Checkov Scan` Success
<details><summary>Show Output</summary>
```hcl
*****************************
Checkov will check the following folders:
terraform/environments/electronic-monitoring-data
terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
*****************************
Running Checkov in terraform/environments/electronic-monitoring-data
Excluding the following checks: CKV_GIT_1,CKV_AWS_126,CKV2_AWS_38,CKV2_AWS_39
2025-01-16 12:19:41,817 [MainThread ] [WARNI] Failed to download module github.com/ministryofjustice/modernisation-platform-terraform-bastion-linux?ref=95ed3c3:None (for external modules, the --download-external-modules flag is required)
2025-01-16 12:19:41,823 [MainThread ] [WARNI] Failed to download module github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060:None (for external modules, the --download-external-modules flag is required)
2025-01-16 12:19:41,823 [MainThread ] [WARNI] Failed to download module terraform-aws-modules/iam/aws//modules/iam-assumable-role:5.48.0 (for external modules, the --download-external-modules flag is required)
2025-01-16 12:19:41,823 [MainThread ] [WARNI] Failed to download module terraform-aws-modules/kms/aws:3.1.1 (for external modules, the --download-external-modules flag is required)
2025-01-16 12:19:41,823 [MainThread ] [WARNI] Failed to download module terraform-aws-modules/secrets-manager/aws:1.3.0 (for external modules, the --download-external-modules flag is required)
terraform scan results:
Passed checks: 2752, Failed checks: 0, Skipped checks: 120
checkov_exitcode=0
*****************************
Running Checkov in terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
Excluding the following checks: CKV_GIT_1,CKV_AWS_126,CKV2_AWS_38,CKV2_AWS_39
checkov_exitcode=0
CTFLint Scan Success
Show Output
*****************************
Setting default tflint config...
Running tflint --init...
Installing "terraform" plugin...
Installed "terraform" (source: github.com/terraform-linters/tflint-ruleset-terraform, version:0.9.1)
tflint will check the following folders:
terraform/environments/electronic-monitoring-data
terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
*****************************
Running tflint in terraform/environments/electronic-monitoring-data
Excluding the following checks: terraform_unused_declarations
tflint_exitcode=0*****************************
Running tflint in terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
Excluding the following checks: terraform_unused_declarations
tflint_exitcode=0
Trivy Scan Success
Show Output
*****************************
Trivy will check the following folders:
terraform/environments/electronic-monitoring-data
terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
*****************************
Running Trivy in terraform/environments/electronic-monitoring-data
2025-01-16T12:19:19Z INFO [vulndb] Need to update DB
2025-01-16T12:19:19Z INFO [vulndb] Downloading vulnerability DB...2025-01-16T12:19:19Z INFO [vulndb] Downloading artifact...repo="public.ecr.aws/aquasecurity/trivy-db:2"2025-01-16T12:19:22Z INFO [vulndb] Artifact successfully downloaded repo="public.ecr.aws/aquasecurity/trivy-db:2"2025-01-16T12:19:22Z INFO [vuln] Vulnerability scanning is enabled
2025-01-16T12:19:22Z INFO [misconfig] Misconfiguration scanning is enabled
2025-01-16T12:19:22Z INFO [misconfig] Need to update the built-in checks
2025-01-16T12:19:22Z INFO [misconfig] Downloading the built-in checks...160.80 KiB /160.80 KiB [------------------------------------------------------] 100.00%? p/s 100ms2025-01-16T12:19:23Z INFO [secret] Secret scanning is enabled
2025-01-16T12:19:23Z INFO [secret] If your scanning is slow, please try '--scanners vuln' to disable secret scanning
2025-01-16T12:19:23Z INFO [secret] Please see also https://aquasecurity.github.io/trivy/v0.57/docs/scanner/secret#recommendation for faster secret detection2025-01-16T12:19:24Z INFO [terraformscanner] Scanning root module file_path="."2025-01-16T12:19:24Z WARN [terraformparser] Variable values was not found in the environment or variable files. Evaluating may not work correctly.module="root"variables="networking"2025-01-16T12:19:27Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.api_gateway_authorizer.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:19:27Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.api_gateway_authorizer.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:19:27Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.calculate_checksum.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:19:27Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.calculate_checksum.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:19:27Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.copy_mdss_data.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:19:27Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.copy_mdss_data.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:19:27Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.format_json_fms_data.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:19:27Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.format_json_fms_data.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:19:27Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:19:27Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:19:27Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.rds_bastion.aws_s3_object.user_public_keys"value="cty.NilVal"2025-01-16T12:19:27Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.rds_bastion.data.aws_subnet.local_account"value="cty.NilVal"2025-01-16T12:19:27Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.rds_bastion.aws_autoscaling_group.bastion_linux_daily"err="1 error occurred:\n\t* invalid for-each in aws_autoscaling_group.bastion_linux_daily.dynamic.tag block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:19:27Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.rds_bastion.aws_autoscaling_group.bastion_linux_daily"err="1 error occurred:\n\t* invalid for-each in aws_autoscaling_group.bastion_linux_daily.dynamic.tag block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:19:28Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.rotate_iam_key.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:19:28Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.rotate_iam_key.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:19:28Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:19:28Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:19:29Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:19:29Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:19:30Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:19:30Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:19:30Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:19:30Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:19:30Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:19:30Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:19:30Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:19:30Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:19:30Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.s3-mdss-general-landing-bucket.module.kms_key.aws_kms_grant.this"value="cty.NilVal"2025-01-16T12:19:30Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:19:30Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:19:30Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-general-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:19:30Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-general-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:19:30Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.s3-mdss-ho-landing-bucket.module.kms_key.aws_kms_grant.this"value="cty.NilVal"2025-01-16T12:19:30Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-ho-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:19:30Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-ho-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:19:30Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-ho-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:19:30Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-ho-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:19:30Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.s3-mdss-specials-landing-bucket.module.kms_key.aws_kms_grant.this"value="cty.NilVal"2025-01-16T12:19:30Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:19:30Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:19:30Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-specials-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:19:30Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-specials-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-16T12:19:30Z INFO [terraformscanner] Scanning root module file_path="glue-job/Archived"2025-01-16T12:19:37Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T12:19:37Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T12:19:37Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T12:19:37Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T12:19:37Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T12:19:37Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T12:19:37Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T12:19:37Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T12:19:37Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T12:19:37Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T12:19:37Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T12:19:37Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T12:19:37Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T12:19:37Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T12:19:37Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T12:19:37Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-16T12:19:37Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-bastion-linux?ref=95ed3c3/github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=568694e50e03630d99cb569eafa06a0b879a1239/main.tf:171-179"2025-01-16T12:19:37Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="s3.tf:1133-1152"2025-01-16T12:19:37Z INFO [terraformexecutor] Ignore finding rule="aws-cloudwatch-log-group-customer-key"range="modules/api_step_function/main.tf:295-300"2025-01-16T12:19:37Z INFO [terraformexecutor] Ignore finding rule="aws-cloudwatch-log-group-customer-key"range="modules/api_step_function/main.tf:421-425"2025-01-16T12:19:37Z INFO [terraformexecutor] Ignore finding rule="aws-s3-enable-logging"range="s3.tf:1133-1152"2025-01-16T12:19:37Z INFO [terraformexecutor] Ignore finding rule="aws-s3-enable-versioning"range="s3.tf:1133-1152"2025-01-16T12:19:37Z INFO [terraformexecutor] Ignore finding rule="aws-s3-enable-bucket-encryption"range="s3.tf:1133-1152"2025-01-16T12:19:37Z INFO [terraformexecutor] Ignore finding rule="aws-ssm-secret-use-customer-key"range="analytical_platform_share.tf:53-71"2025-01-16T12:19:37Z INFO [terraformexecutor] Ignore finding rule="aws-iam-no-user-attached-policies"range="modules/landing_bucket_iam_user_access/main.tf:2-10"2025-01-16T12:19:37Z INFO [terraformexecutor] Ignore finding rule="aws-iam-no-user-attached-policies"range="modules/landing_bucket_iam_user_access/main.tf:2-10"2025-01-16T12:19:37Z INFO Number of language-specific files num=02025-01-16T12:19:37Z INFO Detected config files num=13trivy_exitcode=0*****************************
Running Trivy in terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
2025-01-16T12:19:38Z INFO [vuln] Vulnerability scanning is enabled
2025-01-16T12:19:38Z INFO [misconfig] Misconfiguration scanning is enabled
2025-01-16T12:19:38Z INFO [secret] Secret scanning is enabled
2025-01-16T12:19:38Z INFO [secret] If your scanning is slow, please try '--scanners vuln' to disable secret scanning
2025-01-16T12:19:38Z INFO [secret] Please see also https://aquasecurity.github.io/trivy/v0.57/docs/scanner/secret#recommendation for faster secret detection2025-01-16T12:19:38Z INFO [terraformscanner] Scanning root module file_path="."2025-01-16T12:19:39Z WARN [terraformparser] Variable values was not found in the environment or variable files. Evaluating may not work correctly.module="root"variables="data_locations, databases_to_share, destination_account_id"2025-01-16T12:19:39Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="aws_lakeformation_data_cells_filter.data_filter"value="cty.NilVal"2025-01-16T12:19:39Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="aws_lakeformation_permissions.data_location_share"value="cty.NilVal"2025-01-16T12:19:39Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="aws_lakeformation_permissions.share_filtered_data"value="cty.NilVal"2025-01-16T12:19:39Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="aws_lakeformation_resource.data_location"value="cty.NilVal"2025-01-16T12:19:39Z INFO Number of language-specific files num=02025-01-16T12:19:39Z INFO Detected config files num=1trivy_exitcode=0
Trivy will check the following folders:
terraform/environments/electronic-monitoring-data
terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
Running Trivy in terraform/environments/electronic-monitoring-data
2025-01-17T11:36:30Z INFO [vulndb] Need to update DB
2025-01-17T11:36:30Z INFO [vulndb] Downloading vulnerability DB...
2025-01-17T11:36:30Z INFO [vulndb] Downloading artifact... repo="public.ecr.aws/aquasecurity/trivy-db:2"
2025-01-17T11:36:32Z INFO [vulndb] Artifact successfully downloaded repo="public.ecr.aws/aquasecurity/trivy-db:2"
2025-01-17T11:36:32Z INFO [vuln] Vulnerability scanning is enabled
2025-01-17T11:36:32Z INFO [misconfig] Misconfiguration scanning is enabled
2025-01-17T11:36:32Z INFO [misconfig] Need to update the built-in checks
2025-01-17T11:36:32Z INFO [misconfig] Downloading the built-in checks...
160.80 KiB / 160.80 KiB [------------------------------------------------------] 100.00% ? p/s 100ms2025-01-17T11:36:33Z INFO [secret] Secret scanning is enabled
2025-01-17T11:36:33Z INFO [secret] If your scanning is slow, please try '--scanners vuln' to disable secret scanning
2025-01-17T11:36:33Z INFO [secret] Please see also https://aquasecurity.github.io/trivy/v0.57/docs/scanner/secret#recommendation for faster secret detection
2025-01-17T11:36:34Z INFO [terraform scanner] Scanning root module file_path="."
2025-01-17T11:36:34Z WARN [terraform parser] Variable values was not found in the environment or variable files. Evaluating may not work correctly. module="root" variables="networking"
2025-01-17T11:36:37Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.api_gateway_authorizer.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:36:37Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.api_gateway_authorizer.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:36:37Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.calculate_checksum.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:36:37Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.calculate_checksum.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:36:37Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.copy_mdss_data.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:36:37Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.copy_mdss_data.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:36:37Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.format_json_fms_data.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:36:37Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.format_json_fms_data.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:36:37Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:36:37Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:36:37Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.rds_bastion.aws_s3_object.user_public_keys" value="cty.NilVal"
2025-01-17T11:36:37Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.rds_bastion.data.aws_subnet.local_account" value="cty.NilVal"
2025-01-17T11:36:37Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.rds_bastion.aws_autoscaling_group.bastion_linux_daily" err="1 error occurred:\n\t* invalid for-each in aws_autoscaling_group.bastion_linux_daily.dynamic.tag block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:36:37Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.rds_bastion.aws_autoscaling_group.bastion_linux_daily" err="1 error occurred:\n\t* invalid for-each in aws_autoscaling_group.bastion_linux_daily.dynamic.tag block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:36:39Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.rotate_iam_key.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:36:39Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.rotate_iam_key.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:36:39Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:36:39Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:36:40Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:36:40Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:36:40Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:36:40Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:36:41Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:36:41Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:36:41Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:36:41Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:36:41Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:36:41Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:36:41Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.s3-mdss-general-landing-bucket.module.kms_key.aws_kms_grant.this" value="cty.NilVal"
2025-01-17T11:36:41Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:36:41Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:36:41Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-general-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:36:41Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-general-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:36:41Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.s3-mdss-ho-landing-bucket.module.kms_key.aws_kms_grant.this" value="cty.NilVal"
2025-01-17T11:36:41Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-ho-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:36:41Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-ho-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:36:41Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-ho-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:36:41Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-ho-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:36:41Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.s3-mdss-specials-landing-bucket.module.kms_key.aws_kms_grant.this" value="cty.NilVal"
2025-01-17T11:36:41Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:36:41Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:36:41Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-specials-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:36:41Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-specials-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:36:41Z INFO [terraform scanner] Scanning root module file_path="glue-job/Archived"
2025-01-17T11:36:49Z INFO [terraform executor] Ignore finding rule="aws-cloudwatch-log-group-customer-key" range="modules/api_step_function/main.tf:295-300"
2025-01-17T11:36:49Z INFO [terraform executor] Ignore finding rule="aws-cloudwatch-log-group-customer-key" range="modules/api_step_function/main.tf:421-425"
2025-01-17T11:36:49Z INFO [terraform executor] Ignore finding rule="aws-iam-no-user-attached-policies" range="modules/landing_bucket_iam_user_access/main.tf:2-10"
2025-01-17T11:36:49Z INFO [terraform executor] Ignore finding rule="aws-iam-no-user-attached-policies" range="modules/landing_bucket_iam_user_access/main.tf:2-10"
2025-01-17T11:36:49Z INFO [terraform executor] Ignore finding rule="aws-s3-enable-versioning" range="s3.tf:1133-1152"
2025-01-17T11:36:49Z INFO [terraform executor] Ignore finding rule="aws-s3-enable-bucket-encryption" range="s3.tf:1133-1152"
2025-01-17T11:36:49Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:36:49Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:36:49Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:36:49Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:36:49Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:36:49Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:36:49Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:36:49Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:36:49Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:36:49Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:36:49Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:36:49Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:36:49Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:36:49Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:36:49Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:36:49Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:36:49Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-bastion-linux?ref=95ed3c3/github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=568694e50e03630d99cb569eafa06a0b879a1239/main.tf:171-179"
2025-01-17T11:36:49Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="s3.tf:1133-1152"
2025-01-17T11:36:49Z INFO [terraform executor] Ignore finding rule="aws-s3-enable-logging" range="s3.tf:1133-1152"
2025-01-17T11:36:49Z INFO [terraform executor] Ignore finding rule="aws-ssm-secret-use-customer-key" range="analytical_platform_share.tf:53-71"
2025-01-17T11:36:49Z INFO Number of language-specific files num=0
2025-01-17T11:36:49Z INFO Detected config files num=13
trivy_exitcode=0
Running Trivy in terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
2025-01-17T11:36:49Z INFO [vuln] Vulnerability scanning is enabled
2025-01-17T11:36:49Z INFO [misconfig] Misconfiguration scanning is enabled
2025-01-17T11:36:49Z INFO [secret] Secret scanning is enabled
2025-01-17T11:36:49Z INFO [secret] If your scanning is slow, please try '--scanners vuln' to disable secret scanning
2025-01-17T11:36:49Z INFO [secret] Please see also https://aquasecurity.github.io/trivy/v0.57/docs/scanner/secret#recommendation for faster secret detection
2025-01-17T11:36:50Z INFO [terraform scanner] Scanning root module file_path="."
2025-01-17T11:36:50Z WARN [terraform parser] Variable values was not found in the environment or variable files. Evaluating may not work correctly. module="root" variables="data_locations, databases_to_share, destination_account_id"
2025-01-17T11:36:50Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="aws_lakeformation_data_cells_filter.data_filter" value="cty.NilVal"
2025-01-17T11:36:50Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="aws_lakeformation_permissions.data_location_share" value="cty.NilVal"
2025-01-17T11:36:50Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="aws_lakeformation_permissions.share_filtered_data" value="cty.NilVal"
2025-01-17T11:36:50Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="aws_lakeformation_resource.data_location" value="cty.NilVal"
2025-01-17T11:36:50Z INFO Number of language-specific files num=0
2025-01-17T11:36:50Z INFO Detected config files num=1
trivy_exitcode=0
</details> #### `Checkov Scan` Success
<details><summary>Show Output</summary>
```hcl
*****************************
Checkov will check the following folders:
terraform/environments/electronic-monitoring-data
terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
*****************************
Running Checkov in terraform/environments/electronic-monitoring-data
Excluding the following checks: CKV_GIT_1,CKV_AWS_126,CKV2_AWS_38,CKV2_AWS_39
2025-01-17 11:36:53,155 [MainThread ] [WARNI] Failed to download module github.com/ministryofjustice/modernisation-platform-terraform-bastion-linux?ref=95ed3c3:None (for external modules, the --download-external-modules flag is required)
2025-01-17 11:36:53,155 [MainThread ] [WARNI] Failed to download module github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060:None (for external modules, the --download-external-modules flag is required)
2025-01-17 11:36:53,155 [MainThread ] [WARNI] Failed to download module terraform-aws-modules/iam/aws//modules/iam-assumable-role:5.48.0 (for external modules, the --download-external-modules flag is required)
2025-01-17 11:36:53,156 [MainThread ] [WARNI] Failed to download module terraform-aws-modules/kms/aws:3.1.1 (for external modules, the --download-external-modules flag is required)
2025-01-17 11:36:53,156 [MainThread ] [WARNI] Failed to download module terraform-aws-modules/secrets-manager/aws:1.3.0 (for external modules, the --download-external-modules flag is required)
terraform scan results:
Passed checks: 2737, Failed checks: 0, Skipped checks: 120
checkov_exitcode=0
*****************************
Running Checkov in terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
Excluding the following checks: CKV_GIT_1,CKV_AWS_126,CKV2_AWS_38,CKV2_AWS_39
checkov_exitcode=0
CTFLint Scan Success
Show Output
*****************************
Setting default tflint config...
Running tflint --init...
Installing "terraform" plugin...
Installed "terraform" (source: github.com/terraform-linters/tflint-ruleset-terraform, version:0.9.1)
tflint will check the following folders:
terraform/environments/electronic-monitoring-data
terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
*****************************
Running tflint in terraform/environments/electronic-monitoring-data
Excluding the following checks: terraform_unused_declarations
tflint_exitcode=0*****************************
Running tflint in terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
Excluding the following checks: terraform_unused_declarations
tflint_exitcode=0
Trivy Scan Success
Show Output
*****************************
Trivy will check the following folders:
terraform/environments/electronic-monitoring-data
terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
*****************************
Running Trivy in terraform/environments/electronic-monitoring-data
2025-01-17T11:36:30Z INFO [vulndb] Need to update DB
2025-01-17T11:36:30Z INFO [vulndb] Downloading vulnerability DB...2025-01-17T11:36:30Z INFO [vulndb] Downloading artifact...repo="public.ecr.aws/aquasecurity/trivy-db:2"2025-01-17T11:36:32Z INFO [vulndb] Artifact successfully downloaded repo="public.ecr.aws/aquasecurity/trivy-db:2"2025-01-17T11:36:32Z INFO [vuln] Vulnerability scanning is enabled
2025-01-17T11:36:32Z INFO [misconfig] Misconfiguration scanning is enabled
2025-01-17T11:36:32Z INFO [misconfig] Need to update the built-in checks
2025-01-17T11:36:32Z INFO [misconfig] Downloading the built-in checks...160.80 KiB /160.80 KiB [------------------------------------------------------] 100.00%? p/s 100ms2025-01-17T11:36:33Z INFO [secret] Secret scanning is enabled
2025-01-17T11:36:33Z INFO [secret] If your scanning is slow, please try '--scanners vuln' to disable secret scanning
2025-01-17T11:36:33Z INFO [secret] Please see also https://aquasecurity.github.io/trivy/v0.57/docs/scanner/secret#recommendation for faster secret detection2025-01-17T11:36:34Z INFO [terraformscanner] Scanning root module file_path="."2025-01-17T11:36:34Z WARN [terraformparser] Variable values was not found in the environment or variable files. Evaluating may not work correctly.module="root"variables="networking"2025-01-17T11:36:37Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.api_gateway_authorizer.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:36:37Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.api_gateway_authorizer.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:36:37Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.calculate_checksum.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:36:37Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.calculate_checksum.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:36:37Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.copy_mdss_data.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:36:37Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.copy_mdss_data.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:36:37Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.format_json_fms_data.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:36:37Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.format_json_fms_data.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:36:37Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:36:37Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:36:37Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.rds_bastion.aws_s3_object.user_public_keys"value="cty.NilVal"2025-01-17T11:36:37Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.rds_bastion.data.aws_subnet.local_account"value="cty.NilVal"2025-01-17T11:36:37Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.rds_bastion.aws_autoscaling_group.bastion_linux_daily"err="1 error occurred:\n\t* invalid for-each in aws_autoscaling_group.bastion_linux_daily.dynamic.tag block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:36:37Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.rds_bastion.aws_autoscaling_group.bastion_linux_daily"err="1 error occurred:\n\t* invalid for-each in aws_autoscaling_group.bastion_linux_daily.dynamic.tag block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:36:39Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.rotate_iam_key.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:36:39Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.rotate_iam_key.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:36:39Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:36:39Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:36:40Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:36:40Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:36:40Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:36:40Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:36:41Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:36:41Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:36:41Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:36:41Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:36:41Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:36:41Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:36:41Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.s3-mdss-general-landing-bucket.module.kms_key.aws_kms_grant.this"value="cty.NilVal"2025-01-17T11:36:41Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:36:41Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:36:41Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-general-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:36:41Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-general-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:36:41Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.s3-mdss-ho-landing-bucket.module.kms_key.aws_kms_grant.this"value="cty.NilVal"2025-01-17T11:36:41Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-ho-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:36:41Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-ho-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:36:41Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-ho-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:36:41Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-ho-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:36:41Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.s3-mdss-specials-landing-bucket.module.kms_key.aws_kms_grant.this"value="cty.NilVal"2025-01-17T11:36:41Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:36:41Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:36:41Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-specials-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:36:41Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-specials-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:36:41Z INFO [terraformscanner] Scanning root module file_path="glue-job/Archived"2025-01-17T11:36:49Z INFO [terraformexecutor] Ignore finding rule="aws-cloudwatch-log-group-customer-key"range="modules/api_step_function/main.tf:295-300"2025-01-17T11:36:49Z INFO [terraformexecutor] Ignore finding rule="aws-cloudwatch-log-group-customer-key"range="modules/api_step_function/main.tf:421-425"2025-01-17T11:36:49Z INFO [terraformexecutor] Ignore finding rule="aws-iam-no-user-attached-policies"range="modules/landing_bucket_iam_user_access/main.tf:2-10"2025-01-17T11:36:49Z INFO [terraformexecutor] Ignore finding rule="aws-iam-no-user-attached-policies"range="modules/landing_bucket_iam_user_access/main.tf:2-10"2025-01-17T11:36:49Z INFO [terraformexecutor] Ignore finding rule="aws-s3-enable-versioning"range="s3.tf:1133-1152"2025-01-17T11:36:49Z INFO [terraformexecutor] Ignore finding rule="aws-s3-enable-bucket-encryption"range="s3.tf:1133-1152"2025-01-17T11:36:49Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:36:49Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:36:49Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:36:49Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:36:49Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:36:49Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:36:49Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:36:49Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:36:49Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:36:49Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:36:49Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:36:49Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:36:49Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:36:49Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:36:49Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:36:49Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:36:49Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-bastion-linux?ref=95ed3c3/github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=568694e50e03630d99cb569eafa06a0b879a1239/main.tf:171-179"2025-01-17T11:36:49Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="s3.tf:1133-1152"2025-01-17T11:36:49Z INFO [terraformexecutor] Ignore finding rule="aws-s3-enable-logging"range="s3.tf:1133-1152"2025-01-17T11:36:49Z INFO [terraformexecutor] Ignore finding rule="aws-ssm-secret-use-customer-key"range="analytical_platform_share.tf:53-71"2025-01-17T11:36:49Z INFO Number of language-specific files num=02025-01-17T11:36:49Z INFO Detected config files num=13trivy_exitcode=0*****************************
Running Trivy in terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
2025-01-17T11:36:49Z INFO [vuln] Vulnerability scanning is enabled
2025-01-17T11:36:49Z INFO [misconfig] Misconfiguration scanning is enabled
2025-01-17T11:36:49Z INFO [secret] Secret scanning is enabled
2025-01-17T11:36:49Z INFO [secret] If your scanning is slow, please try '--scanners vuln' to disable secret scanning
2025-01-17T11:36:49Z INFO [secret] Please see also https://aquasecurity.github.io/trivy/v0.57/docs/scanner/secret#recommendation for faster secret detection2025-01-17T11:36:50Z INFO [terraformscanner] Scanning root module file_path="."2025-01-17T11:36:50Z WARN [terraformparser] Variable values was not found in the environment or variable files. Evaluating may not work correctly.module="root"variables="data_locations, databases_to_share, destination_account_id"2025-01-17T11:36:50Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="aws_lakeformation_data_cells_filter.data_filter"value="cty.NilVal"2025-01-17T11:36:50Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="aws_lakeformation_permissions.data_location_share"value="cty.NilVal"2025-01-17T11:36:50Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="aws_lakeformation_permissions.share_filtered_data"value="cty.NilVal"2025-01-17T11:36:50Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="aws_lakeformation_resource.data_location"value="cty.NilVal"2025-01-17T11:36:50Z INFO Number of language-specific files num=02025-01-17T11:36:50Z INFO Detected config files num=1trivy_exitcode=0
Trivy will check the following folders:
terraform/environments/electronic-monitoring-data
terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
Running Trivy in terraform/environments/electronic-monitoring-data
2025-01-17T11:40:36Z INFO [vulndb] Need to update DB
2025-01-17T11:40:36Z INFO [vulndb] Downloading vulnerability DB...
2025-01-17T11:40:36Z INFO [vulndb] Downloading artifact... repo="public.ecr.aws/aquasecurity/trivy-db:2"
2025-01-17T11:40:38Z INFO [vulndb] Artifact successfully downloaded repo="public.ecr.aws/aquasecurity/trivy-db:2"
2025-01-17T11:40:38Z INFO [vuln] Vulnerability scanning is enabled
2025-01-17T11:40:38Z INFO [misconfig] Misconfiguration scanning is enabled
2025-01-17T11:40:38Z INFO [misconfig] Need to update the built-in checks
2025-01-17T11:40:38Z INFO [misconfig] Downloading the built-in checks...
160.80 KiB / 160.80 KiB [------------------------------------------------------] 100.00% ? p/s 100ms2025-01-17T11:40:39Z INFO [secret] Secret scanning is enabled
2025-01-17T11:40:39Z INFO [secret] If your scanning is slow, please try '--scanners vuln' to disable secret scanning
2025-01-17T11:40:39Z INFO [secret] Please see also https://aquasecurity.github.io/trivy/v0.57/docs/scanner/secret#recommendation for faster secret detection
2025-01-17T11:40:40Z INFO [terraform scanner] Scanning root module file_path="."
2025-01-17T11:40:40Z WARN [terraform parser] Variable values was not found in the environment or variable files. Evaluating may not work correctly. module="root" variables="networking"
2025-01-17T11:40:41Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.api_gateway_authorizer.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:40:41Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.api_gateway_authorizer.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:40:41Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.calculate_checksum.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:40:41Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.calculate_checksum.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:40:41Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.copy_mdss_data.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:40:41Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.copy_mdss_data.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:40:41Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.format_json_fms_data.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:40:41Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.format_json_fms_data.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:40:41Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:40:41Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:40:42Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.rds_bastion.aws_s3_object.user_public_keys" value="cty.NilVal"
2025-01-17T11:40:42Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.rds_bastion.data.aws_subnet.local_account" value="cty.NilVal"
2025-01-17T11:40:42Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.rds_bastion.aws_autoscaling_group.bastion_linux_daily" err="1 error occurred:\n\t* invalid for-each in aws_autoscaling_group.bastion_linux_daily.dynamic.tag block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:40:42Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.rds_bastion.aws_autoscaling_group.bastion_linux_daily" err="1 error occurred:\n\t* invalid for-each in aws_autoscaling_group.bastion_linux_daily.dynamic.tag block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:40:42Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.rotate_iam_key.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:40:42Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.rotate_iam_key.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:40:42Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:40:42Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:40:42Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:40:42Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:40:43Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:40:43Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:40:43Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:40:43Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:40:43Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:40:43Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:40:43Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:40:43Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:40:43Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.s3-mdss-general-landing-bucket.module.kms_key.aws_kms_grant.this" value="cty.NilVal"
2025-01-17T11:40:43Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:40:43Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:40:43Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-general-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:40:43Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-general-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:40:43Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.s3-mdss-ho-landing-bucket.module.kms_key.aws_kms_grant.this" value="cty.NilVal"
2025-01-17T11:40:43Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-ho-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:40:43Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-ho-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:40:43Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-ho-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:40:43Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-ho-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:40:43Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.s3-mdss-specials-landing-bucket.module.kms_key.aws_kms_grant.this" value="cty.NilVal"
2025-01-17T11:40:43Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:40:43Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:40:43Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-specials-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:40:43Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-specials-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:40:43Z INFO [terraform scanner] Scanning root module file_path="glue-job/Archived"
2025-01-17T11:40:51Z INFO [terraform executor] Ignore finding rule="aws-iam-no-user-attached-policies" range="modules/landing_bucket_iam_user_access/main.tf:2-10"
2025-01-17T11:40:51Z INFO [terraform executor] Ignore finding rule="aws-iam-no-user-attached-policies" range="modules/landing_bucket_iam_user_access/main.tf:2-10"
2025-01-17T11:40:51Z INFO [terraform executor] Ignore finding rule="aws-s3-enable-bucket-encryption" range="s3.tf:1133-1152"
2025-01-17T11:40:51Z INFO [terraform executor] Ignore finding rule="aws-ssm-secret-use-customer-key" range="analytical_platform_share.tf:53-71"
2025-01-17T11:40:51Z INFO [terraform executor] Ignore finding rule="aws-s3-enable-versioning" range="s3.tf:1133-1152"
2025-01-17T11:40:51Z INFO [terraform executor] Ignore finding rule="aws-s3-enable-logging" range="s3.tf:1133-1152"
2025-01-17T11:40:51Z INFO [terraform executor] Ignore finding rule="aws-cloudwatch-log-group-customer-key" range="modules/api_step_function/main.tf:295-300"
2025-01-17T11:40:51Z INFO [terraform executor] Ignore finding rule="aws-cloudwatch-log-group-customer-key" range="modules/api_step_function/main.tf:421-425"
2025-01-17T11:40:51Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:40:51Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:40:51Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:40:51Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:40:51Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:40:51Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:40:51Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:40:51Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:40:51Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:40:51Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:40:51Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:40:51Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:40:51Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:40:51Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:40:51Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:40:51Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:40:51Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-bastion-linux?ref=95ed3c3/github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=568694e50e03630d99cb569eafa06a0b879a1239/main.tf:171-179"
2025-01-17T11:40:51Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="s3.tf:1133-1152"
2025-01-17T11:40:51Z INFO Number of language-specific files num=0
2025-01-17T11:40:51Z INFO Detected config files num=13
trivy_exitcode=0
Running Trivy in terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
2025-01-17T11:40:51Z INFO [vuln] Vulnerability scanning is enabled
2025-01-17T11:40:51Z INFO [misconfig] Misconfiguration scanning is enabled
2025-01-17T11:40:51Z INFO [secret] Secret scanning is enabled
2025-01-17T11:40:51Z INFO [secret] If your scanning is slow, please try '--scanners vuln' to disable secret scanning
2025-01-17T11:40:51Z INFO [secret] Please see also https://aquasecurity.github.io/trivy/v0.57/docs/scanner/secret#recommendation for faster secret detection
2025-01-17T11:40:52Z INFO [terraform scanner] Scanning root module file_path="."
2025-01-17T11:40:52Z WARN [terraform parser] Variable values was not found in the environment or variable files. Evaluating may not work correctly. module="root" variables="data_locations, databases_to_share, destination_account_id"
2025-01-17T11:40:52Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="aws_lakeformation_data_cells_filter.data_filter" value="cty.NilVal"
2025-01-17T11:40:52Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="aws_lakeformation_permissions.data_location_share" value="cty.NilVal"
2025-01-17T11:40:52Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="aws_lakeformation_permissions.share_filtered_data" value="cty.NilVal"
2025-01-17T11:40:52Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="aws_lakeformation_resource.data_location" value="cty.NilVal"
2025-01-17T11:40:52Z INFO Number of language-specific files num=0
2025-01-17T11:40:52Z INFO Detected config files num=1
trivy_exitcode=0
</details> #### `Checkov Scan` Success
<details><summary>Show Output</summary>
```hcl
*****************************
Checkov will check the following folders:
terraform/environments/electronic-monitoring-data
terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
*****************************
Running Checkov in terraform/environments/electronic-monitoring-data
Excluding the following checks: CKV_GIT_1,CKV_AWS_126,CKV2_AWS_38,CKV2_AWS_39
2025-01-17 11:40:54,705 [MainThread ] [WARNI] Failed to download module github.com/ministryofjustice/modernisation-platform-terraform-bastion-linux?ref=95ed3c3:None (for external modules, the --download-external-modules flag is required)
2025-01-17 11:40:54,708 [MainThread ] [WARNI] Failed to download module github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060:None (for external modules, the --download-external-modules flag is required)
2025-01-17 11:40:54,709 [MainThread ] [WARNI] Failed to download module terraform-aws-modules/iam/aws//modules/iam-assumable-role:5.48.0 (for external modules, the --download-external-modules flag is required)
2025-01-17 11:40:54,709 [MainThread ] [WARNI] Failed to download module terraform-aws-modules/kms/aws:3.1.1 (for external modules, the --download-external-modules flag is required)
2025-01-17 11:40:54,709 [MainThread ] [WARNI] Failed to download module terraform-aws-modules/secrets-manager/aws:1.3.0 (for external modules, the --download-external-modules flag is required)
terraform scan results:
Passed checks: 2737, Failed checks: 0, Skipped checks: 120
checkov_exitcode=0
*****************************
Running Checkov in terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
Excluding the following checks: CKV_GIT_1,CKV_AWS_126,CKV2_AWS_38,CKV2_AWS_39
checkov_exitcode=0
CTFLint Scan Success
Show Output
*****************************
Setting default tflint config...
Running tflint --init...
Installing "terraform" plugin...
Installed "terraform" (source: github.com/terraform-linters/tflint-ruleset-terraform, version:0.9.1)
tflint will check the following folders:
terraform/environments/electronic-monitoring-data
terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
*****************************
Running tflint in terraform/environments/electronic-monitoring-data
Excluding the following checks: terraform_unused_declarations
tflint_exitcode=0*****************************
Running tflint in terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
Excluding the following checks: terraform_unused_declarations
tflint_exitcode=0
Trivy Scan Success
Show Output
*****************************
Trivy will check the following folders:
terraform/environments/electronic-monitoring-data
terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
*****************************
Running Trivy in terraform/environments/electronic-monitoring-data
2025-01-17T11:40:36Z INFO [vulndb] Need to update DB
2025-01-17T11:40:36Z INFO [vulndb] Downloading vulnerability DB...2025-01-17T11:40:36Z INFO [vulndb] Downloading artifact...repo="public.ecr.aws/aquasecurity/trivy-db:2"2025-01-17T11:40:38Z INFO [vulndb] Artifact successfully downloaded repo="public.ecr.aws/aquasecurity/trivy-db:2"2025-01-17T11:40:38Z INFO [vuln] Vulnerability scanning is enabled
2025-01-17T11:40:38Z INFO [misconfig] Misconfiguration scanning is enabled
2025-01-17T11:40:38Z INFO [misconfig] Need to update the built-in checks
2025-01-17T11:40:38Z INFO [misconfig] Downloading the built-in checks...160.80 KiB /160.80 KiB [------------------------------------------------------] 100.00%? p/s 100ms2025-01-17T11:40:39Z INFO [secret] Secret scanning is enabled
2025-01-17T11:40:39Z INFO [secret] If your scanning is slow, please try '--scanners vuln' to disable secret scanning
2025-01-17T11:40:39Z INFO [secret] Please see also https://aquasecurity.github.io/trivy/v0.57/docs/scanner/secret#recommendation for faster secret detection2025-01-17T11:40:40Z INFO [terraformscanner] Scanning root module file_path="."2025-01-17T11:40:40Z WARN [terraformparser] Variable values was not found in the environment or variable files. Evaluating may not work correctly.module="root"variables="networking"2025-01-17T11:40:41Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.api_gateway_authorizer.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:40:41Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.api_gateway_authorizer.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:40:41Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.calculate_checksum.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:40:41Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.calculate_checksum.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:40:41Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.copy_mdss_data.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:40:41Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.copy_mdss_data.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:40:41Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.format_json_fms_data.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:40:41Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.format_json_fms_data.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:40:41Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:40:41Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:40:42Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.rds_bastion.aws_s3_object.user_public_keys"value="cty.NilVal"2025-01-17T11:40:42Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.rds_bastion.data.aws_subnet.local_account"value="cty.NilVal"2025-01-17T11:40:42Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.rds_bastion.aws_autoscaling_group.bastion_linux_daily"err="1 error occurred:\n\t* invalid for-each in aws_autoscaling_group.bastion_linux_daily.dynamic.tag block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:40:42Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.rds_bastion.aws_autoscaling_group.bastion_linux_daily"err="1 error occurred:\n\t* invalid for-each in aws_autoscaling_group.bastion_linux_daily.dynamic.tag block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:40:42Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.rotate_iam_key.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:40:42Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.rotate_iam_key.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:40:42Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:40:42Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:40:42Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:40:42Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:40:43Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:40:43Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:40:43Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:40:43Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:40:43Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:40:43Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:40:43Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:40:43Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:40:43Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.s3-mdss-general-landing-bucket.module.kms_key.aws_kms_grant.this"value="cty.NilVal"2025-01-17T11:40:43Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:40:43Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:40:43Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-general-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:40:43Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-general-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:40:43Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.s3-mdss-ho-landing-bucket.module.kms_key.aws_kms_grant.this"value="cty.NilVal"2025-01-17T11:40:43Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-ho-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:40:43Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-ho-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:40:43Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-ho-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:40:43Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-ho-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:40:43Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.s3-mdss-specials-landing-bucket.module.kms_key.aws_kms_grant.this"value="cty.NilVal"2025-01-17T11:40:43Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:40:43Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:40:43Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-specials-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:40:43Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-specials-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:40:43Z INFO [terraformscanner] Scanning root module file_path="glue-job/Archived"2025-01-17T11:40:51Z INFO [terraformexecutor] Ignore finding rule="aws-iam-no-user-attached-policies"range="modules/landing_bucket_iam_user_access/main.tf:2-10"2025-01-17T11:40:51Z INFO [terraformexecutor] Ignore finding rule="aws-iam-no-user-attached-policies"range="modules/landing_bucket_iam_user_access/main.tf:2-10"2025-01-17T11:40:51Z INFO [terraformexecutor] Ignore finding rule="aws-s3-enable-bucket-encryption"range="s3.tf:1133-1152"2025-01-17T11:40:51Z INFO [terraformexecutor] Ignore finding rule="aws-ssm-secret-use-customer-key"range="analytical_platform_share.tf:53-71"2025-01-17T11:40:51Z INFO [terraformexecutor] Ignore finding rule="aws-s3-enable-versioning"range="s3.tf:1133-1152"2025-01-17T11:40:51Z INFO [terraformexecutor] Ignore finding rule="aws-s3-enable-logging"range="s3.tf:1133-1152"2025-01-17T11:40:51Z INFO [terraformexecutor] Ignore finding rule="aws-cloudwatch-log-group-customer-key"range="modules/api_step_function/main.tf:295-300"2025-01-17T11:40:51Z INFO [terraformexecutor] Ignore finding rule="aws-cloudwatch-log-group-customer-key"range="modules/api_step_function/main.tf:421-425"2025-01-17T11:40:51Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:40:51Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:40:51Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:40:51Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:40:51Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:40:51Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:40:51Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:40:51Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:40:51Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:40:51Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:40:51Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:40:51Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:40:51Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:40:51Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:40:51Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:40:51Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:40:51Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-bastion-linux?ref=95ed3c3/github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=568694e50e03630d99cb569eafa06a0b879a1239/main.tf:171-179"2025-01-17T11:40:51Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="s3.tf:1133-1152"2025-01-17T11:40:51Z INFO Number of language-specific files num=02025-01-17T11:40:51Z INFO Detected config files num=13trivy_exitcode=0*****************************
Running Trivy in terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
2025-01-17T11:40:51Z INFO [vuln] Vulnerability scanning is enabled
2025-01-17T11:40:51Z INFO [misconfig] Misconfiguration scanning is enabled
2025-01-17T11:40:51Z INFO [secret] Secret scanning is enabled
2025-01-17T11:40:51Z INFO [secret] If your scanning is slow, please try '--scanners vuln' to disable secret scanning
2025-01-17T11:40:51Z INFO [secret] Please see also https://aquasecurity.github.io/trivy/v0.57/docs/scanner/secret#recommendation for faster secret detection2025-01-17T11:40:52Z INFO [terraformscanner] Scanning root module file_path="."2025-01-17T11:40:52Z WARN [terraformparser] Variable values was not found in the environment or variable files. Evaluating may not work correctly.module="root"variables="data_locations, databases_to_share, destination_account_id"2025-01-17T11:40:52Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="aws_lakeformation_data_cells_filter.data_filter"value="cty.NilVal"2025-01-17T11:40:52Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="aws_lakeformation_permissions.data_location_share"value="cty.NilVal"2025-01-17T11:40:52Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="aws_lakeformation_permissions.share_filtered_data"value="cty.NilVal"2025-01-17T11:40:52Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="aws_lakeformation_resource.data_location"value="cty.NilVal"2025-01-17T11:40:52Z INFO Number of language-specific files num=02025-01-17T11:40:52Z INFO Detected config files num=1trivy_exitcode=0
Trivy will check the following folders:
terraform/environments/electronic-monitoring-data
terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
Running Trivy in terraform/environments/electronic-monitoring-data
2025-01-17T11:56:05Z INFO [vulndb] Need to update DB
2025-01-17T11:56:05Z INFO [vulndb] Downloading vulnerability DB...
2025-01-17T11:56:05Z INFO [vulndb] Downloading artifact... repo="public.ecr.aws/aquasecurity/trivy-db:2"
2025-01-17T11:56:07Z INFO [vulndb] Artifact successfully downloaded repo="public.ecr.aws/aquasecurity/trivy-db:2"
2025-01-17T11:56:07Z INFO [vuln] Vulnerability scanning is enabled
2025-01-17T11:56:07Z INFO [misconfig] Misconfiguration scanning is enabled
2025-01-17T11:56:07Z INFO [misconfig] Need to update the built-in checks
2025-01-17T11:56:07Z INFO [misconfig] Downloading the built-in checks...
160.80 KiB / 160.80 KiB [---------------------------------------------------------] 100.00% ? p/s 0s2025-01-17T11:56:08Z INFO [secret] Secret scanning is enabled
2025-01-17T11:56:08Z INFO [secret] If your scanning is slow, please try '--scanners vuln' to disable secret scanning
2025-01-17T11:56:08Z INFO [secret] Please see also https://aquasecurity.github.io/trivy/v0.57/docs/scanner/secret#recommendation for faster secret detection
2025-01-17T11:56:09Z INFO [terraform scanner] Scanning root module file_path="."
2025-01-17T11:56:09Z WARN [terraform parser] Variable values was not found in the environment or variable files. Evaluating may not work correctly. module="root" variables="networking"
2025-01-17T11:56:11Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.api_gateway_authorizer.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:56:11Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.api_gateway_authorizer.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:56:11Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.calculate_checksum.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:56:11Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.calculate_checksum.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:56:11Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.copy_mdss_data.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:56:11Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.copy_mdss_data.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:56:11Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.format_json_fms_data.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:56:11Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.format_json_fms_data.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:56:11Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:56:11Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:56:11Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.rds_bastion.aws_s3_object.user_public_keys" value="cty.NilVal"
2025-01-17T11:56:11Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.rds_bastion.data.aws_subnet.local_account" value="cty.NilVal"
2025-01-17T11:56:11Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.rds_bastion.aws_autoscaling_group.bastion_linux_daily" err="1 error occurred:\n\t* invalid for-each in aws_autoscaling_group.bastion_linux_daily.dynamic.tag block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:56:11Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.rds_bastion.aws_autoscaling_group.bastion_linux_daily" err="1 error occurred:\n\t* invalid for-each in aws_autoscaling_group.bastion_linux_daily.dynamic.tag block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:56:12Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.rotate_iam_key.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:56:12Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.rotate_iam_key.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:56:12Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:56:12Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:56:13Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:56:13Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:56:14Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:56:14Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:56:14Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:56:14Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:56:14Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:56:14Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:56:14Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:56:14Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:56:14Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.s3-mdss-general-landing-bucket.module.kms_key.aws_kms_grant.this" value="cty.NilVal"
2025-01-17T11:56:14Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:56:14Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:56:14Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-general-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:56:14Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-general-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:56:14Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.s3-mdss-ho-landing-bucket.module.kms_key.aws_kms_grant.this" value="cty.NilVal"
2025-01-17T11:56:14Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-ho-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:56:14Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-ho-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:56:14Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-ho-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:56:14Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-ho-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:56:14Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.s3-mdss-specials-landing-bucket.module.kms_key.aws_kms_grant.this" value="cty.NilVal"
2025-01-17T11:56:14Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:56:14Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:56:14Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-specials-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:56:14Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-specials-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T11:56:14Z INFO [terraform scanner] Scanning root module file_path="glue-job/Archived"
2025-01-17T11:56:22Z INFO [terraform executor] Ignore finding rule="aws-cloudwatch-log-group-customer-key" range="modules/api_step_function/main.tf:295-300"
2025-01-17T11:56:22Z INFO [terraform executor] Ignore finding rule="aws-cloudwatch-log-group-customer-key" range="modules/api_step_function/main.tf:421-425"
2025-01-17T11:56:22Z INFO [terraform executor] Ignore finding rule="aws-s3-enable-bucket-encryption" range="s3.tf:1133-1152"
2025-01-17T11:56:22Z INFO [terraform executor] Ignore finding rule="aws-ssm-secret-use-customer-key" range="analytical_platform_share.tf:53-71"
2025-01-17T11:56:22Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:56:22Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:56:22Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:56:22Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:56:22Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:56:22Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:56:22Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:56:22Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:56:22Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:56:22Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:56:22Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:56:22Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:56:22Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:56:22Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:56:22Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:56:22Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T11:56:22Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-bastion-linux?ref=95ed3c3/github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=568694e50e03630d99cb569eafa06a0b879a1239/main.tf:171-179"
2025-01-17T11:56:22Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="s3.tf:1133-1152"
2025-01-17T11:56:22Z INFO [terraform executor] Ignore finding rule="aws-s3-enable-logging" range="s3.tf:1133-1152"
2025-01-17T11:56:22Z INFO [terraform executor] Ignore finding rule="aws-iam-no-user-attached-policies" range="modules/landing_bucket_iam_user_access/main.tf:2-10"
2025-01-17T11:56:22Z INFO [terraform executor] Ignore finding rule="aws-iam-no-user-attached-policies" range="modules/landing_bucket_iam_user_access/main.tf:2-10"
2025-01-17T11:56:22Z INFO [terraform executor] Ignore finding rule="aws-s3-enable-versioning" range="s3.tf:1133-1152"
2025-01-17T11:56:22Z INFO Number of language-specific files num=0
2025-01-17T11:56:22Z INFO Detected config files num=13
trivy_exitcode=0
Running Trivy in terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
2025-01-17T11:56:22Z INFO [vuln] Vulnerability scanning is enabled
2025-01-17T11:56:22Z INFO [misconfig] Misconfiguration scanning is enabled
2025-01-17T11:56:22Z INFO [secret] Secret scanning is enabled
2025-01-17T11:56:22Z INFO [secret] If your scanning is slow, please try '--scanners vuln' to disable secret scanning
2025-01-17T11:56:22Z INFO [secret] Please see also https://aquasecurity.github.io/trivy/v0.57/docs/scanner/secret#recommendation for faster secret detection
2025-01-17T11:56:23Z INFO [terraform scanner] Scanning root module file_path="."
2025-01-17T11:56:23Z WARN [terraform parser] Variable values was not found in the environment or variable files. Evaluating may not work correctly. module="root" variables="data_locations, databases_to_share, destination_account_id"
2025-01-17T11:56:23Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="aws_lakeformation_data_cells_filter.data_filter" value="cty.NilVal"
2025-01-17T11:56:23Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="aws_lakeformation_permissions.data_location_share" value="cty.NilVal"
2025-01-17T11:56:23Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="aws_lakeformation_permissions.share_filtered_data" value="cty.NilVal"
2025-01-17T11:56:23Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="aws_lakeformation_resource.data_location" value="cty.NilVal"
2025-01-17T11:56:23Z INFO Number of language-specific files num=0
2025-01-17T11:56:23Z INFO Detected config files num=1
trivy_exitcode=0
</details> #### `Checkov Scan` Success
<details><summary>Show Output</summary>
```hcl
*****************************
Checkov will check the following folders:
terraform/environments/electronic-monitoring-data
terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
*****************************
Running Checkov in terraform/environments/electronic-monitoring-data
Excluding the following checks: CKV_GIT_1,CKV_AWS_126,CKV2_AWS_38,CKV2_AWS_39
2025-01-17 11:56:26,118 [MainThread ] [WARNI] Failed to download module github.com/ministryofjustice/modernisation-platform-terraform-bastion-linux?ref=95ed3c3:None (for external modules, the --download-external-modules flag is required)
2025-01-17 11:56:26,118 [MainThread ] [WARNI] Failed to download module github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060:None (for external modules, the --download-external-modules flag is required)
2025-01-17 11:56:26,118 [MainThread ] [WARNI] Failed to download module terraform-aws-modules/iam/aws//modules/iam-assumable-role:5.48.0 (for external modules, the --download-external-modules flag is required)
2025-01-17 11:56:26,118 [MainThread ] [WARNI] Failed to download module terraform-aws-modules/kms/aws:3.1.1 (for external modules, the --download-external-modules flag is required)
2025-01-17 11:56:26,122 [MainThread ] [WARNI] Failed to download module terraform-aws-modules/secrets-manager/aws:1.3.0 (for external modules, the --download-external-modules flag is required)
terraform scan results:
Passed checks: 2737, Failed checks: 0, Skipped checks: 120
checkov_exitcode=0
*****************************
Running Checkov in terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
Excluding the following checks: CKV_GIT_1,CKV_AWS_126,CKV2_AWS_38,CKV2_AWS_39
checkov_exitcode=0
CTFLint Scan Success
Show Output
*****************************
Setting default tflint config...
Running tflint --init...
Installing "terraform" plugin...
Installed "terraform" (source: github.com/terraform-linters/tflint-ruleset-terraform, version:0.9.1)
tflint will check the following folders:
terraform/environments/electronic-monitoring-data
terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
*****************************
Running tflint in terraform/environments/electronic-monitoring-data
Excluding the following checks: terraform_unused_declarations
tflint_exitcode=0*****************************
Running tflint in terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
Excluding the following checks: terraform_unused_declarations
tflint_exitcode=0
Trivy Scan Success
Show Output
*****************************
Trivy will check the following folders:
terraform/environments/electronic-monitoring-data
terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
*****************************
Running Trivy in terraform/environments/electronic-monitoring-data
2025-01-17T11:56:05Z INFO [vulndb] Need to update DB
2025-01-17T11:56:05Z INFO [vulndb] Downloading vulnerability DB...2025-01-17T11:56:05Z INFO [vulndb] Downloading artifact...repo="public.ecr.aws/aquasecurity/trivy-db:2"2025-01-17T11:56:07Z INFO [vulndb] Artifact successfully downloaded repo="public.ecr.aws/aquasecurity/trivy-db:2"2025-01-17T11:56:07Z INFO [vuln] Vulnerability scanning is enabled
2025-01-17T11:56:07Z INFO [misconfig] Misconfiguration scanning is enabled
2025-01-17T11:56:07Z INFO [misconfig] Need to update the built-in checks
2025-01-17T11:56:07Z INFO [misconfig] Downloading the built-in checks...160.80 KiB /160.80 KiB [---------------------------------------------------------] 100.00%? p/s 0s2025-01-17T11:56:08Z INFO [secret] Secret scanning is enabled
2025-01-17T11:56:08Z INFO [secret] If your scanning is slow, please try '--scanners vuln' to disable secret scanning
2025-01-17T11:56:08Z INFO [secret] Please see also https://aquasecurity.github.io/trivy/v0.57/docs/scanner/secret#recommendation for faster secret detection2025-01-17T11:56:09Z INFO [terraformscanner] Scanning root module file_path="."2025-01-17T11:56:09Z WARN [terraformparser] Variable values was not found in the environment or variable files. Evaluating may not work correctly.module="root"variables="networking"2025-01-17T11:56:11Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.api_gateway_authorizer.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:56:11Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.api_gateway_authorizer.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:56:11Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.calculate_checksum.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:56:11Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.calculate_checksum.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:56:11Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.copy_mdss_data.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:56:11Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.copy_mdss_data.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:56:11Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.format_json_fms_data.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:56:11Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.format_json_fms_data.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:56:11Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:56:11Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:56:11Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.rds_bastion.aws_s3_object.user_public_keys"value="cty.NilVal"2025-01-17T11:56:11Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.rds_bastion.data.aws_subnet.local_account"value="cty.NilVal"2025-01-17T11:56:11Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.rds_bastion.aws_autoscaling_group.bastion_linux_daily"err="1 error occurred:\n\t* invalid for-each in aws_autoscaling_group.bastion_linux_daily.dynamic.tag block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:56:11Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.rds_bastion.aws_autoscaling_group.bastion_linux_daily"err="1 error occurred:\n\t* invalid for-each in aws_autoscaling_group.bastion_linux_daily.dynamic.tag block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:56:12Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.rotate_iam_key.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:56:12Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.rotate_iam_key.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:56:12Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:56:12Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:56:13Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:56:13Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:56:14Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:56:14Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:56:14Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:56:14Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:56:14Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:56:14Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:56:14Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:56:14Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:56:14Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.s3-mdss-general-landing-bucket.module.kms_key.aws_kms_grant.this"value="cty.NilVal"2025-01-17T11:56:14Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:56:14Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:56:14Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-general-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:56:14Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-general-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:56:14Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.s3-mdss-ho-landing-bucket.module.kms_key.aws_kms_grant.this"value="cty.NilVal"2025-01-17T11:56:14Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-ho-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:56:14Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-ho-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:56:14Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-ho-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:56:14Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-ho-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:56:14Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.s3-mdss-specials-landing-bucket.module.kms_key.aws_kms_grant.this"value="cty.NilVal"2025-01-17T11:56:14Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:56:14Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:56:14Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-specials-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:56:14Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-specials-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T11:56:14Z INFO [terraformscanner] Scanning root module file_path="glue-job/Archived"2025-01-17T11:56:22Z INFO [terraformexecutor] Ignore finding rule="aws-cloudwatch-log-group-customer-key"range="modules/api_step_function/main.tf:295-300"2025-01-17T11:56:22Z INFO [terraformexecutor] Ignore finding rule="aws-cloudwatch-log-group-customer-key"range="modules/api_step_function/main.tf:421-425"2025-01-17T11:56:22Z INFO [terraformexecutor] Ignore finding rule="aws-s3-enable-bucket-encryption"range="s3.tf:1133-1152"2025-01-17T11:56:22Z INFO [terraformexecutor] Ignore finding rule="aws-ssm-secret-use-customer-key"range="analytical_platform_share.tf:53-71"2025-01-17T11:56:22Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:56:22Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:56:22Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:56:22Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:56:22Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:56:22Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:56:22Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:56:22Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:56:22Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:56:22Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:56:22Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:56:22Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:56:22Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:56:22Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:56:22Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:56:22Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T11:56:22Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-bastion-linux?ref=95ed3c3/github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=568694e50e03630d99cb569eafa06a0b879a1239/main.tf:171-179"2025-01-17T11:56:22Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="s3.tf:1133-1152"2025-01-17T11:56:22Z INFO [terraformexecutor] Ignore finding rule="aws-s3-enable-logging"range="s3.tf:1133-1152"2025-01-17T11:56:22Z INFO [terraformexecutor] Ignore finding rule="aws-iam-no-user-attached-policies"range="modules/landing_bucket_iam_user_access/main.tf:2-10"2025-01-17T11:56:22Z INFO [terraformexecutor] Ignore finding rule="aws-iam-no-user-attached-policies"range="modules/landing_bucket_iam_user_access/main.tf:2-10"2025-01-17T11:56:22Z INFO [terraformexecutor] Ignore finding rule="aws-s3-enable-versioning"range="s3.tf:1133-1152"2025-01-17T11:56:22Z INFO Number of language-specific files num=02025-01-17T11:56:22Z INFO Detected config files num=13trivy_exitcode=0*****************************
Running Trivy in terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
2025-01-17T11:56:22Z INFO [vuln] Vulnerability scanning is enabled
2025-01-17T11:56:22Z INFO [misconfig] Misconfiguration scanning is enabled
2025-01-17T11:56:22Z INFO [secret] Secret scanning is enabled
2025-01-17T11:56:22Z INFO [secret] If your scanning is slow, please try '--scanners vuln' to disable secret scanning
2025-01-17T11:56:22Z INFO [secret] Please see also https://aquasecurity.github.io/trivy/v0.57/docs/scanner/secret#recommendation for faster secret detection2025-01-17T11:56:23Z INFO [terraformscanner] Scanning root module file_path="."2025-01-17T11:56:23Z WARN [terraformparser] Variable values was not found in the environment or variable files. Evaluating may not work correctly.module="root"variables="data_locations, databases_to_share, destination_account_id"2025-01-17T11:56:23Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="aws_lakeformation_data_cells_filter.data_filter"value="cty.NilVal"2025-01-17T11:56:23Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="aws_lakeformation_permissions.data_location_share"value="cty.NilVal"2025-01-17T11:56:23Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="aws_lakeformation_permissions.share_filtered_data"value="cty.NilVal"2025-01-17T11:56:23Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="aws_lakeformation_resource.data_location"value="cty.NilVal"2025-01-17T11:56:23Z INFO Number of language-specific files num=02025-01-17T11:56:23Z INFO Detected config files num=1trivy_exitcode=0
Trivy will check the following folders:
terraform/environments/electronic-monitoring-data
terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
Running Trivy in terraform/environments/electronic-monitoring-data
2025-01-17T12:13:09Z INFO [vulndb] Need to update DB
2025-01-17T12:13:09Z INFO [vulndb] Downloading vulnerability DB...
2025-01-17T12:13:09Z INFO [vulndb] Downloading artifact... repo="public.ecr.aws/aquasecurity/trivy-db:2"
2025-01-17T12:13:11Z INFO [vulndb] Artifact successfully downloaded repo="public.ecr.aws/aquasecurity/trivy-db:2"
2025-01-17T12:13:11Z INFO [vuln] Vulnerability scanning is enabled
2025-01-17T12:13:11Z INFO [misconfig] Misconfiguration scanning is enabled
2025-01-17T12:13:11Z INFO [misconfig] Need to update the built-in checks
2025-01-17T12:13:11Z INFO [misconfig] Downloading the built-in checks...
160.80 KiB / 160.80 KiB [---------------------------------------------------------] 100.00% ? p/s 0s2025-01-17T12:13:11Z INFO [secret] Secret scanning is enabled
2025-01-17T12:13:11Z INFO [secret] If your scanning is slow, please try '--scanners vuln' to disable secret scanning
2025-01-17T12:13:11Z INFO [secret] Please see also https://aquasecurity.github.io/trivy/v0.57/docs/scanner/secret#recommendation for faster secret detection
2025-01-17T12:13:12Z INFO [terraform scanner] Scanning root module file_path="."
2025-01-17T12:13:12Z WARN [terraform parser] Variable values was not found in the environment or variable files. Evaluating may not work correctly. module="root" variables="networking"
2025-01-17T12:13:13Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.api_gateway_authorizer.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T12:13:13Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.api_gateway_authorizer.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T12:13:13Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.calculate_checksum.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T12:13:13Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.calculate_checksum.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T12:13:13Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.copy_mdss_data.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T12:13:13Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.copy_mdss_data.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T12:13:14Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.format_json_fms_data.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T12:13:14Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.format_json_fms_data.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T12:13:14Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T12:13:14Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T12:13:14Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.rds_bastion.aws_s3_object.user_public_keys" value="cty.NilVal"
2025-01-17T12:13:14Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.rds_bastion.data.aws_subnet.local_account" value="cty.NilVal"
2025-01-17T12:13:14Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.rds_bastion.aws_autoscaling_group.bastion_linux_daily" err="1 error occurred:\n\t* invalid for-each in aws_autoscaling_group.bastion_linux_daily.dynamic.tag block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T12:13:14Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.rds_bastion.aws_autoscaling_group.bastion_linux_daily" err="1 error occurred:\n\t* invalid for-each in aws_autoscaling_group.bastion_linux_daily.dynamic.tag block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T12:13:14Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.rotate_iam_key.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T12:13:14Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.rotate_iam_key.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T12:13:14Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T12:13:14Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T12:13:14Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T12:13:14Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T12:13:15Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T12:13:15Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T12:13:15Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T12:13:15Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T12:13:15Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T12:13:15Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T12:13:15Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T12:13:15Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T12:13:15Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.s3-mdss-general-landing-bucket.module.kms_key.aws_kms_grant.this" value="cty.NilVal"
2025-01-17T12:13:15Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T12:13:15Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T12:13:15Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-general-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T12:13:15Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-general-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T12:13:15Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.s3-mdss-ho-landing-bucket.module.kms_key.aws_kms_grant.this" value="cty.NilVal"
2025-01-17T12:13:15Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-ho-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T12:13:15Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-ho-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T12:13:15Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-ho-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T12:13:15Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-ho-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T12:13:15Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="module.s3-mdss-specials-landing-bucket.module.kms_key.aws_kms_grant.this" value="cty.NilVal"
2025-01-17T12:13:15Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T12:13:15Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this" err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T12:13:15Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-specials-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T12:13:15Z ERROR [terraform evaluator] Failed to expand dynamic block. block="module.s3-mdss-specials-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2" err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"
2025-01-17T12:13:15Z INFO [terraform scanner] Scanning root module file_path="glue-job/Archived"
2025-01-17T12:13:23Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T12:13:23Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T12:13:23Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T12:13:23Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T12:13:23Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T12:13:23Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T12:13:23Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T12:13:23Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T12:13:23Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T12:13:23Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T12:13:23Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T12:13:23Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T12:13:23Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T12:13:23Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T12:13:23Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T12:13:23Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"
2025-01-17T12:13:23Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="github.com/ministryofjustice/modernisation-platform-terraform-bastion-linux?ref=95ed3c3/github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=568694e50e03630d99cb569eafa06a0b879a1239/main.tf:171-179"
2025-01-17T12:13:23Z INFO [terraform executor] Ignore finding rule="aws-s3-encryption-customer-key" range="s3.tf:1133-1152"
2025-01-17T12:13:23Z INFO [terraform executor] Ignore finding rule="aws-s3-enable-bucket-encryption" range="s3.tf:1133-1152"
2025-01-17T12:13:23Z INFO [terraform executor] Ignore finding rule="aws-s3-enable-versioning" range="s3.tf:1133-1152"
2025-01-17T12:13:23Z INFO [terraform executor] Ignore finding rule="aws-iam-no-user-attached-policies" range="modules/landing_bucket_iam_user_access/main.tf:2-10"
2025-01-17T12:13:23Z INFO [terraform executor] Ignore finding rule="aws-iam-no-user-attached-policies" range="modules/landing_bucket_iam_user_access/main.tf:2-10"
2025-01-17T12:13:23Z INFO [terraform executor] Ignore finding rule="aws-cloudwatch-log-group-customer-key" range="modules/api_step_function/main.tf:295-300"
2025-01-17T12:13:23Z INFO [terraform executor] Ignore finding rule="aws-cloudwatch-log-group-customer-key" range="modules/api_step_function/main.tf:421-425"
2025-01-17T12:13:23Z INFO [terraform executor] Ignore finding rule="aws-s3-enable-logging" range="s3.tf:1133-1152"
2025-01-17T12:13:23Z INFO [terraform executor] Ignore finding rule="aws-ssm-secret-use-customer-key" range="analytical_platform_share.tf:53-71"
2025-01-17T12:13:23Z INFO Number of language-specific files num=0
2025-01-17T12:13:23Z INFO Detected config files num=13
trivy_exitcode=0
Running Trivy in terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
2025-01-17T12:13:23Z INFO [vuln] Vulnerability scanning is enabled
2025-01-17T12:13:23Z INFO [misconfig] Misconfiguration scanning is enabled
2025-01-17T12:13:23Z INFO [secret] Secret scanning is enabled
2025-01-17T12:13:23Z INFO [secret] If your scanning is slow, please try '--scanners vuln' to disable secret scanning
2025-01-17T12:13:23Z INFO [secret] Please see also https://aquasecurity.github.io/trivy/v0.57/docs/scanner/secret#recommendation for faster secret detection
2025-01-17T12:13:24Z INFO [terraform scanner] Scanning root module file_path="."
2025-01-17T12:13:24Z WARN [terraform parser] Variable values was not found in the environment or variable files. Evaluating may not work correctly. module="root" variables="data_locations, databases_to_share, destination_account_id"
2025-01-17T12:13:24Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="aws_lakeformation_data_cells_filter.data_filter" value="cty.NilVal"
2025-01-17T12:13:24Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="aws_lakeformation_permissions.data_location_share" value="cty.NilVal"
2025-01-17T12:13:24Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="aws_lakeformation_permissions.share_filtered_data" value="cty.NilVal"
2025-01-17T12:13:24Z ERROR [terraform evaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable. block="aws_lakeformation_resource.data_location" value="cty.NilVal"
2025-01-17T12:13:24Z INFO Number of language-specific files num=0
2025-01-17T12:13:24Z INFO Detected config files num=1
trivy_exitcode=0
</details> #### `Checkov Scan` Success
<details><summary>Show Output</summary>
```hcl
*****************************
Checkov will check the following folders:
terraform/environments/electronic-monitoring-data
terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
*****************************
Running Checkov in terraform/environments/electronic-monitoring-data
Excluding the following checks: CKV_GIT_1,CKV_AWS_126,CKV2_AWS_38,CKV2_AWS_39
2025-01-17 12:13:27,047 [MainThread ] [WARNI] Failed to download module github.com/ministryofjustice/modernisation-platform-terraform-bastion-linux?ref=95ed3c3:None (for external modules, the --download-external-modules flag is required)
2025-01-17 12:13:27,047 [MainThread ] [WARNI] Failed to download module github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060:None (for external modules, the --download-external-modules flag is required)
2025-01-17 12:13:27,048 [MainThread ] [WARNI] Failed to download module terraform-aws-modules/iam/aws//modules/iam-assumable-role:5.48.0 (for external modules, the --download-external-modules flag is required)
2025-01-17 12:13:27,048 [MainThread ] [WARNI] Failed to download module terraform-aws-modules/kms/aws:3.1.1 (for external modules, the --download-external-modules flag is required)
2025-01-17 12:13:27,048 [MainThread ] [WARNI] Failed to download module terraform-aws-modules/secrets-manager/aws:1.3.0 (for external modules, the --download-external-modules flag is required)
terraform scan results:
Passed checks: 2737, Failed checks: 0, Skipped checks: 120
checkov_exitcode=0
*****************************
Running Checkov in terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
Excluding the following checks: CKV_GIT_1,CKV_AWS_126,CKV2_AWS_38,CKV2_AWS_39
checkov_exitcode=0
CTFLint Scan Success
Show Output
*****************************
Setting default tflint config...
Running tflint --init...
Installing "terraform" plugin...
Installed "terraform" (source: github.com/terraform-linters/tflint-ruleset-terraform, version:0.9.1)
tflint will check the following folders:
terraform/environments/electronic-monitoring-data
terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
*****************************
Running tflint in terraform/environments/electronic-monitoring-data
Excluding the following checks: terraform_unused_declarations
tflint_exitcode=0*****************************
Running tflint in terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
Excluding the following checks: terraform_unused_declarations
tflint_exitcode=0
Trivy Scan Success
Show Output
*****************************
Trivy will check the following folders:
terraform/environments/electronic-monitoring-data
terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
*****************************
Running Trivy in terraform/environments/electronic-monitoring-data
2025-01-17T12:13:09Z INFO [vulndb] Need to update DB
2025-01-17T12:13:09Z INFO [vulndb] Downloading vulnerability DB...2025-01-17T12:13:09Z INFO [vulndb] Downloading artifact...repo="public.ecr.aws/aquasecurity/trivy-db:2"2025-01-17T12:13:11Z INFO [vulndb] Artifact successfully downloaded repo="public.ecr.aws/aquasecurity/trivy-db:2"2025-01-17T12:13:11Z INFO [vuln] Vulnerability scanning is enabled
2025-01-17T12:13:11Z INFO [misconfig] Misconfiguration scanning is enabled
2025-01-17T12:13:11Z INFO [misconfig] Need to update the built-in checks
2025-01-17T12:13:11Z INFO [misconfig] Downloading the built-in checks...160.80 KiB /160.80 KiB [---------------------------------------------------------] 100.00%? p/s 0s2025-01-17T12:13:11Z INFO [secret] Secret scanning is enabled
2025-01-17T12:13:11Z INFO [secret] If your scanning is slow, please try '--scanners vuln' to disable secret scanning
2025-01-17T12:13:11Z INFO [secret] Please see also https://aquasecurity.github.io/trivy/v0.57/docs/scanner/secret#recommendation for faster secret detection2025-01-17T12:13:12Z INFO [terraformscanner] Scanning root module file_path="."2025-01-17T12:13:12Z WARN [terraformparser] Variable values was not found in the environment or variable files. Evaluating may not work correctly.module="root"variables="networking"2025-01-17T12:13:13Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.api_gateway_authorizer.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T12:13:13Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.api_gateway_authorizer.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T12:13:13Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.calculate_checksum.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T12:13:13Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.calculate_checksum.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T12:13:13Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.copy_mdss_data.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T12:13:13Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.copy_mdss_data.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T12:13:14Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.format_json_fms_data.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T12:13:14Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.format_json_fms_data.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T12:13:14Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T12:13:14Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T12:13:14Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.rds_bastion.aws_s3_object.user_public_keys"value="cty.NilVal"2025-01-17T12:13:14Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.rds_bastion.data.aws_subnet.local_account"value="cty.NilVal"2025-01-17T12:13:14Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.rds_bastion.aws_autoscaling_group.bastion_linux_daily"err="1 error occurred:\n\t* invalid for-each in aws_autoscaling_group.bastion_linux_daily.dynamic.tag block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T12:13:14Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.rds_bastion.aws_autoscaling_group.bastion_linux_daily"err="1 error occurred:\n\t* invalid for-each in aws_autoscaling_group.bastion_linux_daily.dynamic.tag block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T12:13:14Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.rotate_iam_key.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T12:13:14Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.rotate_iam_key.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T12:13:14Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T12:13:14Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T12:13:14Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T12:13:14Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T12:13:15Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T12:13:15Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T12:13:15Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T12:13:15Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.output_file_structure_as_json_from_zip.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T12:13:15Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T12:13:15Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T12:13:15Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T12:13:15Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-fms-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T12:13:15Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.s3-mdss-general-landing-bucket.module.kms_key.aws_kms_grant.this"value="cty.NilVal"2025-01-17T12:13:15Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T12:13:15Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-general-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T12:13:15Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-general-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T12:13:15Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-general-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T12:13:15Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.s3-mdss-ho-landing-bucket.module.kms_key.aws_kms_grant.this"value="cty.NilVal"2025-01-17T12:13:15Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-ho-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T12:13:15Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-ho-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T12:13:15Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-ho-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T12:13:15Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-ho-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T12:13:15Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="module.s3-mdss-specials-landing-bucket.module.kms_key.aws_kms_grant.this"value="cty.NilVal"2025-01-17T12:13:15Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T12:13:15Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-specials-landing-bucket.module.process_landing_bucket_files.aws_lambda_function.this"err="1 error occurred:\n\t* invalid for-each in aws_lambda_function.this.dynamic.vpc_config block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T12:13:15Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-specials-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T12:13:15Z ERROR [terraformevaluator] Failed to expand dynamic block.block="module.s3-mdss-specials-landing-bucket.module.this-bucket.data.aws_iam_policy_document.bucket_policy_v2"err="1 error occurred:\n\t* invalid for-each in data.aws_iam_policy_document.bucket_policy_v2.dynamic.statement block: cannot use a cty.NilVal value in for_each. An iterable collection is required\n\n"2025-01-17T12:13:15Z INFO [terraformscanner] Scanning root module file_path="glue-job/Archived"2025-01-17T12:13:23Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T12:13:23Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T12:13:23Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T12:13:23Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T12:13:23Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T12:13:23Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T12:13:23Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T12:13:23Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T12:13:23Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T12:13:23Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T12:13:23Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T12:13:23Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T12:13:23Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T12:13:23Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T12:13:23Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T12:13:23Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=f759060/main.tf:153-163"2025-01-17T12:13:23Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="github.com/ministryofjustice/modernisation-platform-terraform-bastion-linux?ref=95ed3c3/github.com/ministryofjustice/modernisation-platform-terraform-s3-bucket?ref=568694e50e03630d99cb569eafa06a0b879a1239/main.tf:171-179"2025-01-17T12:13:23Z INFO [terraformexecutor] Ignore finding rule="aws-s3-encryption-customer-key"range="s3.tf:1133-1152"2025-01-17T12:13:23Z INFO [terraformexecutor] Ignore finding rule="aws-s3-enable-bucket-encryption"range="s3.tf:1133-1152"2025-01-17T12:13:23Z INFO [terraformexecutor] Ignore finding rule="aws-s3-enable-versioning"range="s3.tf:1133-1152"2025-01-17T12:13:23Z INFO [terraformexecutor] Ignore finding rule="aws-iam-no-user-attached-policies"range="modules/landing_bucket_iam_user_access/main.tf:2-10"2025-01-17T12:13:23Z INFO [terraformexecutor] Ignore finding rule="aws-iam-no-user-attached-policies"range="modules/landing_bucket_iam_user_access/main.tf:2-10"2025-01-17T12:13:23Z INFO [terraformexecutor] Ignore finding rule="aws-cloudwatch-log-group-customer-key"range="modules/api_step_function/main.tf:295-300"2025-01-17T12:13:23Z INFO [terraformexecutor] Ignore finding rule="aws-cloudwatch-log-group-customer-key"range="modules/api_step_function/main.tf:421-425"2025-01-17T12:13:23Z INFO [terraformexecutor] Ignore finding rule="aws-s3-enable-logging"range="s3.tf:1133-1152"2025-01-17T12:13:23Z INFO [terraformexecutor] Ignore finding rule="aws-ssm-secret-use-customer-key"range="analytical_platform_share.tf:53-71"2025-01-17T12:13:23Z INFO Number of language-specific files num=02025-01-17T12:13:23Z INFO Detected config files num=13trivy_exitcode=0*****************************
Running Trivy in terraform/environments/electronic-monitoring-data/modules/analytical-platform-lakeformation
2025-01-17T12:13:23Z INFO [vuln] Vulnerability scanning is enabled
2025-01-17T12:13:23Z INFO [misconfig] Misconfiguration scanning is enabled
2025-01-17T12:13:23Z INFO [secret] Secret scanning is enabled
2025-01-17T12:13:23Z INFO [secret] If your scanning is slow, please try '--scanners vuln' to disable secret scanning
2025-01-17T12:13:23Z INFO [secret] Please see also https://aquasecurity.github.io/trivy/v0.57/docs/scanner/secret#recommendation for faster secret detection2025-01-17T12:13:24Z INFO [terraformscanner] Scanning root module file_path="."2025-01-17T12:13:24Z WARN [terraformparser] Variable values was not found in the environment or variable files. Evaluating may not work correctly.module="root"variables="data_locations, databases_to_share, destination_account_id"2025-01-17T12:13:24Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="aws_lakeformation_data_cells_filter.data_filter"value="cty.NilVal"2025-01-17T12:13:24Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="aws_lakeformation_permissions.data_location_share"value="cty.NilVal"2025-01-17T12:13:24Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="aws_lakeformation_permissions.share_filtered_data"value="cty.NilVal"2025-01-17T12:13:24Z ERROR [terraformevaluator] Failed to expand block. Invalid "for-each" argument. Must be known and iterable.block="aws_lakeformation_resource.data_location"value="cty.NilVal"2025-01-17T12:13:24Z INFO Number of language-specific files num=02025-01-17T12:13:24Z INFO Detected config files num=1trivy_exitcode=0
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Introduce a new module for sharing data within Lake Formation, enhancing the analytical platform's data management capabilities.