共用方式為


Get-AzNetworkManagerActiveSecurityAdminRule

列出網路管理員中的 NetworkManager Active Security 管理員規則。

語法

Get-AzNetworkManagerActiveSecurityAdminRule
   -NetworkManagerName <String>
   -ResourceGroupName <String>
   [-Region <String[]>]
   [-SkipToken <String>]
   [-DefaultProfile <IAzureContextContainer>]
   [<CommonParameters>]

Description

Get-AzNetworkManagerActiveSecurityAdminRule Cmdlet 會列出網路管理員中的 NetworkManager Active Security 管理員規則。

範例

範例 1

$regions = @("centraluseuap")  
Get-AzNetworkManagerActiveSecurityAdminRule -NetworkManagerName "TestNMName" -ResourceGroupName "TestRG" -Region $regions -SkipToken "FakeSkipToken"

Value     : [
              {
                "DisplayName": "Sample Rule Name",
                "Description": "Description",
                "Protocol": "Tcp",
                "Sources": [
                  {
                    "AddressPrefix": "Internet",
                    "AddressPrefixType": "ServiceTag"
                  }
                ],
                "Destinations": [
                  {
                    "AddressPrefix": "10.0.0.1",
                    "AddressPrefixType": "IPPrefix"
                  }
                ],
                "SourcePortRanges": [
                  "100"
                ],
                "DestinationPortRanges": [
                  "99"
                ],
                "Access": "Allow",
                "Priority": 100,
                "Direction": "Inbound",
                "ProvisioningState": "Succeeded",
                "Id": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/TestRG/providers/Microsoft.Network/networkManagers/TestNMName/securityAdminConfigurations/TestAdminConfig/ruleCollections/TestRuleCollection/rules/TestRule",
                "Region": "eastus2euap",
                "ConfigurationDisplayName": "sample Config DisplayName",
                "ConfigurationDescription": "DESCription",
                "RuleCollectionDisplayName": "Sample rule Collection displayName",
                "RuleCollectionDescription": "Sample rule Collection Description",
                "RuleCollectionAppliesToGroups": [
                  {
                    "NetworkGroupId": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/TestRG/providers/Microsoft.Network/networkManagers/TestNMName/networkGroups/testNG"
                  }
                ],
                "RuleGroups": [
                  {
                    "Id": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/TestRG/providers/Microsoft.Network/networkManagers/TestNMName/networkGroups/testNG",
                    "DisplayName": "DISplayName",
                    "Description": "SampleConfigDESCRIption",
                    "GroupMembers": [
                      {
                        "ResourceId": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/TestRG/providers/Microsoft.Network/virtualNetworks/testvnet"
                      }
                    ],
                    "ConditionalMembership": "",
                    "ProvisioningState": "Succeeded"
                  }
                ]
              }
            ]
SkipToken :

列出區域 centraluseuap 的網路管理員中的 NetworkManager Active Security 管理員規則。

參數

-DefaultProfile

用於與 Azure 通訊的認證、帳戶、租用戶和訂用帳戶。

類型:IAzureContextContainer
別名:AzContext, AzureRmContext, AzureCredential
Position:Named
預設值:None
必要:False
接受管線輸入:False
接受萬用字元:False

-NetworkManagerName

網路管理員名稱。

類型:String
Position:Named
預設值:None
必要:True
接受管線輸入:True
接受萬用字元:True

-Region

區域清單。

類型:String[]
Position:Named
預設值:None
必要:False
接受管線輸入:True
接受萬用字元:False

-ResourceGroupName

資源組名。

類型:String
Position:Named
預設值:None
必要:True
接受管線輸入:True
接受萬用字元:True

-SkipToken

SkipToken。

類型:String
Position:Named
預設值:None
必要:False
接受管線輸入:True
接受萬用字元:False

輸入

String

System.String[]

輸出

Microsoft.Azure.Commands.Network.Models.NetworkManager.PSNetworkManagerActiveSecurityAdminRuleListResult