Compartilhar via


KeyVaultClientExtensions.GetSecretAsync Método

Definição

Sobrecargas

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

Obtenha um segredo especificado de um determinado cofre de chaves.

GetSecretAsync(IKeyVaultClient, String, String, CancellationToken)

Obtém um segredo.

GetSecretAsync(IKeyVaultClient, String, CancellationToken)

Obtém um segredo.

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

Origem:
KeyVaultClientExtensions.cs

Obtenha um segredo especificado de um determinado cofre de chaves.

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)

Parâmetros

operations
IKeyVaultClient

O grupo de operações para esse método de extensão.

vaultBaseUrl
String

O nome do cofre, por exemplo https://myvault.vault.azure.net, .

secretName
String

O nome do segredo.

secretVersion
String

A versão do segredo.

cancellationToken
CancellationToken

O token de cancelamento.

Retornos

Comentários

A operação GET se aplica a qualquer segredo armazenado em um Cofre de Chaves do Azure. Essa operação requer a permissão secrets/get.

Aplica-se a

GetSecretAsync(IKeyVaultClient, String, String, CancellationToken)

Origem:
KeyVaultClientExtensions.cs

Obtém um segredo.

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)

Parâmetros

operations
IKeyVaultClient
vaultBaseUrl
String

A URL do cofre que contém os segredos.

secretName
String

O nome do segredo no cofre fornecido.

cancellationToken
CancellationToken

Token de cancelamento opcional

Retornos

Uma mensagem de resposta que contém o segredo

Aplica-se a

GetSecretAsync(IKeyVaultClient, String, CancellationToken)

Origem:
KeyVaultClientExtensions.cs

Obtém um segredo.

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)

Parâmetros

operations
IKeyVaultClient
secretIdentifier
String

A URL do segredo.

cancellationToken
CancellationToken

Token de cancelamento opcional

Retornos

Uma mensagem de resposta que contém o segredo

Aplica-se a