-
Notifications
You must be signed in to change notification settings - Fork 1.1k
/
Certificates_RSA_MinimumKeySize.json
72 lines (72 loc) · 2.04 KB
/
Certificates_RSA_MinimumKeySize.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
{
"properties": {
"displayName": "Certificates using RSA cryptography should have the specified minimum key size",
"policyType": "BuiltIn",
"mode": "Microsoft.KeyVault.Data",
"description": "Manage your organizational compliance requirements by specifying a minimum key size for RSA certificates stored in your key vault.",
"metadata": {
"version": "2.1.0",
"category": "Key Vault"
},
"version": "2.1.0",
"parameters": {
"minimumRSAKeySize": {
"type": "Integer",
"metadata": {
"displayName": "Minimum RSA key size",
"description": "The minimum key size for RSA certificates."
},
"allowedValues": [
2048,
3072,
4096
]
},
"effect": {
"type": "string",
"metadata": {
"displayName": "Effect",
"description": "'Audit' allows a non-compliant resource to be created, but flags it as non-compliant. 'Deny' blocks the resource creation. 'Disable' turns off the policy."
},
"allowedValues": [
"audit",
"Audit",
"deny",
"Deny",
"disabled",
"Disabled"
],
"defaultValue": "Audit"
}
},
"policyRule": {
"if": {
"allOf": [
{
"field": "type",
"equals": "Microsoft.KeyVault.Data/vaults/certificates"
},
{
"field": "Microsoft.KeyVault.Data/vaults/certificates/keyProperties.keyType",
"in": [
"RSA",
"RSA-HSM"
]
},
{
"field": "Microsoft.KeyVault.Data/vaults/certificates/keyProperties.keySize",
"less": "[parameters('minimumRSAKeySize')]"
}
]
},
"then": {
"effect": "[parameters('effect')]"
}
},
"versions": [
"2.1.0"
]
},
"id": "/providers/Microsoft.Authorization/policyDefinitions/cee51871-e572-4576-855c-047c820360f0",
"name": "cee51871-e572-4576-855c-047c820360f0"
}