Neuron®
The Neuron® is the basis for the creation of open and secure federated networks for smart societies.
Loading...
Searching...
No Matches
RemoteCertificateEventArgs.cs
1using System;
2using System.Net.Security;
3using System.Security.Cryptography.X509Certificates;
4
5namespace Waher.Content
6{
12 public delegate void RemoteCertificateEventHandler(object Sender, RemoteCertificateEventArgs e);
13
17 public class RemoteCertificateEventArgs : EventArgs
18 {
19 private bool? isValid = null;
20
29 {
30 this.Certificate = Certificate;
31 this.Chain = Chain;
32 this.SslPolicyErrors = SslPolicyErrors;
33 }
34
39 public bool? IsValid
40 {
41 get => this.isValid;
42 set
43 {
44 if (this.isValid.HasValue)
45 throw new InvalidOperationException("Value has already been set.");
46
47 this.isValid = value;
48 }
49 }
50
54 public X509Certificate Certificate
55 {
56 get;
57 private set;
58 }
59
63 public X509Chain Chain
64 {
65 get;
66 private set;
67 }
68
73 {
74 get;
75 private set;
76 }
77 }
78}
Remove certificate validation event arguments.
bool? IsValid
If remote certificate is considered valid or not. null means default validation rules will be applied...
RemoteCertificateEventArgs(X509Certificate Certificate, X509Chain Chain, SslPolicyErrors SslPolicyErrors)
Remove certificate validation event arguments.
X509Certificate Certificate
Remote certificate.
SslPolicyErrors SslPolicyErrors
Any SSL policy errors detected.
delegate void RemoteCertificateEventHandler(object Sender, RemoteCertificateEventArgs e)
Delegate for remote certificate event handlers.