CertificateRequestProperties.KeyProtectionLevel Свойство

Определение

Возвращает или задает уровень защиты строгого ключа.

public:
 property KeyProtectionLevel KeyProtectionLevel { KeyProtectionLevel get(); void set(KeyProtectionLevel value); };
KeyProtectionLevel KeyProtectionLevel();

void KeyProtectionLevel(KeyProtectionLevel value);
public KeyProtectionLevel KeyProtectionLevel { get; set; }
var keyProtectionLevel = certificateRequestProperties.keyProtectionLevel;
certificateRequestProperties.keyProtectionLevel = keyProtectionLevel;
Public Property KeyProtectionLevel As KeyProtectionLevel

Значение свойства

Уровень защиты строгого ключа.

Примеры

public KeyProtectionLevel GetSetKeyProtectionLevel(KeyProtectionLevel levelIn)
{
    // Create a new CertificateRequestProperties object.
    CertificateRequestProperties reqProperties = new CertificateRequestProperties();

    // The default value is NoConsent.
    KeyProtectionLevel defaultLevel = reqProperties.KeyProtectionLevel;

    // If the input option does not equal the default option, reset the property value.
    if (levelIn != defaultLevel)
    {
        reqProperties.KeyProtectionLevel = levelIn;
    }

    // return the key protection level.
    return reqProperties.KeyProtectionLevel;
}

Комментарии

Значение keyProtectionLevel по умолчанию — NoConsent. Поэтому по умолчанию защита с помощью строгого ключа не указана.

Применяется к