Exemplo n.º 1
0
 public SecurePipelineListener(PipelineFactory factory, CertificateList certificateList)
 {
     _factory             = factory;
     _serverNameProvider  = new ServerNameProvider();
     _keyscheduleProvider = new KeyScheduleProvider();
     _cryptoProvider      = new CryptoProvider();
     _resumptionProvider  = new ResumptionProvider(4, _cryptoProvider);
     _certificateList     = certificateList;
 }
Exemplo n.º 2
0
 public SecurePipeListener(PipeFactory factory, CertificateList certificateList, ILoggerFactory logFactory)
 {
     _logFactory          = logFactory;
     _logger              = logFactory?.CreateLogger <SecurePipeListener>();
     _connectionLogger    = logFactory?.CreateLogger <SecurePipelineConnection>();
     _factory             = factory;
     _serverNameProvider  = new ServerNameProvider();
     _keyscheduleProvider = new KeyScheduleProvider();
     _cryptoProvider      = new CryptoProvider(certificateList);
     _resumptionProvider  = new ResumptionProvider(4, _cryptoProvider);
     _certificateList     = certificateList;
 }
Exemplo n.º 3
0
        public IServiceConnection Create(HubServiceEndpoint endpoint, IServiceMessageHandler serviceMessageHandler,
                                         ServiceConnectionType type)
        {
            var connectionId = Guid.NewGuid().ToString("N");
            var connection   = new ServiceConnection(
                SharedServiceProtocol,
                this,
                ConnectionFactory,
                NullLoggerFactory.Instance,
                ConnectionDelegateCallback,
                this,
                ServerNameProvider.GetName(),
                connectionId,
                endpoint,
                serviceMessageHandler,
                type);

            ServiceConnections.TryAdd(connectionId, connection);
            return(connection);
        }