Bewerken

Share via


X509SecurityTokenProvider Constructors

Definition

Initializes a new instance of the X509SecurityTokenProvider class.

Overloads

X509SecurityTokenProvider(X509Certificate2)

Initializes a new instance of the X509SecurityTokenProvider class using the specified X.509 certificate.

X509SecurityTokenProvider(StoreLocation, StoreName, X509FindType, Object)

Initializes a new instance of the X509SecurityTokenProvider class by getting an X.509 certificate from the specified certificate store criteria.

X509SecurityTokenProvider(X509Certificate2)

Source:
X509SecurityTokenProvider.cs
Source:
X509SecurityTokenProvider.cs

Initializes a new instance of the X509SecurityTokenProvider class using the specified X.509 certificate.

public:
 X509SecurityTokenProvider(System::Security::Cryptography::X509Certificates::X509Certificate2 ^ certificate);
public X509SecurityTokenProvider (System.Security.Cryptography.X509Certificates.X509Certificate2 certificate);
new System.IdentityModel.Selectors.X509SecurityTokenProvider : System.Security.Cryptography.X509Certificates.X509Certificate2 -> System.IdentityModel.Selectors.X509SecurityTokenProvider
Public Sub New (certificate As X509Certificate2)

Parameters

certificate
X509Certificate2

The X509Certificate2 to get a security token for.

Exceptions

certificate is null.

Remarks

The GetTokenCore method gets a security token based on the certificate specified in the certificate parameter.

Applies to

X509SecurityTokenProvider(StoreLocation, StoreName, X509FindType, Object)

Initializes a new instance of the X509SecurityTokenProvider class by getting an X.509 certificate from the specified certificate store criteria.

public:
 X509SecurityTokenProvider(System::Security::Cryptography::X509Certificates::StoreLocation storeLocation, System::Security::Cryptography::X509Certificates::StoreName storeName, System::Security::Cryptography::X509Certificates::X509FindType findType, System::Object ^ findValue);
public X509SecurityTokenProvider (System.Security.Cryptography.X509Certificates.StoreLocation storeLocation, System.Security.Cryptography.X509Certificates.StoreName storeName, System.Security.Cryptography.X509Certificates.X509FindType findType, object findValue);
new System.IdentityModel.Selectors.X509SecurityTokenProvider : System.Security.Cryptography.X509Certificates.StoreLocation * System.Security.Cryptography.X509Certificates.StoreName * System.Security.Cryptography.X509Certificates.X509FindType * obj -> System.IdentityModel.Selectors.X509SecurityTokenProvider
Public Sub New (storeLocation As StoreLocation, storeName As StoreName, findType As X509FindType, findValue As Object)

Parameters

storeLocation
StoreLocation

One of the StoreLocation values that specifies the certificate store location.

storeName
StoreName

One of the StoreName values that specifies the certificate store name.

findType
X509FindType

One of the X509FindType values that specifies how to search the certificate store.

findValue
Object

The value used to find the X.509 certificate in the certificate store.

Exceptions

findValue is null.

No certificates match the specified criteria.

-or-

More than one certificate matches the specified criteria.

Remarks

The GetTokenCore method gets a security token based on the certificate that matches the specified certificate store criteria.

Applies to