public override void SetSecurity(string relative_path, GenericObjectSecurity obj_security) { using (var key = Open(relative_path, KeyAccessRights.WriteDac, false)) { if (!key.IsSuccess) { throw new NtException(NtStatus.STATUS_OBJECT_NAME_NOT_FOUND); } obj_security.PersistHandle(key.Result.Handle); } }
public override void SetSecurity(string relative_path, GenericObjectSecurity obj_security) { var dir_info = _dir.GetDirectoryEntry(relative_path); if (dir_info == null) { throw new NtException(NtStatus.STATUS_OBJECT_NAME_NOT_FOUND); } using (NtObject obj = dir_info.Open(GenericAccessRights.WriteDac)) { obj_security.PersistHandle(obj.Handle); } }
public abstract void SetSecurity(string relative_path, GenericObjectSecurity obj_security);