MLDsa.SignPreHash メソッド

定義

オーバーロード

名前 説明
SignPreHash(ReadOnlySpan<Byte>, Span<Byte>, String, ReadOnlySpan<Byte>)

FIPS 204 事前ハッシュ署名アルゴリズムを使用して指定されたハッシュに署名し、指定されたバッファーに署名を書き込みます。

SignPreHash(Byte[], String, Byte[])

FIPS 204 事前ハッシュ署名アルゴリズムを使用して、指定されたハッシュに署名します。

SignPreHash(ReadOnlySpan<Byte>, Span<Byte>, String, ReadOnlySpan<Byte>)

ソース:
MLDsa.cs
ソース:
MLDsa.cs
ソース:
MLDsa.cs

FIPS 204 事前ハッシュ署名アルゴリズムを使用して指定されたハッシュに署名し、指定されたバッファーに署名を書き込みます。

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

パラメーター

hash
ReadOnlySpan<Byte>

署名するハッシュ。

destination
Span<Byte>

署名を受け取るバッファー。 その長さは正確に SignatureSizeInBytesする必要があります。

hashAlgorithmOid
String

ハッシュの作成に使用されるハッシュ アルゴリズムの OID。

context
ReadOnlySpan<Byte>

シグネチャのスコープを制限する省略可能なコンテキスト固有の値。

既定値は空のバッファーです。

属性

例外

hashAlgorithmOidnullです。

destination内のバッファーは、署名を受け取る正しくない長さです。

context には、255 バイトを超える Length があります。

このインスタンスは破棄されました。

hashAlgorithmOid は整形式 OID ではありません。

-又は-

hashAlgorithmOid は既知のアルゴリズムであり、 hash は予想される長さを持っていません。

-又は-

インスタンスは公開キーのみを表します。

-又は-

ハッシュの署名中にエラーが発生しました。

適用対象

SignPreHash(Byte[], String, Byte[])

ソース:
MLDsa.cs
ソース:
MLDsa.cs
ソース:
MLDsa.cs

FIPS 204 事前ハッシュ署名アルゴリズムを使用して、指定されたハッシュに署名します。

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

パラメーター

hash
Byte[]

署名するハッシュ。

hashAlgorithmOid
String

ハッシュの作成に使用されるハッシュ アルゴリズムの OID。

context
Byte[]

シグネチャのスコープを制限する省略可能なコンテキスト固有の値。

既定値は null です。

返品

Byte[]
属性

例外

hash または hashAlgorithmOidnull

データの検証中にエラーが発生しました。

hashAlgorithmOid は整形式 OID ではありません。

-又は-

hashAlgorithmOid は既知のアルゴリズムであり、 hash は予想される長さを持っていません。

-又は-

インスタンスは公開キーのみを表します。

-又は-

ハッシュの署名中にエラーが発生しました。

適用対象