AuthorizationRule(IdentityReference, Int32, Boolean, InheritanceFlags, PropagationFlags) Constructor

Definition

Initializes a new instance of the AccessRule class by using the specified values.

protected public:
 AuthorizationRule(System::Security::Principal::IdentityReference ^ identity, int accessMask, bool isInherited, System::Security::AccessControl::InheritanceFlags inheritanceFlags, System::Security::AccessControl::PropagationFlags propagationFlags);
protected internal AuthorizationRule (System.Security.Principal.IdentityReference identity, int accessMask, bool isInherited, System.Security.AccessControl.InheritanceFlags inheritanceFlags, System.Security.AccessControl.PropagationFlags propagationFlags);
new System.Security.AccessControl.AuthorizationRule : System.Security.Principal.IdentityReference * int * bool * System.Security.AccessControl.InheritanceFlags * System.Security.AccessControl.PropagationFlags -> System.Security.AccessControl.AuthorizationRule

Parameters

identity
IdentityReference

The identity to which the access rule applies. This parameter must be an object that can be cast as a SecurityIdentifier.

accessMask
Int32

The access mask of this rule. The access mask is a 32-bit collection of anonymous bits, the meaning of which is defined by the individual integrators.

isInherited
Boolean

true to inherit this rule from a parent container.

inheritanceFlags
InheritanceFlags

The inheritance properties of the access rule.

propagationFlags
PropagationFlags

Whether inherited access rules are automatically propagated. The propagation flags are ignored if inheritanceFlags is set to None.

Exceptions

The value of the identity parameter cannot be cast as a SecurityIdentifier.

The value of the accessMask parameter is zero, or the inheritanceFlags or propagationFlags parameters contain unrecognized flag values.

Applies to