UA Bundle SDK .NET  2.1.2.227
 All Classes Namespaces Functions Variables Enumerations Enumerator Properties Events Groups Pages
UnifiedAutomation.UaBase.CertificateValidator Class Reference

Validates certificates. More...

Public Member Functions

 CertificateValidator (ApplicationInstance application)
 The default constructor. More...
 
virtual void Validate (ICertificate certificate)
 Validates a certificate. More...
 
virtual void Validate (ICertificate certificate, ICertificate[] chain, bool mustValidateChain)
 Validates the specified certificate. More...
 
virtual void Validate (ICertificate[] certificates, bool mustValidateChain)
 Validates a certificate. More...
 
bool GetIssuers (ICertificate certificate, List< ICertificate > issuers, ICertificate[] chain, int chainIndex)
 Returns the issuers for the certificate. More...
 
X509CertificateValidator GetChannelValidator ()
 Returns an object that can be used with WCF channel. More...
 

Protected Member Functions

virtual void InternalValidate (ICertificate[] certificates, bool mustValidateChain)
 Throws an exception if validation fails. More...
 

Properties

CertificateValidationEventHandler CertificateValidation
 Raised when a certificate validation error occurs. More...
 

Detailed Description

Validates certificates.

Constructor & Destructor Documentation

UnifiedAutomation.UaBase.CertificateValidator.CertificateValidator ( ApplicationInstance  application)

The default constructor.

Member Function Documentation

X509CertificateValidator UnifiedAutomation.UaBase.CertificateValidator.GetChannelValidator ( )

Returns an object that can be used with WCF channel.

bool UnifiedAutomation.UaBase.CertificateValidator.GetIssuers ( ICertificate  certificate,
List< ICertificate issuers,
ICertificate[]  chain,
int  chainIndex 
)

Returns the issuers for the certificate.

virtual void UnifiedAutomation.UaBase.CertificateValidator.InternalValidate ( ICertificate[]  certificates,
bool  mustValidateChain 
)
protectedvirtual

Throws an exception if validation fails.

Parameters
certificatesThe certificates.
mustValidateChainif set to true the all certificates in the chain must be available and valid.
Exceptions
StatusExceptionIf certificate cannot be accepted
virtual void UnifiedAutomation.UaBase.CertificateValidator.Validate ( ICertificate  certificate)
virtual

Validates a certificate.

Parameters
certificateThe certificate to validate.

Each UA application may have a list of trusted certificates that is different from all other UA applications that may be running on the same machine. As a result, the certificate validator cannot rely completely on the Windows certificate store and user or machine specific CTLs (certificate trust lists). The validator constructs the trust chain for the certificate and follows the chain until it finds a certification that is in the application trust list. Non-fatal trust chain errors (i.e. certificate expired) are ignored if the certificate is in the application trust list. If no certificate in the chain is trusted then the validator will still accept the certification if there are no trust chain errors. The validator may be configured to ignore the application trust list and/or trust chain.

virtual void UnifiedAutomation.UaBase.CertificateValidator.Validate ( ICertificate  certificate,
ICertificate[]  chain,
bool  mustValidateChain 
)
virtual

Validates the specified certificate.

Parameters
certificateThe certificate.
chainThe chain.
mustValidateChainif set to true then all certificates in the chain must be available and valid.
virtual void UnifiedAutomation.UaBase.CertificateValidator.Validate ( ICertificate[]  certificates,
bool  mustValidateChain 
)
virtual

Validates a certificate.

Parameters
certificatesThe certificate chain. Must start with the certificate to validate.
mustValidateChainif set to true then all certificates in the chain must be available and valid.

Property Documentation

CertificateValidationEventHandler UnifiedAutomation.UaBase.CertificateValidator.CertificateValidation
addremove

Raised when a certificate validation error occurs.


The documentation for this class was generated from the following file: