void Client1(object state) { Stream client = (Stream)state; IntegratedSecurityClient sa = new IntegratedSecurityClient(); m_sw.Start(); _ = sa.TryAuthenticateAsClient(client); m_sw.Stop(); System.Console.WriteLine(m_sw.Elapsed.TotalMilliseconds); m_sw.Restart(); bool success = sa.TryAuthenticateAsClient(client); m_sw.Stop(); System.Console.WriteLine(m_sw.Elapsed.TotalMilliseconds); if (!success) { throw new Exception(); } }
/// <summary> /// Creates a new <see cref="SecureStreamClientIntegratedSecurity"/> /// </summary> public SecureStreamClientIntegratedSecurity(string username, string password, string domain) { m_client = new IntegratedSecurityClient(username, password, domain); }
/// <summary> /// Creates a new <see cref="SecureStreamClientIntegratedSecurity"/> /// </summary> public SecureStreamClientIntegratedSecurity() { m_client = new IntegratedSecurityClient(); }