Esempio n. 1
0
        public async Task <AuthorizationResult> AuthorizeAsync(ClaimsPrincipal user, object resource, IEnumerable <IAuthorizationRequirement> requirements)
        {
            _logger.LogDebug($"Before {nameof(AuthorizeAsync)} 1");
            var context = _contextFactory.CreateContext(requirements, user, resource);
            var result  = await _defaultAuthorizationService.AuthorizeAsync(user, resource, requirements);

            _logger.LogDebug($"After {nameof(AuthorizeAsync)} 1");
            return(result);
        }
 public Task <AuthorizationResult> AuthorizeAsync(ClaimsPrincipal user, object resource, IEnumerable <IAuthorizationRequirement> requirements) => _defaultAuthorizationService.AuthorizeAsync(user, resource, requirements);