在PowerShell中设置Azure密钥保管库访问策略时出错

时间:2017-12-11 21:58:07

标签: powershell azure

我正在尝试为我通过PowerShell在Azure中创建的密钥保管库设置访问策略。我正在使用的命令是

Set-AzureRmKeyVaultAccessPolicy -VaultName <key vault name> -UserPrincipalName <microsoft account> -PermissionsToKeys all

当我运行该命令时,我收到错误。

Set-AzureRmKeyVaultAccessPolicy : Sequence contains more than one element
At line:1 char:1
+ Set-AzureRmKeyVaultAccessPolicy -VaultName <key vault name> -UserPr ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : CloseError: (:) [Set-AzureRmKeyVaultAccessPolicy], InvalidOperationException
    + FullyQualifiedErrorId : Microsoft.Azure.Commands.KeyVault.SetAzureKeyVaultAccessPolicy

关于此错误的含义以及如何解决此问题的任何想法?

0 个答案:

没有答案