RSACryptoServiceProvider.ExportCspBlob(Boolean) RSACryptoServiceProvider.ExportCspBlob(Boolean) RSACryptoServiceProvider.ExportCspBlob(Boolean) RSACryptoServiceProvider.ExportCspBlob(Boolean) Method

Definition

Exports a blob containing the key information associated with an RSACryptoServiceProvider object.

public:
 virtual cli::array <System::Byte> ^ ExportCspBlob(bool includePrivateParameters);
[System.Runtime.InteropServices.ComVisible(false)]
public byte[] ExportCspBlob (bool includePrivateParameters);
abstract member ExportCspBlob : bool -> byte[]
override this.ExportCspBlob : bool -> byte[]
Public Function ExportCspBlob (includePrivateParameters As Boolean) As Byte()

Parameters

includePrivateParameters
Boolean Boolean Boolean Boolean

true to include the private key; otherwise, false.

Returns

Byte[]

A byte array containing the key information associated with an RSACryptoServiceProvider object.

Implements

Remarks

The ExportCspBlob method returns a blob containing key information that is compatible with the unmanaged Microsoft Cryptographic API (CAPI).

Security

KeyContainerPermissionAccessEntryCollection
for permission to access a key container when exporting a private key. Security action: Demand. Associated enumeration: Export

Applies to

See also