Skip to content

Commit

Permalink
Fixing the bug for google_kms_crypto_key policies (#848)
Browse files Browse the repository at this point in the history
* Fixing the bug for google_kms_crypto_key policies:
- checkRotation90Days
- checkRotation365Days

* Indentation changes
  • Loading branch information
shreyas-phansalkar-189 authored Jun 9, 2021
1 parent cbbde51 commit 0eae483
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 8 deletions.
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package accurics

checkRotation365Days[kms.id] {
kms := input.google_kms_crypto_key[_]
kms.config.rotation_period <= "31536000s"
}
checkRotation365Days[crypto_key.id]{
crypto_key := input.google_kms_crypto_key[_]
to_number(trim(crypto_key.config.rotation_period, "s")) > 31536000
}
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package accurics

checkRotation90Days[api.id]
{
api := input.google_kms_crypto_key[_]
api.config.rotation_period <= "7776000s"
checkRotation90Days[crypto_key.id]{
crypto_key := input.google_kms_crypto_key[_]
to_number(trim(crypto_key.config.rotation_period, "s")) > 7776000
}

0 comments on commit 0eae483

Please sign in to comment.