using System;
using System.Collections.Generic;
namespace System.Security.AccessControl
{
/// Controls access to objects without direct manipulation of access control lists (ACLs). This class is the abstract base class for the class.
// Token: 0x020004B0 RID: 1200
[MonoTODO("required for NativeObjectSecurity - implementation is missing")]
public abstract class CommonObjectSecurity : ObjectSecurity
{
/// Initializes a new instance of the class.
/// true if the new object is a container object.
// Token: 0x06002CCC RID: 11468 RVA: 0x000930AC File Offset: 0x000912AC
protected CommonObjectSecurity(bool isContainer)
: base(isContainer, false)
{
}
/// Gets a collection of the access rules associated with the specified security identifier.
/// The collection of access rules associated with the specified object.
/// true to include access rules explicitly set for the object.
/// true to include inherited access rules.
/// Specifies whether the security identifier for which to retrieve access rules is of type T:System.Security.Principal.SecurityIdentifier or type T:System.Security.Principal.NTAccount. The value of this parameter must be a type that can be translated to the type.
///
///
///
// Token: 0x06002CCD RID: 11469 RVA: 0x000930CC File Offset: 0x000912CC
public AuthorizationRuleCollection GetAccessRules(bool includeExplicit, bool includeInherited, Type targetType)
{
throw new NotImplementedException();
}
/// Gets a collection of the audit rules associated with the specified security identifier.
/// The collection of audit rules associated with the specified object.
/// true to include audit rules explicitly set for the object.
/// true to include inherited audit rules.
/// The security identifier for which to retrieve audit rules. This must be an object that can be cast as a object.
///
///
///
// Token: 0x06002CCE RID: 11470 RVA: 0x000930D4 File Offset: 0x000912D4
public AuthorizationRuleCollection GetAuditRules(bool includeExplicit, bool includeInherited, Type targetType)
{
throw new NotImplementedException();
}
/// Adds the specified access rule to the Discretionary Access Control List (DACL) associated with this object.
/// The access rule to add.
// Token: 0x06002CCF RID: 11471 RVA: 0x000930DC File Offset: 0x000912DC
protected void AddAccessRule(AccessRule rule)
{
this.access_rules.Add(rule);
base.AccessRulesModified = true;
}
/// Removes access rules that contain the same security identifier and access mask as the specified access rule from the Discretionary Access Control List (DACL) associated with this object.
/// true if the access rule was successfully removed; otherwise, false.
/// The access rule to remove.
// Token: 0x06002CD0 RID: 11472 RVA: 0x000930F4 File Offset: 0x000912F4
protected bool RemoveAccessRule(AccessRule rule)
{
throw new NotImplementedException();
}
/// Removes all access rules that have the same security identifier as the specified access rule from the Discretionary Access Control List (DACL) associated with this object.
/// The access rule to remove.
// Token: 0x06002CD1 RID: 11473 RVA: 0x000930FC File Offset: 0x000912FC
protected void RemoveAccessRuleAll(AccessRule rule)
{
throw new NotImplementedException();
}
/// Removes all access rules that exactly match the specified access rule from the Discretionary Access Control List (DACL) associated with this object.
/// The access rule to remove.
// Token: 0x06002CD2 RID: 11474 RVA: 0x00093104 File Offset: 0x00091304
protected void RemoveAccessRuleSpecific(AccessRule rule)
{
throw new NotImplementedException();
}
/// Removes all access rules in the Discretionary Access Control List (DACL) associated with this object and then adds the specified access rule.
/// The access rule to reset.
// Token: 0x06002CD3 RID: 11475 RVA: 0x0009310C File Offset: 0x0009130C
protected void ResetAccessRule(AccessRule rule)
{
throw new NotImplementedException();
}
/// Removes all access rules that contain the same security identifier and qualifier as the specified access rule in the Discretionary Access Control List (DACL) associated with this object and then adds the specified access rule.
/// The access rule to set.
// Token: 0x06002CD4 RID: 11476 RVA: 0x00093114 File Offset: 0x00091314
protected void SetAccessRule(AccessRule rule)
{
throw new NotImplementedException();
}
/// Applies the specified modification to the Discretionary Access Control List (DACL) associated with this object.
/// true if the DACL is successfully modified; otherwise, false.
/// The modification to apply to the DACL.
/// The access rule to modify.
/// true if the DACL is successfully modified; otherwise, false.
// Token: 0x06002CD5 RID: 11477 RVA: 0x0009311C File Offset: 0x0009131C
protected override bool ModifyAccess(AccessControlModification modification, AccessRule rule, out bool modified)
{
foreach (AccessRule accessRule in this.access_rules)
{
if (rule == accessRule)
{
switch (modification)
{
case AccessControlModification.Add:
this.AddAccessRule(rule);
break;
case AccessControlModification.Set:
this.SetAccessRule(rule);
break;
case AccessControlModification.Reset:
this.ResetAccessRule(rule);
break;
case AccessControlModification.Remove:
this.RemoveAccessRule(rule);
break;
case AccessControlModification.RemoveAll:
this.RemoveAccessRuleAll(rule);
break;
case AccessControlModification.RemoveSpecific:
this.RemoveAccessRuleSpecific(rule);
break;
}
modified = true;
return true;
}
}
modified = false;
return false;
}
/// Adds the specified audit rule to the System Access Control List (SACL) associated with this object.
/// The audit rule to add.
// Token: 0x06002CD6 RID: 11478 RVA: 0x00093208 File Offset: 0x00091408
protected void AddAuditRule(AuditRule rule)
{
this.audit_rules.Add(rule);
base.AuditRulesModified = true;
}
/// Removes audit rules that contain the same security identifier and access mask as the specified audit rule from the System Access Control List (SACL) associated with this object.
/// true if the audit rule was successfully removed; otherwise, false.
/// The audit rule to remove.
// Token: 0x06002CD7 RID: 11479 RVA: 0x00093220 File Offset: 0x00091420
protected bool RemoveAuditRule(AuditRule rule)
{
throw new NotImplementedException();
}
/// Removes all audit rules that have the same security identifier as the specified audit rule from the System Access Control List (SACL) associated with this object.
/// The audit rule to remove.
// Token: 0x06002CD8 RID: 11480 RVA: 0x00093228 File Offset: 0x00091428
protected void RemoveAuditRuleAll(AuditRule rule)
{
throw new NotImplementedException();
}
/// Removes all audit rules that exactly match the specified audit rule from the System Access Control List (SACL) associated with this object.
/// The audit rule to remove.
// Token: 0x06002CD9 RID: 11481 RVA: 0x00093230 File Offset: 0x00091430
protected void RemoveAuditRuleSpecific(AuditRule rule)
{
throw new NotImplementedException();
}
/// Removes all audit rules that contain the same security identifier and qualifier as the specified audit rule in the System Access Control List (SACL) associated with this object and then adds the specified audit rule.
/// The audit rule to set.
// Token: 0x06002CDA RID: 11482 RVA: 0x00093238 File Offset: 0x00091438
protected void SetAuditRule(AuditRule rule)
{
throw new NotImplementedException();
}
/// Applies the specified modification to the System Access Control List (SACL) associated with this object.
/// true if the SACL is successfully modified; otherwise, false.
/// The modification to apply to the SACL.
/// The audit rule to modify.
/// true if the SACL is successfully modified; otherwise, false.
// Token: 0x06002CDB RID: 11483 RVA: 0x00093240 File Offset: 0x00091440
protected override bool ModifyAudit(AccessControlModification modification, AuditRule rule, out bool modified)
{
foreach (AuditRule auditRule in this.audit_rules)
{
if (rule == auditRule)
{
switch (modification)
{
case AccessControlModification.Add:
this.AddAuditRule(rule);
break;
case AccessControlModification.Set:
this.SetAuditRule(rule);
break;
case AccessControlModification.Remove:
this.RemoveAuditRule(rule);
break;
case AccessControlModification.RemoveAll:
this.RemoveAuditRuleAll(rule);
break;
case AccessControlModification.RemoveSpecific:
this.RemoveAuditRuleSpecific(rule);
break;
}
base.AuditRulesModified = true;
modified = true;
return true;
}
}
modified = false;
return false;
}
// Token: 0x040011A1 RID: 4513
private List access_rules = new List();
// Token: 0x040011A2 RID: 4514
private List audit_rules = new List();
}
}