pub struct SandboxSettings {
pub read_roots: Vec<String>,
pub proxy_port: Option<NonZeroU16>,
pub proxy_allow_ech: bool,
pub proxy_serve_without_credential: bool,
pub package_min_release_age_days: Option<u16>,
pub env: Option<RunEnv>,
pub env_allow: Vec<String>,
pub project_top: ProjectTop,
pub project_hook_off: ProjectHookOff,
pub strict: bool,
}Expand description
The sandbox: section (ADR-018, ADR-019).
Fields§
§read_roots: Vec<String>Paths (directories or files) the OS layers let commands read although no
allow rule covers them: system and toolchain directories every build
reads. The hook decision ignores them, and deny rules win over them in
every layer. Absolute or ~/…, never a glob.
proxy_port: Option<NonZeroU16>The loopback port moat proxy listens on and the host sandboxes send
their commands’ traffic to; absent, the CLI’s default.
proxy_allow_ech: boolLet moat proxy forward a TLS ClientHello that carries an encrypted
server name (ECH, ESNI). Off, such a tunnel is refused: the server acts
on the encrypted name, which may be another site than the allowed host.
proxy_serve_without_credential: boolLet moat proxy serve a request that carries no session credential,
with no session (ADR-044). Off, such a request gets 407: a session’s
taint and connection share cannot be escaped by sending no credential,
and other local processes cannot use the proxy. moat run ignores it.
package_min_release_age_days: Option<u16>Days a package version must have been published before the package
managers moat run starts install it (ADR-030); 0 turns this off,
absent is 7 days (Policy::package_min_release_age_days).
env: Option<RunEnv>Whether openmoat run passes on the whole environment it is started
from or only its allowlist (ADR-105); absent, RunEnv::DEFAULT.
require.run: full-boundary scrubs whatever this says. Read from the
person’s own policy alone: a repository policy or a pack has no
sandbox:.
env_allow: Vec<String>Names of inherited environment variables openmoat run passes on
when it scrubs the environment, beyond its own list and the agent’s
(ADR-077, ADR-105). Names only, never a pattern. Read from the person’s
own policy alone: a repository policy or a pack has no sandbox:.
project_top: ProjectTopWhat openmoat run’s Lightweight tier on Linux without a network
namespace grants at the top of the project (ADR-090): protected
grants it entry by entry, so nothing can be created there and .env,
.git and .moat stay covered; writable grants it whole, so new
entries and save-by-rename work there and those paths are open to the
agent’s commands. Never read by the Isolated tier or the network
namespace. Read from the person’s own policy alone: a repository policy
or a pack has no sandbox:.
project_hook_off: ProjectHookOffWhat openmoat run does when a file of the project would turn the
agent’s OpenMoat hook off as the session starts (ADR-098): refuse
(absent) does not start the agent; start starts it anyway, says so
and records it. Read from the person’s own policy alone: a repository
policy or a pack has no sandbox:.
strict: boolopenmoat run starts only when every kernel feature of its protection
score is in force (ADR-108): planned before the start, confirmed after
it, so a missing Landlock step, a port-only network or the Lightweight
tier refuses the run (fail closed). Read from the person’s own policy
alone: a repository policy or a pack has no sandbox:.