/
DeployAtpOnMariaDbServers_DINE.json
94 lines (94 loc) · 2.99 KB
/
DeployAtpOnMariaDbServers_DINE.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
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
{
"properties": {
"displayName": "Configure Advanced Threat Protection to be enabled on Azure database for MariaDB servers",
"policyType": "BuiltIn",
"mode": "Indexed",
"description": "Enable Advanced Threat Protection on your non-Basic tier Azure database for MariaDB servers to detect anomalous activities indicating unusual and potentially harmful attempts to access or exploit databases.",
"metadata": {
"version": "1.2.0",
"category": "SQL"
},
"version": "1.2.0",
"parameters": {
"effect": {
"type": "string",
"defaultValue": "DeployIfNotExists",
"allowedValues": [
"DeployIfNotExists",
"Disabled"
],
"metadata": {
"displayName": "Effect",
"description": "Enable or disable the execution of the policy"
}
}
},
"policyRule": {
"if": {
"allOf": [
{
"field": "type",
"equals": "Microsoft.DBforMariaDB/servers"
},
{
"field": "Microsoft.DBforMariaDB/servers/sku.tier",
"notContains": "basic"
}
]
},
"then": {
"effect": "[parameters('effect')]",
"details": {
"type": "Microsoft.DBforMariaDB/servers/securityAlertPolicies",
"name": "Default",
"evaluationDelay": "AfterProvisioningSuccess",
"existenceCondition": {
"field": "Microsoft.DBforMariaDB/servers/securityAlertPolicies/Default.state",
"equals": "Enabled"
},
"roleDefinitionIds": [
"/providers/microsoft.authorization/roleDefinitions/b24988ac-6180-42a0-ab88-20f7382dd24c"
],
"deployment": {
"properties": {
"mode": "incremental",
"template": {
"$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentTemplate.json#",
"contentVersion": "1.0.0.0",
"parameters": {
"serverName": {
"type": "string"
}
},
"variables": {},
"resources": [
{
"name": "[concat(parameters('serverName'), '/Default')]",
"type": "Microsoft.DBforMariaDB/servers/securityAlertPolicies",
"apiVersion": "2018-06-01",
"properties": {
"state": "Enabled",
"emailAccountAdmins": false
}
}
]
},
"parameters": {
"serverName": {
"value": "[field('name')]"
}
}
}
}
}
}
},
"versions": [
"1.2.0",
"1.1.0",
"1.0.1"
]
},
"id": "/providers/Microsoft.Authorization/policyDefinitions/a6cf7411-da9e-49e2-aec0-cba0250eaf8c",
"name": "a6cf7411-da9e-49e2-aec0-cba0250eaf8c"
}