public class QuickIOFileSystemSecurity
Provides methods for accessing the security information of files and folders, such as for example the getting and setting of the owner.
QuickIOFileSystemSecurity(QuickIOPathInfo pathInfo)
Creates new instance of QuickIOFileSystemSecurity for specified path. Current Windows Identtiy is used.
public void QuickIOFileSystemSecurity(QuickIOPathInfo pathInfo)
Parameters
pathInfo
QuickIOPathInfoQuickIOFileSystemSecurity(QuickIOPathInfo pathInfo, WindowsIdentity principal)
Supply the path to the file or directory and a user or group. Access checks are done during instantiation to ensure we always have a valid object
public void QuickIOFileSystemSecurity(QuickIOPathInfo pathInfo, WindowsIdentity principal)
Parameters
pathInfo
QuickIOPathInfoprincipal
WindowsIdentityContains(FileSystemRights right, FileSystemAccessRule rule)
Returs the if right is in
public Boolean Contains(FileSystemRights right, FileSystemAccessRule rule)
GetSecurityFromFileSystem()
Get the File Information and set's the result to FileSystemSecurityInformation on success. Also set's owner and owner's domain
private void GetSecurityFromFileSystem()
Returns
true on success. Use native win32 exception to get further error information
HandleAccessControlType(FileSystemAccessRule rule)
Handles the access rights. Differentiates between allowed and denied rights
private void HandleAccessControlType(FileSystemAccessRule rule)
HandleAllowedAccessRule(FileSystemAccessRule rule)
Processed the permitted rights
private void HandleAllowedAccessRule(FileSystemAccessRule rule)
HandleDeniedAccessRule(FileSystemAccessRule rule)
Processed the denied rights
private void HandleDeniedAccessRule(FileSystemAccessRule rule)
HandleFileSystemAccessRule(FileSystemAccessRule rule, IdentityReference identity)
Processes the authentication data of a Windows identity
private void HandleFileSystemAccessRule(FileSystemAccessRule rule, IdentityReference identity)
Parameters
rule
FileSystemAccessRuleFileSystemAccessRule
identity
IdentityReferenceReadSecurityInformation()
Reads the security information of FileSystemSecurityInformation
private void ReadSecurityInformation()
ReceiveFileSystemSecurityInformation(IntPtr& sidHandle)
Gets the security information of specified handle from file system
private CommonObjectSecurity ReceiveFileSystemSecurityInformation(IntPtr& sidHandle)
Parameters
sidHandle
IntPtr&Handle to get file security information
Returns
CommonObjectSecurityResult
ReceiveUserIdentityRules(AuthorizationRuleCollection acl)
Processes the authentication data of a Windows user
private void ReceiveUserIdentityRules(AuthorizationRuleCollection acl)
Parameters
acl
AuthorizationRuleCollectionAuthorizationRuleCollection
ReceivGroupIdentityRules(AuthorizationRuleCollection acl)
Processes the authentication data of a Windows Group
private void ReceivGroupIdentityRules(AuthorizationRuleCollection acl)
Parameters
acl
AuthorizationRuleCollectionAuthorizationRuleCollection
Refresh()
Refreshes the Information
public void Refresh()
CanAppendData
Ermittelt, ob etwas hinzugefügt werden kann (Dateien)
public Boolean CanAppendData { get; }
CanChangePermissions
Ermittelt, ob die Rechte verändert werden dürfen
public Boolean CanChangePermissions { get; }
CanCreateDirectories
Ermittelt, ob neue Ordner hinzugefügt werden dürfen (Ordner)
public Boolean CanCreateDirectories { get; }
CanCreateFiles
Ermittelt, ob neue Dateien hinzugefügt werden dürfen (Ordner)
public Boolean CanCreateFiles { get; }
CanDelete
Ermittelt, ob etwas gelöscht werden darf (Ordner)
public Boolean CanDelete { get; }
CanDeleteSubdirectoriesAndFiles
Ermittelt, ob darunterliegende Ordner und Dateien gelöscht werden dürfen (Ordner)
public Boolean CanDeleteSubdirectoriesAndFiles { get; }
CanExecuteFile
Ermittelt, ob eine Datei ausgeführt werden darf (Dateien)
public Boolean CanExecuteFile { get; }
CanFullControl
Ermittelt, ob die vollständige Kontrolle gewährt ist
public Boolean CanFullControl { get; }
CanListDirectory
Ermittelt, ob die Ordner aufgelistet werden dürfen (Ordner)
public Boolean CanListDirectory { get; }
CanModify
Ermittelt, ob etwas verändert werden darf
public Boolean CanModify { get; }
CanRead
Ermittelt, ob etwas gelesen werden darf
public Boolean CanRead { get; }
CanReadAndExecute
Ermittelt, ob gelesen und ausgeführt werden darf
public Boolean CanReadAndExecute { get; }
CanReadAttributes
Ermittelt, ob die Attribute gelesen werden dürfen
public Boolean CanReadAttributes { get; }
CanReadData
Ermittelt, ob Daten gelesen werden dürfen
public Boolean CanReadData { get; }
CanReadExtendedAttributes
Ermittelt, ob die erweiterten Attribute gelesen werden dürfen
public Boolean CanReadExtendedAttributes { get; }
CanReadPermissions
Ermittelt, ob die Rechte gelesen werden dürfen
public Boolean CanReadPermissions { get; }
CanSynchronize
Ermittelt, ob synchronisiert werden darf
public Boolean CanSynchronize { get; }
CanTakeOwnership
Ermittelt, ob der Besitzerstatus eingenommen werden darf
public Boolean CanTakeOwnership { get; }
CanTraverse
Ermittelt, ob ???????
public Boolean CanTraverse { get; }
CanWrite
Ermittelt, ob geschrieben werden darf
public Boolean CanWrite { get; }
CanWriteAttributes
Ermittelt, ob Attribute verändert werden dürfen
public Boolean CanWriteAttributes { get; }
CanWriteData
Ermittelt, ob Daten geschrieben werden dürfen
public Boolean CanWriteData { get; }
CanWriteExtendedAttributes
Ermittelt, ob erweiterte Attribute geschrieben werden dürfen
public Boolean CanWriteExtendedAttributes { get; }
FileSystemSecurityInformation
File System Security Information
public CommonObjectSecurity FileSystemSecurityInformation { get; set; }
IsAllowedAppendData
Returns true if specified right level is explizit allowed
public Boolean IsAllowedAppendData { get; set; }
IsAllowedChangePermissions
Returns true if specified right level is explizit allowed
public Boolean IsAllowedChangePermissions { get; set; }
IsAllowedCreateDirectories
Returns true if specified right level is explizit allowed
public Boolean IsAllowedCreateDirectories { get; set; }
IsAllowedCreateFiles
Returns true if specified right level is explizit allowed
public Boolean IsAllowedCreateFiles { get; set; }
IsAllowedDelete
Returns true if specified right level is explizit allowed
public Boolean IsAllowedDelete { get; set; }
IsAllowedDeleteSubdirectoriesAndFiles
Returns true if specified right level is explizit allowed
public Boolean IsAllowedDeleteSubdirectoriesAndFiles { get; set; }
IsAllowedExecuteFile
Returns true if specified right level is explizit allowed
public Boolean IsAllowedExecuteFile { get; set; }
IsAllowedFullControl
Returns true if specified right level is explizit allowed
public Boolean IsAllowedFullControl { get; set; }
IsAllowedListDirectory
Returns true if specified right level is explizit allowed
public Boolean IsAllowedListDirectory { get; set; }
IsAllowedModify
Returns true if specified right level is explizit allowed
public Boolean IsAllowedModify { get; set; }
IsAllowedRead
Returns true if specified right level is explizit allowed
public Boolean IsAllowedRead { get; set; }
IsAllowedReadAndExecute
Returns true if specified right level is explizit allowed
public Boolean IsAllowedReadAndExecute { get; set; }
IsAllowedReadAttributes
Returns true if specified right level is explizit allowed
public Boolean IsAllowedReadAttributes { get; set; }
IsAllowedReadData
Returns true if specified right level is explizit allowed
public Boolean IsAllowedReadData { get; set; }
IsAllowedReadExtendedAttributes
Returns true if specified right level is explizit allowed
public Boolean IsAllowedReadExtendedAttributes { get; set; }
IsAllowedReadPermissions
Returns true if specified right level is explizit allowed
public Boolean IsAllowedReadPermissions { get; set; }
IsAllowedSynchronize
Returns true if specified right level is explizit allowed
public Boolean IsAllowedSynchronize { get; set; }
IsAllowedTakeOwnership
Returns true if specified right level is explizit allowed
public Boolean IsAllowedTakeOwnership { get; set; }
IsAllowedTraverse
Returns true if specified right level is explizit allowed
public Boolean IsAllowedTraverse { get; set; }
IsAllowedWrite
Returns true if specified right level is explizit allowed
public Boolean IsAllowedWrite { get; set; }
IsAllowedWriteAttributes
Returns true if specified right level is explizit allowed
public Boolean IsAllowedWriteAttributes { get; set; }
IsAllowedWriteData
Returns true if specified right level is explizit allowed
public Boolean IsAllowedWriteData { get; set; }
IsAllowedWriteExtendedAttributes
Returns true if specified right level is explizit allowed
public Boolean IsAllowedWriteExtendedAttributes { get; set; }
IsDeniedAppendData
Returns true if specified right level is denied
public Boolean IsDeniedAppendData { get; set; }
IsDeniedChangePermissions
Returns true if specified right level is denied
public Boolean IsDeniedChangePermissions { get; set; }
IsDeniedCreateDirectories
Returns true if specified right level is denied
public Boolean IsDeniedCreateDirectories { get; set; }
IsDeniedCreateFiles
Returns true if specified right level is denied
public Boolean IsDeniedCreateFiles { get; set; }
IsDeniedDelete
Returns true if specified right level is denied
public Boolean IsDeniedDelete { get; set; }
IsDeniedDeleteSubdirectoriesAndFiles
Returns true if specified right level is denied
public Boolean IsDeniedDeleteSubdirectoriesAndFiles { get; set; }
IsDeniedExecuteFile
Returns true if specified right level is denied
public Boolean IsDeniedExecuteFile { get; set; }
IsDeniedFullControl
Returns true if specified right level is denied
public Boolean IsDeniedFullControl { get; set; }
IsDeniedListDirectory
Returns true if specified right level is denied
public Boolean IsDeniedListDirectory { get; set; }
IsDeniedModify
Returns true if specified right level is denied
public Boolean IsDeniedModify { get; set; }
IsDeniedRead
Returns true if specified right level is denied
public Boolean IsDeniedRead { get; set; }
IsDeniedReadAndExecute
Returns true if specified right level is denied
public Boolean IsDeniedReadAndExecute { get; set; }
IsDeniedReadAttributes
Returns true if specified right level is denied
public Boolean IsDeniedReadAttributes { get; set; }
IsDeniedReadData
Returns true if specified right level is denied
public Boolean IsDeniedReadData { get; set; }
IsDeniedReadExtendedAttributes
Returns true if specified right level is denied
public Boolean IsDeniedReadExtendedAttributes { get; set; }
IsDeniedReadPermissions
Returns true if specified right level is denied
public Boolean IsDeniedReadPermissions { get; set; }
IsDeniedSynchronize
Returns true if specified right level is denied
public Boolean IsDeniedSynchronize { get; set; }
IsDeniedTakeOwnership
Returns true if specified right level is denied
public Boolean IsDeniedTakeOwnership { get; set; }
IsDeniedTraverse
Returns true if specified right level is denied
public Boolean IsDeniedTraverse { get; set; }
IsDeniedWrite
Returns true if specified right level is denied
public Boolean IsDeniedWrite { get; set; }
IsDeniedWriteAttributes
Returns true if specified right level is denied
public Boolean IsDeniedWriteAttributes { get; set; }
IsDeniedWriteData
Returns true if specified right level is denied
public Boolean IsDeniedWriteData { get; set; }
IsDeniedWriteExtendedAttributes
Returns true if specified right level is denied
public Boolean IsDeniedWriteExtendedAttributes { get; set; }
PathInfo
Affected path
public QuickIOPathInfo PathInfo { get; set; }
WindowsIdentity
Affected Windows IDentity
public WindowsIdentity WindowsIdentity { get; set; }