Azure / Azure/template-analyzer

[Built-in Rule] Certificates should not expire within the specified number of days

Open
#52 0 comments 0 reactions 0 assignees View on GitHub
✔ greater/lesser ❌ datetime operators ❌ parameters built-in rule
Dominant language
C#
Stars
143
Forks
47
PR merge metrics
No merged PRs in 30d

Description

Azure policy: https://github.com/Azure/azure-policy/blob/master/built-in-policies/policyDefinitions/Key%20Vault/Certificates_Expiry_ByDays.json

``` javascript
{
"name": "Certificates_Expiry_ByDays",
"description": "Certificates should not expire within the specified number of days",
"recommendation": "Have certificates expire within a certain number of days",
"helpUri": "https://github.com/Azure/template-analyzer/docs/built-in-bpa-rules.md/#certificates-should-not-expire-within-the-specified-number-of-days",
"parameters": {
"daysToExpire": 90
},
"evaluation": {
"resourceType": "Microsoft.KeyVault.Data/vaults/certificates",
"path": "attribures.expiresOn",
"lessOrEquals": "[addDays(utcNow(), parameters('daysToExpire'))]"
}
}
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.