feat(ui): complete Avalonia UI port with 7 main pages, tool settings & top MenuBar

This commit is contained in:
Richard
2026-08-10 10:48:34 +02:00
parent a0e18d2a57
commit b5bf97ae74
187 changed files with 20054 additions and 882 deletions
+8 -2
View File
@@ -1,5 +1,6 @@
using System.Text;
using System.Text.Json;
using ClawdDotNet.Core.Storage;
using ClawdDotNet.Core.Tools;
using FluentFTP;
using Microsoft.Extensions.Logging;
@@ -151,8 +152,13 @@ public sealed class FTPTool : IAgentTool
basePath = Path.GetFullPath(basePath);
var fullPath = Path.GetFullPath(Path.Combine(basePath, relativePath));
// Sicherheitsprüfung: Kein Ausbruch aus dem Workspace
if (!fullPath.StartsWith(basePath, StringComparison.OrdinalIgnoreCase))
// Sicherheitsprüfung: Kein Ausbruch aus dem Workspace.
//
// PathBoundary statt eines Zeichenketten-Präfixes: Es vergleicht auf
// Verzeichnisgrenzen (sonst gälte "…/Workspace-Backup" als Teil von
// "…/Workspace"), berücksichtigt die Groß-/Kleinschreibung des Dateisystems
// und löst symbolische Verknüpfungen auf.
if (!PathBoundary.IsInside(fullPath, basePath))
{
throw new UnauthorizedAccessException(
$"Zugriff außerhalb des {label} Workspace-Verzeichnisses verweigert.");