X509ClientCertificateAuthentication::CustomCertificateValidator Property

 

Gets or sets a custom client certificate validator.

Namespace:   System.ServiceModel.Security
Assembly:  System.ServiceModel (in System.ServiceModel.dll)

public:
property X509CertificateValidator^ CustomCertificateValidator {
	X509CertificateValidator^ get();
	void set(X509CertificateValidator^ value);
}

Property Value

Type: System.IdentityModel.Selectors::X509CertificateValidator^

The custom client certificate validator.

Exception Condition
InvalidOperationException

set when credential is read-only.

If the CertificateValidationMode property is set to Custom, you must set the CustomCertificateValidator property to a custom validator that inherits from the X509CertificateValidator class.

For more information, seeHow to: Create a Service that Employs a Custom Certificate Validator.

The following code shows how to set this property.

No code example is currently available or this language may not be supported.

The property can also be set in a configuration file.

<serviceCredentials>
  <clientCertificate>
     <authentication certificateValidationMode='Custom' customCertificateValidatorType='Samples.MyCertificateValidator, Samples' />
  </clientCertificate>
</serviceCredentials>

.NET Framework
Available since 3.0
Return to top
Show: