Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches
System.Security.AccessControl.FileSecurity Class Referencesealed

Public Member Functions

 FileSecurity ()
 
 FileSecurity (string fileName, AccessControlSections includeSections)
 
override AccessRule AccessRuleFactory (IdentityReference identityReference, int accessMask, bool isInherited, InheritanceFlags inheritanceFlags, PropagationFlags propagationFlags, AccessControlType type)
 
override AuditRule AuditRuleFactory (IdentityReference identityReference, int accessMask, bool isInherited, InheritanceFlags inheritanceFlags, PropagationFlags propagationFlags, AuditFlags flags)
 
void AddAccessRule (FileSystemAccessRule rule)
 
virtual void AddAccessRule (AccessRule< T > rule)
 
void SetAccessRule (FileSystemAccessRule rule)
 
virtual void SetAccessRule (AccessRule< T > rule)
 
void ResetAccessRule (FileSystemAccessRule rule)
 
virtual void ResetAccessRule (AccessRule< T > rule)
 
bool RemoveAccessRule (FileSystemAccessRule rule)
 
virtual bool RemoveAccessRule (AccessRule< T > rule)
 
void RemoveAccessRuleAll (FileSystemAccessRule rule)
 
virtual void RemoveAccessRuleAll (AccessRule< T > rule)
 
void RemoveAccessRuleSpecific (FileSystemAccessRule rule)
 
virtual void RemoveAccessRuleSpecific (AccessRule< T > rule)
 
void AddAuditRule (FileSystemAuditRule rule)
 
virtual void AddAuditRule (AuditRule< T > rule)
 
void SetAuditRule (FileSystemAuditRule rule)
 
virtual void SetAuditRule (AuditRule< T > rule)
 
bool RemoveAuditRule (FileSystemAuditRule rule)
 
virtual bool RemoveAuditRule (AuditRule< T > rule)
 
void RemoveAuditRuleAll (FileSystemAuditRule rule)
 
virtual void RemoveAuditRuleAll (AuditRule< T > rule)
 
void RemoveAuditRuleSpecific (FileSystemAuditRule rule)
 
virtual void RemoveAuditRuleSpecific (AuditRule< T > rule)
 
AuthorizationRuleCollection GetAccessRules (bool includeExplicit, bool includeInherited, Type targetType)
 
AuthorizationRuleCollection GetAuditRules (bool includeExplicit, bool includeInherited, Type targetType)
 
IdentityReferenceGetOwner (Type targetType)
 
void SetOwner (IdentityReference identity)
 
IdentityReferenceGetGroup (Type targetType)
 
void SetGroup (IdentityReference identity)
 
virtual void PurgeAccessRules (IdentityReference identity)
 
virtual void PurgeAuditRules (IdentityReference identity)
 
void SetAccessRuleProtection (bool isProtected, bool preserveInheritance)
 
void SetAuditRuleProtection (bool isProtected, bool preserveInheritance)
 
string GetSecurityDescriptorSddlForm (AccessControlSections includeSections)
 
void SetSecurityDescriptorSddlForm (string sddlForm)
 
void SetSecurityDescriptorSddlForm (string sddlForm, AccessControlSections includeSections)
 
byte[] GetSecurityDescriptorBinaryForm ()
 
void SetSecurityDescriptorBinaryForm (byte[] binaryForm)
 
void SetSecurityDescriptorBinaryForm (byte[] binaryForm, AccessControlSections includeSections)
 
virtual bool ModifyAccessRule (AccessControlModification modification, AccessRule rule, out bool modified)
 
virtual bool ModifyAuditRule (AccessControlModification modification, AuditRule rule, out bool modified)
 

Static Public Member Functions

static bool IsSddlConversionSupported ()
 

Protected Member Functions

override void Persist (string name, AccessControlSections includeSections)
 
void Persist (string name, AccessControlSections includeSections, object? exceptionContext)
 
override void Persist (SafeHandle handle, AccessControlSections includeSections)
 
