HMACSHA256.TryHashData Método

Definição

Tenta calcular o HMAC de dados usando o algoritmo SHA256.

public:
 static bool TryHashData(ReadOnlySpan<System::Byte> key, ReadOnlySpan<System::Byte> source, Span<System::Byte> destination, [Runtime::InteropServices::Out] int % bytesWritten);
public static bool TryHashData (ReadOnlySpan<byte> key, ReadOnlySpan<byte> source, Span<byte> destination, out int bytesWritten);
static member TryHashData : ReadOnlySpan<byte> * ReadOnlySpan<byte> * Span<byte> * int -> bool
Public Shared Function TryHashData (key As ReadOnlySpan(Of Byte), source As ReadOnlySpan(Of Byte), destination As Span(Of Byte), ByRef bytesWritten As Integer) As Boolean

Parâmetros

key
ReadOnlySpan<Byte>

A chave HMAC.

source
ReadOnlySpan<Byte>

Os dados para HMAC.

destination
Span<Byte>

O buffer que receberá o valor de HMAC.

bytesWritten
Int32

Quando esse método é retornado, o número total de bytes gravados em destination.

Retornos

Boolean

false se destination for muito pequeno para manter o hash calculado. Caso contrário, true.

Aplica-se a