Tags: Luffytnes/Burrow
Tags
Fix P1 security: validate paths in get_disk_breakdown and start_clama… …v_scan get_disk_breakdown accepted any path from the frontend without validation, allowing a compromised WebView to list protected directories (~/.ssh, ~/.gnupg, etc.) via the directory enumeration and du output. start_clamav_scan accepted arbitrary paths, enabling information disclosure through scan-line events and unintended CPU exhaustion. Additionally, grant_path was called for FOUND files without validating the path first, which could inject entries into the quarantine grant registry for files in forbidden zones. Fixes: - get_disk_breakdown: validate via guard::validate_trash_path before fs::read_dir - start_clamav_scan: filter_map paths through validate_trash_path on entry - start_clamav_scan: guard grant_path calls with validate_trash_path check All 46 cargo tests pass. clippy -D warnings, rustfmt, tsc, eslint --max-warnings=0 and prettier all clean. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>