MLDsa.VerifyPreHash Metoda

Definice

Ověřuje, že zadaný podpis před hashem FIPS 204 je platný pro tento klíč a zadanou hodnotu hash.

Přetížení

Name Description
VerifyPreHash(ReadOnlySpan<Byte>, ReadOnlySpan<Byte>, String, ReadOnlySpan<Byte>)

Ověřuje, že zadaný podpis před hashem FIPS 204 je platný pro tento klíč a zadanou hodnotu hash.

VerifyPreHash(Byte[], Byte[], String, Byte[])

Ověřuje, že zadaný podpis před hashem FIPS 204 je platný pro tento klíč a zadanou hodnotu hash.

VerifyPreHash(ReadOnlySpan<Byte>, ReadOnlySpan<Byte>, String, ReadOnlySpan<Byte>)

Zdroj:
MLDsa.cs
Zdroj:
MLDsa.cs
Zdroj:
MLDsa.cs

Ověřuje, že zadaný podpis před hashem FIPS 204 je platný pro tento klíč a zadanou hodnotu hash.

[System.Diagnostics.CodeAnalysis.Experimental("SYSLIB5006", UrlFormat="https://aka.ms/dotnet-warnings/{0}")]
public bool VerifyPreHash(ReadOnlySpan<byte> hash, ReadOnlySpan<byte> signature, string hashAlgorithmOid, ReadOnlySpan<byte> context = default);
public bool VerifyPreHash(ReadOnlySpan<byte> hash, ReadOnlySpan<byte> signature, string hashAlgorithmOid, ReadOnlySpan<byte> context = default);
[<System.Diagnostics.CodeAnalysis.Experimental("SYSLIB5006", UrlFormat="https://aka.ms/dotnet-warnings/{0}")>]
member this.VerifyPreHash : ReadOnlySpan<byte> * ReadOnlySpan<byte> * string * ReadOnlySpan<byte> -> bool
member this.VerifyPreHash : ReadOnlySpan<byte> * ReadOnlySpan<byte> * string * ReadOnlySpan<byte> -> bool
Public Function VerifyPreHash (hash As ReadOnlySpan(Of Byte), signature As ReadOnlySpan(Of Byte), hashAlgorithmOid As String, Optional context As ReadOnlySpan(Of Byte) = Nothing) As Boolean

Parametry

hash
ReadOnlySpan<Byte>

Hodnota hash, která se má ověřit.

signature
ReadOnlySpan<Byte>

Podpis, který chcete ověřit.

hashAlgorithmOid
String

Identifikátor hashového algoritmu použitého k vytvoření hodnoty hash.

context
ReadOnlySpan<Byte>

Kontextová hodnota, která byla poskytována během podepisování.

Výchozí hodnota je prázdná vyrovnávací paměť.

Návraty

truepokud podpis ověří hodnotu hash; v opačném případě . false

Atributy

Výjimky

hashAlgorithmOid je null.

context Length má více než 255 bajtů.

Tato instance byla odstraněna.

hashAlgorithmOid není dobře formátovaný identifikátor OID.

nebo

hashAlgorithmOid je dobře známý algoritmus a hash nemá očekávanou délku.

nebo

Při ověřování hodnoty hash došlo k chybě.

Platí pro

VerifyPreHash(Byte[], Byte[], String, Byte[])

Zdroj:
MLDsa.cs
Zdroj:
MLDsa.cs
Zdroj:
MLDsa.cs

Ověřuje, že zadaný podpis před hashem FIPS 204 je platný pro tento klíč a zadanou hodnotu hash.

[System.Diagnostics.CodeAnalysis.Experimental("SYSLIB5006", UrlFormat="https://aka.ms/dotnet-warnings/{0}")]
public bool VerifyPreHash(byte[] hash, byte[] signature, string hashAlgorithmOid, byte[]? context = default);
public bool VerifyPreHash(byte[] hash, byte[] signature, string hashAlgorithmOid, byte[]? context = default);
[<System.Diagnostics.CodeAnalysis.Experimental("SYSLIB5006", UrlFormat="https://aka.ms/dotnet-warnings/{0}")>]
member this.VerifyPreHash : byte[] * byte[] * string * byte[] -> bool
member this.VerifyPreHash : byte[] * byte[] * string * byte[] -> bool
Public Function VerifyPreHash (hash As Byte(), signature As Byte(), hashAlgorithmOid As String, Optional context As Byte() = Nothing) As Boolean

Parametry

hash
Byte[]

Hodnota hash, která se má ověřit.

signature
Byte[]

Podpis, který chcete ověřit.

hashAlgorithmOid
String

Identifikátor hashového algoritmu použitého k vytvoření hodnoty hash.

context
Byte[]

Kontextová hodnota, která byla poskytována během podepisování.

Výchozí hodnota je null.

Návraty

truepokud podpis ověří hodnotu hash; v opačném případě . false

Atributy

Výjimky

hash nebo signaturehashAlgorithmOid je null.

context má délku přesahující 255 bajtů.

Tato instance byla odstraněna.

hashAlgorithmOid není dobře formátovaný identifikátor OID.

nebo

hashAlgorithmOid je dobře známý algoritmus a hash nemá očekávanou délku.

nebo

Při ověřování hodnoty hash došlo k chybě.

Poznámky

Kontext null se považuje za prázdný.

Platí pro