Skip to main content
CertificateRequestProperties.KeyStorageProviderName | keyStorageProviderName property

Gets or sets the name of the key storage provider (KSP) that will be used to generate the private key.

Syntax


var keyStorageProviderName = certificateRequestProperties.keyStorageProviderName;
certificateRequestProperties.keyStorageProviderName = keyStorageProviderName;

public string KeyStorageProviderName { get; set; }

Public Property KeyStorageProviderName As String

public:
property String^ KeyStorageProviderName { 
   String^ get();
   void set (String^ value);
}

Property value

Type: String [JavaScript] | System.String [.NET] | Platform::String [C++]

The KSP name. The default value is "Microsoft Software Key Storage Provider".

Remarks

The name of a cryptographic service provider ( CSP) cannot be used.

Examples


public String GetSetKspName(String strNameIn)
{
    // Create a new CertificateRequestProperties object.
    CertificateRequestProperties reqProperties = new CertificateRequestProperties();

    // The default value is Microsoft Software Key Storage Provider.
    String strDefaultName = reqProperties.KeyStorageProviderName;

    // If the input option does not equal the default option, reset the property value.
    if (strNameIn != strDefaultName)
    {
        reqProperties.KeyStorageProviderName = strNameIn;
    }

    // Return the KSP name.
    return reqProperties.KeyStorageProviderName;
}

Requirements (Windows 10 device family)

Device family

Universal, introduced version 10.0.10240.0

API contract

Windows.Foundation.UniversalApiContract, introduced version 1.0

Namespace

Windows.Security.Cryptography.Certificates
Windows::Security::Cryptography::Certificates [C++]

Metadata

Windows.Foundation.UniversalApiContract.winmd

Requirements (Windows 8.x and Windows Phone 8.x)

Minimum supported client

Windows 8

Minimum supported server

Windows Server 2012

Minimum supported phone

Windows Phone 8.1 [Windows Runtime apps only]

Namespace

Windows.Security.Cryptography.Certificates
Windows::Security::Cryptography::Certificates [C++]

Metadata

Windows.winmd

See also

CertificateRequestProperties