Exemplo n.º 1
0
        private IEnumerable <Claim> BuildClaims(HttpContext context)
        {
            // Make sticky mode required if detect using blazor
            var mode              = _blazorDetector.IsBlazor(_hubName) ? ServerStickyMode.Required : _mode;
            var userId            = _userIdProvider.GetUserId(new ServiceHubConnectionContext(context));
            var httpTransportType = _transportTypeDetector?.Invoke(context);

            return(ClaimsUtility.BuildJwtClaims(context.User, userId, GetClaimsProvider(context), _serverName, mode, _enableDetailedErrors, _endpointsCount, _maxPollInterval, IsDiagnosticClient(context), _customHandshakeTimeout, httpTransportType));
        }
Exemplo n.º 2
0
        private IEnumerable <Claim> BuildClaims(HttpContext context)
        {
            var userId = _userIdProvider.GetUserId(new ServiceHubConnectionContext(context));

            return(ClaimsUtility.BuildJwtClaims(context.User, userId, GetClaimsProvider(context), _serverName, _mode, _enableDetailedErrors, _endpointsCount).ToList());
        }
Exemplo n.º 3
0
        private IEnumerable <Claim> BuildClaims(HttpContext context)
        {
            var userId = _userIdProvider.GetUserId(new ServiceHubConnectionContext(context));

            return(ClaimsUtility.BuildJwtClaims(context.User, userId, GetClaimsProvider(context)).ToList());
        }