-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsecurityRules.json
103 lines (103 loc) · 3.48 KB
/
securityRules.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
95
96
97
98
99
100
101
102
103
{
"$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#",
"contentVersion": "2017.09.01.0",
"parameters": {
"Name": {
"type": "string",
"metadata": {
"description": "The name of the resource that is unique within a resource group. This name can be used to access the resource."
}
},
"Description": {
"type": "string",
"maxLength": 140,
"metadata": {
"description": "A description for this rule. Restricted to 140 chars."
}
},
"access": {
"type": "string",
"allowedValues": [
"Allow",
"Deny"
]
},
"destinationAddressPrefix": {
"type": "string",
"metadata": {
"description": "The destination address prefix. CIDR or destination IP range. Asterix '*' can also be used to match all source IPs. Default tags such as 'VirtualNetwork', 'AzureLoadBalancer' and 'Internet' can also be used."
}
},
"destinationPortRange": {
"type": "string",
"metadata": {
"description": "The destination port or range. Integer or range between 0 and 65535. Asterix '*' can also be used to match all ports."
}
},
"direction": {
"type": "string",
"allowedValues": [
"Inbound",
"Outbound"
],
"metadata": {
"description": "The direction of the rule. The direction specifies if rule will be evaluated on incoming or outcoming traffic. Possible values are: 'Inbound' and 'Outbound'."
}
},
"priority": {
"type": "int",
"minValue": 100,
"maxValue": 4096,
"metadata": {
"description": "The priority of the rule. The value can be between 100 and 4096. The priority number must be unique for each rule in the collection. The lower the priority number, the higher the priority of the rule."
}
},
"protocol": {
"type": "string",
"allowedValues": [
"*",
"Tcp",
"Udp"
]
},
"sourceAddressPrefix": {
"type": "string",
"metadata": {
"description": "The CIDR or source IP range. Asterix '*' can also be used to match all source IPs. Default tags such as 'VirtualNetwork', 'AzureLoadBalancer' and 'Internet' can also be used. If this is an ingress rule, specifies where network traffic originates from."
}
},
"sourcePortRange": {
"type": "string",
"metadata": {
"description": "The source port or range. Integer or range between 0 and 65535. Asterix '*' can also be used to match all ports."
}
}
},
"variables": {
"comment": {
"documentation": "https://docs.microsoft.com/en-us/rest/api/virtualnetwork/networksecuritygroups/createorupdate#definitions_securityrule"
},
"securityRule": {
"name": "[parameters('Name')]",
"properties": {
"description": "[parameters('Description')]",
"protocol": "[parameters('protocol')]",
"sourcePortRange": "[parameters('sourcePortRange')]",
"destinationPortRange": "[parameters('destinationPortRange')]",
"sourceAddressPrefix": "[parameters('sourceAddressPrefix')]",
"destinationAddressPrefix": "[parameters('destinationAddressPrefix')]",
"access": "[parameters('access')]",
"priority": "[parameters('priority')]",
"direction": "[parameters('direction')]"
}
}
},
"resources": [
],
"outputs": {
"securityRule": {
"type": "object",
"value": "[variables('securityRule')]"
}
}
}