SystemAcl.AddAudit Method

Definition

Adds an audit rule to the current SystemAcl object.

Overloads

AddAudit(SecurityIdentifier, ObjectAuditRule)

Adds an audit rule to the current SystemAcl object.

AddAudit(AuditFlags, SecurityIdentifier, Int32, InheritanceFlags, PropagationFlags)

Adds an audit rule to the current SystemAcl object.

AddAudit(AuditFlags, SecurityIdentifier, Int32, InheritanceFlags, PropagationFlags, ObjectAceFlags, Guid, Guid)

Adds an audit rule with the specified settings to the current SystemAcl object. Use this method for directory object Access Control Lists (ACLs) when specifying the object type or the inherited object type for the new audit rule.

Remarks

Adding an audit rule might cause one or more existing Access Control Entries (ACEs) to be combined.

AddAudit(SecurityIdentifier, ObjectAuditRule)

Source:
ACL.cs

Adds an audit rule to the current SystemAcl object.

C#
public void AddAudit(System.Security.Principal.SecurityIdentifier sid, System.Security.AccessControl.ObjectAuditRule rule);

Parameters

sid
SecurityIdentifier

The SecurityIdentifier for which to add an audit rule.

rule
ObjectAuditRule

The ObjectAuditRule for the new audit rule.

Remarks

Adding an audit rule might cause one or more existing Access Control Entries (ACEs) to be combined.

Applies to

.NET 10 ja muud versioonid
Toode Versioonid
.NET Core 1.0, Core 1.1, 6 (package-provided), 6, 7 (package-provided), 7, 8 (package-provided), 8, 9 (package-provided), 9, 10 (package-provided), 10
.NET Framework 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1
.NET Standard 2.0 (package-provided)
Windows Desktop 3.0, 3.1, 5

AddAudit(AuditFlags, SecurityIdentifier, Int32, InheritanceFlags, PropagationFlags)

Source:
ACL.cs

Adds an audit rule to the current SystemAcl object.

C#
public void AddAudit(System.Security.AccessControl.AuditFlags auditFlags, System.Security.Principal.SecurityIdentifier sid, int accessMask, System.Security.AccessControl.InheritanceFlags inheritanceFlags, System.Security.AccessControl.PropagationFlags propagationFlags);

Parameters

auditFlags
AuditFlags

The type of audit rule to add.

sid
SecurityIdentifier

The SecurityIdentifier for which to add an audit rule.

accessMask
Int32

The access mask for the new audit rule.

inheritanceFlags
InheritanceFlags

Flags that specify the inheritance properties of the new audit rule.

propagationFlags
PropagationFlags

Flags that specify the inheritance propagation properties for the new audit rule.

Remarks

Adding an audit rule might cause one or more existing Access Control Entries (ACEs) to be combined.

Applies to

.NET 10 ja muud versioonid
Toode Versioonid
.NET Core 1.0, Core 1.1, 6 (package-provided), 6, 7 (package-provided), 7, 8 (package-provided), 8, 9 (package-provided), 9, 10 (package-provided), 10
.NET Framework 2.0, 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1
.NET Standard 2.0 (package-provided)
Windows Desktop 3.0, 3.1, 5

AddAudit(AuditFlags, SecurityIdentifier, Int32, InheritanceFlags, PropagationFlags, ObjectAceFlags, Guid, Guid)

Source:
ACL.cs

Adds an audit rule with the specified settings to the current SystemAcl object. Use this method for directory object Access Control Lists (ACLs) when specifying the object type or the inherited object type for the new audit rule.

C#
public void AddAudit(System.Security.AccessControl.AuditFlags auditFlags, System.Security.Principal.SecurityIdentifier sid, int accessMask, System.Security.AccessControl.InheritanceFlags inheritanceFlags, System.Security.AccessControl.PropagationFlags propagationFlags, System.Security.AccessControl.ObjectAceFlags objectFlags, Guid objectType, Guid inheritedObjectType);

Parameters

auditFlags
AuditFlags

The type of audit rule to add.

sid
SecurityIdentifier

The SecurityIdentifier for which to add an audit rule.

accessMask
Int32

The access mask for the new audit rule.

inheritanceFlags
InheritanceFlags

Flags that specify the inheritance properties of the new audit rule.

propagationFlags
PropagationFlags

Flags that specify the inheritance propagation properties for the new audit rule.

objectFlags
ObjectAceFlags

Flags that specify if the objectType and inheritedObjectType parameters contain non-null values.

objectType
Guid

The identity of the class of objects to which the new audit rule applies.

inheritedObjectType
Guid

The identity of the class of child objects which can inherit the new audit rule.

Applies to

.NET 10 ja muud versioonid
Toode Versioonid
.NET Core 1.0, Core 1.1, 6 (package-provided), 6, 7 (package-provided), 7, 8 (package-provided), 8, 9 (package-provided), 9, 10 (package-provided), 10
.NET Framework 2.0, 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1
.NET Standard 2.0 (package-provided)
Windows Desktop 3.0, 3.1, 5