Share via


RSAOpenSsl.SignHash(Byte[], HashAlgorithmName, RSASignaturePadding) 方法

定義

針對指定雜湊值的簽章,使用指定的填補來計算。

public:
 override cli::array <System::Byte> ^ SignHash(cli::array <System::Byte> ^ hash, System::Security::Cryptography::HashAlgorithmName hashAlgorithm, System::Security::Cryptography::RSASignaturePadding ^ padding);
public override byte[] SignHash (byte[] hash, System.Security.Cryptography.HashAlgorithmName hashAlgorithm, System.Security.Cryptography.RSASignaturePadding padding);
override this.SignHash : byte[] * System.Security.Cryptography.HashAlgorithmName * System.Security.Cryptography.RSASignaturePadding -> byte[]
Public Overrides Function SignHash (hash As Byte(), hashAlgorithm As HashAlgorithmName, padding As RSASignaturePadding) As Byte()

參數

hash
Byte[]

要簽署之資料的雜湊值。

hashAlgorithm
HashAlgorithmName

用來建立該資料雜湊值的雜湊演算法。

padding
RSASignaturePadding

填補。

傳回

Byte[]

指定雜湊值的 RSA 簽章。

例外狀況

datapaddingnull

hashAlgorithm.NamenullEmpty

padding 未知,或不支援此實作。

-或-

這個執行個體只表示公開金鑰。

-或-

建立簽章時發生錯誤。

適用於

另請參閱