RSACng::Decrypt Method (array<Byte>^, RSAEncryptionPadding^)

 

Decrypts input data using the specified padding mode.

Namespace:   System.Security.Cryptography
Assembly:  System.Core (in System.Core.dll)

public:
virtual array<unsigned char>^ Decrypt(
	array<unsigned char>^ data,
	RSAEncryptionPadding^ padding
) override

Parameters

data
Type: array<System::Byte>^

The data to decrypt.

padding
Type: System.Security.Cryptography::RSAEncryptionPadding^

The padding mode.

Return Value

Type: array<System::Byte>^

The decrypted data.

Exception Condition
ArgumentNullException

data is null.

-or-

padding is null.

CryptographicException

padding does not equal RSAEncryptionPadding::Pkcs1, or else the Mode of padding does not equal RSAEncryptionPaddingMode::Oaep.

.NET Framework
Available since 4.6
Return to top
Show: