Skip to content
This repository has been archived by the owner on Jun 27, 2024. It is now read-only.

Fix providers to use testing-ci #16

Merged
merged 1 commit into from
Aug 17, 2022
Merged

Fix providers to use testing-ci #16

merged 1 commit into from
Aug 17, 2022

Conversation

davidkelliott
Copy link
Contributor

Tests were failing as using the incorrect provider to get the
environment secret.

Tests were failing as using the incorrect provider to get the
environment secret.
@davidkelliott davidkelliott requested a review from a team as a code owner August 17, 2022 09:14
@github-actions
Copy link
Contributor

TFSEC Scan Failed

Show Output
*****************************

TFSEC will check the following folders:
.

*****************************

Running TFSEC in .
Excluding the following checks: AWS089, AWS099, AWS009, AWS097, AWS018

Results #1-2 HIGH IAM policy document uses sensitive action 's3:ReplicateObject' on wildcarded resource '*' (2 similar results)
────────────────────────────────────────────────────────────────────────────────
  main.tf:71
────────────────────────────────────────────────────────────────────────────────
   33    data "aws_iam_policy_document" "default-policy" {
   ..  
   71  [     resources = ["${var.replication_bucket != "" ? local.replication_bucket : "*"}"]
   ..  
   82    }
────────────────────────────────────────────────────────────────────────────────
  Individual Causes
  - main.tf:33-82 (data.aws_iam_policy_document.default-policy) 2 instances
────────────────────────────────────────────────────────────────────────────────
          ID aws-iam-no-policy-wildcards
      Impact Overly permissive policies may grant access to sensitive resources
  Resolution Specify the exact permissions required, and to which resources they should apply instead of using wildcards.

  More Information
  - https://aquasecurity.github.io/tfsec/latest/checks/aws/iam/no-policy-wildcards/
  - https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/iam_policy_document
────────────────────────────────────────────────────────────────────────────────


  timings
  ──────────────────────────────────────────
  disk i/o             65.301µs
  parsing              738.008µs
  adaptation           369.104µs
  checks               44.327575ms
  total                45.499988ms

  counts
  ──────────────────────────────────────────
  modules downloaded   0
  modules processed    1
  blocks processed     13
  files read           4

  results
  ──────────────────────────────────────────
  passed               26
  ignored              0
  critical             0
  high                 2
  medium               0
  low                  0

  26 passed, 2 potential problem(s) detected.

tfsec_exitcode=1

Checkov Scan Success

Show Output
*****************************

Checkov will check the following folders:
.

*****************************

Running Checkov in .
Excluding the following checks: CKV_GIT_1
terraform scan results:

Passed checks: 23, Failed checks: 0, Skipped checks: 0

github_actions scan results:

Passed checks: 73, Failed checks: 0, Skipped checks: 0


checkov_exitcode=0

CTFLint Scan Failed

Show Output
*****************************

Setting default tflint config...
Running tflint --init...
Installing `aws` plugin...
Installed `aws` (source: github.com/terraform-linters/tflint-ruleset-aws, version: 0.15.0)
tflint will check the following folders:
.

*****************************

Running tflint in .
1 issue(s) found:

Warning: Interpolation-only expressions are deprecated in Terraform v0.12.14 (terraform_deprecated_interpolation)

  on /github/workspace/main.tf line 71:
  71:     resources = ["${var.replication_bucket != "" ? local.replication_bucket : "*"}"]

Reference: https://github.com/terraform-linters/tflint/blob/v0.39.3/docs/rules/terraform_deprecated_interpolation.md

tflint_exitcode=2

@davidkelliott davidkelliott merged commit 63c8eab into main Aug 17, 2022
@davidkelliott davidkelliott deleted the bug/fix-tests branch August 17, 2022 09:18
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants