Skip to content

Commit

Permalink
fix(arm): improve CKV_AZURE_24 check (#5427)
Browse files Browse the repository at this point in the history
improve CKV_AZURE_24 check
  • Loading branch information
omryMen committed Aug 10, 2023
1 parent 48a158a commit ec28bcc
Showing 1 changed file with 6 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,12 @@ def check_resource(resource: Dict[str, Any]) -> CheckResult:
retention = properties.get("retentionDays")
if isinstance(retention, int) and retention >= 90:
return CheckResult.PASSED
if isinstance(retention, str):
try:
if int(retention) >= 90:
return CheckResult.PASSED
except ValueError: # not a valid number
return CheckResult.FAILED
return CheckResult.FAILED


Expand Down

0 comments on commit ec28bcc

Please sign in to comment.