你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn

KeyVaultClientExtensions.GetSecretAsync 方法

定义

重载

GetSecretAsync(IKeyVaultClient, String, String, String, CancellationToken)

从给定密钥保管库获取指定的机密。

GetSecretAsync(IKeyVaultClient, String, String, CancellationToken)

获取机密。

GetSecretAsync(IKeyVaultClient, String, CancellationToken)

获取机密。

GetSecretAsync(IKeyVaultClient, String, String, String, CancellationToken)

Source:
KeyVaultClientExtensions.cs

从给定密钥保管库获取指定的机密。

public static System.Threading.Tasks.Task<Microsoft.Azure.KeyVault.Models.SecretBundle> GetSecretAsync (this Microsoft.Azure.KeyVault.IKeyVaultClient operations, string vaultBaseUrl, string secretName, string secretVersion, System.Threading.CancellationToken cancellationToken = default);
static member GetSecretAsync : Microsoft.Azure.KeyVault.IKeyVaultClient * string * string * string * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Azure.KeyVault.Models.SecretBundle>
<Extension()>
Public Function GetSecretAsync (operations As IKeyVaultClient, vaultBaseUrl As String, secretName As String, secretVersion As String, Optional cancellationToken As CancellationToken = Nothing) As Task(Of SecretBundle)

参数

operations
IKeyVaultClient

此扩展方法的操作组。

vaultBaseUrl
String

保管库名称,例如 https://myvault.vault.azure.net

secretName
String

机密的名称。

secretVersion
String

机密的版本。

cancellationToken
CancellationToken

取消标记。

返回

注解

GET 操作适用于 Azure 密钥保管库中存储的任何机密。 此操作需要机密/get 权限。

适用于

GetSecretAsync(IKeyVaultClient, String, String, CancellationToken)

Source:
KeyVaultClientExtensions.cs

获取机密。

public static System.Threading.Tasks.Task<Microsoft.Azure.KeyVault.Models.SecretBundle> GetSecretAsync (this Microsoft.Azure.KeyVault.IKeyVaultClient operations, string vaultBaseUrl, string secretName, System.Threading.CancellationToken cancellationToken = default);
static member GetSecretAsync : Microsoft.Azure.KeyVault.IKeyVaultClient * string * string * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Azure.KeyVault.Models.SecretBundle>
<Extension()>
Public Function GetSecretAsync (operations As IKeyVaultClient, vaultBaseUrl As String, secretName As String, Optional cancellationToken As CancellationToken = Nothing) As Task(Of SecretBundle)

参数

operations
IKeyVaultClient
vaultBaseUrl
String

包含机密的保管库的 URL。

secretName
String

给定保管库中机密的名称。

cancellationToken
CancellationToken

可选取消令牌

返回

包含机密的响应消息

适用于

GetSecretAsync(IKeyVaultClient, String, CancellationToken)

Source:
KeyVaultClientExtensions.cs

获取机密。

public static System.Threading.Tasks.Task<Microsoft.Azure.KeyVault.Models.SecretBundle> GetSecretAsync (this Microsoft.Azure.KeyVault.IKeyVaultClient operations, string secretIdentifier, System.Threading.CancellationToken cancellationToken = default);
static member GetSecretAsync : Microsoft.Azure.KeyVault.IKeyVaultClient * string * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Azure.KeyVault.Models.SecretBundle>
<Extension()>
Public Function GetSecretAsync (operations As IKeyVaultClient, secretIdentifier As String, Optional cancellationToken As CancellationToken = Nothing) As Task(Of SecretBundle)

参数

operations
IKeyVaultClient
secretIdentifier
String

机密的 URL。

cancellationToken
CancellationToken

可选取消令牌

返回

包含机密的响应消息

适用于