コード例 #1
0
        public Server(int port)
        {
            this.port    = port;
            activeTasks  = new List <Task>();
            usersHandler = new OnlineUsersHandler();
            isStarted    = false;

            try
            {
                certificate = SslTools.CreateCertificate(typeof(Server), "Server.Certificate.cert.pfx");
            }
            catch (CertificateException e)
            {
                log.Error("Can't create certificate. Server will not start.", e);
            }
        }
コード例 #2
0
ファイル: Server.cs プロジェクト: pr3sto/CryptoMessenger
		public Server(int port)
		{
			this.port = port;
			activeTasks = new List<Task>();
			usersHandler = new OnlineUsersHandler();
			isStarted = false;

			try
			{
				certificate = SslTools.CreateCertificate(typeof(Server), "Server.Certificate.cert.pfx");
			}
			catch (CertificateException e)
			{
				log.Info("Can't create certificate. Server will not start.");
				log.Error(e);
			}
		}