IKeyVaultClient.SetSecretWithHttpMessagesAsync Método

Definição

Define um segredo em um cofre de chaves especificado.

public System.Threading.Tasks.Task<Microsoft.Rest.Azure.AzureOperationResponse<Microsoft.Azure.KeyVault.Models.SecretBundle>> SetSecretWithHttpMessagesAsync (string vaultBaseUrl, string secretName, string value, System.Collections.Generic.IDictionary<string,string> tags = default, string contentType = default, Microsoft.Azure.KeyVault.Models.SecretAttributes secretAttributes = default, System.Collections.Generic.Dictionary<string,System.Collections.Generic.List<string>> customHeaders = default, System.Threading.CancellationToken cancellationToken = default);
abstract member SetSecretWithHttpMessagesAsync : string * string * string * System.Collections.Generic.IDictionary<string, string> * string * Microsoft.Azure.KeyVault.Models.SecretAttributes * System.Collections.Generic.Dictionary<string, System.Collections.Generic.List<string>> * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Rest.Azure.AzureOperationResponse<Microsoft.Azure.KeyVault.Models.SecretBundle>>
Public Function SetSecretWithHttpMessagesAsync (vaultBaseUrl As String, secretName As String, value As String, Optional tags As IDictionary(Of String, String) = Nothing, Optional contentType As String = Nothing, Optional secretAttributes As SecretAttributes = Nothing, Optional customHeaders As Dictionary(Of String, List(Of String)) = Nothing, Optional cancellationToken As CancellationToken = Nothing) As Task(Of AzureOperationResponse(Of SecretBundle))

Parâmetros

vaultBaseUrl
String

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

secretName
String

O nome do segredo.

value
String

O valor do segredo.

tags
IDictionary<String,String>

Metadados específicos do aplicativo na forma de pares chave-valor.

contentType
String

Tipo do valor do segredo, como uma senha.

secretAttributes
SecretAttributes

Os atributos de gerenciamento de segredos.

customHeaders
Dictionary<String,List<String>>

Os cabeçalhos que serão adicionados à solicitação.

cancellationToken
CancellationToken

O token de cancelamento.

Retornos

Comentários

A operação SET adiciona um segredo ao Key Vault do Azure. Se o segredo denominado já existir, o Cofre de Chaves do Azure cria uma nova versão do segredo. Essa operação requer a permissão secrets/set.

Aplica-se a