Skip to content

Commit 86d915a

Browse files
Add PUT InboundSecurityRules for NVA (#10452)
1 parent 4dc7b7e commit 86d915a

File tree

6 files changed

+237
-0
lines changed

6 files changed

+237
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
{
2+
"parameters": {
3+
"api-version": "2020-06-01",
4+
"ruleCollectionName": "rule1",
5+
"subscriptionId": "subid",
6+
"resourceGroupName": "rg1",
7+
"networkVirtualApplianceName": "nva",
8+
"parameters": {
9+
"properties": {
10+
"rules": [
11+
{
12+
"protocol": "TCP",
13+
"sourceAddressPrefix": "50.20.121.5/32",
14+
"destinationPortRange": 22
15+
}
16+
]
17+
}
18+
}
19+
},
20+
"responses": {
21+
"200": {
22+
"body": {
23+
"name": "rule1",
24+
"id": "/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/networkVirtualAppliances/nva/InboundSecurityRules/rule1",
25+
"etag": "W/\"72090554-7e3b-43f2-80ad-99a9020dcb11\"",
26+
"properties": {
27+
"provisioningState": "Succeeded",
28+
"rules": [
29+
{
30+
"protocol": "TCP",
31+
"sourceAddressPrefix": "50.20.121.5/32",
32+
"destinationPortRange": 22
33+
}
34+
]
35+
}
36+
}
37+
},
38+
"201": {
39+
"body": {
40+
"name": "rule1",
41+
"id": "/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/networkVirtualAppliances/nva/InboundSecurityRules/rule1",
42+
"etag": "W/\"72090554-7e3b-43f2-80ad-99a9020dcb11\"",
43+
"properties": {
44+
"provisioningState": "Succeeded",
45+
"rules": [
46+
{
47+
"protocol": "TCP",
48+
"sourceAddressPrefix": "50.20.121.5/32",
49+
"destinationPortRange": 22
50+
}
51+
]
52+
}
53+
}
54+
}
55+
}
56+
}

specification/network/resource-manager/Microsoft.Network/stable/2020-06-01/examples/NetworkVirtualApplianceGet.json

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,11 @@
3737
"id": "/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/networtkVirtualAppliances/nva/virtualApplianceSites/site1"
3838
}
3939
],
40+
"inboundSecurityRules": [
41+
{
42+
"id": "/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/networkVirtualAppliances/nva/InboundSecurityRules/rule1"
43+
}
44+
],
4045
"provisioningState": "Succeeded",
4146
"bootStrapConfigurationBlobs": [
4247
"https://csrncvhdstorage1.blob.core.windows.net/csrncvhdstoragecont/csrbootstrapconfig"

specification/network/resource-manager/Microsoft.Network/stable/2020-06-01/examples/NetworkVirtualApplianceListByResourceGroup.json

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,11 @@
3838
"id": "/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/networtkVirtualAppliances/nva/virtualApplianceSites/site1"
3939
}
4040
],
41+
"inboundSecurityRules": [
42+
{
43+
"id": "/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/networkVirtualAppliances/nva/InboundSecurityRules/rule1"
44+
}
45+
],
4146
"provisioningState": "Succeeded",
4247
"bootStrapConfigurationBlobs": [
4348
"https://csrncvhdstorage1.blob.core.windows.net/csrncvhdstoragecont/csrbootstrapconfig"

specification/network/resource-manager/Microsoft.Network/stable/2020-06-01/examples/NetworkVirtualApplianceListBySubscription.json

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,11 @@
3737
"id": "/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/networtkVirtualAppliances/nva/virtualApplianceSites/site1"
3838
}
3939
],
40+
"inboundSecurityRules": [
41+
{
42+
"id": "/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/networkVirtualAppliances/nva/InboundSecurityRules/rule1"
43+
}
44+
],
4045
"provisioningState": "Succeeded",
4146
"bootStrapConfigurationBlobs": [
4247
"https://csrncvhdstorage1.blob.core.windows.net/csrncvhdstoragecont/csrbootstrapconfig"

specification/network/resource-manager/Microsoft.Network/stable/2020-06-01/examples/NetworkVirtualAppliancePut.json

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,11 @@
6666
"id": "/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/networtkVirtualAppliances/nva/virtualApplianceSites/site1"
6767
}
6868
],
69+
"inboundSecurityRules": [
70+
{
71+
"id": "/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/networkVirtualAppliances/nva/InboundSecurityRules/rule1"
72+
}
73+
],
6974
"provisioningState": "Succeeded",
7075
"bootStrapConfigurationBlobs": [
7176
"https://csrncvhdstorage1.blob.core.windows.net/csrncvhdstoragecont/csrbootstrapconfig"
@@ -119,6 +124,11 @@
119124
"id": "/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/networtkVirtualAppliances/nva/virtualApplianceSites/site1"
120125
}
121126
],
127+
"inboundSecurityRules": [
128+
{
129+
"id": "/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/networkVirtualAppliances/nva/InboundSecurityRules/rule1"
130+
}
131+
],
122132
"provisioningState": "Succeeded",
123133
"bootStrapConfigurationBlobs": [
124134
"https://csrncvhdstorage1.blob.core.windows.net/csrncvhdstoragecont/csrbootstrapconfig"

specification/network/resource-manager/Microsoft.Network/stable/2020-06-01/networkVirtualAppliance.json

Lines changed: 156 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -682,6 +682,79 @@
682682
}
683683
}
684684
}
685+
},
686+
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/networkVirtualAppliances/{networkVirtualApplianceName}/inboundSecurityRules/{ruleCollectionName}": {
687+
"put": {
688+
"operationId": "InboundSecurityRule_CreateOrUpdate",
689+
"description": "Creates or updates the specified Network Virtual Appliance Inbound Security Rules.",
690+
"parameters": [
691+
{
692+
"name": "resourceGroupName",
693+
"in": "path",
694+
"required": true,
695+
"type": "string",
696+
"description": "The name of the resource group."
697+
},
698+
{
699+
"name": "networkVirtualApplianceName",
700+
"in": "path",
701+
"required": true,
702+
"type": "string",
703+
"description": "The name of the Network Virtual Appliance."
704+
},
705+
{
706+
"name": "ruleCollectionName",
707+
"in": "path",
708+
"required": true,
709+
"type": "string",
710+
"description": "The name of security rule collection."
711+
},
712+
{
713+
"name": "parameters",
714+
"in": "body",
715+
"required": true,
716+
"schema": {
717+
"$ref": "#/definitions/InboundSecurityRule"
718+
},
719+
"description": "Parameters supplied to the create or update Network Virtual Appliance Inbound Security Rules operation."
720+
},
721+
{
722+
"$ref": "./network.json#/parameters/ApiVersionParameter"
723+
},
724+
{
725+
"$ref": "./network.json#/parameters/SubscriptionIdParameter"
726+
}
727+
],
728+
"responses": {
729+
"200": {
730+
"description": "Request successful. The operation returns the resulting Network Virtual Appliance Inbound Security Rules resource.",
731+
"schema": {
732+
"$ref": "#/definitions/InboundSecurityRule"
733+
}
734+
},
735+
"201": {
736+
"description": "Request received successfully. The operation returns the resulting Network Virtual Appliance Inbound Security Rules resource.",
737+
"schema": {
738+
"$ref": "#/definitions/InboundSecurityRule"
739+
}
740+
},
741+
"default": {
742+
"description": "Error response describing why the operation failed.",
743+
"schema": {
744+
"$ref": "./network.json#/definitions/CloudError"
745+
}
746+
}
747+
},
748+
"x-ms-examples": {
749+
"Create Network Virtual Appliance Inbound Security Rules": {
750+
"$ref": "./examples/InboundSecurityRulePut.json"
751+
}
752+
},
753+
"x-ms-long-running-operation": true,
754+
"x-ms-long-running-operation-options": {
755+
"final-state-via": "azure-async-operation"
756+
}
757+
}
685758
}
686759
},
687760
"definitions": {
@@ -771,6 +844,14 @@
771844
"$ref": "./network.json#/definitions/SubResource"
772845
}
773846
},
847+
"inboundSecurityRules": {
848+
"type": "array",
849+
"readOnly": true,
850+
"description": "List of references to InboundSecurityRules.",
851+
"items": {
852+
"$ref": "./network.json#/definitions/SubResource"
853+
}
854+
},
774855
"provisioningState": {
775856
"description": "The provisioning state of the resource.",
776857
"readOnly": true,
@@ -1009,6 +1090,81 @@
10091090
}
10101091
},
10111092
"description": "Response for ListNetworkVirtualApplianceSkus API service call."
1093+
},
1094+
"InboundSecurityRule": {
1095+
"properties": {
1096+
"properties": {
1097+
"x-ms-client-flatten": true,
1098+
"$ref": "#/definitions/InboundSecurityRuleProperties",
1099+
"description": "The properties of the Inbound Security Rules."
1100+
},
1101+
"name": {
1102+
"type": "string",
1103+
"description": "Name of security rule collection."
1104+
},
1105+
"etag": {
1106+
"type": "string",
1107+
"readOnly": true,
1108+
"description": "A unique read-only string that changes whenever the resource is updated."
1109+
},
1110+
"type": {
1111+
"type": "string",
1112+
"readOnly": true,
1113+
"description": "NVA inbound security rule type."
1114+
}
1115+
},
1116+
"allOf": [
1117+
{
1118+
"$ref": "./network.json#/definitions/SubResource"
1119+
}
1120+
],
1121+
"description": "NVA Inbound Security Rule resource."
1122+
},
1123+
"InboundSecurityRuleProperties": {
1124+
"properties": {
1125+
"rules": {
1126+
"type": "array",
1127+
"readOnly": false,
1128+
"description": "List of allowed rules.",
1129+
"items": {
1130+
"$ref": "#/definitions/InboundSecurityRules"
1131+
}
1132+
},
1133+
"provisioningState": {
1134+
"description": "The provisioning state of the resource.",
1135+
"readOnly": true,
1136+
"$ref": "./network.json#/definitions/ProvisioningState"
1137+
}
1138+
},
1139+
"description": "Properties of the Inbound Security Rules resource."
1140+
},
1141+
"InboundSecurityRules": {
1142+
"properties": {
1143+
"protocol": {
1144+
"type": "string",
1145+
"enum": [
1146+
"TCP",
1147+
"UDP"
1148+
],
1149+
"x-ms-enum": {
1150+
"name": "InboundSecurityRulesProtocol",
1151+
"modelAsString": true
1152+
},
1153+
"description": "Protocol. This should be either TCP or UDP."
1154+
},
1155+
"sourceAddressPrefix": {
1156+
"type": "string",
1157+
"description": "The CIDR or source IP range. Only /30, /31 and /32 Ip ranges are allowed."
1158+
},
1159+
"destinationPortRange": {
1160+
"type": "integer",
1161+
"format": "int32",
1162+
"minimum": 0,
1163+
"maximum": 65535,
1164+
"description": "NVA port ranges to be opened up. One needs to provide specific ports."
1165+
}
1166+
},
1167+
"description": "Properties of the Inbound Security Rules resource."
10121168
}
10131169
}
10141170
}

0 commit comments

Comments
 (0)