public void init() { EMSSSLFileStoreInfo storeInfo = new EMSSSLFileStoreInfo(); if (ssl_trace) { EMSSSL.SetClientTracer(new System.IO.StreamWriter(System.Console.OpenStandardOutput())); } if (ssl_target_hostname != null) { EMSSSL.SetTargetHostName(ssl_target_hostname); } if (ssl_custom) { HostVerifier v = new HostVerifier(); EMSSSL.SetHostNameVerifier(new EMSSSLHostNameVerifier(v.verifyHost)); } if (ssl_trusted != null) { for (int i = 0; i < ssl_trusted.Count; i++) { String certfile = (String)ssl_trusted[i]; storeInfo.SetSSLTrustedCertificate(certfile); } } if (ssl_identity != null) { storeInfo.SetSSLClientIdentity(ssl_identity); storeInfo.SetSSLPassword(ssl_password.ToCharArray()); } EMSSSL.SetCertificateStoreType(EMSSSLStoreType.EMSSSL_STORE_TYPE_FILE, storeInfo); }
public void init() { EMSSSLFileStoreInfo storeInfo = new EMSSSLFileStoreInfo(); if (ssl_trace) EMSSSL.SetClientTracer(new System.IO.StreamWriter(System.Console.OpenStandardOutput())); if (ssl_target_hostname != null) EMSSSL.SetTargetHostName(ssl_target_hostname); if (ssl_custom) { HostVerifier v = new HostVerifier(); EMSSSL.SetHostNameVerifier(new EMSSSLHostNameVerifier(v.verifyHost)); } if (ssl_trusted != null) { for (int i = 0; i < ssl_trusted.Count; i++) { String certfile = (String)ssl_trusted[i]; storeInfo.SetSSLTrustedCertificate(certfile); } } if (ssl_identity != null) { storeInfo.SetSSLClientIdentity(ssl_identity); storeInfo.SetSSLPassword(ssl_password.ToCharArray()); } EMSSSL.SetCertificateStoreType(EMSSSLStoreType.EMSSSL_STORE_TYPE_FILE, storeInfo); }