Stop --chdir from binding the working directory read-write
This commit is contained in:
@@ -66,11 +66,14 @@ impl Sandbox {
|
||||
fn build(prefix: &[&str], extra_args: &[&str], guard: Option<HostGlobsGuard>) -> Self {
|
||||
let mut cmd = Command::new(env!("CARGO_BIN_EXE_agent-sandbox"));
|
||||
cmd.args(prefix);
|
||||
cmd.args(LAUNCH_DIR_WRITABLE);
|
||||
cmd.args(extra_args);
|
||||
Self { cmd, _guard: guard }
|
||||
}
|
||||
}
|
||||
|
||||
const LAUNCH_DIR_WRITABLE: [&str; 2] = ["--rw", "."];
|
||||
|
||||
fn scan_guard_for(extra_args: &[&str]) -> Option<HostGlobsGuard> {
|
||||
extra_args
|
||||
.contains(&"--blacklist")
|
||||
|
||||
Reference in New Issue
Block a user