語言

RSACng.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[]

簽名資料。

例外狀況

hash 是 null。

-或-

padding 是 null。

Name的hashAlgorithm屬性值為nullEmpty或。

padding 不等於 Pkcs1 或 Pss。

適用於