more world-writable warning improvements (#6389)

3 improvements:
1. show up to 3 actual paths that are world-writable
2. do the scan/warning for Read-Only mode too, because it also applies
there
3. remove the "Cancel" option since it doesn't always apply (like on
startup)
This commit is contained in:
iceweasel-oai
2025-11-08 11:35:43 -08:00
committed by GitHub
parent 5beb6167c8
commit a47181e471
5 changed files with 155 additions and 64 deletions

View File

@@ -172,7 +172,7 @@ mod windows_impl {
cwd: &Path,
env_map: &HashMap<String, String>,
logs_base_dir: Option<&Path>,
) -> Result<()> {
) -> Result<Vec<PathBuf>> {
audit::audit_everyone_writable(cwd, env_map, logs_base_dir)
}
@@ -438,7 +438,7 @@ mod stub {
_cwd: &Path,
_env_map: &HashMap<String, String>,
_logs_base_dir: Option<&Path>,
) -> Result<()> {
) -> Result<Vec<std::path::PathBuf>> {
bail!("Windows sandbox is only available on Windows")
}