Class ServicePointManagerHelper
Setup a disposable ServerCertificateValidationCallback
Implements
System.IDisposable
Namespace: ImageVault.Common.Security
Assembly: ImageVault.Common.dll
Syntax
public class ServicePointManagerHelper : Object
Constructors
ServicePointManagerHelper(Func<Object, X509Certificate, X509Chain, SslPolicyErrors, Boolean>)
Setup System.Net.ServicePointManager.ServerCertificateValidationCallback to allow all valid certificates
Declaration
public ServicePointManagerHelper(Func<object, X509Certificate, X509Chain, SslPolicyErrors, bool> callback)
Parameters
Type | Name | Description |
---|---|---|
System.Func<System.Object, System.Security.Cryptography.X509Certificates.X509Certificate, System.Security.Cryptography.X509Certificates.X509Chain, System.Net.Security.SslPolicyErrors, System.Boolean> | callback |
Methods
Dispose()
Releases the resources used by the ServicePointManagerHelper.
Declaration
public void Dispose()
Dispose(Boolean)
Releases the resources used by the ServicePointManagerHelper.
Declaration
protected void Dispose(bool disposing)
Parameters
Type | Name | Description |
---|---|---|
System.Boolean | disposing | Set to true to release both managed and unmanaged resources; false to release only unmanaged resources. |
Finalize()
Releases unmanaged resources and performs other cleanup operations before the ServicePointManagerHelper is reclaimed by garbage collection.
Declaration
protected override void Finalize()
SetSecurityProtocolFromConfiguration()
Sets the System.Net.ServicePointManager.SecurityProtocol to the configured value
Declaration
public static void SetSecurityProtocolFromConfiguration()
Implements
System.IDisposable