Поделиться через


CertificateLoader.LoadFromStoreCert Метод

Определение

Загружает сертификат из хранилища сертификатов.

public:
 static System::Security::Cryptography::X509Certificates::X509Certificate2 ^ LoadFromStoreCert(System::String ^ subject, System::String ^ storeName, System::Security::Cryptography::X509Certificates::StoreLocation storeLocation, bool allowInvalid);
public static System.Security.Cryptography.X509Certificates.X509Certificate2 LoadFromStoreCert (string subject, string storeName, System.Security.Cryptography.X509Certificates.StoreLocation storeLocation, bool allowInvalid);
static member LoadFromStoreCert : string * string * System.Security.Cryptography.X509Certificates.StoreLocation * bool -> System.Security.Cryptography.X509Certificates.X509Certificate2
Public Shared Function LoadFromStoreCert (subject As String, storeName As String, storeLocation As StoreLocation, allowInvalid As Boolean) As X509Certificate2

Параметры

subject
String

Субъект сертификата.

storeName
String

Имя хранилища сертификатов.

storeLocation
StoreLocation

Расположение хранилища сертификатов.

allowInvalid
Boolean

Указывает, следует ли загружать сертификаты, которые считаются недопустимыми.

Возвращаемое значение

Загруженный сертификат.

Комментарии

Точное совпадение субъекта загружается, если он имеется, в противном случае лучше всего соответствует сертификат с именем субъекта, содержащим указанную тему. Сравнение субъектов не учитывает регистр.

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