AuthorizeFilter Class

Definition

An implementation of IAsyncAuthorizationFilter which applies a specific AuthorizationPolicy. MVC recognizes the AuthorizeAttribute and adds an instance of this filter to the associated action or controller.

public ref class AuthorizeFilter : Microsoft::AspNetCore::Mvc::Filters::IAsyncAuthorizationFilter
public ref class AuthorizeFilter : Microsoft::AspNetCore::Mvc::Filters::IAsyncAuthorizationFilter, Microsoft::AspNetCore::Mvc::Filters::IFilterFactory
public class AuthorizeFilter : Microsoft.AspNetCore.Mvc.Filters.IAsyncAuthorizationFilter
public class AuthorizeFilter : Microsoft.AspNetCore.Mvc.Filters.IAsyncAuthorizationFilter, Microsoft.AspNetCore.Mvc.Filters.IFilterFactory
type AuthorizeFilter = class
    interface IAsyncAuthorizationFilter
    interface IFilterMetadata
type AuthorizeFilter = class
    interface IAsyncAuthorizationFilter
    interface IFilterMetadata
    interface IFilterFactory
Public Class AuthorizeFilter
Implements IAsyncAuthorizationFilter
Public Class AuthorizeFilter
Implements IAsyncAuthorizationFilter, IFilterFactory
Inheritance
AuthorizeFilter
Implements

Constructors

AuthorizeFilter()

Initializes a new AuthorizeFilter instance.

AuthorizeFilter(AuthorizationPolicy)

Initialize a new AuthorizeFilter instance.

AuthorizeFilter(IAuthorizationPolicyProvider, IEnumerable<IAuthorizeData>)

Initialize a new AuthorizeFilter instance.

AuthorizeFilter(IEnumerable<IAuthorizeData>)

Initializes a new instance of AuthorizeFilter.

AuthorizeFilter(String)

Initializes a new instance of AuthorizeFilter.

Properties

AuthorizeData

The IAuthorizeData to combine into an IAuthorizeData.

Policy

Gets the authorization policy to be used.

PolicyProvider

The IAuthorizationPolicyProvider to use to resolve policy names.

Methods

OnAuthorizationAsync(AuthorizationFilterContext)

Explicit Interface Implementations

IFilterFactory.CreateInstance(IServiceProvider)
IFilterFactory.IsReusable

Applies to