Skip to content
Permalink
Branch: master
Find file Copy path
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
19 lines (16 sloc) 714 Bytes
// www.craftedforeveryone.com
// Licensed under the MIT License. See LICENSE file in the project root for full license information.
using Microsoft.AspNetCore.Authorization;
namespace CustomAuthorizeAttribute.Approach2
{
//IAuthorizationRequirement is needed for creating AuthorizationHandler
//and also when dynalically creating policy, object are created only for requirement which inturn invokes the AuthorizationHandler
public class A2AuthorizePermissionRequirement: IAuthorizationRequirement
{
public string Permissions { get; private set; }
public A2AuthorizePermissionRequirement(string permissions)
{
Permissions = permissions;
}
}
}
You can’t perform that action at this time.