System.Security.AccessControl.DiscretionaryAcl.RemoveAccess Method

Removes the specified access control rule from the current System.Security.AccessControl.DiscretionaryAcl object.

Syntax

public bool RemoveAccess (AccessControlType accessType, System.Security.Principal.SecurityIdentifier sid, int accessMask, InheritanceFlags inheritanceFlags, PropagationFlags propagationFlags)

Parameters

accessType
The type of access control (allow or deny) to remove.
sid
The System.Security.Principal.SecurityIdentifier for which to remove an access control rule.
accessMask
The access mask for the rule to be removed.
inheritanceFlags
Flags that specify the inheritance properties of the rule to be removed.
propagationFlags
Flags that specify the inheritance propagation properties for the rule to be removed.

Returns

true if this method successfully removes the specified access; otherwise, false.

Remarks

Access removal is accomplished by using a complex algorithm that might add Access Control Entries (ACEs) in addition to removing them.

Requirements

Namespace: System.Security.AccessControl
Assembly: mscorlib (in mscorlib.dll)
Assembly Versions: 2.0.0.0, 4.0.0.0
Since: .NET 2.0