New-AzIotHubKey
Bir Azure IoT Hub anahtarı oluşturun.
Syntax
New-AzIotHubKey
[-ResourceGroupName] <String>
[-Name] <String>
[-KeyName] <String>
[-RenewKey] <String>
[-DefaultProfile <IAzureContextContainer>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
New-AzIotHubKey
[-HubId] <String>
[-KeyName] <String>
[-RenewKey] <String>
[-DefaultProfile <IAzureContextContainer>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Description
Bir Azure IoT Hub anahtarı oluşturun.
Örnekler
Örnek 1 Birincil anahtarı yeniden oluşturma
New-AzIotHubKey -ResourceGroupName "myresourcegroup" -Name "myiothub" -KeyName "testKey" -RenewKey "primary"
KeyName PrimaryKey SecondaryKey Rights
------- ---------- ------------ ------
test SXSdm31aT+i3939xSnA191f8g3uRhIUCTsO26b9s/nE= 6JqGKGUTL0mhQwvcOeIRT7OnT6noK/tie6jBY77sJTE= ServiceConnect
Azure iot hub'ının yetkilendirme ilkesi "testKey" için yeniden oluşturulan birincil anahtar.
Örnek 2 Anahtar değiştirme
New-AzIotHubKey -ResourceGroupName "myresourcegroup" -Name "myiothub" -KeyName "testKey" -RenewKey "swap"
KeyName PrimaryKey SecondaryKey Rights
------- ---------- ------------ ------
test 6JqGKGUTL0mhQwvcOeIRT7OnT6noK/tie6jBY77sJTE= SXSdm31aT+i3939xSnA191f8g3uRhIUCTsO26b9s/nE= ServiceConnect
Azure iot hub'ının yetkilendirme ilkesi "testKey" için anahtarları değiştirme.
Parametreler
-Confirm
Cmdlet'i çalıştırmadan önce sizden onay ister.
Type: | SwitchParameter |
Aliases: | cf |
Position: | Named |
Default value: | False |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-DefaultProfile
Azure ile iletişim için kullanılan kimlik bilgileri, hesap, kiracı ve abonelik
Type: | IAzureContextContainer |
Aliases: | AzContext, AzureRmContext, AzureCredential |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-HubId
IotHub Kaynak Kimliği
Type: | String |
Position: | 0 |
Default value: | None |
Required: | True |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-KeyName
Anahtarın Adı
Type: | String |
Position: | 1 |
Default value: | None |
Required: | True |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-Name
IotHub'ın adı
Type: | String |
Position: | 1 |
Default value: | None |
Required: | True |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-RenewKey
Anahtarı yeniden oluştur.
Type: | String |
Position: | 2 |
Default value: | None |
Required: | True |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-ResourceGroupName
Kaynak Grubu Adı
Type: | String |
Position: | 0 |
Default value: | None |
Required: | True |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-WhatIf
Cmdlet çalıştırılıyorsa ne olacağını gösterir. Cmdlet çalıştırılmaz.
Type: | SwitchParameter |
Aliases: | wi |
Position: | Named |
Default value: | False |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
Girişler
Çıkışlar
Azure PowerShell
Geri Bildirim
https://aka.ms/ContentUserFeedback.
Çok yakında: 2024 boyunca, içerik için geri bildirim mekanizması olarak GitHub Sorunları’nı kullanımdan kaldıracak ve yeni bir geri bildirim sistemiyle değiştireceğiz. Daha fazla bilgi için bkz.Gönderin ve geri bildirimi görüntüleyin