Bewerken

Share via


X509SignatureGenerator.CreateForRSA(RSA, RSASignaturePadding) Method

Definition

Creates an X509SignatureGenerator object for RSA signatures using the specified private key and padding mode.

public:
 static System::Security::Cryptography::X509Certificates::X509SignatureGenerator ^ CreateForRSA(System::Security::Cryptography::RSA ^ key, System::Security::Cryptography::RSASignaturePadding ^ signaturePadding);
public static System.Security.Cryptography.X509Certificates.X509SignatureGenerator CreateForRSA (System.Security.Cryptography.RSA key, System.Security.Cryptography.RSASignaturePadding signaturePadding);
static member CreateForRSA : System.Security.Cryptography.RSA * System.Security.Cryptography.RSASignaturePadding -> System.Security.Cryptography.X509Certificates.X509SignatureGenerator
Public Shared Function CreateForRSA (key As RSA, signaturePadding As RSASignaturePadding) As X509SignatureGenerator

Parameters

key
RSA

The private key.

signaturePadding
RSASignaturePadding

The padding mode.

Returns

An X509SignatureGenerator object for RSA signatures.

Exceptions

key is null.

-or-

signaturePadding is null.

The specified padding mode is not valid for this algorithm.

Applies to