Freigeben über


Get-AzDeviceSecurityGroup

Gerätesicherheitsgruppe abrufen (IoT Hub-Sicherheit)

Syntax

ResourceIdScope (Standard)

Get-AzDeviceSecurityGroup
    -HubResourceId <String>
    [-DefaultProfile <IAzureContextContainer>]
    [<CommonParameters>]

ResourceIdLevelResource

Get-AzDeviceSecurityGroup
    -HubResourceId <String>
    -Name <String>
    [-DefaultProfile <IAzureContextContainer>]
    [<CommonParameters>]

Beschreibung

Das Cmdlet Get-AzDeviceSecurityGroup gibt eine Gerätesicherheitsgruppe zurück, die in der Iot-Sicherheitslösung definiert ist.

Beispiele

Beispiel 1

Get-AzDeviceSecurityGroup -HubResourceId "/subscriptions/XXXXXXXX-XXXX-XXXXX-XXXX-XXXXXXXXXXXX/resourceGroups/MyResourceGroup/providers/Microsoft.Devices/IotHubs/MyHub" -Name "MySecurityGroup"
Id: "/subscriptions/XXXXXXXX-XXXX-XXXXX-XXXX-XXXXXXXXXXXX/resourceGroups/MyResourceGroup/providers/Microsoft.Devices/IotHubs/MyHub/providers/Microsoft.Security/deviceSecurityGroups/MySecurityGroup"
Name: "MySecurityGroup"
Type: "Microsoft.Security/deviceSecurityGroups"
ThresholdRules: []
TimeWindowRules: [
			{
              RuleType: "ActiveConnectionsNotInAllowedRange"
              DisplayName: "Number of active connections is not in allowed range"
              Description: "Get an alert when the number of active connections of a device in the time window is not in the allowed range"
              IsEnabled: false
              MinThreshold: 0
              MaxThreshold: 0
              TimeWindowSize: "PT15M"
            }
            {
              RuleType: "AmqpC2DMessagesNotInAllowedRange"
              DisplayName: "Number of cloud to device messages (AMQP protocol) is not in allowed range"
              Description: "Get an alert when the number of cloud to device messages (AMQP protocol) in the time window is not in the allowed range"
              IsEnabled: false
              MinThreshold: 0
              MaxThreshold: 0
              TimeWindowSize: "PT15M"
            }]
AllowlistRules: [
			{
              RuleType": "ConnectionToIpNotAllowed",
              DisplayName: "Outbound connection to an ip that isn't allowed"
              Description: "Get an alert when an outbound connection is created between your device and an ip that isn't allowed"
              IsEnabled: false
              ValueType: "IpCidr"
              AllowlistValues: []
            },
            {
              RuleType: "LocalUserNotAllowed"
              DisplayName: "Login by a local user that isn't allowed"
              Description: "Get an alert when a local user that isn't allowed logins to the device"
              IsEnabled: false
              ValueType: "String"
              AllowlistValues: []
            }]
DenylistRules: []

Abrufen der Gerätesicherheitsgruppe "MySecurityGroup" im IoT Hub mit ressourcen-ID "/subscriptions/XXXXXX-XXXX-XXXXX-XXXX-XXXX-XXXXXX/resourceGroups/MyResourceGroup/providers/Microsoft.Devices/IotHubs/MyHub"

Beispiel 2

Get-AzDeviceSecurityGroup -HubResourceId "/subscriptions/XXXXXXXX-XXXX-XXXXX-XXXX-XXXXXXXXXXXX/resourceGroups/MyResourceGroup/providers/Microsoft.Devices/IotHubs/MyHub"
Array of security group items like the item returned in example 1

Abrufen einer Liste der Gerätesicherheitsgruppe im IoT Hub mit der Ressourcen-ID "/subscriptions/XXXXXXXX-XXXX-XXXXX-XXXX-XXXXXXXX/resourceGroups/MyResourceGroup/providers/Microsoft.Devices/IotHubs/MyHub"

Parameter

-DefaultProfile

Anmeldeinformationen, Konto, Mandant und Abonnement für die Kommunikation mit Azure

Parametereigenschaften

Typ:IAzureContextContainer
Standardwert:None
Unterstützt Platzhalter:False
Nicht anzeigen:False
Aliase:AzContext, AzureRmContext, AzureCredential

Parametersätze

(All)
Position:Named
Obligatorisch:False
Wert aus Pipeline:False
Wert aus Pipeline nach dem Eigenschaftsnamen:False
Wert aus verbleibenden Argumenten:False

-HubResourceId

ID der Sicherheitsressource, für die Sie den Befehl aufrufen möchten.

Parametereigenschaften

Typ:String
Standardwert:None
Unterstützt Platzhalter:False
Nicht anzeigen:False

Parametersätze

(All)
Position:Named
Obligatorisch:True
Wert aus Pipeline:False
Wert aus Pipeline nach dem Eigenschaftsnamen:False
Wert aus verbleibenden Argumenten:False

-Name

Ressourcenname.

Parametereigenschaften

Typ:String
Standardwert:None
Unterstützt Platzhalter:False
Nicht anzeigen:False

Parametersätze

ResourceIdLevelResource
Position:Named
Obligatorisch:True
Wert aus Pipeline:False
Wert aus Pipeline nach dem Eigenschaftsnamen:False
Wert aus verbleibenden Argumenten:False

CommonParameters

Dieses Cmdlet unterstützt die allgemeinen Parameter -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, -ProgressAction, -Verbose, -WarningAction und -WarningVariable. Weitere Informationen findest du unter about_CommonParameters.

Eingaben

None

Ausgaben

PSDeviceSecurityGroup