From 74c76bb5cea8ff70153a8f9ebe02df6ffb0205f7 Mon Sep 17 00:00:00 2001 From: qvkap Date: Sat, 5 Sep 2026 08:29:46 +0300 Subject: fix: dependency resolution, update file removal and sync TLS validation --- src/delete.rs | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'src/delete.rs') diff --git a/src/delete.rs b/src/delete.rs index 6966f82..094e4c4 100644 --- a/src/delete.rs +++ b/src/delete.rs @@ -175,7 +175,13 @@ pub fn remove_package_files_only(_pkg_name: &str, files: &[String]) -> bool { let mut failed = false; for rel_path in files { - let full_path = Path::new("/").join(rel_path); + let clean = rel_path.trim_start_matches('/'); + if clean.contains("..") || clean.is_empty() { + eprintln!("{} Skipping suspicious path: {}", "[ror]".red().bold(), rel_path); + failed = true; + continue; + } + let full_path = Path::new("/").join(clean); if full_path.exists() { debug!("Removing file {}", full_path.display()); if let Err(e) = fs::remove_file(&full_path) { -- cgit v1.2.3