static void Main(string[] args) { EventLogManager.InitializeCMSEventLog(); NetTcpBinding binding = new NetTcpBinding(); InitializeWindowsAuthentication(binding); ServiceHost host = new ServiceHost(typeof(CertificateManager)); SpecifyAuditingBehavior(host); if (ServerHosting(host, binding)) { Console.WriteLine("WCFService is started..."); RootCert rc = new RootCert(); Console.WriteLine("Enter root name: "); string root = Console.ReadLine(); rc.createRootCertificate(root); Console.WriteLine("Press <enter> to close server..."); } Console.ReadLine(); host.Close(); }