示例#1
0
 void IFeatureCache.CheckFeaturesRevision()
 {
     if (_cachedFeaturesRevision != _features.Revision)
     {
         _connection             = null;
         _tlsConnection          = null;
         _cachedFeaturesRevision = _features.Revision;
     }
 }
 void IFeatureCache.CheckFeaturesRevision()
 {
     if (_cachedFeaturesRevision != _features.Revision)
     {
         _connection = null;
         _tlsConnection = null;
         _cachedFeaturesRevision = _features.Revision;
     }
 }
示例#3
0
        public ClientEnvironment(IHttpContextAccessor httpContextAccessor)
        {
            Guard.ArgumentNotNull(httpContextAccessor, nameof(httpContextAccessor));

            var connectionFeature = httpContextAccessor.HttpContext.Features.Get <IHttpConnectionFeature>();

            _clientCertificateFeature = httpContextAccessor.HttpContext.Features.Get <ITlsConnectionFeature>();
            if (connectionFeature != null)
            {
                this.IpAddress = connectionFeature.RemoteIpAddress;
                this.Port      = connectionFeature.RemotePort;
            }
        }
 public ClientCertBufferingFeature(ITlsConnectionFeature tlsFeature, HttpContext context)
 {
     _tlsFeature = tlsFeature;
     _context    = context;
 }