void Persist (SafeHandle handle, AccessControlSections includeSections, object? exceptionContext)
 
virtual void Persist (bool enableOwnershipPrivilege, string name, AccessControlSections includeSections)
 
void AddAccessRule (AccessRule rule)
 
void SetAccessRule (AccessRule rule)
 
void ResetAccessRule (AccessRule rule)
 
bool RemoveAccessRule (AccessRule rule)
 
void RemoveAccessRuleAll (AccessRule rule)
 
void RemoveAccessRuleSpecific (AccessRule rule)
 
void AddAuditRule (AuditRule rule)
 
void SetAuditRule (AuditRule rule)
 
bool RemoveAuditRule (AuditRule rule)
 
void RemoveAuditRuleAll (AuditRule rule)
 
void RemoveAuditRuleSpecific (AuditRule rule)
 
override bool ModifyAccess (AccessControlModification modification, AccessRule rule, out bool modified)
 
override bool ModifyAudit (AccessControlModification modification, AuditRule rule, out bool modified)
 
void ReadLock ()
 
void ReadUnlock ()
 
void WriteLock ()
 
void WriteUnlock ()
 

Package Functions

 FileSecurity (SafeFileHandle handle, AccessControlSections includeSections)
 
AccessControlSections GetAccessControlSectionsFromChanges ()
 
void Persist (string fullPath)
 
void Persist (SafeFileHandle handle, string fullPath)
 
void Persist (SafeHandle handle)
 
delegate? Exception ExceptionFromErrorCode (int errorCode, string? name, SafeHandle? handle, object? context)
 

Package Attributes

readonly CommonSecurityDescriptor _securityDescriptor
 

Properties

override Type AccessRightType [get]
 
override Type AccessRuleType [get]
 
override Type AuditRuleType [get]
 
CommonSecurityDescriptor SecurityDescriptor [get]
 
bool OwnerModified [get, set]
 
bool GroupModified [get, set]
 
bool AuditRulesModified [get, set]
 
bool AccessRulesModified [get, set]
 
bool IsContainer [get]
 
bool IsDS [get]
 
bool AreAccessRulesProtected [get]
 
bool AreAuditRulesProtected [get]
 
bool AreAccessRulesCanonical [get]
 
bool AreAuditRulesCanonical [get]
 

Private Member Functions

AuthorizationRuleCollection GetRules (bool access, bool includeExplicit, bool includeInherited, Type targetType)
 
bool AceNeedsTranslation ([NotNullWhen(true)] CommonAce ace, bool isAccessAce, bool includeExplicit, bool includeInherited)
 
void UpdateWithNewSecurityDescriptor (RawSecurityDescriptor newOne, AccessControlSections includeSections)
 

Static Private Member Functions

static Exception _HandleErrorCode (int errorCode, string name, SafeHandle handle, object context)
 
static CommonSecurityDescriptor CreateInternal (ResourceType resourceType, bool isContainer, string name, SafeHandle handle, AccessControlSections includeSections, bool createByName, ExceptionFromErrorCode exceptionFromErrorCode, object exceptionContext)
 
static bool IsValidTargetTypeStatic (Type targetType)
 

Private Attributes

readonly ResourceType _resourceType
 
readonly ExceptionFromErrorCode _exceptionFromErrorCode
 
readonly object _exceptionContext
 
readonly uint ProtectedDiscretionaryAcl = 2147483648u
 
readonly uint ProtectedSystemAcl = 1073741824u
 
readonly uint UnprotectedDiscretionaryAcl = 536870912u
 
readonly uint UnprotectedSystemAcl = 268435456u
 
readonly ReaderWriterLockSlim _lock = new ReaderWriterLockSlim(LockRecursionPolicy.SupportsRecursion)
 
bool _ownerModified
 
bool _groupModified
 
bool _saclModified
 
bool _daclModified
 

Detailed Description

Definition at line 5 of file FileSecurity.cs.


The documentation for this class was generated from the following file: