Network Rule Sets - Create Or Update Network Rule Set
NetworkRuleSet maken of bijwerken voor een naamruimte.
PUT https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventHub/namespaces/{namespaceName}/networkRuleSets/default?api-version=2021-11-01
URI-parameters
| Name | In | Vereist | Type | Description |
|---|---|---|---|---|
|
namespace
|
path | True |
string minLength: 6maxLength: 50 pattern: ^[a-zA-Z][a-zA-Z0-9-]{6,50}[a-zA-Z0-9]$ |
De naam van de naamruimte |
|
resource
|
path | True |
string minLength: 1maxLength: 90 |
Naam van de resourcegroep binnen het Azure-abonnement. |
|
subscription
|
path | True |
string |
Abonnementsreferenties waarmee een Microsoft Azure-abonnement uniek wordt geïdentificeerd. De abonnements-id maakt deel uit van de URI voor elke serviceoproep. |
|
api-version
|
query | True |
string |
Client-API-versie. |
Aanvraagbody
| Name | Type | Description |
|---|---|---|
| properties.defaultAction |
Standaardactie voor netwerkregelset |
|
| properties.ipRules |
Lijst met IpRules |
|
| properties.publicNetworkAccess |
Hiermee wordt bepaald of verkeer via een openbaar netwerk is toegestaan. Deze functie is standaard ingeschakeld. |
|
| properties.trustedServiceAccessEnabled |
boolean |
Waarde die aangeeft of Vertrouwde servicetoegang is ingeschakeld of niet. |
| properties.virtualNetworkRules |
VirtualNetwork-regels weergeven |
Antwoorden
| Name | Type | Description |
|---|---|---|
| 200 OK |
Naamruimte NetworkRuleSet is geretourneerd. |
|
| Other Status Codes |
ServiceBus-foutantwoord waarin wordt beschreven waarom de bewerking is mislukt. |
Beveiliging
azure_auth
Azure Active Directory OAuth2-stroom
Type:
oauth2
Stroom:
implicit
Autorisatie-URL:
https://login.microsoftonline.com/common/oauth2/authorize
Bereiken
| Name | Description |
|---|---|
| user_impersonation | Uw gebruikersaccount imiteren |
Voorbeelden
NameSpaceNetworkRuleSetCreate
Voorbeeldaanvraag
PUT https://management.azure.com/subscriptions/Subscription/resourceGroups/ResourceGroup/providers/Microsoft.EventHub/namespaces/sdk-Namespace-6019/networkRuleSets/default?api-version=2021-11-01
{
"properties": {
"defaultAction": "Deny",
"virtualNetworkRules": [
{
"subnet": {
"id": "/subscriptions/subscriptionid/resourcegroups/resourcegroupid/providers/Microsoft.Network/virtualNetworks/myvn/subnets/subnet2"
},
"ignoreMissingVnetServiceEndpoint": true
},
{
"subnet": {
"id": "/subscriptions/subscriptionid/resourcegroups/resourcegroupid/providers/Microsoft.Network/virtualNetworks/myvn/subnets/subnet3"
},
"ignoreMissingVnetServiceEndpoint": false
},
{
"subnet": {
"id": "/subscriptions/subscriptionid/resourcegroups/resourcegroupid/providers/Microsoft.Network/virtualNetworks/myvn/subnets/subnet6"
},
"ignoreMissingVnetServiceEndpoint": false
}
],
"ipRules": [
{
"ipMask": "1.1.1.1",
"action": "Allow"
},
{
"ipMask": "1.1.1.2",
"action": "Allow"
},
{
"ipMask": "1.1.1.3",
"action": "Allow"
},
{
"ipMask": "1.1.1.4",
"action": "Allow"
},
{
"ipMask": "1.1.1.5",
"action": "Allow"
}
]
}
}
Voorbeeldrespons
{
"id": "/subscriptions/854d368f-1828-428f-8f3c-f2affa9b2f7d/resourceGroups/resourcegroupid/providers/Microsoft.EventHub/namespaces/sdk-Namespace-9659/networkruleset/default",
"name": "default",
"type": "Microsoft.EventHub/Namespaces/NetworkRuleSet",
"properties": {
"defaultAction": "Deny",
"publicNetworkAccess": "Enabled",
"virtualNetworkRules": [
{
"subnet": {
"id": "/subscriptions/subscriptionid/resourcegroups/resourcegroupid/providers/Microsoft.Network/virtualNetworks/myvn/subnets/subnet2"
},
"ignoreMissingVnetServiceEndpoint": true
},
{
"subnet": {
"id": "/subscriptions/subscriptionid/resourcegroups/resourcegroupid/providers/Microsoft.Network/virtualNetworks/myvn/subnets/subnet3"
},
"ignoreMissingVnetServiceEndpoint": false
},
{
"subnet": {
"id": "/subscriptions/subscriptionid/resourcegroups/resourcegroupid/providers/Microsoft.Network/virtualNetworks/myvn/subnets/subnet6"
},
"ignoreMissingVnetServiceEndpoint": false
}
],
"ipRules": [
{
"ipMask": "1.1.1.1",
"action": "Allow"
},
{
"ipMask": "1.1.1.2",
"action": "Allow"
},
{
"ipMask": "1.1.1.3",
"action": "Allow"
},
{
"ipMask": "1.1.1.4",
"action": "Allow"
},
{
"ipMask": "1.1.1.5",
"action": "Allow"
}
]
}
}
Definities
| Name | Description |
|---|---|
|
created |
Het type identiteit waarmee de resource is gemaakt. |
|
Default |
Standaardactie voor netwerkregelset |
|
Error |
Aanvullende informatie over de resourcebeheerfout. |
|
Error |
De foutdetails. |
|
Error |
Foutreactie geeft aan dat de Event Hub-service de binnenkomende aanvraag niet kan verwerken. De reden is opgegeven in het foutbericht. |
|
Network |
De IP-filteractie |
|
Network |
Beschrijving van onderwerpresource. |
|
NWRule |
Het antwoord van de bewerking Lijstnaamruimte. |
|
NWRule |
Het antwoord van de bewerking Lijstnaamruimte. |
|
Public |
Hiermee wordt bepaald of verkeer via een openbaar netwerk is toegestaan. Deze functie is standaard ingeschakeld. |
| Subnet |
Eigenschappen die zijn opgegeven voor subnet |
|
system |
Metagegevens met betrekking tot het maken en de laatste wijziging van de resource. |
createdByType
Het type identiteit waarmee de resource is gemaakt.
| Waarde | Description |
|---|---|
| User | |
| Application | |
| ManagedIdentity | |
| Key |
DefaultAction
Standaardactie voor netwerkregelset
| Waarde | Description |
|---|---|
| Allow | |
| Deny |
ErrorAdditionalInfo
Aanvullende informatie over de resourcebeheerfout.
| Name | Type | Description |
|---|---|---|
| info |
object |
De aanvullende informatie. |
| type |
string |
Het extra informatietype. |
ErrorDetail
De foutdetails.
| Name | Type | Description |
|---|---|---|
| additionalInfo |
De fout bevat aanvullende informatie. |
|
| code |
string |
De foutcode. |
| details |
De foutdetails. |
|
| message |
string |
Het foutbericht. |
| target |
string |
Het foutdoel. |
ErrorResponse
Foutreactie geeft aan dat de Event Hub-service de binnenkomende aanvraag niet kan verwerken. De reden is opgegeven in het foutbericht.
| Name | Type | Description |
|---|---|---|
| error |
Het foutobject. |
NetworkRuleIPAction
De IP-filteractie
| Waarde | Description |
|---|---|
| Allow |
NetworkRuleSet
Beschrijving van onderwerpresource.
| Name | Type | Default value | Description |
|---|---|---|---|
| id |
string |
Volledig gekwalificeerde resource-id voor de resource. Vb.: - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} |
|
| location |
string |
De geografische locatie waar de resource zich bevindt |
|
| name |
string |
De naam van de resource |
|
| properties.defaultAction |
Standaardactie voor netwerkregelset |
||
| properties.ipRules |
Lijst met IpRules |
||
| properties.publicNetworkAccess | Enabled |
Hiermee wordt bepaald of verkeer via een openbaar netwerk is toegestaan. Deze functie is standaard ingeschakeld. |
|
| properties.trustedServiceAccessEnabled |
boolean |
Waarde die aangeeft of Vertrouwde servicetoegang is ingeschakeld of niet. |
|
| properties.virtualNetworkRules |
VirtualNetwork-regels weergeven |
||
| systemData |
De systeemmetagegevens met betrekking tot deze resource. |
||
| type |
string |
Het type resource. Bijvoorbeeld 'Microsoft.EventHub/Namespaces' of 'Microsoft.EventHub/Namespaces/EventHubs' |
NWRuleSetIpRules
Het antwoord van de bewerking Lijstnaamruimte.
| Name | Type | Description |
|---|---|---|
| action |
De IP-filteractie |
|
| ipMask |
string |
IP-masker |
NWRuleSetVirtualNetworkRules
Het antwoord van de bewerking Lijstnaamruimte.
| Name | Type | Description |
|---|---|---|
| ignoreMissingVnetServiceEndpoint |
boolean |
Waarde die aangeeft of ontbrekend Vnet-service-eindpunt moet worden genegeerd |
| subnet |
Subneteigenschappen |
PublicNetworkAccessFlag
Hiermee wordt bepaald of verkeer via een openbaar netwerk is toegestaan. Deze functie is standaard ingeschakeld.
| Waarde | Description |
|---|---|
| Enabled | |
| Disabled |
Subnet
Eigenschappen die zijn opgegeven voor subnet
| Name | Type | Description |
|---|---|---|
| id |
string |
Resource-id van subnet van virtueel netwerk |
systemData
Metagegevens met betrekking tot het maken en de laatste wijziging van de resource.
| Name | Type | Description |
|---|---|---|
| createdAt |
string (date-time) |
De tijdstempel van het maken van resources (UTC). |
| createdBy |
string |
De identiteit waarmee de resource is gemaakt. |
| createdByType |
Het type identiteit waarmee de resource is gemaakt. |
|
| lastModifiedAt |
string (date-time) |
Het type identiteit dat de resource voor het laatst heeft gewijzigd. |
| lastModifiedBy |
string |
De identiteit die de resource voor het laatst heeft gewijzigd. |
| lastModifiedByType |
Het type identiteit dat de resource voor het laatst heeft gewijzigd. |