Exemplo n.º 1
0
 /// <summary>
 /// Initializes a new instance of <see cref="RoleRule"/>
 /// </summary>
 /// <param name="userToAuthorize">The <see cref="UserSecurityActor" /> to check the role against.</param>
 /// <param name="role">The role to check for</param>
 public RoleRule(IUserSecurityActor userToAuthorize, string role)
 {
     _userToAuthorize = userToAuthorize;
     Role             = role;
 }
Exemplo n.º 2
0
 /// <summary>
 /// Initializes a new instance of <see cref="RoleRule"/>
 /// </summary>
 /// <param name="userToAuthorize">The <see cref="UserSecurityActor" /> to check the role against.</param>
 /// <param name="role">The role to check for</param>
 public RoleRule(IUserSecurityActor userToAuthorize, string role)
 {
     _userToAuthorize = userToAuthorize;
     Role = role;
 }
Exemplo n.º 3
0
 /// <summary>
 /// Initializes a new instance of <see cref="RoleRule"/>
 /// </summary>
 /// <param name="userToAuthorize">The <see cref="UserSecurityActor" /> to check the role against.</param>
 /// <param name="claimType">The claim type to check for</param>
 /// <param name="value">The value of the claim to check for</param>
 public ClaimTypeAndValueRule(IUserSecurityActor userToAuthorize, string claimType, string value)
 {
     _userToAuthorize = userToAuthorize;
     ClaimType        = claimType;
     Value            = value;
 }
Exemplo n.º 4
0
 /// <summary>
 /// Initializes a new instance of the <see cref="ClaimTypeRule"/> class.
 /// </summary>
 /// <param name="userToAuthorize">The <see cref="UserSecurityActor" /> to check the role against.</param>
 /// <param name="claimType">The claim type to check for.</param>
 public ClaimTypeRule(IUserSecurityActor userToAuthorize, string claimType)
 {
     _userToAuthorize = userToAuthorize;
     ClaimType        = claimType;
 }