RSA.DecryptValue(Byte[]) Method

Definition

Caution

RSA.EncryptValue and DecryptValue are not supported and throw NotSupportedException. Use RSA.Encrypt and RSA.Decrypt instead.

When overridden in a derived class, decrypts the input data using the private key.

C#
public virtual byte[] DecryptValue (byte[] rgb);
C#
[System.Obsolete("RSA.EncryptValue and DecryptValue are not supported and throw NotSupportedException. Use RSA.Encrypt and RSA.Decrypt instead.", DiagnosticId="SYSLIB0048", UrlFormat="https://aka.ms/dotnet-warnings/{0}")]
public virtual byte[] DecryptValue (byte[] rgb);
C#
public abstract byte[] DecryptValue (byte[] rgb);

Parameters

rgb
Byte[]

The cipher text to be decrypted.

Returns

Byte[]

The resulting decryption of the rgb parameter in plain text.

Attributes

Exceptions

This method call is not supported. This exception is thrown starting with the .NET Framework 4.6.

Remarks

In the .NET Framework 4.5.2 and earlier versions of the .NET Framework, this method was abstract. However, the only implementation by a derived class, RSACryptoServiceProvider.DecryptValue, also threw a NotSupportedException exception.

Applies to

Product Versies (Verouderd)
.NET Core 2.0, Core 2.1, Core 2.2, Core 3.0, Core 3.1, 5, 6, 7 (8, 9)
.NET Framework 1.1, 2.0, 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1
.NET Standard 2.0, 2.1

See also